|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
javax.xml.stream.events Interface Characters
- All Superinterfaces:
- XMLEvent, XMLStreamConstants
public interface Characters
- extends XMLEvent
Implements:
XMLEvent
此方法将描述 Characters 事件的接口。所有文本事件都被报告为 Characters 事件。内容、CData 和空格都被报告为 Characters 事件。在大多数情况下,IgnorableWhitespace 被设置为 false,除非元素内容的声明是用于当前元素的。
version | 1.0 |
This describes the interface to Characters events. All text events get reported as Characters events. Content, CData and whitespace are all reported as Characters events. IgnorableWhitespace, in most cases, will be set to false unless an element declaration of element content is present for the current element.
- Version:
- 1.0
- Author:
- Copyright (c) 2003 by BEA Systems. All Rights Reserved.
Field Summary |
---|
Fields inherited from interface javax.xml.stream.XMLStreamConstants |
---|
ATTRIBUTE, CDATA, CHARACTERS, COMMENT, DTD, END_DOCUMENT, END_ELEMENT, ENTITY_DECLARATION, ENTITY_REFERENCE, NAMESPACE, NOTATION_DECLARATION, PROCESSING_INSTRUCTION, SPACE, START_DOCUMENT, START_ELEMENT |
Method Summary | |
---|---|
String |
getData()
Get the character data of this event |
boolean |
isCData()
Returns true if this is a CData section. |
boolean |
isIgnorableWhiteSpace()
Return true if this is ignorableWhiteSpace. |
boolean |
isWhiteSpace()
Returns true if this set of Characters is all whitespace. |
Methods inherited from interface javax.xml.stream.events.XMLEvent |
---|
asCharacters, asEndElement, asStartElement, getEventType, getLocation, getSchemaType, isAttribute, isCharacters, isEndDocument, isEndElement, isEntityReference, isNamespace, isProcessingInstruction, isStartDocument, isStartElement, writeAsEncodedUnicode |
Method Detail |
---|
public String
getData()
获取此事件的字符数据。
英文文档:
getData
String getData()
- Get the character data of this event
public boolean
isWhiteSpace()
如果此 Characters 集合中都是空格,则返回 true。文档内的空格报告为 CHARACTERS。此方法允许查看 CHARACTERS 事件是否只由空格组成。
英文文档:
isWhiteSpace
boolean isWhiteSpace()
- Returns true if this set of Characters
is all whitespace. Whitespace inside a document
is reported as CHARACTERS. This method allows
checking of CHARACTERS events to see if they
are composed of only whitespace characters
public boolean
isCData()
如果它是一个 CData 节,则返回 true。如果此事件是 CData,则其事件类型为 CDATA。
如果将 javax.xml.stream.isCoalescing 设置为 true,则由非 CDATA 字符包围的 CDATA 节将被报告为单个字符事件。这种情况下,此方法将返回 false。
英文文档:
isCData
boolean isCData()
- Returns true if this is a CData section. If this
event is CData its event type will be CDATA
If javax.xml.stream.isCoalescing is set to true CDATA Sections
that are surrounded by non CDATA characters will be reported
as a single Characters event. This method will return false
in this case.
public boolean
isIgnorableWhiteSpace()
如果它是 ignorableWhiteSpace,则返回 ture。如果此事件是 ignorableWhiteSpace,则其事件类型为 SPACE。
英文文档:
isIgnorableWhiteSpace
boolean isIgnorableWhiteSpace()
- Return true if this is ignorableWhiteSpace. If
this event is ignorableWhiteSpace its event type will
be SPACE.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Submit a bug or feature
Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.
PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!