public class DefaultReportingData extends AbstractReportingExportable implements NumericValue, Cloneable
Modifier and Type | Field and Description |
---|---|
protected Attribute |
a |
protected String |
alias |
protected boolean |
attributeHasUserdefType |
protected boolean |
dontUseMappedString |
protected Entity |
e |
protected Object |
value |
Constructor and Description |
---|
DefaultReportingData() |
DefaultReportingData(Entity e,
Attribute a) |
Modifier and Type | Method and Description |
---|---|
NumericValue |
add(NumericValue v2)
Adds the Values of two NumericValue Objects
|
void |
addClientConditionWidgetOptions(JSONObject json,
boolean paramAtExec,
Element condition)
add clientcondition attributes to attribute store
|
void |
addConditionToQuery(Query q,
Element c)
Adds the XMLAttribute as a conditon to the query.
|
static void |
addIgnoreCaseComponents(DivComponent root,
boolean checked) |
void |
addSelectAttributeToQuery(Query q,
Element select)
Adds the XMLAttribute as a select attribute to the query.
|
NumericValue |
avg(long count)
Calculates the average of a numeric data.
|
protected void |
checkTempJoin(Query q,
String tablename_new,
String alias_new,
String entity_new,
String entity_orig,
String alias_orig) |
static int |
compare2(Object o1,
Object o2) |
int |
compareTo(ReportingExportable o) |
Collection<ReportingExportable> |
completeSeries(Set<ReportingExportable> series,
Query q)
invoked for matrix-style reports to be able to add missing entries in the given
series |
String |
getAlias() |
Attribute |
getAttribute() |
protected Class<?> |
getBaseType() |
String |
getColumnRenderer()
Defines Columnrenderer which implements the render function (used in ep 9.0)
|
static String |
getDBData(Entity e,
Attribute a) |
Entity |
getEntity() |
protected String |
getMappedValue(Object key) |
protected List<Pair<String,String>> |
getMappedValues()
get ALL possible key-value-pairs for
Attribute getAttribute()
key is the value stored in the DB, value is the value used for display |
List<Pair<String,String>> |
getOperatorList(boolean comesFromParamMask) |
Object |
getValue() |
boolean |
hasAttributeUserdefinedType() |
protected boolean |
hasMappedValues()
|
protected List<Pair<String,String>> |
pairList(List<Pair<String,String>> aggrs) |
static List<Pair<String,String>> |
pairList(List<Pair<String,String>> toAdd,
List<Pair<String,String>> aggrs) |
static List<Pair<String,String>> |
pairList(List<Pair<String,String>> toAdd,
String[] aggrs) |
static List<Pair<String,String>> |
pairList(String[] aggrs) |
void |
setAlias(String alias) |
void |
setAttribute(Attribute a) |
void |
setAttributeHasUserdefinedType(boolean attributeHasUserdefType) |
protected <T extends Component> |
setDojoAndStyle(T c,
String dojoType,
String dojoAttachPoint,
String dojoProps,
String className,
String style)
Deprecated.
|
void |
setEntity(Entity e) |
protected void |
setMappedValue(String key,
String value)
set internal fields for a possible mapped value. is used when restoring/completing series in
completeSeries(Set, Query)
by creating synthetic data-instances |
void |
setValue(Object val)
Sets the value for this object
|
void |
setValue(ResultSet rs,
Element selectAttribute,
Query q)
Sets the value of this object.
|
static String[] |
splitValueAttribute(String value,
String operator,
boolean paramAtExec) |
Object |
toHtml()
return type is either an implementation of
Component or a String |
Object |
toJson()
Export Data to Json (used in ep 9.0)
|
String |
toString() |
String |
toText()
used for CSV/EXCEL/XML export...
|
getSortText
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addClientConditionWidgetOptions
getSortText
protected Object value
protected Entity e
protected Attribute a
protected String alias
protected boolean dontUseMappedString
protected boolean attributeHasUserdefType
public void setAttribute(Attribute a)
setAttribute
in interface ReportingData
a
- - set the attribute of schema which refers to this objectpublic void setEntity(Entity e)
setEntity
in interface ReportingData
e
- - set the entitypublic Attribute getAttribute()
getAttribute
in interface ReportingData
public Entity getEntity()
getEntity
in interface ReportingData
public void setAlias(String alias)
public String getAlias()
public static List<Pair<String,String>> pairList(List<Pair<String,String>> toAdd, String[] aggrs)
public static List<Pair<String,String>> pairList(List<Pair<String,String>> toAdd, List<Pair<String,String>> aggrs)
public Object toHtml()
ReportingExportable
Component
or a StringtoHtml
in interface ReportingExportable
public String toText()
ReportingExportable
toText
in interface ReportingExportable
public void addSelectAttributeToQuery(Query q, Element select)
ReportingData
Query.addSelect(String, String, String, String, boolean, boolean)
and Query.addSelectNameOfAttrib(Element, String)
!addSelectAttributeToQuery
in interface ReportingData
q
- - the query Object, where select attribute is addedselect
- - the xml element of type attributeprotected void checkTempJoin(Query q, String tablename_new, String alias_new, String entity_new, String entity_orig, String alias_orig)
protected Class<?> getBaseType()
public void addConditionToQuery(Query q, Element c)
ReportingData
Query.addCondition(String, String, String, String, List)
addConditionToQuery
in interface ReportingData
q
- - the query Object, where condtion has to be addedc
- - the xml element of type conditionpublic void setValue(ResultSet rs, Element selectAttribute, Query q)
ReportingData
setValue
in interface ReportingData
rs
- - the result set of the queryselectAttribute
- - the xml-element attribute of the queryq
- - the query objectpublic int compareTo(ReportingExportable o)
compareTo
in interface ReportingExportable
compareTo
in interface Comparable<ReportingExportable>
public Object getValue()
getValue
in interface ReportingExportable
public List<Pair<String,String>> getOperatorList(boolean comesFromParamMask)
getOperatorList
in interface ReportingData
comesFromParamMask
- true if list is taken for parameter of execution.public void addClientConditionWidgetOptions(JSONObject json, boolean paramAtExec, Element condition)
ReportingData
addClientConditionWidgetOptions
in interface ReportingData
json
- the json object of this attributeparamAtExec
- indicates if method is called in normal condition or param-at-execution modecondition
- the optional <condition> element. can be used to mimic special behavior for parameter-at-execution scenariosprotected boolean hasMappedValues()
protected List<Pair<String,String>> getMappedValues()
Attribute
getAttribute()
key is the value stored in the DB, value is the value used for displayprotected String getMappedValue(Object key)
hasMappedValues()
is true
protected void setMappedValue(String key, String value)
completeSeries(Set, Query)
by creating synthetic data-instanceskey
- value
- @Deprecated protected <T extends Component> T setDojoAndStyle(T c, String dojoType, String dojoAttachPoint, String dojoProps, String className, String style)
public static void addIgnoreCaseComponents(DivComponent root, boolean checked)
public static String[] splitValueAttribute(String value, String operator, boolean paramAtExec)
public NumericValue add(NumericValue v2)
NumericValue
add
in interface NumericValue
v2
- the second NumericValue to addpublic NumericValue avg(long count)
NumericValue
avg
in interface NumericValue
count
- the amount of NumericValue Objectspublic void setValue(Object val)
ReportingExportable
setValue
in interface ReportingExportable
val
- - the value objectpublic String getColumnRenderer()
ReportingExportable
getColumnRenderer
in interface ReportingExportable
public Object toJson()
ReportingExportable
toJson
in interface ReportingExportable
public Collection<ReportingExportable> completeSeries(Set<ReportingExportable> series, Query q)
ReportingData
series
completeSeries
in interface ReportingData
series
- the current values from the DBq
- the querypublic void setAttributeHasUserdefinedType(boolean attributeHasUserdefType)
attributeHasUserdefType
- the attributeHasUserdefType to setpublic boolean hasAttributeUserdefinedType()
@enterprise 10.0.39049 Copyright © 2024 FREQUENTIS AG. All Rights Reserved.