public interface Attributes2 extends Attributes
Attributes
。如果实现这个扩展提供支持,
ContentHandler.startElement()
属性将实现这个接口,和http://xml.org/sax/features/use-attributes2特征标志将有价值的真实。
This module, both source code and documentation, is in the Public Domain, and comes with NO WARRANTY.
XmlReader实现不要求支持这一信息,而不是部分核心SAX2分布。
注意,如果一个属性是默认的(!isspecified())它必然也已宣布在DTD(isdeclared())。同样,如果一个属性的类型是什么,除了我,那么它一定是宣布。
Modifier and Type | Method and Description |
---|---|
boolean |
isDeclared(int index)
返回false,除非是在DTD中声明的属性。
|
boolean |
isDeclared(String qName)
返回false,除非是在DTD中声明的属性。
|
boolean |
isDeclared(String uri, String localName)
返回false,除非是在DTD中声明的属性。
|
boolean |
isSpecified(int index)
返回true如果属性值是由违约提供DTD。
|
boolean |
isSpecified(String qName)
返回true如果属性值是由违约提供DTD。
|
boolean |
isSpecified(String uri, String localName)
返回true如果属性值是由违约提供DTD。
|
boolean isDeclared(int index)
index
-属性索引(从零开始)。
ArrayIndexOutOfBoundsException
-当供电指标不确定属性。
boolean isDeclared(String qName)
qName
合格的XML(前缀)的名字。
IllegalArgumentException
时提供的名称不能识别属性。
boolean isDeclared(String uri, String localName)
记住,因为DTDs不理解命名空间与属性关联的命名空间URI可能来自DTD。该宣言将应用于属性的属性。
uri
的命名空间URI或空字符串,如果名字没有命名空间URI。
localName
-属性的本地名称。
IllegalArgumentException
时提供的名称不确定属性。
boolean isSpecified(int index)
index
-属性索引(从零开始)。
ArrayIndexOutOfBoundsException
-当供电指标不确定属性。
boolean isSpecified(String uri, String localName)
记住,因为DTDs不理解命名空间与属性关联的命名空间URI可能来自DTD。该宣言将应用于属性的属性。
uri
的命名空间URI或空字符串,如果名字没有命名空间URI。
localName
-属性的本地名称。
IllegalArgumentException
时提供的名称不确定属性。
boolean isSpecified(String qName)
qName
合格的XML(前缀)的名字。
IllegalArgumentException
时提供的名称不能识别属性。
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.