public static class SharedLinkSettings.Builder
extends java.lang.Object
SharedLinkSettings
.Modifier and Type | Field and Description |
---|---|
protected RequestedLinkAccessLevel |
access |
protected LinkAudience |
audience |
protected java.util.Date |
expires |
protected java.lang.String |
linkPassword |
protected RequestedVisibility |
requestedVisibility |
Modifier | Constructor and Description |
---|---|
protected |
Builder() |
Modifier and Type | Method and Description |
---|---|
SharedLinkSettings |
build()
Builds an instance of
SharedLinkSettings configured with this
builder's values |
SharedLinkSettings.Builder |
withAccess(RequestedLinkAccessLevel access)
Set value for optional field.
|
SharedLinkSettings.Builder |
withAudience(LinkAudience audience)
Set value for optional field.
|
SharedLinkSettings.Builder |
withExpires(java.util.Date expires)
Set value for optional field.
|
SharedLinkSettings.Builder |
withLinkPassword(java.lang.String linkPassword)
Set value for optional field.
|
SharedLinkSettings.Builder |
withRequestedVisibility(RequestedVisibility requestedVisibility)
Set value for optional field.
|
protected RequestedVisibility requestedVisibility
protected java.lang.String linkPassword
protected java.util.Date expires
protected LinkAudience audience
protected RequestedLinkAccessLevel access
public SharedLinkSettings.Builder withRequestedVisibility(RequestedVisibility requestedVisibility)
requestedVisibility
- The requested access for this shared
link.public SharedLinkSettings.Builder withLinkPassword(java.lang.String linkPassword)
linkPassword
- If SharedLinkSettings.getRequestedVisibility()
is RequestedVisibility.PASSWORD
this is needed to specify the
password to access the link.public SharedLinkSettings.Builder withExpires(java.util.Date expires)
expires
- Expiration time of the shared link. By default the
link won't expire.public SharedLinkSettings.Builder withAudience(LinkAudience audience)
audience
- The new audience who can benefit from the access
level specified by the link's access level specified in the
`link_access_level` field of `LinkPermissions`. This is used in
conjunction with team policies and shared folder policies to
determine the final effective audience type in the
`effective_audience` field of `LinkPermissions.public SharedLinkSettings.Builder withAccess(RequestedLinkAccessLevel access)
access
- Requested access level you want the audience to gain
from this link. Note, modifying access level for an existing link
is not supported.public SharedLinkSettings build()
SharedLinkSettings
configured with this
builder's valuesSharedLinkSettings