Package com.oracle.bmc.identity.model
Class Tag.Builder
- java.lang.Object
-
- com.oracle.bmc.identity.model.Tag.Builder
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tag
build()
Tag.Builder
compartmentId(String compartmentId)
The OCID of the compartment that contains the tag definition.Tag.Builder
copy(Tag model)
Tag.Builder
definedTags(Map<String,Map<String,Object>> definedTags)
Defined tags for this resource.Tag.Builder
description(String description)
The description you assign to the tag.Tag.Builder
freeformTags(Map<String,String> freeformTags)
Free-form tags for this resource.Tag.Builder
id(String id)
The OCID of the tag definition.Tag.Builder
isCostTracking(Boolean isCostTracking)
Indicates whether the tag is enabled for cost tracking.Tag.Builder
isRetired(Boolean isRetired)
Indicates whether the tag is retired.Tag.Builder
lifecycleState(Tag.LifecycleState lifecycleState)
The tag’s current state.Tag.Builder
name(String name)
The name assigned to the tag during creation.Tag.Builder
tagNamespaceId(String tagNamespaceId)
The OCID of the namespace that contains the tag definition.Tag.Builder
tagNamespaceName(String tagNamespaceName)
The name of the tag namespace that contains the tag definition.Tag.Builder
timeCreated(Date timeCreated)
Date and time the tag was created, in the format defined by RFC3339.Tag.Builder
validator(BaseTagDefinitionValidator validator)
-
-
-
Method Detail
-
compartmentId
public Tag.Builder compartmentId(String compartmentId)
The OCID of the compartment that contains the tag definition.- Parameters:
compartmentId
- the value to set- Returns:
- this builder
-
tagNamespaceId
public Tag.Builder tagNamespaceId(String tagNamespaceId)
The OCID of the namespace that contains the tag definition.- Parameters:
tagNamespaceId
- the value to set- Returns:
- this builder
-
tagNamespaceName
public Tag.Builder tagNamespaceName(String tagNamespaceName)
The name of the tag namespace that contains the tag definition.- Parameters:
tagNamespaceName
- the value to set- Returns:
- this builder
-
id
public Tag.Builder id(String id)
The OCID of the tag definition.- Parameters:
id
- the value to set- Returns:
- this builder
-
name
public Tag.Builder name(String name)
The name assigned to the tag during creation.This is the tag key definition. The name must be unique within the tag namespace and cannot be changed.
- Parameters:
name
- the value to set- Returns:
- this builder
-
description
public Tag.Builder description(String description)
The description you assign to the tag.- Parameters:
description
- the value to set- Returns:
- this builder
-
freeformTags
public Tag.Builder freeformTags(Map<String,String> freeformTags)
Free-form tags for this resource.Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.
Example: {"Department": "Finance"}
- Parameters:
freeformTags
- the value to set- Returns:
- this builder
-
definedTags
public Tag.Builder definedTags(Map<String,Map<String,Object>> definedTags)
Defined tags for this resource.Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
Example: {"Operations": {"CostCenter": "42"}}
- Parameters:
definedTags
- the value to set- Returns:
- this builder
-
isRetired
public Tag.Builder isRetired(Boolean isRetired)
Indicates whether the tag is retired.- Parameters:
isRetired
- the value to set- Returns:
- this builder
-
lifecycleState
public Tag.Builder lifecycleState(Tag.LifecycleState lifecycleState)
The tag’s current state.After creating a tag, make sure its lifecycleState is ACTIVE before using it. After retiring a tag, make sure its lifecycleState is INACTIVE before using it. If you delete a tag, you cannot delete another tag until the deleted tag’s lifecycleState changes from DELETING to DELETED.
- Parameters:
lifecycleState
- the value to set- Returns:
- this builder
-
timeCreated
public Tag.Builder timeCreated(Date timeCreated)
Date and time the tag was created, in the format defined by RFC3339.Example: 2016-08-25T21:10:29.600Z
- Parameters:
timeCreated
- the value to set- Returns:
- this builder
-
isCostTracking
public Tag.Builder isCostTracking(Boolean isCostTracking)
Indicates whether the tag is enabled for cost tracking.- Parameters:
isCostTracking
- the value to set- Returns:
- this builder
-
validator
public Tag.Builder validator(BaseTagDefinitionValidator validator)
-
build
public Tag build()
-
copy
public Tag.Builder copy(Tag model)
-
-