FreeHEP API
Version v1.2.2

hep.graphics.heprep.ref
Class DefaultHepRepAttribute

java.lang.Object
  |
  +--hep.graphics.heprep.ref.DefaultHepRepAttribute
All Implemented Interfaces:
HepRepAttribute, HepRepConstants, Serializable
Direct Known Subclasses:
DefaultHepRepDefinition, DefaultHepRepInstance, DefaultHepRepPoint

public abstract class DefaultHepRepAttribute
extends Object
implements HepRepAttribute, Serializable

Version:
$Id: DefaultHepRepAttribute.java,v 1.23 2003/12/04 23:25:48 duns Exp $
Author:
M.Donszelmann
See Also:
Serialized Form

Field Summary
static String cvsId
           
 
Fields inherited from interface hep.graphics.heprep.HepRepConstants
SHOW_DESC, SHOW_EXTRA, SHOW_NAME, SHOW_NONE, SHOW_VALUE, TYPE_BOOLEAN, TYPE_COLOR, TYPE_DOUBLE, TYPE_INT, TYPE_LONG, TYPE_STRING, TYPE_UNKNOWN
 
Constructor Summary
DefaultHepRepAttribute()
           
 
Method Summary
 void addAttColor(String key, double r, double g, double b, double alpha, int showLabel)
           
 void addAttColor(String key, String colorName, int showLabel)
           
 void addAttValue(HepRepAttValue hepRepAttValue)
          Adds an attValue.
 void addAttValue(String key, boolean value)
          Adds an attValue.
 void addAttValue(String key, boolean value, int showLabel)
          Adds an attValue.
 void addAttValue(String key, Color value)
          Adds a Color attValue.
 void addAttValue(String key, Color value, int showLabel)
          Adds a Color attValue.
 void addAttValue(String key, double value)
          Adds an attValue.
 void addAttValue(String key, double value, int showLabel)
          Adds an attValue.
 void addAttValue(String key, int value)
          Adds an attValue.
 void addAttValue(String key, int value, int showLabel)
          Adds an attValue.
 void addAttValue(String key, String value)
          Adds an attValue.
 void addAttValue(String key, String value, int showLabel)
          Adds an attValue.
 void addAttValue(String name, String value, String type, int showLabel)
           
 boolean equals(Object o)
           
abstract  HepRepAttValue getAttValue(String name)
          Returns the attValue specified by name.
 HepRepAttValue getAttValueFromNode(String lowerCaseName)
          Returns a named attribute value from this node.
 Set getAttValuesFromNode()
          Returns a collection of all attribute values from this node.
 int hashCode()
           
 HepRepAttValue removeAttValue(String key)
          Remove the attvalue named by key.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cvsId

public static final String cvsId
See Also:
Constant Field Values
Constructor Detail

DefaultHepRepAttribute

public DefaultHepRepAttribute()
Method Detail

getAttValuesFromNode

public Set getAttValuesFromNode()
Description copied from interface: HepRepAttribute
Returns a collection of all attribute values from this node.

Specified by:
getAttValuesFromNode in interface HepRepAttribute
Returns:
collection of HepRepAttValues.

addAttValue

public void addAttValue(HepRepAttValue hepRepAttValue)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
hepRepAttValue - to be added.

addAttValue

public void addAttValue(String key,
                        String value)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue

addAttValue

public void addAttValue(String key,
                        int value)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue

addAttValue

public void addAttValue(String key,
                        double value)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue

addAttValue

public void addAttValue(String key,
                        boolean value)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue

addAttValue

public void addAttValue(String key,
                        Color value)
Description copied from interface: HepRepAttribute
Adds a Color attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue

addAttValue

public void addAttValue(String key,
                        String value,
                        int showLabel)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue
showLabel - show this as label

addAttValue

public void addAttValue(String key,
                        int value,
                        int showLabel)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue
showLabel - show this as label

addAttValue

public void addAttValue(String key,
                        double value,
                        int showLabel)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue
showLabel - show this as label

addAttValue

public void addAttValue(String key,
                        boolean value,
                        int showLabel)
Description copied from interface: HepRepAttribute
Adds an attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue
showLabel - show this as label

addAttValue

public void addAttValue(String key,
                        Color value,
                        int showLabel)
Description copied from interface: HepRepAttribute
Adds a Color attValue.

Specified by:
addAttValue in interface HepRepAttribute
Parameters:
key - name of attValue
value - value of attValue
showLabel - show this as label

addAttColor

public void addAttColor(String key,
                        String colorName,
                        int showLabel)

addAttColor

public void addAttColor(String key,
                        double r,
                        double g,
                        double b,
                        double alpha,
                        int showLabel)

addAttValue

public void addAttValue(String name,
                        String value,
                        String type,
                        int showLabel)

getAttValueFromNode

public HepRepAttValue getAttValueFromNode(String lowerCaseName)
Description copied from interface: HepRepAttribute
Returns a named attribute value from this node.

Specified by:
getAttValueFromNode in interface HepRepAttribute
Parameters:
lowerCaseName - name in all lowercase.
Returns:
corresponding HepRepAttValue.

removeAttValue

public HepRepAttValue removeAttValue(String key)
Description copied from interface: HepRepAttribute
Remove the attvalue named by key.

Specified by:
removeAttValue in interface HepRepAttribute
Parameters:
key - name of the attValue to be removed.
Returns:
removed HepRepAttValue, or null if not removed.

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

getAttValue

public abstract HepRepAttValue getAttValue(String name)
Description copied from interface: HepRepAttribute
Returns the attValue specified by name. This attValue is normally searched on the node itself and then on its type, moving up the typetree.

Specified by:
getAttValue in interface HepRepAttribute
Parameters:
name - of attribute value.
Returns:
attribute value.

FreeHEP API
Version v1.2.2

Copyright © 2000-2003 FreeHEP, All Rights Reserved.