Package org.nuxeo.drive.adapter
Interface FolderItem
- All Superinterfaces:
Comparable<FileSystemItem>
,FileSystemItem
- All Known Implementing Classes:
AbstractVirtualFolderItem
,CollectionSyncRootFolderItem
,DefaultSyncRootFolderItem
,DefaultTopLevelFolderItem
,DocumentBackedFolderItem
,ESSyncRootFolderItem
,PermissionTopLevelFolderItem
,SharedSyncRootParentFolderItem
,UserSyncRootParentFolderItem
,UserWorkspaceSyncRootParentFolderItem
,UserWorkspaceTopLevelFolderItem
Representation of a folder.
In the case of a DocumentModel
backed implementation, the backing document is Folderish. Typically a Folder
or a Workspace.
- Author:
- Antoine Taillefer
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptioncreateFile
(Blob blob, boolean overwrite) createFolder
(String name, boolean overwrite) boolean
boolean
Returnstrue
if thescrollDescendants(String, int, long)
API can be used.scrollDescendants
(String scrollId, int batchSize, long keepAlive) Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface org.nuxeo.drive.adapter.FileSystemItem
canMove, delete, getCanDelete, getCanRename, getCreationDate, getCreator, getId, getLastContributor, getLastModificationDate, getLockInfo, getName, getParentId, getPath, isFolder, move, rename
-
Method Details
-
getChildren
List<FileSystemItem> getChildren() -
getCanScrollDescendants
boolean getCanScrollDescendants()Returnstrue
if thescrollDescendants(String, int, long)
API can be used.- Since:
- 8.3
-
scrollDescendants
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.- Throws:
UnsupportedOperationException
- ifgetCanScrollDescendants()
returnsfalse
.- Since:
- 8.3
-
getCanCreateChild
boolean getCanCreateChild() -
createFile
- Parameters:
overwrite
- allows to overwrite an existing file with the same title- Since:
- 9.1
-
createFolder
- Parameters:
overwrite
- allows to overwrite an existing folder with the same title- Since:
- 9.1
-