MicrosoftGraphPermission Class

public final class MicrosoftGraphPermission
extends MicrosoftGraphEntity

permission.

Constructor Summary

Constructor Description
MicrosoftGraphPermission()

Creates an instance of MicrosoftGraphPermission class.

Method Summary

Modifier and Type Method and Description
Map<String,Object> additionalProperties()

Get the additionalProperties property: permission.

OffsetDateTime expirationDateTime()

Get the expirationDateTime property: A format of yyyy-MM-ddTHH:mm:ssZ of DateTimeOffset indicates the expiration time of the permission.

static MicrosoftGraphPermission fromJson(JsonReader jsonReader)

Reads an instance of MicrosoftGraphPermission from the JsonReader.

MicrosoftGraphIdentitySet grantedTo()

Get the grantedTo property: identitySet.

List<MicrosoftGraphIdentitySet> grantedToIdentities()

Get the grantedToIdentities property: For link type permissions, the details of the users to whom permission was granted.

Boolean hasPassword()

Get the hasPassword property: This indicates whether password is set for this permission, it's only showing in response.

MicrosoftGraphItemReference inheritedFrom()

Get the inheritedFrom property: itemReference.

MicrosoftGraphSharingInvitation invitation()

Get the invitation property: sharingInvitation.

MicrosoftGraphSharingLink link()

Get the link property: sharingLink.

List<String> roles()

Get the roles property: The type of permission, e.g.

String shareId()

Get the shareId property: A unique token that can be used to access this shared item via the **shares** API.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

MicrosoftGraphPermission withAdditionalProperties(Map<String,Object> additionalProperties)

Set the additionalProperties property: permission.

MicrosoftGraphPermission withExpirationDateTime(OffsetDateTime expirationDateTime)

Set the expirationDateTime property: A format of yyyy-MM-ddTHH:mm:ssZ of DateTimeOffset indicates the expiration time of the permission.

MicrosoftGraphPermission withGrantedTo(MicrosoftGraphIdentitySet grantedTo)

Set the grantedTo property: identitySet.

MicrosoftGraphPermission withGrantedToIdentities(List<MicrosoftGraphIdentitySet> grantedToIdentities)

Set the grantedToIdentities property: For link type permissions, the details of the users to whom permission was granted.

MicrosoftGraphPermission withHasPassword(Boolean hasPassword)

Set the hasPassword property: This indicates whether password is set for this permission, it's only showing in response.

MicrosoftGraphPermission withId(String id)

Set the id property: Read-only.

MicrosoftGraphPermission withInheritedFrom(MicrosoftGraphItemReference inheritedFrom)

Set the inheritedFrom property: itemReference.

MicrosoftGraphPermission withInvitation(MicrosoftGraphSharingInvitation invitation)

Set the invitation property: sharingInvitation.

MicrosoftGraphPermission withLink(MicrosoftGraphSharingLink link)

Set the link property: sharingLink.

MicrosoftGraphPermission withRoles(List<String> roles)

Set the roles property: The type of permission, e.g.

MicrosoftGraphPermission withShareId(String shareId)

Set the shareId property: A unique token that can be used to access this shared item via the **shares** API.

Methods inherited from MicrosoftGraphEntity

Methods inherited from java.lang.Object

Constructor Details

MicrosoftGraphPermission

public MicrosoftGraphPermission()

Creates an instance of MicrosoftGraphPermission class.

Method Details

additionalProperties

public Map additionalProperties()

Get the additionalProperties property: permission.

Overrides:

MicrosoftGraphPermission.additionalProperties()

Returns:

the additionalProperties value.

expirationDateTime

public OffsetDateTime expirationDateTime()

Get the expirationDateTime property: A format of yyyy-MM-ddTHH:mm:ssZ of DateTimeOffset indicates the expiration time of the permission. DateTime.MinValue indicates there is no expiration set for this permission. Optional.

Returns:

the expirationDateTime value.

fromJson

public static MicrosoftGraphPermission fromJson(JsonReader jsonReader)

Reads an instance of MicrosoftGraphPermission from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of MicrosoftGraphPermission if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the MicrosoftGraphPermission.

grantedTo

public MicrosoftGraphIdentitySet grantedTo()

Get the grantedTo property: identitySet.

Returns:

the grantedTo value.

grantedToIdentities

public List grantedToIdentities()

Get the grantedToIdentities property: For link type permissions, the details of the users to whom permission was granted. Read-only.

