Package com.oracle.bmc.identity.model
Class Compartment.Builder
- java.lang.Object
-
- com.oracle.bmc.identity.model.Compartment.Builder
-
- Enclosing class:
- Compartment
public static class Compartment.Builder extends Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Compartment
build()
Compartment.Builder
compartmentId(String compartmentId)
The OCID of the parent compartment containing the compartment.Compartment.Builder
copy(Compartment model)
Compartment.Builder
definedTags(Map<String,Map<String,Object>> definedTags)
Defined tags for this resource.Compartment.Builder
description(String description)
The description you assign to the compartment.Compartment.Builder
freeformTags(Map<String,String> freeformTags)
Free-form tags for this resource.Compartment.Builder
id(String id)
The OCID of the compartment.Compartment.Builder
inactiveStatus(Long inactiveStatus)
The detailed status of INACTIVE lifecycleState.Compartment.Builder
isAccessible(Boolean isAccessible)
Indicates whether or not the compartment is accessible for the user making the request.Compartment.Builder
lifecycleState(Compartment.LifecycleState lifecycleState)
The compartment’s current state.Compartment.Builder
name(String name)
The name you assign to the compartment during creation.Compartment.Builder
timeCreated(Date timeCreated)
Date and time the compartment was created, in the format defined by RFC3339.
-
-
-
Method Detail
-
id
public Compartment.Builder id(String id)
The OCID of the compartment.- Parameters:
id
- the value to set- Returns:
- this builder
-
compartmentId
public Compartment.Builder compartmentId(String compartmentId)
The OCID of the parent compartment containing the compartment.- Parameters:
compartmentId
- the value to set- Returns:
- this builder
-
name
public Compartment.Builder name(String name)
The name you assign to the compartment during creation.The name must be unique across all compartments in the parent. Avoid entering confidential information.
- Parameters:
name
- the value to set- Returns:
- this builder
-
description
public Compartment.Builder description(String description)
The description you assign to the compartment.Does not have to be unique, and it’s changeable.
- Parameters:
description
- the value to set- Returns:
- this builder
-
timeCreated
public Compartment.Builder timeCreated(Date timeCreated)
Date and time the compartment was created, in the format defined by RFC3339.Example: 2016-08-25T21:10:29.600Z
- Parameters:
timeCreated
- the value to set- Returns:
- this builder
-
lifecycleState
public Compartment.Builder lifecycleState(Compartment.LifecycleState lifecycleState)
The compartment’s current state.After creating a compartment, make sure its lifecycleState changes from CREATING to ACTIVE before using it.
- Parameters:
lifecycleState
- the value to set- Returns:
- this builder
-
inactiveStatus
public Compartment.Builder inactiveStatus(Long inactiveStatus)
The detailed status of INACTIVE lifecycleState.- Parameters:
inactiveStatus
- the value to set- Returns:
- this builder
-
isAccessible
public Compartment.Builder isAccessible(Boolean isAccessible)
Indicates whether or not the compartment is accessible for the user making the request.Returns true when the user has INSPECT permissions directly on a resource in the compartment or indirectly (permissions can be on a resource in a subcompartment).
- Parameters:
isAccessible
- the value to set- Returns:
- this builder
-
freeformTags
public Compartment.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 Compartment.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
-
build
public Compartment build()
-
copy
public Compartment.Builder copy(Compartment model)
-
-