Class Mechanism

  • Direct Known Subclasses:
    CloudMechanism

    public abstract class Mechanism
    extends java.lang.Object
    The parent class for each type of registered Mechanism.
    • Constructor Summary

      Constructors 
      Constructor Description
      Mechanism()  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getMechURI()
      Getter for the mechanism URI of this Mechanism.
      abstract JSONObject toJson()
      Get a JSON formatted representation of this Mechanism.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • Mechanism

        public Mechanism()
    • Method Detail

      • toJson

        public abstract JSONObject toJson()
        Get a JSON formatted representation of this Mechanism. Each Mechanism that derives from this class will return a JSON representation unique to that particular Mechanism.
        Returns:
        A JSONObject representation of this Mechanism.
        See Also:
        IBM JSONObject
      • getMechURI

        public java.lang.String getMechURI()
        Getter for the mechanism URI of this Mechanism.
        Returns:
        The mechanism URI as a String if this object is a LocalMechanism. "CI_MECHANISM" if this object is a CloudMechanism.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object