public final class ComponentResourceSelector extends Object
ComponentResourceLocator implementation to enforce a naming
convention for locating resources. The primary axis is Locale (Tapestry 5.2 and earlier used a Locale
instance as the selector), but Tapestry 5.3 adds support for additional axes.| Constructor and Description |
|---|
ComponentResourceSelector(Locale locale) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
Returns true if the object is another selector with the same locale and set of axis.
|
<T> T |
getAxis(Class<T> axisType)
Returns a previously stored axis value, or null if no axis value of the specified type has been stored.
|
int |
hashCode() |
String |
toShortString()
Returns a string identifying the locale, and any additional axis types and values.
|
String |
toString() |
<T> ComponentResourceSelector |
withAxis(Class<T> axisType,
T axisValue)
Returns a new selector with the given axis data.
|
public ComponentResourceSelector(Locale locale)
public <T> ComponentResourceSelector withAxis(Class<T> axisType, T axisValue)
equals() and hashCode().axisType - non-blank axis keyaxisValue - non-null axis valuepublic <T> T getAxis(Class<T> axisType)
T - axisType - public boolean equals(Object obj)
public String toShortString()
5.6.4 - Copyright © 2003-2021 The Apache Software Foundation.