org.inria.ns.reflex.processor.exp
Class Exportable

java.lang.Object
  extended by org.inria.ns.reflex.processor.exp.Exportable
All Implemented Interfaces:
Map.Entry, Unwrappable

public class Exportable
extends Object
implements Unwrappable, Map.Entry

An Exportable data embeds the scope of the property to export when using the <exp:export> element.

Author:
Philippe Poulard

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.inria.ns.reflex.structures.Unwrappable
Unwrappable.Unwrapper
 
Field Summary
 
Fields inherited from interface org.inria.ns.reflex.structures.Unwrappable
UNWRAPPER
 
Constructor Summary
Exportable(QName name, Object value, int scope)
          Create an exportable data.
 
Method Summary
 void export(DataSet dataSet)
          Export this data to the data set.
 Object getKey()
          Return the name of the property to export.
 QName getName()
          Return the name of the property to export.
 int getScope()
          Return the scope of the property to export.
 Object getValue()
          Unwrap the value of this exportable data.
 Object setValue(Object value)
          Set the value of this exportable property.
 Object unwrap()
          Unwrap the value of this exportable data.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Map.Entry
equals, hashCode
 

Constructor Detail

Exportable

public Exportable(QName name,
                  Object value,
                  int scope)
Create an exportable data.

Parameters:
name - The name of the exportable data.
value - The value of the exportable data.
scope - The scope of the exportable data.
Method Detail

export

public void export(DataSet dataSet)
Export this data to the data set.

Parameters:
dataSet - The data set to export to.

getName

public QName getName()
Return the name of the property to export.

Returns:
The name.

getScope

public int getScope()
Return the scope of the property to export.

Returns:
The scope of the exportable data.

unwrap

public Object unwrap()
Unwrap the value of this exportable data.

Specified by:
unwrap in interface Unwrappable
Returns:
The value of this exportable data.
See Also:
Unwrappable.unwrap()

getKey

public Object getKey()
Return the name of the property to export.

Specified by:
getKey in interface Map.Entry
Returns:
The name.
See Also:
getName(), Map.Entry.getKey()

getValue

public Object getValue()
Unwrap the value of this exportable data.

Specified by:
getValue in interface Map.Entry
Returns:
The value of this exportable data.
See Also:
unwrap(), Map.Entry.getValue()

setValue

public Object setValue(Object value)
Set the value of this exportable property.

Specified by:
setValue in interface Map.Entry
See Also:
Map.Entry.setValue(java.lang.Object)