public abstract class Link extends BaseFssApiResource
UTF_8| Modifier and Type | Method and Description |
|---|---|
static Link |
create(FssApiVersion apiVersion,
java.lang.String url,
java.lang.String path,
java.lang.Long expiration,
boolean publicLink,
java.lang.String accessCode,
java.util.Set<LinkPermission> permission,
java.lang.String token,
LinkType type,
java.lang.String itemName,
boolean accessible)
Returns a versioned Link that is compatible with the specified apiVersion.
|
java.lang.String |
getAccessCode()
Returns the access code for accessing this link.
|
java.lang.Long |
getExpiration()
Returns the number of milliseconds since epoch before this link expires.
|
static java.lang.Class<? extends Link> |
getFssApiClass(FssApiVersion apiVersion)
Returns the
Class of the Link that corresponds to the specified apiVersion. |
java.lang.String |
getItemName()
Returns the name of the file or folder that the link points to (as opposed to path, which is
the full path of the file or folder).
|
java.util.Set<LinkPermission> |
getLinkPermissions()
Returns the
permissions allowed on this
link |
java.lang.String |
getPath()
Returns the path of the link.
|
java.lang.String |
getToken()
Returns the token for the link
|
LinkType |
getType()
Returns the type of object that the link points to (FILE, FOLDER, or BROKEN).
|
java.lang.String |
getUrl()
Returns the URL of the link.
|
java.lang.Boolean |
isAccessible()
Return whether the link is active
|
java.lang.Boolean |
isPublicLink()
Returns whether or not this link is publicly accessible (accessible without a username and
password).
|
protected void |
validate(java.lang.String fieldName,
BaseFssApiResource parent)
Validates this object.
|
badValue, badValue, fromJson, toJson, toJson, toString, validate, validateFieldInRange, validateFieldInRange, validateFieldIsNull, validateFieldNotNull, validateLocale, validateOptionalField, validateOptionalFieldList, validateRequiredField, validateRequiredFieldList, writeToOutputStreampublic static java.lang.Class<? extends Link> getFssApiClass(FssApiVersion apiVersion)
Class of the Link that corresponds to the specified apiVersion.apiVersion - API version of the class to be returnedClass of the Link that corresponds to the specified apiVersionpublic static Link create(FssApiVersion apiVersion, java.lang.String url, java.lang.String path, java.lang.Long expiration, boolean publicLink, java.lang.String accessCode, java.util.Set<LinkPermission> permission, java.lang.String token, LinkType type, java.lang.String itemName, boolean accessible) throws AwUnsupportedApiVersionException
apiVersion - API version to be supported by the Linkurl - url to the linkpath - path to the file or folderexpiration - number of milliseconds since epoch before this link will expirepublicLink - whether or not this link is publicly accessible (accessible without a
username and password)accessCode - the access code for this linkpermission - the permissions for this link (read, write)token - the token used to uniquely identify the linktype - the type of entry (FILE, FOLDER, BROKEN) the link points to.itemName - the name of the entry the link points to.accessible - the status of accessibleAwUnsupportedApiVersionExceptionpublic java.lang.String getUrl()
public java.lang.String getToken()
public java.lang.String getPath()
public java.lang.Long getExpiration()
public java.lang.Boolean isPublicLink()
public java.lang.String getAccessCode()
public LinkType getType()
public java.util.Set<LinkPermission> getLinkPermissions()
permissions allowed on this
linkpermissions allowed on this
linkpublic java.lang.String getItemName()
public java.lang.Boolean isAccessible()
protected void validate(java.lang.String fieldName,
BaseFssApiResource parent)
throws AwJsonException
validate in class BaseFssApiResourcefieldName - name of this object in the parent (containing) object. If this object is a
top-level object (not contained within another object), then enter null for this
parameterparent - parent (containing) object that contains the object specified in the fieldName
parameter. If this object is a top-level object (not contained within another
object), then enter null for this parameterAwJsonException - if any validation errors occurBaseFssApiResource.validate(String, BaseFssApiResource)