org.graffiti.plugin.parameter
Class AttributeParameter

java.lang.Object
  extended by org.graffiti.plugin.parameter.AbstractSingleParameter<Attribute>
      extended by org.graffiti.plugin.parameter.AttributeParameter
All Implemented Interfaces:
Serializable, Displayable<Attribute>, Parameter<Attribute>, SingleParameter<Attribute>

public class AttributeParameter
extends AbstractSingleParameter<Attribute>

This class is used for Parameters that satisfy the org.graffiti.attributes.Attribte interface.

Version:
$Revision: 5767 $
See Also:
Attribute, Serialized Form

Constructor Summary
AttributeParameter(String name, String description)
          Constructs a new attribute parameter.
 
Method Summary
 Attribute getAttribute()
          Returns the Attribute the AttributeParameter represents.
 String getPath()
          Returns the path to the Attribute the AttributeParameter represents.
 void setValue(Attribute value)
          Sets the value of the AttributeParameter.
 String toXMLString()
          Returns a well-formed XML string representing the Displayable.
 
Methods inherited from class org.graffiti.plugin.parameter.AbstractSingleParameter
canCopy, copy, getDependencyParent, getDependencyValue, getDescription, getImage, getName, getStandardXML, getValue, isVisible, setDependency, setDescription, setObjectValue, setVisible, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AttributeParameter

public AttributeParameter(String name,
                          String description)
Constructs a new attribute parameter.

Parameters:
name - the name of the attribute.
description - the description of the attribute.
Method Detail

getAttribute

public Attribute getAttribute()
Returns the Attribute the AttributeParameter represents.

Returns:
the Attribute the AttributeParameter represents.

getPath

public String getPath()
Returns the path to the Attribute the AttributeParameter represents.

Returns:
the path to the Attribute the AttributeParameter represents.

setValue

public void setValue(Attribute value)
Sets the value of the AttributeParameter.

Specified by:
setValue in interface Displayable<Attribute>
Overrides:
setValue in class AbstractSingleParameter<Attribute>
Parameters:
value - the new value of the AttributeParameter.
See Also:
Displayable.setValue(java.lang.Object)

toXMLString

public String toXMLString()
Description copied from interface: Displayable
Returns a well-formed XML string representing the Displayable. The Displayable should be reconstructable via this representation. Therefore it must at least include the type of Displayable (classname) and a representation of its value. PROBABLE FUTURE DESIGN: The Displayables themselves will provide a method to reconstruct their value from the XML representation they provided.

Specified by:
toXMLString in interface Displayable<Attribute>
Overrides:
toXMLString in class AbstractSingleParameter<Attribute>
Returns:
string holding an XML representation of this Displayable
See Also:
Displayable.toXMLString()


Generated at 2012-05-30 11:00:36 PM CEST