Class UnifiedRoleDefinition

java.lang.Object
com.microsoft.graph.models.Entity
com.microsoft.graph.models.UnifiedRoleDefinition
All Implemented Interfaces:
com.microsoft.kiota.serialization.AdditionalDataHolder, com.microsoft.kiota.serialization.Parsable, com.microsoft.kiota.store.BackedModel

@Generated("com.microsoft.kiota") public class UnifiedRoleDefinition extends Entity implements com.microsoft.kiota.serialization.Parsable
  • Constructor Details

    • UnifiedRoleDefinition

      public UnifiedRoleDefinition()
      Instantiates a new UnifiedRoleDefinition and sets the default values.
  • Method Details

    • createFromDiscriminatorValue

      @Nonnull public static UnifiedRoleDefinition createFromDiscriminatorValue(@Nonnull com.microsoft.kiota.serialization.ParseNode parseNode)
      Creates a new instance of the appropriate class based on discriminator value
      Parameters:
      parseNode - The parse node to use to read the discriminator value and create the object
      Returns:
      a UnifiedRoleDefinition
    • getDescription

      @Nullable public String getDescription()
      Gets the description property value. The description for the unifiedRoleDefinition. Read-only when isBuiltIn is true.
      Returns:
      a String
    • getDisplayName

      @Nullable public String getDisplayName()
      Gets the displayName property value. The display name for the unifiedRoleDefinition. Read-only when isBuiltIn is true. Required. Supports $filter (eq, in).
      Returns:
      a String
    • getFieldDeserializers

      @Nonnull public Map<String,Consumer<com.microsoft.kiota.serialization.ParseNode>> getFieldDeserializers()
      The deserialization information for the current model
      Specified by:
      getFieldDeserializers in interface com.microsoft.kiota.serialization.Parsable
      Overrides:
      getFieldDeserializers in class Entity
      Returns:
      a Map<String,Consumer<com.microsoft.kiota.serialization.ParseNode>>
    • getInheritsPermissionsFrom

      @Nullable public List<UnifiedRoleDefinition> getInheritsPermissionsFrom()
      Gets the inheritsPermissionsFrom property value. Read-only collection of role definitions that the given role definition inherits from. Only Microsoft Entra built-in roles (isBuiltIn is true) support this attribute. Supports $expand.
      Returns:
      a List<UnifiedRoleDefinition>
    • getIsBuiltIn

      @Nullable public Boolean getIsBuiltIn()
      Gets the isBuiltIn property value. Flag indicating whether the role definition is part of the default set included in Microsoft Entra or a custom definition. Read-only. Supports $filter (eq, in).
      Returns:
      a Boolean
    • getIsEnabled

      @Nullable public Boolean getIsEnabled()
      Gets the isEnabled property value. Flag indicating whether the role is enabled for assignment. If false the role is not available for assignment. Read-only when isBuiltIn is true.
      Returns:
      a Boolean
    • getResourceScopes

      @Nullable public List<String> getResourceScopes()
      Gets the resourceScopes property value. List of the scopes or permissions the role definition applies to. Currently only / is supported. Read-only when isBuiltIn is true. DO NOT USE. This will be deprecated soon. Attach scope to role assignment.
      Returns:
      a List<String>
    • getRolePermissions

      @Nullable public List<UnifiedRolePermission> getRolePermissions()
      Gets the rolePermissions property value. List of permissions included in the role. Read-only when isBuiltIn is true. Required.
      Returns:
      a List<UnifiedRolePermission>
    • getTemplateId

      @Nullable public String getTemplateId()
      Gets the templateId property value. Custom template identifier that can be set when isBuiltIn is false but is read-only when isBuiltIn is true. This identifier is typically used if one needs an identifier to be the same across different directories.
      Returns:
      a String
    • getVersion

      @Nullable public String getVersion()
      Gets the version property value. Indicates version of the role definition. Read-only when isBuiltIn is true.
      Returns:
      a String
    • serialize

      public void serialize(@Nonnull com.microsoft.kiota.serialization.SerializationWriter writer)
      Serializes information the current object
      Specified by:
      serialize in interface com.microsoft.kiota.serialization.Parsable
      Overrides:
      serialize in class Entity
      Parameters:
      writer - Serialization writer to use to serialize this model
    • setDescription

      public void setDescription(@Nullable String value)
      Sets the description property value. The description for the unifiedRoleDefinition. Read-only when isBuiltIn is true.
      Parameters:
      value - Value to set for the description property.
    • setDisplayName

      public void setDisplayName(@Nullable String value)
      Sets the displayName property value. The display name for the unifiedRoleDefinition. Read-only when isBuiltIn is true. Required. Supports $filter (eq, in).
      Parameters:
      value - Value to set for the displayName property.
    • setInheritsPermissionsFrom

      public void setInheritsPermissionsFrom(@Nullable List<UnifiedRoleDefinition> value)
      Sets the inheritsPermissionsFrom property value. Read-only collection of role definitions that the given role definition inherits from. Only Microsoft Entra built-in roles (isBuiltIn is true) support this attribute. Supports $expand.
      Parameters:
      value - Value to set for the inheritsPermissionsFrom property.
    • setIsBuiltIn

      public void setIsBuiltIn(@Nullable Boolean value)
      Sets the isBuiltIn property value. Flag indicating whether the role definition is part of the default set included in Microsoft Entra or a custom definition. Read-only. Supports $filter (eq, in).
      Parameters:
      value - Value to set for the isBuiltIn property.
    • setIsEnabled

      public void setIsEnabled(@Nullable Boolean value)
      Sets the isEnabled property value. Flag indicating whether the role is enabled for assignment. If false the role is not available for assignment. Read-only when isBuiltIn is true.
      Parameters:
      value - Value to set for the isEnabled property.
    • setResourceScopes

      public void setResourceScopes(@Nullable List<String> value)
      Sets the resourceScopes property value. List of the scopes or permissions the role definition applies to. Currently only / is supported. Read-only when isBuiltIn is true. DO NOT USE. This will be deprecated soon. Attach scope to role assignment.
      Parameters:
      value - Value to set for the resourceScopes property.
    • setRolePermissions

      public void setRolePermissions(@Nullable List<UnifiedRolePermission> value)
      Sets the rolePermissions property value. List of permissions included in the role. Read-only when isBuiltIn is true. Required.
      Parameters:
      value - Value to set for the rolePermissions property.
    • setTemplateId

      public void setTemplateId(@Nullable String value)
      Sets the templateId property value. Custom template identifier that can be set when isBuiltIn is false but is read-only when isBuiltIn is true. This identifier is typically used if one needs an identifier to be the same across different directories.
      Parameters:
      value - Value to set for the templateId property.
    • setVersion

      public void setVersion(@Nullable String value)
      Sets the version property value. Indicates version of the role definition. Read-only when isBuiltIn is true.
      Parameters:
      value - Value to set for the version property.