Package com.logicaldoc.core.folder
Class Folder
- java.lang.Object
-
- com.logicaldoc.core.PersistentObject
-
- com.logicaldoc.core.metadata.ExtensibleObject
-
- com.logicaldoc.core.folder.Folder
-
- All Implemented Interfaces:
Serializable
,Comparable<Folder>
public class Folder extends ExtensibleObject implements Comparable<Folder>
This class represents the key concept of security of documents. The Folder is used as an element to build hierarchies. With foldergroups you can associate groups to a given folder and grant some permissions. Also setting the recurityRef you can specify another reference folder that contains the security policies.Folders have a type: 0 for standard folders, 1 for workspaces.
- Version:
- 6.0
- Author:
- Marco Meschieri - LogicalDOC
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static long
DEFAULTWORKSPACEID
static String
DEFAULTWORKSPACENAME
static long
ROOTID
static int
TYPE_ALIAS
static int
TYPE_DEFAULT
static int
TYPE_WORKSPACE
-
Fields inherited from class com.logicaldoc.core.PersistentObject
DELETED_CODE_DEFAULT, DELETED_CODE_STRONG
-
-
Method Summary
-
Methods inherited from class com.logicaldoc.core.metadata.ExtensibleObject
getAttribute, getAttributeAtPosition, getAttributeNames, getAttributeNames, getAttributes, getValue, getValueAttributes, getValues, removeAttribute, setAttribute, setAttributes, setValue, setValues, setValues
-
Methods inherited from class com.logicaldoc.core.PersistentObject
equals, getDeleted, getLastModified, getRecordVersion, getTenantId, hashCode, setDeleted, setLastModified, setRecordVersion, setTenantId
-
-
-
-
Field Detail
-
ROOTID
public static final long ROOTID
- See Also:
- Constant Field Values
-
DEFAULTWORKSPACEID
public static final long DEFAULTWORKSPACEID
- See Also:
- Constant Field Values
-
DEFAULTWORKSPACENAME
public static final String DEFAULTWORKSPACENAME
- See Also:
- Constant Field Values
-
TYPE_DEFAULT
public static final int TYPE_DEFAULT
- See Also:
- Constant Field Values
-
TYPE_WORKSPACE
public static final int TYPE_WORKSPACE
- See Also:
- Constant Field Values
-
TYPE_ALIAS
public static final int TYPE_ALIAS
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Folder
public Folder()
-
Folder
public Folder(String name)
-
-
Method Detail
-
isWorkspace
public boolean isWorkspace()
-
isAlias
public boolean isAlias()
-
getId
public long getId()
Description copied from class:PersistentObject
Unique identifier in the data store- Overrides:
getId
in classPersistentObject
- Returns:
- the unique identifier of this record
-
getParentId
public long getParentId()
-
getFolderGroups
public Set<FolderGroup> getFolderGroups()
-
clearFolderGroups
public void clearFolderGroups()
-
setId
public void setId(long id)
- Overrides:
setId
in classPersistentObject
-
setParentId
public void setParentId(long parentId)
-
setFolderGroups
public void setFolderGroups(Set<FolderGroup> fgroup)
-
getFolderGroupIds
public long[] getFolderGroupIds()
-
setFolderGroup
public void setFolderGroup(long[] groups)
Adds FolderGroup object given in a String array to the ArrayList of FolderGroup.- Parameters:
groups
- array of group ids
-
addFolderGroup
public void addFolderGroup(FolderGroup fg)
Adds a new element, substituting an existing one with the same groupId.- Parameters:
fg
- the folder group
-
getFolderGroup
public FolderGroup getFolderGroup(long groupId)
-
compareTo
public int compareTo(Folder o)
- Specified by:
compareTo
in interfaceComparable<Folder>
-
getName
public String getName()
-
setName
public void setName(String name)
-
getSecurityRef
public Long getSecurityRef()
-
setSecurityRef
public void setSecurityRef(Long securityRef)
-
getDescription
public String getDescription()
-
setDescription
public void setDescription(String description)
-
getType
public int getType()
-
setType
public void setType(int type)
-
getCreation
public Date getCreation()
-
setCreation
public void setCreation(Date creation)
-
getCreator
public String getCreator()
-
setCreator
public void setCreator(String creator)
-
getCreatorId
public Long getCreatorId()
-
setCreatorId
public void setCreatorId(Long creatorId)
-
getTemplate
public Template getTemplate()
-
setTemplate
public void setTemplate(Template template)
-
getTemplateLocked
public int getTemplateLocked()
-
setTemplateLocked
public void setTemplateLocked(int templateLocked)
-
getDeleteUserId
public Long getDeleteUserId()
-
setDeleteUserId
public void setDeleteUserId(Long deleteUserId)
-
getPosition
public int getPosition()
-
setPosition
public void setPosition(int position)
-
getHidden
public int getHidden()
-
setHidden
public void setHidden(int hidden)
-
getQuotaDocs
public Long getQuotaDocs()
-
setQuotaDocs
public void setQuotaDocs(Long quotaDocs)
-
getQuotaSize
public Long getQuotaSize()
-
setQuotaSize
public void setQuotaSize(Long quotaSize)
-
getFoldRef
public Long getFoldRef()
-
setFoldRef
public void setFoldRef(Long foldRef)
-
getStorage
public Integer getStorage()
Gets the default storage to use from this folder in the current node- Returns:
- identifier of the default storage
-
setStorage
public void setStorage(Integer storage)
Gets the default storage to use from this folder in the current node- Parameters:
storage
- identifier of the default storage
-
getMaxVersions
public Integer getMaxVersions()
-
setMaxVersions
public void setMaxVersions(Integer maxVersions)
-
getColor
public String getColor()
-
setColor
public void setColor(String color)
-
getTgs
public String getTgs()
-
setTgs
public void setTgs(String tgs)
-
addTag
public void addTag(String word)
-
clearTags
public void clearTags()
-
getGrid
public String getGrid()
-
setGrid
public void setGrid(String grid)
-
getTagsString
public String getTagsString()
-
getQuotaThreshold
public Integer getQuotaThreshold()
-
setQuotaThreshold
public void setQuotaThreshold(Integer quotaThreshold)
-
getQuotaAlertRecipients
public String getQuotaAlertRecipients()
-
setQuotaAlertRecipients
public void setQuotaAlertRecipients(String quotaAlertRecipients)
-
addQuotaAlertRecipient
public void addQuotaAlertRecipient(String recipient)
-
setPath
public void setPath(String path)
-
getPath
public String getPath()
-
getDeleteUser
public String getDeleteUser()
-
setDeleteUser
public void setDeleteUser(String deleteUser)
-
clone
public Object clone()
Clones the folder- Returns:
- a cloned instance
-
getPathExtended
public String getPathExtended()
-
setPathExtended
public void setPathExtended(String pathExtended)
-
getOcrTemplateId
public Long getOcrTemplateId()
-
setOcrTemplateId
public void setOcrTemplateId(Long ocrTemplateId)
-
getBarcodeTemplateId
public Long getBarcodeTemplateId()
-
setBarcodeTemplateId
public void setBarcodeTemplateId(Long barcodeTemplateId)
-
toString
public String toString()
- Overrides:
toString
in classPersistentObject
-
-