I am using the Alfresco Mobile SDK for Android, available on the Alfresco website.
I am trying to obtain the following information from the Alfresco server, if possible with an existing easymethod (maybe not documented inside the doumentation provided):
-
the number of characters inside a
Document(I tried the methodgetContentStreamLength()that you can apply on an Object of type Document) -
the size of a
Document, and then the size of aFolder, or if there is directly a method to obtain the size of a Folder. Which will be the unity of this size (Go, …) retrieved? -
the list of person a
Nodeis shared with -
the number of Folder children, and File children of a
Folder
Thanks in advance for your help.
the number of characters inside a Document
It’s not possible. Indeed depending on what type of document (text, office document, images, movies, etc…) one character is relevant or not. So no it’s not possible.
the size of a Document
Yes. It’s possible simply use
Document.getContentStreamLength(). It returns the size of document in bytes. -1 if there’s no content.the size of a Folder
No. It’s not possible.
the number of Folder children, and File children of a Folder
It’s possible to know the number of sub-Folder or Documents inside the folder limited to level -1. In others terms if the folder has a depth more than 1 it’s not possible to list everything. We are limited to the level -1
You can use those methods
DocumentFolderService.getDocuments()orDocumentFolderService.getFolders()to list folders or documents.the list of person a Node is shared with
There’s no support for the moment around permission management.
Hope it helps.
NB : If you want new features available inside the SDK, Feel free to post any requirements to https://issues.alfresco.com/jira