Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
package com.microsoft.graph.models;
import com.microsoft.kiota.serialization.AdditionalDataHolder;
import com.microsoft.kiota.serialization.Parsable;
import com.microsoft.kiota.serialization.ParseNode;
import com.microsoft.kiota.serialization.SerializationWriter;
import com.microsoft.kiota.store.BackedModel;
import com.microsoft.kiota.store.BackingStore;
import com.microsoft.kiota.store.BackingStoreFactorySingleton;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
import java.util.UUID;
@jakarta.annotation.Generated("com.microsoft.kiota")
public class PermissionScope implements AdditionalDataHolder, BackedModel, Parsable {
/**
* Stores model information.
*/
@jakarta.annotation.Nonnull
protected BackingStore backingStore;
/**
* Instantiates a new {@link PermissionScope} and sets the default values.
*/
public PermissionScope() {
this.backingStore = BackingStoreFactorySingleton.instance.createBackingStore();
this.setAdditionalData(new HashMap<>());
}
/**
* Creates a new instance of the appropriate class based on discriminator value
* @param parseNode The parse node to use to read the discriminator value and create the object
* @return a {@link PermissionScope}
*/
@jakarta.annotation.Nonnull
public static PermissionScope createFromDiscriminatorValue(@jakarta.annotation.Nonnull final ParseNode parseNode) {
Objects.requireNonNull(parseNode);
return new PermissionScope();
}
/**
* Gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @return a {@link Map}
*/
@jakarta.annotation.Nonnull
public Map getAdditionalData() {
Map value = this.backingStore.get("additionalData");
if(value == null) {
value = new HashMap<>();
this.setAdditionalData(value);
}
return value;
}
/**
* Gets the adminConsentDescription property value. A description of the delegated permissions, intended to be read by an administrator granting the permission on behalf of all users. This text appears in tenant-wide admin consent experiences.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getAdminConsentDescription() {
return this.backingStore.get("adminConsentDescription");
}
/**
* Gets the adminConsentDisplayName property value. The permission's title, intended to be read by an administrator granting the permission on behalf of all users.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getAdminConsentDisplayName() {
return this.backingStore.get("adminConsentDisplayName");
}
/**
* Gets the backingStore property value. Stores model information.
* @return a {@link BackingStore}
*/
@jakarta.annotation.Nonnull
public BackingStore getBackingStore() {
return this.backingStore;
}
/**
* The deserialization information for the current model
* @return a {@link Map>}
*/
@jakarta.annotation.Nonnull
public Map> getFieldDeserializers() {
final HashMap> deserializerMap = new HashMap>(10);
deserializerMap.put("adminConsentDescription", (n) -> { this.setAdminConsentDescription(n.getStringValue()); });
deserializerMap.put("adminConsentDisplayName", (n) -> { this.setAdminConsentDisplayName(n.getStringValue()); });
deserializerMap.put("id", (n) -> { this.setId(n.getUUIDValue()); });
deserializerMap.put("isEnabled", (n) -> { this.setIsEnabled(n.getBooleanValue()); });
deserializerMap.put("@odata.type", (n) -> { this.setOdataType(n.getStringValue()); });
deserializerMap.put("origin", (n) -> { this.setOrigin(n.getStringValue()); });
deserializerMap.put("type", (n) -> { this.setType(n.getStringValue()); });
deserializerMap.put("userConsentDescription", (n) -> { this.setUserConsentDescription(n.getStringValue()); });
deserializerMap.put("userConsentDisplayName", (n) -> { this.setUserConsentDisplayName(n.getStringValue()); });
deserializerMap.put("value", (n) -> { this.setValue(n.getStringValue()); });
return deserializerMap;
}
/**
* Gets the id property value. Unique delegated permission identifier inside the collection of delegated permissions defined for a resource application.
* @return a {@link UUID}
*/
@jakarta.annotation.Nullable
public UUID getId() {
return this.backingStore.get("id");
}
/**
* Gets the isEnabled property value. When you create or update a permission, this property must be set to true (which is the default). To delete a permission, this property must first be set to false. At that point, in a subsequent call, the permission may be removed.
* @return a {@link Boolean}
*/
@jakarta.annotation.Nullable
public Boolean getIsEnabled() {
return this.backingStore.get("isEnabled");
}
/**
* Gets the @odata.type property value. The OdataType property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getOdataType() {
return this.backingStore.get("odataType");
}
/**
* Gets the origin property value. The origin property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getOrigin() {
return this.backingStore.get("origin");
}
/**
* Gets the type property value. The possible values are: User and Admin. Specifies whether this delegated permission should be considered safe for non-admin users to consent to on behalf of themselves, or whether an administrator consent should always be required. While Microsoft Graph defines the default consent requirement for each permission, the tenant administrator may override the behavior in their organization (by allowing, restricting, or limiting user consent to this delegated permission). For more information, see Configure how users consent to applications.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getType() {
return this.backingStore.get("type");
}
/**
* Gets the userConsentDescription property value. A description of the delegated permissions, intended to be read by a user granting the permission on their own behalf. This text appears in consent experiences where the user is consenting only on behalf of themselves.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getUserConsentDescription() {
return this.backingStore.get("userConsentDescription");
}
/**
* Gets the userConsentDisplayName property value. A title for the permission, intended to be read by a user granting the permission on their own behalf. This text appears in consent experiences where the user is consenting only on behalf of themselves.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getUserConsentDisplayName() {
return this.backingStore.get("userConsentDisplayName");
}
/**
* Gets the value property value. Specifies the value to include in the scp (scope) claim in access tokens. Must not exceed 120 characters in length. Allowed characters are : ! # $ % & ' ( ) * + , - . / : ; = ? @ [ ] ^ + _ { } ~, and characters in the ranges 0-9, A-Z and a-z. Any other character, including the space character, aren't allowed. May not begin with ..
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getValue() {
return this.backingStore.get("value");
}
/**
* Serializes information the current object
* @param writer Serialization writer to use to serialize this model
*/
public void serialize(@jakarta.annotation.Nonnull final SerializationWriter writer) {
Objects.requireNonNull(writer);
writer.writeStringValue("adminConsentDescription", this.getAdminConsentDescription());
writer.writeStringValue("adminConsentDisplayName", this.getAdminConsentDisplayName());
writer.writeUUIDValue("id", this.getId());
writer.writeBooleanValue("isEnabled", this.getIsEnabled());
writer.writeStringValue("@odata.type", this.getOdataType());
writer.writeStringValue("origin", this.getOrigin());
writer.writeStringValue("type", this.getType());
writer.writeStringValue("userConsentDescription", this.getUserConsentDescription());
writer.writeStringValue("userConsentDisplayName", this.getUserConsentDisplayName());
writer.writeStringValue("value", this.getValue());
writer.writeAdditionalData(this.getAdditionalData());
}
/**
* Sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @param value Value to set for the AdditionalData property.
*/
public void setAdditionalData(@jakarta.annotation.Nullable final Map value) {
this.backingStore.set("additionalData", value);
}
/**
* Sets the adminConsentDescription property value. A description of the delegated permissions, intended to be read by an administrator granting the permission on behalf of all users. This text appears in tenant-wide admin consent experiences.
* @param value Value to set for the adminConsentDescription property.
*/
public void setAdminConsentDescription(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("adminConsentDescription", value);
}
/**
* Sets the adminConsentDisplayName property value. The permission's title, intended to be read by an administrator granting the permission on behalf of all users.
* @param value Value to set for the adminConsentDisplayName property.
*/
public void setAdminConsentDisplayName(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("adminConsentDisplayName", value);
}
/**
* Sets the backingStore property value. Stores model information.
* @param value Value to set for the backingStore property.
*/
public void setBackingStore(@jakarta.annotation.Nonnull final BackingStore value) {
Objects.requireNonNull(value);
this.backingStore = value;
}
/**
* Sets the id property value. Unique delegated permission identifier inside the collection of delegated permissions defined for a resource application.
* @param value Value to set for the id property.
*/
public void setId(@jakarta.annotation.Nullable final UUID value) {
this.backingStore.set("id", value);
}
/**
* Sets the isEnabled property value. When you create or update a permission, this property must be set to true (which is the default). To delete a permission, this property must first be set to false. At that point, in a subsequent call, the permission may be removed.
* @param value Value to set for the isEnabled property.
*/
public void setIsEnabled(@jakarta.annotation.Nullable final Boolean value) {
this.backingStore.set("isEnabled", value);
}
/**
* Sets the @odata.type property value. The OdataType property
* @param value Value to set for the @odata.type property.
*/
public void setOdataType(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("odataType", value);
}
/**
* Sets the origin property value. The origin property
* @param value Value to set for the origin property.
*/
public void setOrigin(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("origin", value);
}
/**
* Sets the type property value. The possible values are: User and Admin. Specifies whether this delegated permission should be considered safe for non-admin users to consent to on behalf of themselves, or whether an administrator consent should always be required. While Microsoft Graph defines the default consent requirement for each permission, the tenant administrator may override the behavior in their organization (by allowing, restricting, or limiting user consent to this delegated permission). For more information, see Configure how users consent to applications.
* @param value Value to set for the type property.
*/
public void setType(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("type", value);
}
/**
* Sets the userConsentDescription property value. A description of the delegated permissions, intended to be read by a user granting the permission on their own behalf. This text appears in consent experiences where the user is consenting only on behalf of themselves.
* @param value Value to set for the userConsentDescription property.
*/
public void setUserConsentDescription(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("userConsentDescription", value);
}
/**
* Sets the userConsentDisplayName property value. A title for the permission, intended to be read by a user granting the permission on their own behalf. This text appears in consent experiences where the user is consenting only on behalf of themselves.
* @param value Value to set for the userConsentDisplayName property.
*/
public void setUserConsentDisplayName(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("userConsentDisplayName", value);
}
/**
* Sets the value property value. Specifies the value to include in the scp (scope) claim in access tokens. Must not exceed 120 characters in length. Allowed characters are : ! # $ % & ' ( ) * + , - . / : ; = ? @ [ ] ^ + _ { } ~, and characters in the ranges 0-9, A-Z and a-z. Any other character, including the space character, aren't allowed. May not begin with ..
* @param value Value to set for the value property.
*/
public void setValue(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("value", value);
}
}