public class Document extends RepositoryEntity<RepositoryAPI,Document>
| Modifier and Type | Class and Description |
|---|---|
static class |
Document.AbstractAdapter<A extends Document.AbstractAdapter<A>>
Adapter is basic class to handle requests against web adapters.
|
static class |
Document.Adapter
Adapter is basic class to handle requests against web adapters.
|
| Modifier and Type | Field and Description |
|---|---|
protected String |
changeToken |
protected Map<String,Object> |
contextParameters |
static String |
DEFAULT_FILE_CONTENT |
protected static String |
DELETED_STATE |
protected Map<String,Object> |
dirtyProperties |
protected List<String> |
facets |
protected String |
isCheckedOut |
protected boolean |
isProxy |
protected Boolean |
isTrashed |
protected String |
lastModified |
protected String |
lockCreated |
protected String |
lockOwner |
protected String |
name |
protected String |
parentRef |
protected String |
path |
protected Map<String,Object> |
properties |
protected String |
state |
protected String |
title |
protected String |
type |
protected String |
uid |
protected String |
versionLabel |
repositoryNameentityTypeapi, apiClass, nuxeoClientheaderInterceptors, headerValues, okhttpBuilder, retrofit, retrofitBuilder| Modifier | Constructor and Description |
|---|---|
protected |
Document()
For internal marshalling purpose.
|
protected |
Document(Document document)
This constructor is providing a way to create 'adapters' of a document.
|
protected |
Document(String uid,
String type)
Protected constructor for adapters implementation.
|
| Modifier and Type | Method and Description |
|---|---|
<A extends Document.AbstractAdapter> |
adapter(Function<Document,A> creator)
Gets an
adapter object to build requests against Nuxeo Server Web Adapter. |
Document.Adapter |
adapter(String adapter)
Gets an
adapter object to build requests against Nuxeo Server Web Adapter. |
Document |
addInvitation(ACE ace,
String email)
Add permission on the current document by passing the related email.
|
void |
addInvitation(ACE ace,
String email,
retrofit2.Callback<Document> callback)
Add permission on the current document by passing the related email.
|
Document |
addPermission(ACE ace)
Add permission on the current document.
|
void |
addPermission(ACE ace,
retrofit2.Callback<Document> callback)
Add permission on the current document.
|
static Document |
createWithId(String uid,
String type)
Regular way to instantiate a
Document in order to update it. |
static Document |
createWithName(String name,
String type)
Regular way to instantiate a
Document in order to create it. |
Audit |
fetchAudit() |
void |
fetchAudit(retrofit2.Callback<Audit> callback) |
FileBlob |
fetchBlob()
Deprecated.
since 3.1, use
streamBlob() instead |
void |
fetchBlob(retrofit2.Callback<FileBlob> callback)
Deprecated.
since 3.1, use
streamBlob(Callback) instead |
FileBlob |
fetchBlob(String fieldPath)
Deprecated.
since 3.1, use
streamBlob(String) instead |
void |
fetchBlob(String fieldPath,
retrofit2.Callback<FileBlob> callback)
Deprecated.
since 3.1, use
streamBlob(String, Callback) instead |
Documents |
fetchChildren() |
void |
fetchChildren(retrofit2.Callback<Documents> callback) |
ACP |
fetchPermissions() |
void |
fetchPermissions(retrofit2.Callback<ACP> callback) |
Task |
fetchTask()
Deprecated.
since 3.2, this method has never worked, use
fetchTasks() instead |
Tasks |
fetchTasks() |
Workflows |
fetchWorkflowInstances() |
void |
fetchWorkflowInstances(retrofit2.Callback<Workflows> callback) |
String |
getChangeToken() |
<T> T |
getContextParameter(String key) |
Map<String,Object> |
getContextParameters() |
Map<String,Object> |
getDirtyProperties()
Get the dirty properties.
|
List<String> |
getFacets() |
String |
getId() |
String |
getIsCheckedOut() |
String |
getLastModified() |
String |
getLock() |
String |
getLockCreated() |
String |
getLockOwner() |
String |
getName() |
String |
getParentRef() |
String |
getPath() |
Map<String,Object> |
getProperties() |
<T> T |
getPropertyValue(String key) |
String |
getState() |
String |
getTitle() |
String |
getType() |
String |
getUid() |
String |
getVersionLabel() |
Boolean |
isCheckedOut() |
boolean |
isLocked() |
boolean |
isProxy()
CAUTION: Only available for Nuxeo Server greater than LTS 2016 - 8.10
|
boolean |
isTrashed() |
void |
reconnectWith(NuxeoClient nuxeoClient) |
void |
removePermission(String username)
Remove all permissions for a given username on the current document.
|
void |
removePermission(String aceId,
String username,
String aclName)
Remove all permissions for a given username, ace id, acl name on the current document.
|
void |
setContextParameters(Map<String,Object> contextParameters) |
void |
setDirtyProperties(Map<String,Object> dirtyProperties) |
void |
setProperties(Map<String,Object> properties)
Sets several properties in one call, this method will also put input properties to dirty properties.
|
void |
setPropertyValue(String key,
Object value)
Sets one property value, property's value will also be put to dirty properties.
|
Workflow |
startWorkflowInstance(Workflow workflow) |
void |
startWorkflowInstance(Workflow workflow,
retrofit2.Callback<Workflow> callback) |
StreamBlob |
streamBlob() |
void |
streamBlob(retrofit2.Callback<StreamBlob> callback) |
StreamBlob |
streamBlob(String fieldPath) |
void |
streamBlob(String fieldPath,
retrofit2.Callback<StreamBlob> callback) |
protected Map<String,Object> |
toAutomationParameters(ACE ace) |
Document |
trash()
This API is available since Nuxeo Server 10.2.
|
Document |
untrash()
This API is available since Nuxeo Server 10.2.
|
Document |
updateDocument() |
getRepositoryNamegetEntityTypebuildRetrofit, fetchResponse, fetchResponseconnectTimeout, depth, enrichers, enrichers, enrichersForDocument, fetchProperties, fetchProperties, fetchPropertiesForDocument, fetchPropertiesForGroup, header, header, header, header, header, header, header, readTimeout, replaceWith, schemas, schemas, timeout, transactionTimeout, versionpublic static final String DEFAULT_FILE_CONTENT
protected static final String DELETED_STATE
protected String path
protected String type
protected String state
protected String lockOwner
protected String lockCreated
protected String versionLabel
protected String isCheckedOut
protected String lastModified
protected String changeToken
protected String parentRef
protected String uid
protected String title
protected String name
protected boolean isProxy
protected Boolean isTrashed
protected Document()
protected Document(String uid, String type)
protected Document(Document document)
document - the document to copy from the sub class.public static Document createWithId(String uid, String type)
Document in order to update it.public static Document createWithName(String name, String type)
Document in order to create it.public String getId()
public String getPath()
public String getType()
public String getLock()
public String getLockOwner()
public String getLockCreated()
public boolean isLocked()
public String getState()
public String getVersionLabel()
public Boolean isCheckedOut()
public String getTitle()
public String getChangeToken()
public String getIsCheckedOut()
public String getParentRef()
public String getUid()
public String getLastModified()
public String getName()
public <T> T getPropertyValue(String key)
public void setPropertyValue(String key, Object value)
public void setProperties(Map<String,Object> properties)
public <T> T getContextParameter(String key)
public Document updateDocument()
public Audit fetchAudit()
public void fetchAudit(retrofit2.Callback<Audit> callback)
public ACP fetchPermissions()
public Document addPermission(ACE ace)
ace - the permission.public Document addInvitation(ACE ace, String email)
ace - the permission.email - the invited email.public void removePermission(String username)
username - User Name.public void removePermission(String aceId, String username, String aclName)
aceId - ACE ID.username - User Name.aclName - Name of the ACL (local, inherited...).public void fetchPermissions(retrofit2.Callback<ACP> callback)
public void addPermission(ACE ace, retrofit2.Callback<Document> callback)
ace - the permission.public void addInvitation(ACE ace, String email, retrofit2.Callback<Document> callback)
ace - the permission.email - the invited email.public Documents fetchChildren()
public void fetchChildren(retrofit2.Callback<Documents> callback)
@Deprecated public FileBlob fetchBlob()
streamBlob() instead@Deprecated public FileBlob fetchBlob(String fieldPath)
streamBlob(String) insteadpublic StreamBlob streamBlob()
public StreamBlob streamBlob(String fieldPath)
@Deprecated public void fetchBlob(retrofit2.Callback<FileBlob> callback)
streamBlob(Callback) instead@Deprecated public void fetchBlob(String fieldPath, retrofit2.Callback<FileBlob> callback)
streamBlob(String, Callback) insteadpublic void streamBlob(retrofit2.Callback<StreamBlob> callback)
public void streamBlob(String fieldPath, retrofit2.Callback<StreamBlob> callback)
public Workflows fetchWorkflowInstances()
public void fetchWorkflowInstances(retrofit2.Callback<Workflows> callback)
public void startWorkflowInstance(Workflow workflow, retrofit2.Callback<Workflow> callback)
@Deprecated public Task fetchTask()
fetchTasks() insteadpublic Tasks fetchTasks()
public boolean isProxy()
public boolean isTrashed()
public Document trash()
public Document untrash()
public Document.Adapter adapter(String adapter)
adapter object to build requests against Nuxeo Server Web Adapter.adapter - the adapter to hitpublic <A extends Document.AbstractAdapter> A adapter(Function<Document,A> creator)
adapter object to build requests against Nuxeo Server Web Adapter.creator - the function used to instantiate a specific adapterpublic void reconnectWith(NuxeoClient nuxeoClient)
reconnectWith in interface ConnectablereconnectWith in class AbstractConnectable<RepositoryAPI,Document>Copyright © 2018 Nuxeo. All rights reserved.