Package org.opencms.jsp
Class CmsJspTagPdfThumbnail
java.lang.Object
javax.servlet.jsp.tagext.TagSupport
org.opencms.jsp.CmsJspTagPdfThumbnail
- All Implemented Interfaces:
Serializable
,javax.servlet.jsp.tagext.IterationTag
,javax.servlet.jsp.tagext.JspTag
,javax.servlet.jsp.tagext.Tag
JSP tag to generate a link to a PDF produced from a given XML content.
- See Also:
-
Field Summary
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
static String
pdfTagAction
(javax.servlet.ServletRequest request, String file, int width, int height, String format) The implementation of the tag.void
Sets the path to the PDF.void
Setter for the format path.void
Sets the height.void
Sets the width.Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
-
Constructor Details
-
CmsJspTagPdfThumbnail
public CmsJspTagPdfThumbnail()
-
-
Method Details
-
pdfTagAction
public static String pdfTagAction(javax.servlet.ServletRequest request, String file, int width, int height, String format) throws CmsException The implementation of the tag.- Parameters:
request
- the current requestfile
- the path to the PDFwidth
- the thumbnail widthheight
- the thumbnail heightformat
- the image format- Returns:
- the link to the PDF thumbnail
- Throws:
CmsException
- if something goes wrong
-
doStartTag
- Specified by:
doStartTag
in interfacejavax.servlet.jsp.tagext.Tag
- Overrides:
doStartTag
in classjavax.servlet.jsp.tagext.TagSupport
- See Also:
-
Tag.doStartTag()
-
setFile
Sets the path to the PDF.- Parameters:
file
- the PDF path
-
setFormat
Setter for the format path.- Parameters:
format
- the format path
-
setHeight
Sets the height.- Parameters:
height
- the height to set
-
setWidth
Sets the width.- Parameters:
width
- the width to set
-