com.intel.gpe.gridbeans.plugins.controls
Class DataControl

java.lang.Object
  extended by com.intel.gpe.gridbeans.plugins.controls.DataControl
All Implemented Interfaces:
IDataControl
Direct Known Subclasses:
ButtonDataControl, CheckBoxControl, LabelDataControl, ListDataControl, TextEditorControl, TextFieldDataControl

public abstract class DataControl
extends java.lang.Object
implements IDataControl

The base class for controls.

Version:
$Id: DataControl.java,v 1.3 2005/12/22 09:20:32 lukichev Exp $
Author:
Alexander Lukichev

Constructor Summary
DataControl()
           
 
Method Summary
 java.lang.String getDescription()
          Get the control description.
 boolean isValid(java.lang.Object value, java.lang.StringBuffer reason)
           
 void setDescription(java.lang.String description)
          Set the description of the component.
 void setValueTranslator(IValueTranslator translator)
          Set the translator that translates the value to the user's representation and back.
 void setValueValidator(IValueValidator validator)
          Set the validator of the component value.
 java.lang.Object translateFrom(java.lang.Object value)
           
 java.lang.Object translateTo(java.lang.Object value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.intel.gpe.gridbeans.plugins.IDataControl
getEnabled, getValue, isValid, setEnabled, setPossibleValues, setValue
 

Constructor Detail

DataControl

public DataControl()
Method Detail

getDescription

public java.lang.String getDescription()
Description copied from interface: IDataControl
Get the control description.

Specified by:
getDescription in interface IDataControl
Returns:
The description of the component

setDescription

public void setDescription(java.lang.String description)
Description copied from interface: IDataControl
Set the description of the component.

Specified by:
setDescription in interface IDataControl
Parameters:
description - The description

setValueTranslator

public void setValueTranslator(IValueTranslator translator)
Description copied from interface: IDataControl
Set the translator that translates the value to the user's representation and back.

Specified by:
setValueTranslator in interface IDataControl
Parameters:
translator - The translator

setValueValidator

public void setValueValidator(IValueValidator validator)
Description copied from interface: IDataControl
Set the validator of the component value. The value of the user's component is first translated using the translator to the internal representation and then is validated.

Specified by:
setValueValidator in interface IDataControl
Parameters:
validator - The validator

translateTo

public java.lang.Object translateTo(java.lang.Object value)
                             throws TranslationException
Throws:
TranslationException

translateFrom

public java.lang.Object translateFrom(java.lang.Object value)
                               throws TranslationException
Throws:
TranslationException

isValid

public boolean isValid(java.lang.Object value,
                       java.lang.StringBuffer reason)
                throws DataSetException
Throws:
DataSetException