Package io.guise.framework.platform.web
Class HTTPServletWebDepictContext
java.lang.Object
com.globalmentor.beans.BoundPropertyObject
io.guise.framework.platform.AbstractDepictContext
io.guise.framework.platform.AbstractTextDepictContext
io.guise.framework.platform.AbstractXMLDepictContext
io.guise.framework.platform.AbstractXHTMLDepictContext
io.guise.framework.platform.web.AbstractWebDepictContext
io.guise.framework.platform.web.HTTPServletWebDepictContext
- All Implemented Interfaces:
com.globalmentor.beans.PropertyBindable
,com.globalmentor.beans.PropertyConstrainable
,DepictContext
,TextDepictContext
,WebDepictContext
,XHTMLDepictContext
,XMLDepictContext
A web depict context of an HTTP servlet.
The output stream defaults to text/plain
encoded in UTF-8
.
- Author:
- Garret Wilson
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.guise.framework.platform.XMLDepictContext
XMLDepictContext.ElementState
-
Field Summary
Fields inherited from class com.globalmentor.beans.BoundPropertyObject
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS
Fields inherited from interface io.guise.framework.platform.XHTMLDepictContext
CSS_PROPERTY_BORDER_X_COLOR_TEMPLATE, CSS_PROPERTY_BORDER_X_STYLE_TEMPLATE, CSS_PROPERTY_BORDER_X_WIDTH_TEMPLATE, CSS_PROPERTY_BORDER_X_Y_RADIUS_TEMPLATE, CSS_PROPERTY_MARGIN_X_TEMPLATE, CSS_PROPERTY_PADDING_X_TEMPLATE, CSS_SIDES
-
Constructor Summary
ConstructorDescriptionHTTPServletWebDepictContext
(HTTPServletGuiseRequest guiseRequest, javax.servlet.http.HttpServletResponse response, GuiseSession session, Destination destination) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected com.globalmentor.xml.spec.NsQualifiedName
protected com.globalmentor.xml.spec.NsQualifiedName
protected HTTPServletGuiseRequest
com.globalmentor.net.MediaType
protected javax.servlet.http.HttpServletResponse
void
setOutputContentType
(com.globalmentor.net.MediaType contentType) Sets the content type of the text output.Methods inherited from class io.guise.framework.platform.web.AbstractWebDepictContext
appendCSSValue, appendCSSValue, appendCSSValue, appendCSSValue, appendCSSValue, appendCSSValue, appendCSSValue, appendCSSValue, getCSSStyleString, getPlatform, isQuirksMode
Methods inherited from class io.guise.framework.platform.AbstractXHTMLDepictContext
appendAttributeName, isAllDataAttributes, isDataAttributeNamespaceURI, registerDataAttributeNamespaceURI, setAllDataAttributes, writeJavaScriptElement, writeMetaElement, writeMetaElement
Methods inherited from class io.guise.framework.platform.AbstractXMLDepictContext
appendAttribute, appendAttributeValue, clearDepictText, encode, getAttributeValue, getDepictStringBuilder, getMessageDigest, getQualifiedName, getXMLNamespacePrefixManager, isHashAttributesGenerated, setHashAttributesGenerated, writeAttribute, writeComment, writeCommentClose, writeCommentOpen, writeDocType, writeDocType, writeDocType, writeDocType, writeElementBegin, writeElementBegin, writeElementEnd
Methods inherited from class io.guise.framework.platform.AbstractTextDepictContext
getDepictText, getIndentLevel, indent, indent, isFormatted, setIndentLevel, unindent, write, write, writeIndent, writeLiteral
Methods inherited from class io.guise.framework.platform.AbstractDepictContext
getDepictionURI, getDepictionURI, getDestination, getSession, getStyles
Methods inherited from class com.globalmentor.beans.BoundPropertyObject
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.guise.framework.platform.DepictContext
getDepictionURI, getDepictionURI, getDestination, getSession, getStyles
Methods inherited from interface com.globalmentor.beans.PropertyBindable
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, hasPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
Methods inherited from interface io.guise.framework.platform.TextDepictContext
clearDepictText, getDepictStringBuilder, getDepictText, getIndentLevel, indent, indent, isFormatted, setIndentLevel, unindent, write, write, writeIndent, writeLiteral
Methods inherited from interface io.guise.framework.platform.XHTMLDepictContext
isAllDataAttributes, isDataAttributeNamespaceURI, registerDataAttributeNamespaceURI, setAllDataAttributes, writeJavaScriptElement, writeMetaElement, writeMetaElement
Methods inherited from interface io.guise.framework.platform.XMLDepictContext
getQualifiedName, writeAttribute, writeComment, writeCommentClose, writeCommentOpen, writeDocType, writeDocType, writeDocType, writeDocType, writeElementBegin, writeElementBegin, writeElementEnd
-
Constructor Details
-
HTTPServletWebDepictContext
public HTTPServletWebDepictContext(HTTPServletGuiseRequest guiseRequest, javax.servlet.http.HttpServletResponse response, GuiseSession session, Destination destination) throws IOException Constructor.- Parameters:
guiseRequest
- Guise request information.response
- The HTTP servlet response.session
- The Guise user session of which this context is a part.destination
- The destination with which this context is associated.- Throws:
NullPointerException
- if the given Guise request, session, and/or destination isnull
.IOException
- If there was an I/O error loading a needed resource.
-
-
Method Details
-
getGuiseRequest
- Returns:
- The Guise HTTP request.
-
getResponse
protected javax.servlet.http.HttpServletResponse getResponse()- Returns:
- The HTTP servlet response.
-
getDepictionURI
- Returns:
- The current full absolute URI for this depiction, including any query.
-
getAttributeHashAttributeQualifiedName
protected com.globalmentor.xml.spec.NsQualifiedName getAttributeHashAttributeQualifiedName()- Specified by:
getAttributeHashAttributeQualifiedName
in classAbstractXMLDepictContext
- Returns:
- The qualified name to use for the attribute hash attribute.
-
getContentHashAttributeQualifiedName
protected com.globalmentor.xml.spec.NsQualifiedName getContentHashAttributeQualifiedName()- Specified by:
getContentHashAttributeQualifiedName
in classAbstractXMLDepictContext
- Returns:
- The qualified name to use for the content hash attribute.
-
getOutputCharset
- Returns:
- The charset currently used for the text output.
-
getOutputContentType
public com.globalmentor.net.MediaType getOutputContentType()- Returns:
- The current content type of the text output.
-
setOutputContentType
public void setOutputContentType(com.globalmentor.net.MediaType contentType) Sets the content type of the text output.This implementation removes all parameters and adds a character set parameter of the current encoding.
- Parameters:
contentType
- The content type of the text output.
-