com.smartgwt.client.data
Class Record
java.lang.Object
com.smartgwt.client.core.JsObject
com.smartgwt.client.core.DataClass
com.smartgwt.client.core.RefDataClass
com.smartgwt.client.data.Record
- Direct Known Subclasses:
- CalendarEvent, DetailViewerRecord, ListGridRecord
public class Record
- extends RefDataClass
A Record is an ordinary Java class with properties that are treated as data to be displayed and edited by a
DataBoundComponent
.
DataBoundComponent
s have a concept of named fields, where values for each field
are found under the same-named property in a Record.
A Record is always an ordinary Java object regardless of how the record is loaded (static data, java server, XML web service, etc).
The concept of working with Records is common to all DataBoundComponent
s, although individual
DataBoundComponents may work with singular records (DynamicForm
) or may work with lists
(ListGrid
), trees (TreeGrid
), or cubes
(CubeGrid) of records.
Individual DataComponents may also look for special properties on Records which control styling or behavior for those records,
such as ListGrid.setRecordEditProperty(String)
Fields inherited from class com.smartgwt.client.core.JsObject |
jsObj |
Methods inherited from class com.smartgwt.client.core.DataClass |
doAddHandler, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsFloat, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsObject, getAttributeAsString, getAttributeAsStringArray, getAttributes, getHandlerCount, getJsObj, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Record
public Record()
Record
public Record(JavaScriptObject jsObj)
getOrCreateRef
public static Record getOrCreateRef(JavaScriptObject jsObj)
getAttributeAsRecordArray
public Record[] getAttributeAsRecordArray(String property)
- Returns the nested structure as Record array.
- Parameters:
property
- the record property
- Returns:
- array of records
getAttributeAsRecordList
public RecordList getAttributeAsRecordList(String property)
- Returns the nested structure as a RecordList.
- Parameters:
property
- the record property
- Returns:
- the RecordList
convertToRecordArray
public static Record[] convertToRecordArray(JavaScriptObject nativeArray)