| java.lang.Object org.w3c.tools.resources.Attribute org.w3c.tools.resources.ObjectAttribute
ObjectAttribute | public class ObjectAttribute extends Attribute (Code) | | A generic Object attribute.
This attribute is usefull for attributes that are:
- Have Object values.
- Need not be saved (have the DONTSAVE bit set).
|
Field Summary | |
protected Class | cls The class for values of this attribute. |
cls | protected Class cls(Code) | | The class for values of this attribute.
|
ObjectAttribute | public ObjectAttribute(String name, Class cls, Object def, int flags)(Code) | | Create a new ObjectAttribute instance.
Parameters: name - The name of the attribute. Parameters: cls - The class for this attribute values. Parameters: def - The default value for this attribute. Parameters: flags - The attribute flags. |
ObjectAttribute | public ObjectAttribute(String name, String cname, Object def, int flags)(Code) | | Create a new ObjectAttribute instance.
Parameters: name - The name of the attribute. Parameters: cname - The name class for this attribute values. Parameters: def - The default value for this attribute. Parameters: flags - The attribute flags. exception: RuntimeException - If we couldn't resolve the class name. |
checkValue | public boolean checkValue(Object value)(Code) | | Check that a value is allowed for this attribute.
Parameters: value - The value to check. A boolean true if value is allowed. |
pickle | public String pickle(Object obj)(Code) | | Pickle an integer to the given output stream.
Parameters: obj - The object to pickle. |
unpickle | public Object unpickle(String value)(Code) | | Unpickle an integer from the given input stream.
Parameters: value - the string representation of this integer An instance of Integer. |
|
|