org.gatein.mop.core.util
Class AbstractAttributes

java.lang.Object
  extended by org.gatein.mop.core.util.AbstractAttributes
All Implemented Interfaces:
Attributes
Direct Known Subclasses:
SimpleAttributes

public abstract class AbstractAttributes
extends Object
implements Attributes

Version:
$Revision$
Author:
Julien Viet

Constructor Summary
AbstractAttributes()
           
 
Method Summary
protected abstract  Object get(String name)
           
 Boolean getBoolean(String name)
           
 Date getDate(String name)
           
 Double getDouble(String name)
           
 Integer getInteger(String name)
           
 Object getObject(String name)
           
 String getString(String name)
           
 ValueType<?> getType(String name)
           
<T> T
getValue(Key<T> key)
           
<T> T
getValue(Key<T> key, T defaultValue)
           
protected abstract  void set(String name, Object o)
           
 void setBoolean(String name, Boolean value)
           
 void setDate(String name, Date value)
           
 void setDouble(String name, Double value)
           
 void setInteger(String name, Integer value)
           
<T> void
setObject(String name, T value)
           
 void setString(String name, String value)
           
<T> void
setValue(Key<T> key, T value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.gatein.mop.api.Attributes
getKeys
 

Constructor Detail

AbstractAttributes

public AbstractAttributes()
Method Detail

get

protected abstract Object get(String name)

set

protected abstract void set(String name,
                            Object o)

getObject

public final Object getObject(String name)
Specified by:
getObject in interface Attributes

setObject

public final <T> void setObject(String name,
                                T value)
Specified by:
setObject in interface Attributes

getType

public final ValueType<?> getType(String name)
Specified by:
getType in interface Attributes

getString

public final String getString(String name)
Specified by:
getString in interface Attributes

setString

public final void setString(String name,
                            String value)
Specified by:
setString in interface Attributes

getBoolean

public final Boolean getBoolean(String name)
Specified by:
getBoolean in interface Attributes

setBoolean

public final void setBoolean(String name,
                             Boolean value)
Specified by:
setBoolean in interface Attributes

getInteger

public final Integer getInteger(String name)
Specified by:
getInteger in interface Attributes

setInteger

public final void setInteger(String name,
                             Integer value)
Specified by:
setInteger in interface Attributes

getDate

public final Date getDate(String name)
Specified by:
getDate in interface Attributes

setDate

public final void setDate(String name,
                          Date value)
Specified by:
setDate in interface Attributes

getDouble

public final Double getDouble(String name)
Specified by:
getDouble in interface Attributes

setDouble

public final void setDouble(String name,
                            Double value)
Specified by:
setDouble in interface Attributes

getValue

public final <T> T getValue(Key<T> key,
                            T defaultValue)
Specified by:
getValue in interface Attributes

getValue

public final <T> T getValue(Key<T> key)
Specified by:
getValue in interface Attributes

setValue

public final <T> void setValue(Key<T> key,
                               T value)
Specified by:
setValue in interface Attributes


Copyright © 2009 eXo Platform SAS. All Rights Reserved.