Interface Body
- All Superinterfaces:
Comparable<StoreElement>,HistoryProvider,IDProvider,StoreElement,Workflowable
- All Known Subinterfaces:
GCABody
This interface provides methods to handle the bodys of pages in the PageStore.
A page in PageStore can have zero or several bodies.
To get all bodies for a page use
Page.getChildren(Body.class)- Since:
- 3.0
-
Nested Class Summary
Nested classes/interfaces inherited from interface de.espirit.firstspirit.storage.HistoryProvider
HistoryProvider.RevisionProviderNested classes/interfaces inherited from interface de.espirit.firstspirit.access.store.IDProvider
IDProvider.DependentReleaseType, IDProvider.RevertType, IDProvider.UidType -
Field Summary
Fields inherited from interface de.espirit.firstspirit.storage.HistoryProvider
ALL_REVISIONS, EVER_SINCE, UNTIL_NOWFields inherited from interface de.espirit.firstspirit.access.store.IDProvider
CHANGED, NEVER_RELEASED, RELEASED -
Method Summary
Modifier and TypeMethodDescriptioncreateSection(String name, Template template) Create a new section with the given name and template.createSectionReference(String name, Section sourceSection) Creates a section reference based on the given source section as new child of this body.@NotNull StringgetName()Get the name of a body for a PagebooleanisHidden()State if the body is hidden for the uservoidsetHidden(boolean hidden) Set the state of the body: hide/showvoidSet the name of a bodyMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface de.espirit.firstspirit.storage.HistoryProvider
asRevisionProvider, getHistory, getHistoryMethods inherited from interface de.espirit.firstspirit.access.store.IDProvider
contrastWith, getDisplayName, getId, getInRevision, getLanguageInfo, getLongID, getMeta, getMetaFormData, getParent, getReleasedBy, getReleaseRevision, getReleaseRevision, getReleaseStatus, getReleaseStatus, getRevision, getUid, getUidType, hasMeta, hasUid, isInReleaseStore, isInReleaseStore, isReachableInReleaseStore, isReleased, isReleased, isReleaseSupported, moveChild, moveChild, release, release, release, release, revert, setDisplayName, setMeta, setMetaFormData, setUidMethods inherited from interface de.espirit.firstspirit.access.store.StoreElement
appendChild, appendChildBefore, delete, exportStoreElement, getChildCount, getChildIndex, getChildren, getChildren, getChildren, getChildren, getCreateWorkflowPermission, getDefinedPrincipalPermissions, getEditor, getElementType, getFirstChild, getIncomingReferences, getInheritedPrincipalPermissions, getLastChanged, getNextSibling, getOutgoingReferences, getPermission, getPermission, getPermission, getPreviousSibling, getProject, getReferenceName, getReferences, getReferences, getStore, getTreePermission, getWorkflowPermission, getWorkflowPermissions, getWriteLock, hasIncomingReferences, hasPermissions, importStoreElement, importStoreElements, inheritWorkflowPermission, isDeleted, isExportSupported, isFolder, isImportSupported, isLocked, isLockedOnServer, isLockSupported, isPermissionSupported, isWorkflowAllowed, isWorkflowSupported, refresh, removeAllWorkflowPermissions, removeChild, removePermission, removePermission, removePermission, removeWorkflowPermission, replaceChild, save, save, save, setInheritWorkflowPermission, setLock, setLock, setPermission, setPermission, setPermission, setWorkflowPermission, setWorkflowPermissions, setWriteLock, toXml, toXml, toXmlMethods inherited from interface de.espirit.firstspirit.access.Workflowable
getColor, getTask, hasTask, removeTask, setColor, setTask
-
Method Details
-
getName
Get the name of a body for a Page- Specified by:
getNamein interfaceStoreElement- Returns:
- name of a body
- Since:
- 3.0
-
setName
Set the name of a body- Parameters:
name- new name of a body- Throws:
LockException- occurs if this node already locked by another user- Since:
- 3.0
-
isHidden
boolean isHidden()State if the body is hidden for the user- Returns:
truefor hidden;falsefor visible- Since:
- 3.0
-
setHidden
Set the state of the body: hide/show- Parameters:
hidden-trueshow the body;falsehide the body- Throws:
LockException- occurs if this node already locked by another user- Since:
- 3.0
-
createSection
Section createSection(String name, Template template) throws IllegalArgumentException, LockException, ElementDeletedException Create a new section with the given name and template.- Parameters:
name- name of the section to be createdtemplate- template instance for the section to be created (either a section or table template instance).- Returns:
- new section (an instance of
SectionorContent2Section) - Throws:
NullPointerException- when parametertemplateisnullIllegalArgumentException- when the provided template is an instance ofTableTemplateand the page already contains a content section or thetypeof the template isTemplate.PAGE_TEMPLATE.LockExceptionElementDeletedException- Since:
- 3.0
-
createSectionReference
SectionReference createSectionReference(String name, Section sourceSection) throws LockException, ElementDeletedException Creates a section reference based on the given source section as new child of this body.- Parameters:
sourceSection- the source section for the new section reference- Throws:
LockExceptionElementDeletedException- Since:
- 3.0
-