Class Attribute


  • public class Attribute
    extends java.lang.Object
    Simple representation of an attribute
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String name  
      private java.lang.String nsURI  
      private java.lang.String value  
    • Constructor Summary

      Constructors 
      Constructor Description
      Attribute​(java.lang.String nsURI, java.lang.String localName, java.lang.String value)
      Constructor of a new Attribute
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getName()
      Get the localName of this attribute
      java.lang.String getNamespace()
      Get the namespace URI of this attribute
      java.lang.String getValue()
      Get value of this attribute
      void setName​(java.lang.String lname)
      Set the localName of this attribute
      void setNsURI​(java.lang.String nsURI)
      Set the namespace URI of this attribute
      void setValue​(java.lang.String value)
      Set value of this attribute
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

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

      • nsURI

        private java.lang.String nsURI
      • name

        private java.lang.String name
      • value

        private java.lang.String value
    • Constructor Detail

      • Attribute

        public Attribute​(java.lang.String nsURI,
                         java.lang.String localName,
                         java.lang.String value)
        Constructor of a new Attribute
        Parameters:
        nsURI - namespaceURI of this attribute (could be null)
        localName - localName of this attribute
        value - value given to this attribute
    • Method Detail

      • getName

        public java.lang.String getName()
        Get the localName of this attribute
        Returns:
        local name of this attribute
      • setName

        public void setName​(java.lang.String lname)
        Set the localName of this attribute
        Parameters:
        lname - the local name to set
      • getNamespace

        public java.lang.String getNamespace()
        Get the namespace URI of this attribute
        Returns:
        the namespace URI associated to this attribute (could be null)
      • setNsURI

        public void setNsURI​(java.lang.String nsURI)
        Set the namespace URI of this attribute
        Parameters:
        nsURI - the namespace URI to set
      • getValue

        public java.lang.String getValue()
        Get value of this attribute
        Returns:
        value of this attribute
      • setValue

        public void setValue​(java.lang.String value)
        Set value of this attribute
        Parameters:
        value - the value to set for this attribute
      • toString

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