|
Style Intelligence v12.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectinetsoft.uql.XDataSelection
public class XDataSelection
An XDataSelection represents a selection of query columns or data model
attributes and a list of filter condtions to be applied to the resulting
data. To use XDataSelection with query columns, use AttributeRef objects
where the attribute property is the column name and the entity property is
null.
AttributeRef,
Serialized Form| Field Summary | |
|---|---|
static int |
CONDITION_AND
Flag indicating that a given condition should be and'ed to the associated column/attribute. |
static int |
CONDITION_OR
Flag indicating that a given condition should be or'ed to the associated column/attribute. |
| Fields inherited from interface inetsoft.uql.XDynamicQuery |
|---|
MODEL_TYPE, QUERY_TYPE |
| Constructor Summary | |
|---|---|
XDataSelection(boolean fromModel)
Deprecated. Use the XDataSelection(String) constructor instead. |
|
XDataSelection(String type)
Construct a new instance of DataSelection that is intended to be used with the specified type of source data. |
|
| Method Summary | |
|---|---|
void |
addAttribute(DataRef attribute)
Add a data model attribute or expression to the selection. |
void |
clear()
Clear all attributes and conditions from this selection. |
Object |
clone()
|
boolean |
containsAttribute(DataRef attribute)
Check if an attribute or expression is already defined in the selection. |
UserVariable[] |
getAllVariables()
Add the data selection's user variables to the list. |
DataRef |
getAttribute(int idx)
Get an attribute or an expression. |
int |
getAttributeCount()
Get the total number of attributes and expressions in this selection. |
Enumeration |
getAttributes()
Get a list of all attributes and expression in this selection. |
ColumnSelection |
getColumnSelection()
Get the column selection object. |
ConditionList |
getConditionList()
Get the row selection object. |
GroupInfo |
getGroup()
Get group attribute of binding. |
ColumnSelection |
getHiddenColumns()
Get the hidden column selection object. |
Object |
getProperty(String name)
Get a property value. |
String |
getSource()
Get the name of the source of the data selection. |
String |
getType()
Get the type of this selection. |
boolean |
isAllRows(String entity)
Check if all rows should be included in output for the specified entity. |
boolean |
isDistinct()
Determine if the query result should only contain unique rows. |
boolean |
isFromModel()
Deprecated. use the getType() method to determine the type of this selection. |
boolean |
isSQLGroup()
Determine if the grouping should be performed by the database (in a SQL GROUP BY clause) or during post-processing by Style Report. |
void |
parseXML(Element tag)
Read in the XML representation of this object. |
void |
removeAllAttributes()
Remove all attributes and expressions from the selection. |
void |
removeAttribute(DataRef attribute)
Remove the specified attribute or expression from the selection. |
void |
setAllRows(String entity,
boolean flag)
Set whether to include all rows from an entity. |
void |
setColumnSelection(ColumnSelection sel)
Set the column selection object. |
void |
setConditionList(ConditionList sel)
Set the row selection object. |
void |
setDistinct(boolean distinct)
Set whether the query result should only contain unique rows. |
void |
setFromModel(boolean fromModel)
Deprecated. use the setType() method to set the type of this selection. |
void |
setGroup(GroupInfo group)
Set group attribute of binding. |
void |
setHiddenColumns(ColumnSelection sel)
Set the hidden column selection object. |
void |
setProperty(String name,
Object val)
Set a property value. |
void |
setSource(String source)
Sets the name of the source of the data selection. |
void |
setSQLGroup(boolean sqlGroup)
Set whether the grouping should be performed by the database (in a SQL GROUP BY clause) or during post-processing by Style Report. |
void |
setType(String type)
Set the type of this selection. |
String |
toString()
|
void |
writeXML(PrintWriter writer)
Write this data selection to XML. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int CONDITION_OR
public static final int CONDITION_AND
| Constructor Detail |
|---|
public XDataSelection(boolean fromModel)
fromModel - a flag indicating where the data will come from.
true indicates that the selection will use the attributes
of a data model and false that a defined query will be used.public XDataSelection(String type)
type - the type of data selection being created. This may be
QUERY_TYPE or MODEL_TYPE.| Method Detail |
|---|
public void setSource(String source)
source - the name of the source of the data selection.public String getSource()
getSource in interface XDynamicQuerypublic void setFromModel(boolean fromModel)
fromModel - true if this is a selection of data model
attributes, false for a selection of query columns.public boolean isFromModel()
true if this is a selection of data model
attributes, false for a selection of query columns.public String getType()
getType in interface XDynamicQuerypublic void setType(String type)
type - the type flag of this selection.public void clear()
public void addAttribute(DataRef attribute)
attribute - an DataRef object describing a data model attribute
or expression.public boolean containsAttribute(DataRef attribute)
public void removeAttribute(DataRef attribute)
attribute - an DataRef object describing a data model attribute
or expression.public Enumeration getAttributes()
public DataRef getAttribute(int idx)
idx - attribute index.public int getAttributeCount()
public void removeAllAttributes()
public UserVariable[] getAllVariables()
public void writeXML(PrintWriter writer)
writer - the stream to output the XML text to.
public void parseXML(Element tag)
throws Exception,
DOMException
tag - the XML element representing this object.
Exception
DOMExceptionpublic Object clone()
clone in class Objectpublic void setColumnSelection(ColumnSelection sel)
public ColumnSelection getColumnSelection()
public void setHiddenColumns(ColumnSelection sel)
public ColumnSelection getHiddenColumns()
public void setConditionList(ConditionList sel)
public ConditionList getConditionList()
public GroupInfo getGroup()
public void setGroup(GroupInfo group)
public void setAllRows(String entity,
boolean flag)
public boolean isAllRows(String entity)
public boolean isDistinct()
true if the query is distinct.public void setDistinct(boolean distinct)
distinct - true if the query is distinct.public boolean isSQLGroup()
true if the grouping should be performed by the
database; false if it should be performed by
StyleReport.public void setSQLGroup(boolean sqlGroup)
sqlGroup - true if the grouping should be performed by
the database; false if it should be
performed by StyleReport.
public void setProperty(String name,
Object val)
setProperty in interface XDynamicQuerypublic Object getProperty(String name)
getProperty in interface XDynamicQuerypublic String toString()
toString in class Object
|
Copyright © 1996-2014 InetSoft Technology Corp. All Rights Reserved. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||