E
- type of objectpublic class ChoiceFilterElement<E> extends FilterElement<E>
fatherisroot, linktoparent
Constructor and Description |
---|
ChoiceFilterElement(ChoiceField field)
create a choice filter element for the given choice field
|
ChoiceFilterElement(ChoiceField field,
boolean needhelper)
create a choice filter element for the given choice field
|
ChoiceFilterElement(ChoiceField field,
ChoiceValue[] valuesin)
create a choice filter element for the given choice field
|
Modifier and Type | Method and Description |
---|---|
ArgumentContent |
getArgumentContent(java.lang.String suffix)
should return an argument content with as base the name of object, the name
of field, and the suffix
|
protected java.lang.String |
getBlankValue() |
java.lang.String[] |
getImportClasses()
provides the import classes to be put in the page
|
java.lang.String[] |
getImportClassesForAction(java.lang.String reportname)
provides he import classes to be put in the action
|
DataObjectDefinition |
getParent() |
protected boolean |
hasfilterafter()
A filter is considered as 'after' if it is a filter after the query was
performed
|
protected boolean |
hasfilterbefore()
A filter is considered as 'before' if it is a condition to be put in the
query to get children objects in the navigation
|
void |
writeFilterCriteria(SourceGenerator sg,
java.lang.String reportname)
The filter criteria for the page of the smart report
|
void |
writeFilterInDataGathering(SourceGenerator sg,
java.lang.String prefixforlinkandchild,
DataObjectDefinition reportroot,
java.lang.String reportname)
writes the filter code in the data gathering phase of the report
|
isHardCoded, setContext
public ChoiceFilterElement(ChoiceField field)
field
- choice field to use as filter elementpublic ChoiceFilterElement(ChoiceField field, boolean needhelper)
field
- choice field to use as filter elementneedhelper
- true if the filter needs an helper, false if data entered
by the userpublic ChoiceFilterElement(ChoiceField field, ChoiceValue[] valuesin)
field
- choice field to use as filter elementvaluesin
- list of values that will be filteredpublic void writeFilterCriteria(SourceGenerator sg, java.lang.String reportname) throws java.io.IOException
FilterElement
writeFilterCriteria
in class FilterElement<E>
sg
- source generator for the given filereportname
- name of the reportjava.io.IOException
- if anything bad happens while writing the filepublic DataObjectDefinition getParent()
getParent
in class FilterElement<E>
public ArgumentContent getArgumentContent(java.lang.String suffix)
FilterElement
getArgumentContent
in class FilterElement<E>
suffix
- suffix of the current node in the reportpublic java.lang.String[] getImportClasses()
FilterElement
getImportClasses
in class FilterElement<E>
protected boolean hasfilterbefore()
FilterElement
hasfilterbefore
in class FilterElement<E>
protected boolean hasfilterafter()
FilterElement
hasfilterafter
in class FilterElement<E>
public void writeFilterInDataGathering(SourceGenerator sg, java.lang.String prefixforlinkandchild, DataObjectDefinition reportroot, java.lang.String reportname) throws java.io.IOException
FilterElement
writeFilterInDataGathering
in class FilterElement<E>
sg
- source generatorprefixforlinkandchild
- step suffixreportroot
- root object of the reportreportname
- report namejava.io.IOException
- if anything bad happens while writing the filepublic java.lang.String[] getImportClassesForAction(java.lang.String reportname)
FilterElement
getImportClassesForAction
in class FilterElement<E>
reportname
- name of the reportprotected java.lang.String getBlankValue()
getBlankValue
in class FilterElement<E>