Show / Hide Table of Contents

Class TagDefault

Tag defaults let you specify a default tag (tagnamespace.tag="value") to apply to all resource types in a specified compartment. The tag default is applied at the time the resource is created. Resources that exist in the compartment before you create the tag default are not tagged.

Inheritance
object
TagDefault
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Oci.GovernancerulescontrolplaneService.Models
Assembly: OCI.DotNetSDK.Governancerulescontrolplane.dll
Syntax
public class TagDefault

Properties

IsRequired

Declaration
[Required(ErrorMessage = "IsRequired is required.")]
[JsonProperty(PropertyName = "isRequired")]
public bool? IsRequired { get; set; }
Property Value
Type Description
bool?

If you specify that a value is required, a value is set during resource creation (either by the user creating the resource or another tag default). If no value is set, resource creation is blocked.

  • If the isRequired flag is set to "true", the value is set during resource creation.
  • If the isRequired flag is set to "false", the value you enter is set during resource creation.
    Example: false
Remarks

Required

TagName

Declaration
[Required(ErrorMessage = "TagName is required.")]
[JsonProperty(PropertyName = "tagName")]
public string TagName { get; set; }
Property Value
Type Description
string

The name of the tag. The tag default will always assign a default value for this tag name.

Remarks

Required

Value

Declaration
[Required(ErrorMessage = "Value is required.")]
[JsonProperty(PropertyName = "value")]
public string Value { get; set; }
Property Value
Type Description
string

The default value for the tag name. This will be applied to all new resources created in the compartment.

Remarks

Required

In this article
Back to top