Struct google_drive2::Permission [−][src]
pub struct Permission { pub domain: Option<String>, pub deleted: Option<bool>, pub email_address: Option<String>, pub expiration_date: Option<String>, pub additional_roles: Option<Vec<String>>, pub with_link: Option<bool>, pub kind: Option<String>, pub name: Option<String>, pub value: Option<String>, pub id: Option<String>, pub auth_key: Option<String>, pub etag: Option<String>, pub role: Option<String>, pub photo_link: Option<String>, pub team_drive_permission_details: Option<Vec<PermissionTeamDrivePermissionDetails>>, pub type_: Option<String>, pub self_link: Option<String>, }
A permission for a file.
Activities
This type is used in activities, which are methods you may call on this type or where this type is involved in. The list links the activity name, along with information about where it is used (one of request and response).
- patch permissions (request|response)
- list permissions (none)
- insert permissions (request|response)
- get permissions (response)
- get id for email permissions (none)
- delete permissions (none)
- update permissions (request|response)
Fields
domain: Option<String>
The domain name of the entity this permission refers to. This is an output-only field which is present when the permission type is user, group or domain.
deleted: Option<bool>
Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
email_address: Option<String>
The email address of the user or group this permission refers to. This is an output-only field which is present when the permission type is user or group.
expiration_date: Option<String>
The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
- They can only be set on user and group permissions
- The date must be in the future
- The date cannot be more than a year in the future
- The date can only be set on drive.permissions.update requests
additional_roles: Option<Vec<String>>
Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
with_link: Option<bool>
Whether the link is required for this permission.
kind: Option<String>
This is always drive#permission.
name: Option<String>
The name for this permission.
value: Option<String>
The email address or domain name for the entity. This is used during inserts and is not populated in responses. When making a drive.permissions.insert request, exactly one of the id or value fields must be specified unless the permission type is anyone, in which case both id and value are ignored.
id: Option<String>
The ID of the user this permission refers to, and identical to the permissionId in the About and Files resources. When making a drive.permissions.insert request, exactly one of the id or value fields must be specified unless the permission type is anyone, in which case both id and value are ignored.
auth_key: Option<String>
Deprecated.
etag: Option<String>
The ETag of the permission.
role: Option<String>
The primary role for this user. While new values may be supported in the future, the following are currently allowed:
- organizer
- owner
- reader
- writer
photo_link: Option<String>
A link to the profile photo, if available.
team_drive_permission_details: Option<Vec<PermissionTeamDrivePermissionDetails>>
Details of whether the permissions on this Team Drive item are inherited or directly on this item. This is an output-only field which is present only for Team Drive items.
type_: Option<String>
The account type. Allowed values are:
- user
- group
- domain
- anyone
self_link: Option<String>
A link back to this permission.
Trait Implementations
impl Default for Permission
[src]
impl Default for Permission
fn default() -> Permission
[src]
fn default() -> Permission
Returns the "default value" for a type. Read more
impl Clone for Permission
[src]
impl Clone for Permission
fn clone(&self) -> Permission
[src]
fn clone(&self) -> Permission
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for Permission
[src]
impl Debug for Permission
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl RequestValue for Permission
[src]
impl RequestValue for Permission
impl Resource for Permission
[src]
impl Resource for Permission
impl ResponseResult for Permission
[src]
impl ResponseResult for Permission
Auto Trait Implementations
impl Send for Permission
impl Send for Permission
impl Sync for Permission
impl Sync for Permission