org.netbeans.microedition.databinding
Interface DataSet

All Known Subinterfaces:
IndexableDataSet

public interface DataSet

An interface for describing


Method Summary
 java.lang.Class getType(java.lang.String dataItemName)
          Gets type of the given data item
 java.lang.Object getValue(java.lang.String dataItemName)
          Gets value for the given data item
 boolean isReadOnly(java.lang.String dataItemName)
          Checks whether the given data item is read only (i.e.
 void setAsString(java.lang.String dataItemName, java.lang.String value)
          Sets string value to the given data item.
 void setValue(java.lang.String dataItemName, java.lang.Object value)
          Sets value to the given data item.
 

Method Detail

getType

java.lang.Class getType(java.lang.String dataItemName)
                        throws DataBindingException
Gets type of the given data item

Parameters:
dataItemName -
Returns:
type for the given data item
Throws:
DataBindingException

getValue

java.lang.Object getValue(java.lang.String dataItemName)
                          throws DataBindingException
Gets value for the given data item

Parameters:
dataItemName -
Returns:
value for the given data item
Throws:
DataBindingException

setValue

void setValue(java.lang.String dataItemName,
              java.lang.Object value)
              throws DataBindingException
Sets value to the given data item.

Parameters:
dataItemName - name of the data item
value - value to be set
Throws:
DataBindingException

setAsString

void setAsString(java.lang.String dataItemName,
                 java.lang.String value)
                 throws DataBindingException
Sets string value to the given data item. This method needs to perform conversion from string to the correct type of the value specified by given data item name. In the case the conversion cannot be done, DataBindingException is thrown.

Parameters:
dataItemName - name of the data item
value - String value to be set
Throws:
DataBindingException

isReadOnly

boolean isReadOnly(java.lang.String dataItemName)
                   throws DataBindingException
Checks whether the given data item is read only (i.e. setValue() method should not be called on this data item

Parameters:
dataItemName - name of the data item to be checked
Returns:
Throws:
DataBindingException