|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.formaria.aria.data.DataModel
org.formaria.editor.data.pojo.PojoModelVis
public abstract class PojoModelVis
An abstract class representing design-time pojo model (for use by "data visualiser")
Copyright (c) Formaria Ltd., 2001-2007, This software is licensed under the GNU Public License (GPL), please see license.txt for more details. If you make commercial use of this software you must purchase a commercial license from Formaria.
| Field Summary | |
|---|---|
protected PojoAdapterEx |
adapter
|
static int |
ATTRIB_COMBO
|
static int |
ATTRIB_FREETEXT
|
static int |
ATTRIB_NEDITABLE
|
protected PojoDataSourceEx |
dataSource
|
protected java.lang.Class[] |
getterSig
|
protected int |
hashcode
|
static int |
ID_ATTRIBUTE
|
protected java.lang.String |
idAttrib
|
static int |
NUM_FIXED_ATTRIBUTE
|
protected java.lang.Object |
pojo
|
protected java.lang.Class |
pojoClass
|
protected PojoModelVis[] |
pojoCollection
|
protected java.lang.reflect.Method |
pojoGetter
|
protected java.lang.reflect.Method |
pojoSetter
|
protected java.lang.Class[] |
setterSig
|
static int |
VALUE_ATTRIBUTE
|
protected java.lang.String |
valueAttrib
|
| Fields inherited from class org.formaria.aria.data.DataModel |
|---|
parentModel, tagName |
| Constructor Summary | |
|---|---|
PojoModelVis(DataModel pr,
java.lang.Class clazz,
PojoDataSourceEx ds)
Creates a new instance of PojoModelVis |
|
PojoModelVis(DataModel pr,
java.lang.reflect.Method gtr,
java.lang.reflect.Method str,
PojoDataSourceEx ds)
Creates a new instance of PojoModelVis class. |
|
PojoModelVis(DataModel pr,
java.lang.Object pj,
PojoDataSourceEx ds)
Creates a new instance of PojoModelVis |
|
PojoModelVis(DataModel pr,
PojoDataSourceEx ds)
Creates a new instance of PojoModelVis class. |
|
| Method Summary | |
|---|---|
void |
append(DataModel xModel)
Append a node |
java.lang.Object |
append(java.lang.String string)
Append a new node with the specified name. |
java.lang.Object |
get()
gets the value attribute |
DataModel |
get(int i)
Get the DataModel at element i |
PojoAdapterEx |
getAdapter()
Gets the adapter of this model node |
java.lang.String[] |
getAttribAvailableValues(int i)
|
java.lang.String |
getAttribName(int i)
Retrieve the name of the attribute at the specified index |
boolean |
getAttribRuntime(int i)
Indicates whether the attribute will be available in the run-time mode. |
int |
getAttribType(int i)
|
int |
getAttribute(java.lang.String string)
returns the index of the attribiteNames array whose value is the same as the attribName |
java.lang.Object |
getAttribValue(int i)
Retrieve the value of the attribute at the specified index and return it. |
double |
getAttribValueAsDouble(int i)
Retrieve the value of the attribute at the specified index, convert it to a double and return it. |
double |
getAttribValueAsDouble(int i,
char c,
char c0)
Convert the attribute at the specified index to a double and return it |
int |
getAttribValueAsInt(int i)
Retrieve the value of the attribute at the specified index, convert it to an int and return it. |
java.lang.String |
getAttribValueAsString(int i)
Retrieve the value of the attribute at the specified index, convert it to a String and return it. |
java.util.Vector |
getBindingAttributes()
Gest the binding attributes that this model node can provide. |
java.lang.String |
getBindingPath()
Gets the runtime binding path of this model node |
java.lang.String |
getCaption()
Gets the visualiser tree caption of this node. |
java.lang.String |
getId()
Gets the ID attribute of this node |
int |
getNumAttributes()
Gets the number of attributes |
java.lang.Class |
getPojoClass()
|
PojoProperties |
getProperties()
Gets the properties of the encapsulated POJO |
double |
getValueAsDouble(java.lang.String string)
Retrieve the named child, convert it's value to a double and return it. |
int |
getValueAsInt(java.lang.String string)
Retrieve the named child, convert it's value to an int and return it. |
java.lang.String |
getValueAsString(java.lang.String string)
Retrieve the named child, convert it's value to a String and return it. |
int |
hashCode()
The hashcode of this instance. |
boolean |
isAttribEditable(int i)
|
boolean |
isDirty()
Gets the value of the dirty property |
void |
set(java.lang.Object obj)
Sets the model value |
void |
set(java.lang.String string,
java.lang.Object object)
Set the named attribute value of this DataModel node. |
void |
setAttribValue(int i,
java.lang.Object value)
Sets the attribute value |
void |
setAttribValue(int i,
java.lang.String string,
java.lang.Object object)
Sets the attribute name and value |
void |
setCaption(java.lang.String caption)
Sets the caption of this node which will be shown in the model visualiser tree. |
void |
setDirty(boolean state)
Sets the dirty flag of this model node. |
void |
setId(java.lang.String newId)
Sets the ID attribute |
protected void |
setPojo(java.lang.Object aPojo)
Sets the underlying pojo of this model node |
protected void |
setPojoClass(java.lang.Class clazz)
Sets the type of the underlying pojo. |
protected void |
setPojoGetter(java.lang.reflect.Method aMethod)
Sets the method being used to obtain the pojo of this node. |
protected void |
setPojoSetter(java.lang.reflect.Method aMethod)
Sets the method being used to set the pojo of this node |
| Methods inherited from class org.formaria.aria.data.DataModel |
|---|
addModelListener, clear, fireModelUpdated, get, getNumChildren, getParent, getTagName, hasAutoId, hasAutoId, prefixOutputPath, removeChildren, reset, resetAttributes, setNumAttributes, setNumChildren, setParent, setTagName |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int ATTRIB_NEDITABLE
public static final int ATTRIB_COMBO
public static final int ATTRIB_FREETEXT
public static final int ID_ATTRIBUTE
public static final int VALUE_ATTRIBUTE
public static final int NUM_FIXED_ATTRIBUTE
protected volatile int hashcode
protected java.lang.String idAttrib
protected java.lang.String valueAttrib
protected PojoDataSourceEx dataSource
protected java.lang.Object pojo
protected PojoModelVis[] pojoCollection
protected java.lang.Class pojoClass
protected java.lang.reflect.Method pojoGetter
protected java.lang.Class[] getterSig
protected java.lang.reflect.Method pojoSetter
protected java.lang.Class[] setterSig
protected PojoAdapterEx adapter
| Constructor Detail |
|---|
public PojoModelVis(DataModel pr,
java.lang.Object pj,
PojoDataSourceEx ds)
pr - the parent model node.pojo - Object being wrapped by this model node.ds - the data source object.
public PojoModelVis(DataModel pr,
java.lang.reflect.Method gtr,
java.lang.reflect.Method str,
PojoDataSourceEx ds)
pr - the parent mode nodemth - the getter method being used to obtain
the pojo to be wrapped by this model node.ds - the data source object.
public PojoModelVis(DataModel pr,
java.lang.Class clazz,
PojoDataSourceEx ds)
pr - the parent model nodeclazz - the type of the underlying pojo.ds - the data source object.
public PojoModelVis(DataModel pr,
PojoDataSourceEx ds)
pr - the parent model node| Method Detail |
|---|
public PojoProperties getProperties()
protected void setPojo(java.lang.Object aPojo)
aPojo - the new pojopublic PojoAdapterEx getAdapter()
protected void setPojoGetter(java.lang.reflect.Method aMethod)
aMethod - the getter methodprotected void setPojoSetter(java.lang.reflect.Method aMethod)
aMethod - the setterprotected void setPojoClass(java.lang.Class clazz)
clazz - the type of the underlying pojopublic java.lang.Class getPojoClass()
public void setDirty(boolean state)
dirty flag of this model node.
state - the new value of the dirty flagpublic boolean isDirty()
public java.lang.String getBindingPath()
getBindingPath in interface ModelVispublic java.lang.String getCaption()
getCaption in interface TreeNodeCaptionpublic void setCaption(java.lang.String caption)
setCaption in interface TreeNodeCaptioncaption - the caption to be setpublic java.lang.String getId()
getId in class DataModelpublic void setId(java.lang.String newId)
setId in class DataModelnewId - the new namepublic int getNumAttributes()
getNumAttributes in class DataModelpublic java.lang.String getAttribName(int i)
DataModel
getAttribName in class DataModeli - The index of the attributeNames array whose value we want
public java.lang.Object getAttribValue(int i)
DataModel
getAttribValue in class DataModeli - The index of the attributeValues array whose value we want
public java.lang.String getAttribValueAsString(int i)
DataModel
getAttribValueAsString in class DataModeli - The index of the attributeValues array whose value we want
public int hashCode()
hashCode in class DataModelpublic java.util.Vector getBindingAttributes()
getBindingAttributes in interface ModelVis
public void set(java.lang.String string,
java.lang.Object object)
DataModel
set in class DataModelstring - The path to the DataModel in the format 'base/fooobject - The new value of the DataModelpublic int getAttribute(java.lang.String string)
DataModel
getAttribute in class DataModelstring - The name of the attribute we are trying to locate
public void setAttribValue(int i,
java.lang.String string,
java.lang.Object object)
DataModel
setAttribValue in class DataModeli - The index of the attributeValues array whose value we wantstring - the name of the attributeobject - the value objectpublic java.lang.Object get()
DataModel
get in class DataModelpublic double getAttribValueAsDouble(int i)
DataModel
getAttribValueAsDouble in class DataModeli - The index of the attributeValues array whose value we want
public double getAttribValueAsDouble(int i,
char c,
char c0)
DataModel
getAttribValueAsDouble in class DataModeli - The index of the attributeValues array whose value we wantc - the decimal separatorc0 - the grouping (thousands) separator
public int getAttribValueAsInt(int i)
DataModel
getAttribValueAsInt in class DataModeli - The index of the attributeValues array whose value we want
public double getValueAsDouble(java.lang.String string)
DataModel
getValueAsDouble in class DataModelstring - The name of the child whose value is required
public int getValueAsInt(java.lang.String string)
DataModel
getValueAsInt in class DataModelstring - The name of the child to be retrieved
public java.lang.String getValueAsString(java.lang.String string)
DataModel
getValueAsString in class DataModelstring - The name of the child whose value is required
public void append(DataModel xModel)
DataModel
append in class DataModelxModel - the child nodepublic java.lang.Object append(java.lang.String string)
DataModel
append in class DataModelstring - The immediate path to the DataModel required
public DataModel get(int i)
DataModel
get in class DataModeli - The index of the values array
public void set(java.lang.Object obj)
DataModel
set in class DataModelobj - the new valuepublic boolean getAttribRuntime(int i)
i - the index of the attribute
public int getAttribType(int i)
public java.lang.String[] getAttribAvailableValues(int i)
public boolean isAttribEditable(int i)
public void setAttribValue(int i,
java.lang.Object value)
DataModel
setAttribValue in class DataModeli - The index of the attributeValues array whose value we wantvalue - the value object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||