01: package javax.xml.stream.events;
02:
03: import javax.xml.namespace.QName;
04:
05: /**
06: * An interface that contains information about an attribute. Attributes are reported
07: * as a set of events accessible from a StartElement. Other applications may report
08: * Attributes as first-order events, for example as the results of an XPath expression.
09: *
10: * @version 1.0
11: * @author Copyright (c) 2003 by BEA Systems. All Rights Reserved.
12: * @see StartElement
13: */
14: public interface Attribute extends XMLEvent {
15:
16: /**
17: * Returns the QName for this attribute
18: */
19: QName getName();
20:
21: /**
22: * Gets the normalized value of this attribute
23: */
24: public String getValue();
25:
26: /**
27: * Gets the type of this attribute, default is
28: * the String "CDATA"
29: * @return the type as a String, default is "CDATA"
30: */
31: public String getDTDType();
32:
33: /**
34: * A flag indicating whether this attribute was actually
35: * specified in the start-tag of its element, or was defaulted from the schema.
36: * @return returns true if this was specified in the start element
37: */
38: public boolean isSpecified();
39:
40: }
|