Class CDAResource

    • Constructor Summary

      Constructors 
      Constructor Description
      CDAResource()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.lang.Object> attrs()  
      <T> T getAttribute​(java.lang.String key)
      Retrieve a specific attribute of this resource.
      java.lang.String id()  
      java.lang.String toString()  
      CDAType type()  
      • Methods inherited from class java.lang.Object

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

      • CDAResource

        public CDAResource()
    • Method Detail

      • id

        public java.lang.String id()
        Returns:
        a string representing this object's id.
      • type

        public CDAType type()
        Returns:
        the type of this resource.
      • attrs

        public java.util.Map<java.lang.String,​java.lang.Object> attrs()
        Returns:
        all of the attributes, this object holds.
      • getAttribute

        public <T> T getAttribute​(java.lang.String key)
        Retrieve a specific attribute of this resource.
        Type Parameters:
        T - the type of the attribute to be retrieved.
        Parameters:
        key - a string key associated with the value to be retrieved.
        Returns:
        the actual value of the attribute, or null, if there the key was not found.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
        Returns:
        a human readable string, representing the object.