Package io.guise.framework
Class ComponentDestination
- java.lang.Object
-
- com.globalmentor.beans.BoundPropertyObject
-
- io.guise.framework.AbstractDestination
-
- io.guise.framework.ComponentDestination
-
- All Implemented Interfaces:
com.globalmentor.beans.PropertyBindable
,com.globalmentor.beans.PropertyConstrainable
,Destination
public class ComponentDestination extends AbstractDestination
Default implementation of a navigation point based upon a component.- Author:
- Garret Wilson
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
STYLE_PROPERTY
The style bound property.
-
Constructor Summary
Constructors Constructor Description ComponentDestination(com.globalmentor.net.URIPath path, java.lang.Class<? extends Component> componentClass)
Path and component constructor with no style specified.ComponentDestination(com.globalmentor.net.URIPath path, java.lang.Class<? extends Component> componentClass, java.net.URI style)
Path, component, and style constructor.ComponentDestination(java.util.regex.Pattern pathPattern, java.lang.Class<? extends Component> componentClass)
Path pattern and component constructor with no style specified.ComponentDestination(java.util.regex.Pattern pathPattern, java.lang.Class<? extends Component> componentClass, java.net.URI style)
Path pattern, component, and style constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Class<? extends Component>
getComponentClass()
java.net.URI
getStyle()
void
setStyle(java.net.URI newStyle)
Sets the style of this destination.-
Methods inherited from class io.guise.framework.AbstractDestination
equals, exists, getCategories, getDescription, getPath, getPath, getPathPattern, hashCode, isAuthorized, setCategories
-
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
-
-
-
-
Constructor Detail
-
ComponentDestination
public ComponentDestination(com.globalmentor.net.URIPath path, java.lang.Class<? extends Component> componentClass)
Path and component constructor with no style specified.- Parameters:
path
- The application context-relative path within the Guise container context, which does not begin with '/'.componentClass
- The class of the component to represent this destination.- Throws:
java.lang.NullPointerException
- if the path and/or the component class isnull
.java.lang.IllegalArgumentException
- if the provided path is absolute.
-
ComponentDestination
public ComponentDestination(com.globalmentor.net.URIPath path, java.lang.Class<? extends Component> componentClass, java.net.URI style)
Path, component, and style constructor.- Parameters:
path
- The application context-relative path within the Guise container context, which does not begin with '/'.componentClass
- The class of the component to represent this destination.style
- The style of this destination, ornull
if no destination-specific style is specified.- Throws:
java.lang.NullPointerException
- if the path and/or the component class isnull
.java.lang.IllegalArgumentException
- if the provided path is absolute.
-
ComponentDestination
public ComponentDestination(java.util.regex.Pattern pathPattern, java.lang.Class<? extends Component> componentClass)
Path pattern and component constructor with no style specified.- Parameters:
pathPattern
- The pattern to match an application context-relative path within the Guise container context, which does not begin with '/'.componentClass
- The class of the component to represent this destination.- Throws:
java.lang.NullPointerException
- if the path pattern and/or the component class isnull
.
-
ComponentDestination
public ComponentDestination(java.util.regex.Pattern pathPattern, java.lang.Class<? extends Component> componentClass, java.net.URI style)
Path pattern, component, and style constructor.- Parameters:
pathPattern
- The pattern to match an application context-relative path within the Guise container context, which does not begin with '/'.componentClass
- The class of the component to represent this destination.style
- The style of this destination, ornull
if no destination-specific style is specified.- Throws:
java.lang.NullPointerException
- if the path pattern and/or the component class isnull
.java.lang.IllegalArgumentException
- if the provided path is absolute.
-
-
Method Detail
-
getComponentClass
public java.lang.Class<? extends Component> getComponentClass()
- Returns:
- The class of the component to represent this destination.
-
getStyle
public java.net.URI getStyle()
- Returns:
- The style of this destination, or
null
if no destination-specific style is specified.
-
setStyle
public void setStyle(java.net.URI newStyle)
Sets the style of this destination. This is a bound property of typeURI
.- Parameters:
newStyle
- The style of this destination, ornull
if no destination-specific style is specified.- See Also:
STYLE_PROPERTY
-
-