Class IdRefAttribute

  • Direct Known Subclasses:
    Element_label.Attr_for

    public abstract class IdRefAttribute
    extends NmTokenAttribute
    Implements an Attribute of "IDREF" type, which holds as its value a single id value. See [XML 1.0], "3.3.1 Attribute Types".
    • Method Detail

      • checkValue

        protected void checkValue​(@Opt
                                  @Opt java.lang.String value)
                           throws TdomAttributeSyntaxException
        Description copied from class: TypedAttribute
        Check routine for the validity of the attributes' intended value. Is a call-back, implemented by the sub-classes. Is called only here, by two constructors and the #set_value(V) method. The value null means "absent" for #IMPLIED attributes and passes the test.
        Overrides:
        checkValue in class NmTokenAttribute
        Parameters:
        value - the value to test; maybe null.
        Throws:
        TdomAttributeSyntaxException - iff the value does not match the type of the XML attribute, including a forbidden Null.
      • getTypeString

        public java.lang.String getTypeString()
        Description copied from class: TypedAttribute
        The definition text for the "type" of the attribute in the original DTD.
        Overrides:
        getTypeString in class NmTokenAttribute
      • getValue

        @Opt
        public <E extends TypedElement<E,​X>,​X extends TypedExtension> E getValue​(ElementDictionary<? extends E,​X> dict)
        Look up the element for the current value of this.
        Parameters:
        dict - The dictionary to use.
        Returns:
        the Element found, or null if no such exists. (This is always the case if the value==null, i.e. "this" is IMPLIED and unset in the document.)