Class BaseEdge

  • All Implemented Interfaces:
    Edge, Attributable

    public abstract class BaseEdge
    extends java.lang.Object
    implements Edge
    Common implementation of Attributable interface used by Nodes.
    Version:
    $Id: BaseEdge.java 956 2008-11-30 01:18:20Z rambaut $
    Author:
    Joseph Heled
    • Constructor Summary

      Constructors 
      Constructor Description
      BaseEdge()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object getAttribute​(java.lang.String name)  
      java.util.Map<java.lang.String,​java.lang.Object> getAttributeMap()
      Gets the entire attribute map.
      java.util.Set<java.lang.String> getAttributeNames()  
      void removeAttribute​(java.lang.String name)  
      void setAttribute​(java.lang.String name, java.lang.Object value)
      Sets an named attribute for this object.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface jebl.evolution.graphs.Edge

        getLength
    • Constructor Detail

      • BaseEdge

        public BaseEdge()
    • Method Detail

      • setAttribute

        public void setAttribute​(java.lang.String name,
                                 java.lang.Object value)
        Description copied from interface: Attributable
        Sets an named attribute for this object.
        Specified by:
        setAttribute in interface Attributable
        Parameters:
        name - the name of the attribute.
        value - the new value of the attribute.
      • getAttribute

        public java.lang.Object getAttribute​(java.lang.String name)
        Specified by:
        getAttribute in interface Attributable
        Parameters:
        name - the name of the attribute of interest, or null if the attribute doesn't exist.
        Returns:
        an object representing the named attributed for this object.
      • removeAttribute

        public void removeAttribute​(java.lang.String name)
        Specified by:
        removeAttribute in interface Attributable
        Parameters:
        name - name of attribute to remove
      • getAttributeNames

        public java.util.Set<java.lang.String> getAttributeNames()
        Specified by:
        getAttributeNames in interface Attributable
        Returns:
        an array of the attributeNames that this object has.
      • getAttributeMap

        public java.util.Map<java.lang.String,​java.lang.Object> getAttributeMap()
        Description copied from interface: Attributable
        Gets the entire attribute map.
        Specified by:
        getAttributeMap in interface Attributable
        Returns:
        an unmodifiable map