Class UserWorkspaceTopLevelFolderItem
java.lang.Object
org.nuxeo.drive.adapter.impl.AbstractFileSystemItem
org.nuxeo.drive.adapter.impl.AbstractDocumentBackedFileSystemItem
org.nuxeo.drive.adapter.impl.DocumentBackedFolderItem
org.nuxeo.drive.hierarchy.userworkspace.adapter.UserWorkspaceTopLevelFolderItem
- All Implemented Interfaces:
Comparable<FileSystemItem>
,FileSystemItem
,FolderItem
User workspace based implementation of the top level
FolderItem
.
Implements the following tree:
Nuxeo Drive |-- User workspace child 1 |-- User workspace child 2 |-- ... |-- My synchronized folders |-- Synchronized folder 1 |-- Synchronized folder 2 |-- ...
- Author:
- Antoine Taillefer
-
Field Summary
Fields inherited from class org.nuxeo.drive.adapter.impl.DocumentBackedFolderItem
canCreateChild, canScrollDescendants, DESCENDANTS_SCROLL_CACHE, MAX_DESCENDANTS_BATCH_SIZE_DEFAULT, MAX_DESCENDANTS_BATCH_SIZE_PROPERTY, VCS_CHUNK_SIZE
Fields inherited from class org.nuxeo.drive.adapter.impl.AbstractDocumentBackedFileSystemItem
docId, docPath, docTitle, PERMISSION_CHECK_OPTIMIZED_PROPERTY, repositoryName
Fields inherited from class org.nuxeo.drive.adapter.impl.AbstractFileSystemItem
canDelete, canRename, creationDate, creator, factoryName, FILE_SYSTEM_ITEM_ID_SEPARATOR, FILE_SYSTEM_ITEM_PATH_SEPARATOR, folder, id, lastContributor, lastModificationDate, lockInfo, name, parentId, path, principal, userName
-
Constructor Summary
ModifierConstructorDescriptionprotected
UserWorkspaceTopLevelFolderItem
(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName) UserWorkspaceTopLevelFolderItem
(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName, boolean relaxSyncRootConstraint) UserWorkspaceTopLevelFolderItem
(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName, boolean relaxSyncRootConstraint, boolean getLockInfo) -
Method Summary
Modifier and TypeMethodDescriptionvoid
delete()
boolean
protected NuxeoDriveManager
int
hashCode()
move
(FolderItem dest) void
scrollDescendants
(String scrollId, int batchSize, long keepAlive) Methods inherited from class org.nuxeo.drive.adapter.impl.DocumentBackedFolderItem
adaptDocuments, checkBatchSize, createFile, createFolder, doScrollDescendants, fetchFromVCS, fetchFromVcsChunk, getBatch, getCanCreateChild, getCanScrollDescendants, getFileManager, getFolderItem, getScrollBatch, initialize, populateAncestorCache, setCanCreateChild, setCanScrollDescendants
Methods inherited from class org.nuxeo.drive.adapter.impl.AbstractDocumentBackedFileSystemItem
canMove, computeId, getDocId, getDocPath, getDocument, getDocumentById, getRepositoryName, getTrashService, handleCollectionMember, parseFileSystemId, setId, updateLastModificationDate
Methods inherited from class org.nuxeo.drive.adapter.impl.AbstractFileSystemItem
compareTo, getCanDelete, getCanRename, getCreationDate, getCreator, getFileSystemItemAdapterService, getId, getLastContributor, getLastModificationDate, getLockInfo, getName, getParentId, getPath, getUserName, isFolder, setCanDelete, setCanRename, setCreationDate, setCreator, setFolder, setLastContributor, setLastModificationDate, setLockInfo, setName, setParentId, setPath, setUserName, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface org.nuxeo.drive.adapter.FileSystemItem
canMove, getCanDelete, getCanRename, getCreationDate, getCreator, getId, getLastContributor, getLastModificationDate, getLockInfo, getName, getParentId, getPath, isFolder
-
Field Details
-
userWorkspace
-
syncRootParentFactoryName
-
-
Constructor Details
-
UserWorkspaceTopLevelFolderItem
public UserWorkspaceTopLevelFolderItem(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName) -
UserWorkspaceTopLevelFolderItem
public UserWorkspaceTopLevelFolderItem(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName, boolean relaxSyncRootConstraint) -
UserWorkspaceTopLevelFolderItem
public UserWorkspaceTopLevelFolderItem(String factoryName, DocumentModel userWorkspace, String folderName, String syncRootParentFactoryName, boolean relaxSyncRootConstraint, boolean getLockInfo) -
UserWorkspaceTopLevelFolderItem
protected UserWorkspaceTopLevelFolderItem()
-
-
Method Details
-
rename
- Specified by:
rename
in interfaceFileSystemItem
- Overrides:
rename
in classDocumentBackedFolderItem
-
delete
public void delete()- Specified by:
delete
in interfaceFileSystemItem
- Overrides:
delete
in classAbstractDocumentBackedFileSystemItem
-
move
- Specified by:
move
in interfaceFileSystemItem
- Overrides:
move
in classAbstractDocumentBackedFileSystemItem
-
getChildren
- Specified by:
getChildren
in interfaceFolderItem
- Overrides:
getChildren
in classDocumentBackedFolderItem
-
scrollDescendants
Description copied from interface:FolderItem
Retrieves at mostbatchSize
FileSystemItem
descendants for the givenscrollId
.When passing a null
scrollId
the initial search request is executed and the first batch of results is returned along with ascrollId
which should be passed to the next call in order to retrieve the next batch of results.Ideally, the search context made available by the initial search request is kept alive during
keepAlive
milliseconds ifkeepAlive
is positive.Results are not necessarily sorted.
This method is protected by a
Semaphore
, made available byFileSystemItemAdapterService.getScrollBatchSemaphore()
, to limit the number of concurrent executions and avoid too much memory pressure.- Specified by:
scrollDescendants
in interfaceFolderItem
- Overrides:
scrollDescendants
in classDocumentBackedFolderItem
-
equals
- Overrides:
equals
in classDocumentBackedFolderItem
-
hashCode
public int hashCode()- Overrides:
hashCode
in classDocumentBackedFolderItem
-
getNuxeoDriveManager
-