Package org.jcsp.net

Class NodeUIImpl

  • All Implemented Interfaces:
    Serializable, Comparable

    public class NodeUIImpl
    extends NodeUI
    This is a default implementation for NodeUI that is used if no other implementation is supplied.
    Author:
    Quickstone Technologies Limited
    See Also:
    Serialized Form
    • Constructor Detail

      • NodeUIImpl

        protected NodeUIImpl()
        Constructor which is used as standard to create a new NodeUIImpl object.
      • NodeUIImpl

        public NodeUIImpl​(String s)
        A constructor which takes a String that should be in the format of that returned by the getImplStringForm() method.
        Parameters:
        s - a String used to construct the NodeUIImpl object.
    • Method Detail

      • getImplStringForm

        public String getImplStringForm()
        Returns a String object that can be used with the constructor that takes a String parameter.
        Specified by:
        getImplStringForm in class NodeUI
        Returns:
        a String that holds this object in "string form".
      • checkEqual

        public final boolean checkEqual​(NodeUI other)
        Compares another NodeUI with this NodeUIImpl.
        Specified by:
        checkEqual in class NodeUI
        Parameters:
        other - another NodeUI to compare with this object.
        Returns:
        true iff the NodeUI supplied is a NodeUIImpl object that contains the same internal unique identifier as this object.
      • getComparisonString

        protected String getComparisonString()
        Returns a String that can be used by the superclass to compare two NodeUI objects.
        Specified by:
        getComparisonString in class NodeUI
        Returns:
        a String that follows the rules stated for this method in the NodeUI class.
      • hashCode

        public final int hashCode()
        Returns a hash code for this object.
        Specified by:
        hashCode in class NodeUI
        Returns:
        an int hash code for this object.