Class CostCategoryRule
- java.lang.Object
-
- software.amazon.awssdk.services.costexplorer.model.CostCategoryRule
-
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<CostCategoryRule.Builder,CostCategoryRule>
@Generated("software.amazon.awssdk:codegen") public final class CostCategoryRule extends Object implements SdkPojo, Serializable, ToCopyableBuilder<CostCategoryRule.Builder,CostCategoryRule>
Rules are processed in order. If there are multiple rules that match the line item, then the first rule to match is used to determine that Cost Category value.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceCostCategoryRule.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CostCategoryRule.Builderbuilder()booleanequals(Object obj)booleanequalsBySdkFields(Object obj)<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)inthashCode()CostCategoryInheritedValueDimensioninheritedValue()The value the line item is categorized as if the line item contains the matched dimension.Expressionrule()An Expression object used to categorize costs.List<SdkField<?>>sdkFields()static Class<? extends CostCategoryRule.Builder>serializableBuilderClass()CostCategoryRule.BuildertoBuilder()StringtoString()Returns a string representation of this object.CostCategoryRuleTypetype()You can define theCostCategoryRulerule type as eitherREGULARorINHERITED_VALUE.StringtypeAsString()You can define theCostCategoryRulerule type as eitherREGULARorINHERITED_VALUE.Stringvalue()Returns the value of the Value property for this object.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
value
public final String value()
Returns the value of the Value property for this object.- Returns:
- The value of the Value property for this object.
-
rule
public final Expression rule()
An Expression object used to categorize costs. This supports dimensions, tags, and nested expressions. Currently the only dimensions supported are
LINKED_ACCOUNT,SERVICE_CODE,RECORD_TYPE,LINKED_ACCOUNT_NAME,REGION, andUSAGE_TYPE.RECORD_TYPEis a dimension used for Cost Explorer APIs, and is also supported for Cost Category expressions. This dimension uses different terms, depending on whether you're using the console or API/JSON editor. For a detailed comparison, see Term Comparisons in the Billing and Cost Management User Guide.- Returns:
- An Expression
object used to categorize costs. This supports dimensions, tags, and nested expressions. Currently
the only dimensions supported are
LINKED_ACCOUNT,SERVICE_CODE,RECORD_TYPE,LINKED_ACCOUNT_NAME,REGION, andUSAGE_TYPE.RECORD_TYPEis a dimension used for Cost Explorer APIs, and is also supported for Cost Category expressions. This dimension uses different terms, depending on whether you're using the console or API/JSON editor. For a detailed comparison, see Term Comparisons in the Billing and Cost Management User Guide.
-
inheritedValue
public final CostCategoryInheritedValueDimension inheritedValue()
The value the line item is categorized as if the line item contains the matched dimension.
- Returns:
- The value the line item is categorized as if the line item contains the matched dimension.
-
type
public final CostCategoryRuleType type()
You can define the
CostCategoryRulerule type as eitherREGULARorINHERITED_VALUE. TheINHERITED_VALUErule type adds the flexibility to define a rule that dynamically inherits the cost category value. This value is from the dimension value that's defined byCostCategoryInheritedValueDimension. For example, suppose that you want to costs to be dynamically grouped based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use.If the service returns an enum value that is not available in the current SDK version,
typewill returnCostCategoryRuleType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromtypeAsString().- Returns:
- You can define the
CostCategoryRulerule type as eitherREGULARorINHERITED_VALUE. TheINHERITED_VALUErule type adds the flexibility to define a rule that dynamically inherits the cost category value. This value is from the dimension value that's defined byCostCategoryInheritedValueDimension. For example, suppose that you want to costs to be dynamically grouped based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use. - See Also:
CostCategoryRuleType
-
typeAsString
public final String typeAsString()
You can define the
CostCategoryRulerule type as eitherREGULARorINHERITED_VALUE. TheINHERITED_VALUErule type adds the flexibility to define a rule that dynamically inherits the cost category value. This value is from the dimension value that's defined byCostCategoryInheritedValueDimension. For example, suppose that you want to costs to be dynamically grouped based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use.If the service returns an enum value that is not available in the current SDK version,
typewill returnCostCategoryRuleType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromtypeAsString().- Returns:
- You can define the
CostCategoryRulerule type as eitherREGULARorINHERITED_VALUE. TheINHERITED_VALUErule type adds the flexibility to define a rule that dynamically inherits the cost category value. This value is from the dimension value that's defined byCostCategoryInheritedValueDimension. For example, suppose that you want to costs to be dynamically grouped based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use. - See Also:
CostCategoryRuleType
-
toBuilder
public CostCategoryRule.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<CostCategoryRule.Builder,CostCategoryRule>
-
builder
public static CostCategoryRule.Builder builder()
-
serializableBuilderClass
public static Class<? extends CostCategoryRule.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
-