public static class UserPermissions.Builder
extends java.lang.Object
UserPermissions
.Modifier and Type | Field and Description |
---|---|
protected boolean |
canComment |
protected boolean |
canDownload |
protected boolean |
canEdit |
protected boolean |
canRename |
Modifier | Constructor and Description |
---|---|
protected |
Builder() |
Modifier and Type | Method and Description |
---|---|
UserPermissions |
build()
Builds an instance of
UserPermissions configured with this
builder's values |
UserPermissions.Builder |
withCanComment(java.lang.Boolean canComment)
Set value for optional field.
|
UserPermissions.Builder |
withCanDownload(java.lang.Boolean canDownload)
Set value for optional field.
|
UserPermissions.Builder |
withCanEdit(java.lang.Boolean canEdit)
Set value for optional field.
|
UserPermissions.Builder |
withCanRename(java.lang.Boolean canRename)
Set value for optional field.
|
protected boolean canEdit
protected boolean canRename
protected boolean canComment
protected boolean canDownload
public UserPermissions.Builder withCanEdit(java.lang.Boolean canEdit)
If left unset or set to null
, defaults to false
.
canEdit
- true if the user can edit the content of this
document. Defaults to false
when set to null
.public UserPermissions.Builder withCanRename(java.lang.Boolean canRename)
If left unset or set to null
, defaults to false
.
canRename
- true if the user can edit the title of this
document. Defaults to false
when set to null
.public UserPermissions.Builder withCanComment(java.lang.Boolean canComment)
If left unset or set to null
, defaults to false
.
canComment
- true if the user can comment on this document.
Defaults to false
when set to null
.public UserPermissions.Builder withCanDownload(java.lang.Boolean canDownload)
If left unset or set to null
, defaults to false
.
canDownload
- true if the user can download the contents of
this document. currently always true if the user has view access
to the document. Defaults to false
when set to null
.public UserPermissions build()
UserPermissions
configured with this
builder's valuesUserPermissions