Package com.saperion.folder
Class FolderUpdateInfo
java.lang.Object
com.saperion.folder.FolderUpdateInfo
- All Implemented Interfaces:
Serializable
Container for informational objects that describe the folders (workflow or
simple) that shall be refreshed on ngclient side.
- Author:
- chg
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionFolderUpdateInfo
(SaDocumentInfo folderInfo, boolean refreshChilds, long cacheTime) Constructor for simple Folders.FolderUpdateInfo
(BoxDefinition wfBoxDef, boolean refreshChilds, long cacheTime) Constructor for Workflow Folders.FolderUpdateInfo
(String sysrowId, String ddcName, long cacheTime, boolean refreshChilds) -
Method Summary
Modifier and TypeMethodDescriptionReturns the DDX of the folder.Returns the sysrowid of the folder.The Type of the Folder to refresh.Returns the xhdoc of the folder.long
The time stamp the object has been put into cache.long
Returns the number of total workflows.long
Returns the number of unread of workflows.int
The Id of the Workflow Box.The name of the Workflow Box.The Type of the Workflow Box.boolean
We have to differentiate two cases.
-
Constructor Details
-
FolderUpdateInfo
- Parameters:
sysrowId
- - SYSROWIDddcName
- - DDC namecacheTime
- - time stamp the object has been cached.refreshChilds
- - shall the children of this folder be refreshed or not.
-
FolderUpdateInfo
Constructor for simple Folders. Just give FolderUpdateInfo the SaFolderInfo and whether the childs for this folder shall also be refreshed.- Parameters:
folderInfo
- - FolderInfo that stores XHDOC, SysRowId etc.refreshChilds
- - shall the children of this folder be refreshed or not.cacheTime
- - time stamp the object has been cached.- See Also:
-
FolderUpdateInfo
Constructor for Workflow Folders. The FolderType is internally set to WORKFLOW_FORM so the client just needs to check if the folder to refresh is a workflow folder or not. Just give FolderUpdateInfo the BoxDefinition and whether the childs for this folder shall also be refreshed.- Parameters:
wfBoxDef
- - the Workflow Box Definition that stores the BoxId, the BoxName and the BoxTyperefreshChilds
- - shall the children of this folder be refreshed or not.cacheTime
- - time stamp the object has been cached.- See Also:
-
-
Method Details
-
getTotalCount
public long getTotalCount()Returns the number of total workflows. This method also can be used to check if it is a simple folder. In this case the returned Value is -1.- Returns:
- the totalCount for Folders.
-
getUnreadCount
public long getUnreadCount()Returns the number of unread of workflows. This Method also can be used to check if it is a simple folder. In this case the returned Value is -1.- Returns:
- the unreadCount for Workflow Folders.
-
isRefreshChildren
public boolean isRefreshChildren()We have to differentiate two cases.-
File & Unfile
The given folder information are the one of the current folder the documents are filed or unfiled in. The folder can be refreshed directly.
-
Add & Delete
If a folder was deleted the ngclient still holds this folder. If a new folder was added the ngclient doesn't know the added folder, yet. For both cases a refresh it would be a refresh for a non existing folder. Thus, the here given folder to refresh is the parent folder of the added or deleted one. The client needs to update this parent folder including its children to recognize the changes.
- Returns:
- whether to refresh the children of the given folderId.
-
-
getFolderSysrowId
Returns the sysrowid of the folder.- Returns:
- the folderSysrowId
-
getFolderXhdoc
Returns the xhdoc of the folder.- Returns:
- the folderXhdoc
-
getFolderDDC
Returns the DDX of the folder.- Returns:
- the folderDDC
-
getFolderType
The Type of the Folder to refresh.- Returns:
- the folderType.
-
getWfBoxId
public int getWfBoxId()The Id of the Workflow Box.- Returns:
- the wfBoxId
-
getWfBoxType
The Type of the Workflow Box.- Returns:
- the wfBoxType
-
getWfBoxName
The name of the Workflow Box.- Returns:
- the wfBoxName
-
getTimeStamp
public long getTimeStamp()The time stamp the object has been put into cache.- Returns:
- the time stamp.
-