|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectorg.apache.jasper.xmlparser.XMLString
public class XMLString
This class is used as a structure to pass text contained in the underlying character buffer of the scanner. The offset and length fields allow the buffer to be re-used without creating new character arrays.
Note: Methods that are passed an XMLString structure should consider the contents read-only and not make any modifications to the contents of the buffer. The method receiving this structure should also not modify the offset and length if this structure (or the values of this structure) are passed to another method.
Note: Methods that are passed an XMLString structure are required to copy the information out of the buffer if it is to be saved for use beyond the scope of the method. The contents of the structure are volatile and the contents of the character buffer cannot be assured once the method that is passed this structure returns. Therefore, methods passed this structure should not save any reference to the structure or the character array contained in the structure.
| 字段摘要 | |
|---|---|
char[] |
ch
The character array. |
int |
length
The length of characters from the offset. |
int |
offset
The offset into the character array. |
| 构造方法摘要 | |
|---|---|
XMLString()
Default constructor. |
|
XMLString(char[] ch,
int offset,
int length)
Constructs an XMLString structure preset with the specified values. |
|
XMLString(XMLString string)
Constructs an XMLString structure with copies of the values in the given structure. |
|
| 方法摘要 | |
|---|---|
void |
clear()
Resets all of the values to their defaults. |
boolean |
equals(char[] ch,
int offset,
int length)
Returns true if the contents of this XMLString structure and the specified array are equal. |
boolean |
equals(String s)
Returns true if the contents of this XMLString structure and the specified string are equal. |
void |
setValues(char[] ch,
int offset,
int length)
Initializes the contents of the XMLString structure with the specified values. |
void |
setValues(XMLString s)
Initializes the contents of the XMLString structure with copies of the given string structure. |
String |
toString()
Returns a string representation of this object. |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| 字段详细信息 |
|---|
public char[] ch
public int offset
public int length
| 构造方法详细信息 |
|---|
public XMLString()
public XMLString(char[] ch,
int offset,
int length)
ch - The character array.offset - The offset into the character array.length - The length of characters from the offset.public XMLString(XMLString string)
Note: This does not copy the character array; only the reference to the array is copied.
string - The XMLString to copy.| 方法详细信息 |
|---|
public void setValues(char[] ch,
int offset,
int length)
ch - The character array.offset - The offset into the character array.length - The length of characters from the offset.public void setValues(XMLString s)
Note: This does not copy the character array; only the reference to the array is copied.
s - public void clear()
public boolean equals(char[] ch,
int offset,
int length)
ch - The character array.offset - The offset into the character array.length - The length of characters from the offset.public boolean equals(String s)
s - The string to compare.public String toString()
Object 中的 toString
|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||