Returns:

the grantedToIdentities value.

hasPassword

public Boolean hasPassword()

Get the hasPassword property: This indicates whether password is set for this permission, it's only showing in response. Optional and Read-only and for OneDrive Personal only.

Returns:

the hasPassword value.

inheritedFrom

public MicrosoftGraphItemReference inheritedFrom()

Get the inheritedFrom property: itemReference.

Returns:

the inheritedFrom value.

invitation

public MicrosoftGraphSharingInvitation invitation()

Get the invitation property: sharingInvitation.

Returns:

the invitation value.

link

public MicrosoftGraphSharingLink link()

Get the link property: sharingLink.

Returns:

the link value.

roles

public List roles()

Get the roles property: The type of permission, e.g. read. See below for the full list of roles. Read-only.

Returns:

the roles value.

shareId

public String shareId()

Get the shareId property: A unique token that can be used to access this shared item via the **shares** API. Read-only.

Returns:

the shareId value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

MicrosoftGraphPermission.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

Overrides:

MicrosoftGraphPermission.validate()

withAdditionalProperties

public MicrosoftGraphPermission withAdditionalProperties(Map additionalProperties)

Set the additionalProperties property: permission.

Overrides:

MicrosoftGraphPermission.withAdditionalProperties(Map<String,Object> additionalProperties)

Parameters:

additionalProperties - the additionalProperties value to set.

Returns:

the MicrosoftGraphPermission object itself.

withExpirationDateTime

public MicrosoftGraphPermission withExpirationDateTime(OffsetDateTime expirationDateTime)

Set the expirationDateTime property: A format of yyyy-MM-ddTHH:mm:ssZ of DateTimeOffset indicates the expiration time of the permission. DateTime.MinValue indicates there is no expiration set for this permission. Optional.

Parameters:

expirationDateTime - the expirationDateTime value to set.

Returns:

the MicrosoftGraphPermission object itself.

withGrantedTo

public MicrosoftGraphPermission withGrantedTo(MicrosoftGraphIdentitySet grantedTo)

Set the grantedTo property: identitySet.

Parameters:

grantedTo - the grantedTo value to set.

Returns:

the MicrosoftGraphPermission object itself.

withGrantedToIdentities

public MicrosoftGraphPermission withGrantedToIdentities(List grantedToIdentities)

Set the grantedToIdentities property: For link type permissions, the details of the users to whom permission was granted. Read-only.

Parameters:

grantedToIdentities - the grantedToIdentities value to set.

Returns:

the MicrosoftGraphPermission object itself.

withHasPassword

public MicrosoftGraphPermission withHasPassword(Boolean hasPassword)

Set the hasPassword property: This indicates whether password is set for this permission, it's only showing in response. Optional and Read-only and for OneDrive Personal only.

Parameters:

hasPassword - the hasPassword value to set.

Returns:

the MicrosoftGraphPermission object itself.

withId

public MicrosoftGraphPermission withId(String id)

Set the id property: Read-only.

Overrides:

MicrosoftGraphPermission.withId(String id)

Parameters:

id

withInheritedFrom

public MicrosoftGraphPermission withInheritedFrom(MicrosoftGraphItemReference inheritedFrom)

Set the inheritedFrom property: itemReference.

Parameters:

inheritedFrom - the inheritedFrom value to set.

Returns:

the MicrosoftGraphPermission object itself.

withInvitation

public MicrosoftGraphPermission withInvitation(MicrosoftGraphSharingInvitation invitation)

Set the invitation property: sharingInvitation.

Parameters:

invitation - the invitation value to set.

Returns:

the MicrosoftGraphPermission object itself.

withLink

public MicrosoftGraphPermission withLink(MicrosoftGraphSharingLink link)

Set the link property: sharingLink.

Parameters:

link - the link value to set.

Returns:

the MicrosoftGraphPermission object itself.

withRoles

public MicrosoftGraphPermission withRoles(List roles)

Set the roles property: The type of permission, e.g. read. See below for the full list of roles. Read-only.

Parameters:

roles - the roles value to set.

Returns:

the MicrosoftGraphPermission object itself.

withShareId

public MicrosoftGraphPermission withShareId(String shareId)

Set the shareId property: A unique token that can be used to access this shared item via the **shares** API. Read-only.

Parameters:

shareId - the shareId value to set.

Returns:

the MicrosoftGraphPermission object itself.

Applies to