Package io.guise.framework.platform
Class AbstractDepictContext
java.lang.Object
com.globalmentor.beans.BoundPropertyObject
io.guise.framework.platform.AbstractDepictContext
- All Implemented Interfaces:
com.globalmentor.beans.PropertyBindable
,com.globalmentor.beans.PropertyConstrainable
,DepictContext
- Direct Known Subclasses:
AbstractTextDepictContext
public abstract class AbstractDepictContext
extends com.globalmentor.beans.BoundPropertyObject
implements DepictContext
Abstract encapsulation of information related to the current depiction.
- Author:
- Garret Wilson
-
Field Summary
Fields inherited from class com.globalmentor.beans.BoundPropertyObject
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS
-
Constructor Summary
ConstructorDescriptionAbstractDepictContext
(GuiseSession session, Destination destination) Guise session constructor. -
Method Summary
Modifier and TypeMethodDescriptiongetDepictionURI
(com.globalmentor.net.URIPath navigationPath, String... suffixes) Determines the URI to use for depiction based upon a navigation path.getDepictionURI
(URI navigationURI, String... suffixes) Determines the URI to use for depiction based upon a navigation URI.Retrieves styles for this context.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
Methods inherited from interface com.globalmentor.beans.PropertyBindable
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, hasPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
-
Constructor Details
-
AbstractDepictContext
Guise session constructor.- Parameters:
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 session and/or destination is null.IOException
- If there was an I/O error loading a needed resource.
-
-
Method Details
-
getSession
- Specified by:
getSession
in interfaceDepictContext
- Returns:
- The Guise user session of which this context is a part.
-
getPlatform
- Specified by:
getPlatform
in interfaceDepictContext
- Returns:
- The platform on which Guise objects are depicted.
-
getDestination
- Specified by:
getDestination
in interfaceDepictContext
- Returns:
- The destination with which this context is associated.
-
getStyles
Description copied from interface:DepictContext
Retrieves styles for this context. Styles appear in the following order:- theme styles (from most distant parent to current theme)
- application style
- destination style
- Specified by:
getStyles
in interfaceDepictContext
- Returns:
- The URIs of the styles for this context, in order.
-
getDepictionURI
Description copied from interface:DepictContext
Determines the URI to use for depiction based upon a navigation path. The path will first be dereferenced for the current session and then resolved to the application. The resulting URI may not be absolute, but can be made absolute by resolving it against the depiction root URI. This method is equivalent to callingGuiseSession.getDepictionURI(URIPath, String...)
.- Specified by:
getDepictionURI
in interfaceDepictContext
- Parameters:
navigationPath
- The navigation path, which may be absolute or relative to the application.suffixes
- The suffixes, if any, to append to a resource key in a URI reference.- Returns:
- A URI suitable for depiction, deferenced and resolved to the application.
- See Also:
-
getDepictionURI
Description copied from interface:DepictContext
Determines the URI to use for depiction based upon a navigation URI. The URI will first be dereferenced for the current session and then resolved to the application. The resulting URI may not be absolute, but can be made absolute by resolving it against the depiction root URI. This method is equivalent to callingGuiseSession.getDepictionURI(URI, String...)
.- Specified by:
getDepictionURI
in interfaceDepictContext
- Parameters:
navigationURI
- The navigation URI, which may be absolute or have an absolute path or a path relative to the application.suffixes
- The suffixes, if any, to append to a resource key in a URI reference.- Returns:
- A URI suitable for depiction, deferenced and resolved to the application.
- See Also:
-