|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.restlet.engine.Helper fr.cnes.sitools.common.model.ExtensionModel<E> fr.cnes.sitools.common.business.AbstractExtension<FilterParameter> fr.cnes.sitools.dataset.filter.business.AbstractFilter
public abstract class AbstractFilter
Abstract class from which all filters must inherits.
Constructor Summary | |
---|---|
AbstractFilter()
Default constructor |
|
AbstractFilter(org.restlet.Context ctx)
Constructor with DataSet parameter |
Method Summary | |
---|---|
void |
addParam(FilterParameter param)
Add a parameter to the list of parameter The key to this parameter is its name |
java.lang.Number |
convert(java.lang.String unitFromName,
java.lang.String unitToName,
java.lang.String valueFrom,
java.lang.String dimension)
Convert valueFrom from unitFromName to unitToName |
abstract java.util.List<Predicat> |
createPredicats(org.restlet.Request request,
java.util.List<Predicat> predicats)
Method to process conversion, Must be overridden |
java.lang.Boolean |
getDefaultFilter()
Gets whether or not a Filter is a added by default to a Dataset when a new Dataset is created |
Dictionary |
getDictionaryFromName(java.lang.String dicoName)
Get a dictionary from its name |
FilterParameter |
getInternParam(java.lang.String name)
Gets the FilterParameter of type PARAMETER_INTERN corresponding to the following name |
java.util.HashMap<java.lang.String,org.restlet.ext.wadl.ParameterInfo> |
getRequestParamsDescription()
Gets the requestParamsDescription value |
void |
setDefaultFilter(java.lang.Boolean defaultFilter)
The default filter value is used to tell whether or not a Filter is a added by default to a Dataset when a new Dataset is created |
void |
setRequestParamsDescription(java.util.HashMap<java.lang.String,org.restlet.ext.wadl.ParameterInfo> requestParamsDescription)
Sets the value of requestParamsDescription |
Methods inherited from class fr.cnes.sitools.common.business.AbstractExtension |
---|
getContext, setContext |
Methods inherited from class fr.cnes.sitools.common.model.ExtensionModel |
---|
getClassAuthor, getClassName, getClassOwner, getClassVersion, getDescription, getDescriptionAction, getId, getName, getParametersMap, setClassAuthor, setClassName, setClassOwner, setClassVersion, setDescription, setDescriptionAction, setId, setName, setParametersMap |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface fr.cnes.sitools.common.validator.Validable |
---|
getValidator |
Constructor Detail |
---|
public AbstractFilter()
public AbstractFilter(org.restlet.Context ctx)
ctx
- Context Object, contains the dataset as a property "DATASET"Method Detail |
---|
public final java.lang.Boolean getDefaultFilter()
public java.util.HashMap<java.lang.String,org.restlet.ext.wadl.ParameterInfo> getRequestParamsDescription()
public final void setRequestParamsDescription(java.util.HashMap<java.lang.String,org.restlet.ext.wadl.ParameterInfo> requestParamsDescription)
requestParamsDescription
- the requestParamsDescription to setpublic final void setDefaultFilter(java.lang.Boolean defaultFilter)
defaultFilter
- true to set the filter to default, false otherwisepublic abstract java.util.List<Predicat> createPredicats(org.restlet.Request request, java.util.List<Predicat> predicats) throws java.lang.Exception
request
- the request to be processedpredicats
- the ArrayListjava.lang.Exception
- TODO EVOLUTION - Possibilité de passer des paramètres d'un filtre à l'autre autrement que par les
predicats Voir si besoin.public final void addParam(FilterParameter param)
param
- the Recordpublic final FilterParameter getInternParam(java.lang.String name)
FilterParameter
of type PARAMETER_INTERN corresponding to the following name
name
- The name of the FilterParameter
FilterParameter
of type PARAMETER_INTERN corresponding to the following name
or
null if the FilterParameter
is not foundpublic final java.lang.Number convert(java.lang.String unitFromName, java.lang.String unitToName, java.lang.String valueFrom, java.lang.String dimension) throws SitoolsException
unitFromName
- the name of the unit fromunitToName
- the name of the unit tovalueFrom
- the value to convertdimension
- the dimension
SitoolsException
- if something wrong occurspublic Dictionary getDictionaryFromName(java.lang.String dicoName)
dicoName
- the name of the dictionary
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |