Class TocFunctionality
java.lang.Object
io.goobi.viewer.model.cms.itemfunctionality.TocFunctionality
- All Implemented Interfaces:
Functionality
CMS item functionality that displays a table of contents for a specified record.
- Author:
- Florian Alpers
-
Constructor Summary
ConstructorsConstructorDescriptionTocFunctionality(TocFunctionality blueprint) Creates a new TocFunctionality instance.Creates a new TocFunctionality instance. -
Method Summary
Modifier and TypeMethodDescriptiongetBannerUrl(int width, int height) getBannerUrl.Getter for the fielddocStruct.intgetPageNo.getPi()Getter for the fieldpi.getToc()Getter for the fieldtoc.voidsetPageNo(int pageNo) setPageNo.
-
Constructor Details
-
TocFunctionality
Creates a new TocFunctionality instance.- Parameters:
pi- process identifier of the record to display
-
TocFunctionality
Creates a new TocFunctionality instance.- Parameters:
blueprint- existing instance to copy state from
-
-
Method Details
-
getBannerUrl
public String getBannerUrl(int width, int height) throws IndexUnreachableException, PresentationException, DAOException, ViewerConfigurationException getBannerUrl.- Parameters:
width- a int.height- a int.- Returns:
- the banner image URL for the current TOC record, scaled to the given dimensions
- Throws:
IndexUnreachableException- if any.PresentationException- if any.DAOException- if any.ViewerConfigurationException- if any.
-
getToc
public TOC getToc() throws PresentationException, IndexUnreachableException, DAOException, ViewerConfigurationExceptionGetter for the fieldtoc.- Returns:
- the TOC for the current record, creating it if necessary
- Throws:
PresentationException- if any.IndexUnreachableException- if any.DAOException- if any.ViewerConfigurationException- if any.
-
getDocStruct
Getter for the fielddocStruct.- Returns:
- the top-level StructElement for the current record, creating it if necessary
- Throws:
IndexUnreachableException- if any.PresentationException- if any.
-
getPi
Getter for the fieldpi.- Returns:
- the persistent identifier of the record whose table of contents is displayed, or an empty string if none is set
-
setPageNo
public void setPageNo(int pageNo) setPageNo.- Specified by:
setPageNoin interfaceFunctionality- Parameters:
pageNo- a int.
-
getPageNo
public int getPageNo()getPageNo.- Specified by:
getPageNoin interfaceFunctionality- Returns:
- a int.
-