public abstract class AbstractParameter extends Object implements Parameter
Parameter
.Modifier and Type | Field and Description |
---|---|
protected int |
index |
protected GwtLocaleFactory |
localeFactory |
protected Type |
type |
Constructor and Description |
---|
AbstractParameter(GwtLocaleFactory localeFactory,
int index,
Type type) |
Modifier and Type | Method and Description |
---|---|
AlternateMessageSelector |
getAlternateMessageSelector()
Get an
AlternateMessageSelector instance associated with this
parameter, or null if none. |
abstract <A extends Annotation> |
getAnnotation(Class<A> annotClass)
Get an annotation from this parameter.
|
int |
getIndex()
Get parameter index, starting from 0.
|
static PluralRule |
getLocalizedPluralRule(Class<? extends PluralRule> pluralClass,
GwtLocale locale)
Instantiate a plural rule class.
|
abstract String |
getName()
Get the name of this parameter.
|
Type |
getType()
Get the type of this parameter.
|
boolean |
isAnnotationPresent(Class<? extends Annotation> annotClass)
Check if an annotation is present on this parameter.
|
protected final GwtLocaleFactory localeFactory
protected final int index
protected final Type type
public AbstractParameter(GwtLocaleFactory localeFactory, int index, Type type)
public static PluralRule getLocalizedPluralRule(Class<? extends PluralRule> pluralClass, GwtLocale locale)
pluralClass
- base plural rule classlocale
- PluralRule
instance for the specified localepublic AlternateMessageSelector getAlternateMessageSelector()
Parameter
AlternateMessageSelector
instance associated with this
parameter, or null if none.getAlternateMessageSelector
in interface Parameter
AlternateMessageSelector
instance or nullpublic abstract <A extends Annotation> A getAnnotation(Class<A> annotClass)
Parameter
getAnnotation
in interface Parameter
public int getIndex()
Parameter
public abstract String getName()
Parameter
getName
in interface Parameter
Parameter.getIndex()
if it cannot be
determinedpublic Type getType()
Parameter
public boolean isAnnotationPresent(Class<? extends Annotation> annotClass)
Parameter
isAnnotationPresent
in interface Parameter
Copyright © 2016. All rights reserved.