| Modifier and Type | Field and Description |
|---|---|
| private static CharsetEncoder | |
| private String | |
| private static CharsetEncoder | |
| private static CharsetEncoder |
| Access | Constructor and Description |
|---|---|
| public | |
| public | NSString(byte[]
An array containing the binary representation of the string. bytes, final int The offset inside the array at which the string data starts. startIndex, final int The offset inside the array at which the string data ends. endIndex, String The string encoding (name of the charset). encoding)Creates a new NSString instance from its binary representation. |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void | |
| public boolean | Returns: The boolean value of this string. Leading whitespaces are ignored. Any + or - sign and leading zeroes are ignored. If the remaining string starts with 'Y', 'y', 'T', 't' or a positive digit (1-9), true is returned. Otherwise, false is returned.Examples: "YES" is true "true" is true " YES" is true "+1" is true "-9" is true " +01" is true "0" is false "false" is false "no" is false "1FALSE" is true "0TRUE" is true "FALSE1" is false Gets the boolean value of this string. |
| public NSString | clone()
Implements abstract com. Creates and returns a deep copy of this instance. |
| public int | compareTo(NSObject o)
Implements java. Compares this object with the specified object for order. |
| public double | Returns: The floating-point value of this string, assuming a decimal representation and skipping whitespace at the beginning of the string. If the string does not contain a valid decimal representation of a floating-point number, 0 is returned.Gets the floating-point value (double precision) of this string. |
| public boolean | equals(Object obj)
Overrides java. Indicates whether some other object is "equal to" this one. |
| pack-priv static String | Returns: The escaped string.The unescaped string. s)Escapes a string for use in ASCII property lists. |
| pack-priv static String | |
| public float | Returns: The floating-point value of this string, assuming a decimal representation and skipping whitespace at the beginning of the string. If the string does not contain a valid decimal representation of a number, 0 is returned. If the string contains an integer larger than Float.MAX_VALUE, Float.MAX_VALUE is returned. If the string contains an integer less than -Float.MAX_VALUE, -Float.MAX_VALUE is returned.Gets the floating-point value of this string. |
| public String | Returns: This string contained in this instance.Gets the string content of this instance. |
| public int | |
| public int | Returns: The integer value of this string, assuming a decimal representation and skipping whitespace at the beginning of the string. If the string does not contain a valid decimal representation of a number, 0 is returned. If the string contains an integer larger than Integer.MAX_VALUE, Integer.MAX_VALUE is returned. If the string contains an integer less than Integer.MIN_VALUE, Integer.MIN_VALUE is returned.Gets the integer value of this string. |
| public void | |
| public void | |
| public void | |
| protected void | toASCII(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object. |
| protected void | toASCIIGnuStep(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object in the GnuStep format. |
| public void | toBinary(BinaryPropertyListWriter out)
Implements abstract com. Generates the binary representation of the object. |
| public Object | toJavaObject()
Implements abstract com. Converts this NSObject into an equivalent object of the Java Runtime Environment. |
| public String | |
| pack-priv void | toXML(StringBuilder xml, int level)
Implements abstract com. Generates the XML representation of the object (without XML headers or enclosing plist-tags). |
| asciiEncoder | back to summary |
|---|---|
| private static CharsetEncoder asciiEncoder | |
| content | back to summary |
|---|---|
| private String content | |
| utf16beEncoder | back to summary |
|---|---|
| private static CharsetEncoder utf16beEncoder | |
| utf8Encoder | back to summary |
|---|---|
| private static CharsetEncoder utf8Encoder | |
| NSString | back to summary |
|---|---|
| public NSString(byte[] bytes, String encoding) throws UnsupportedEncodingException Creates a new NSString instance from its binary representation.
| |
| NSString | back to summary |
|---|---|
| public NSString(byte[] bytes, final int startIndex, final int endIndex, String encoding) throws UnsupportedEncodingException Creates a new NSString instance from its binary representation.
| |
| NSString | back to summary |
|---|---|
| public NSString(String string) Creates a new NSString instance with the specified content.
| |
| append | back to summary |
|---|---|
| public void append(NSString s) Appends a string to this string.
| |
| append | back to summary |
|---|---|
| public void append(String s) Appends a string to this string.
| |
| boolValue | back to summary |
|---|---|
| public boolean boolValue() Gets the boolean value of this string.
| |
| clone | back to summary |
|---|---|
| public NSString clone() Implements abstract com. Doc from com. Creates and returns a deep copy of this instance.
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(NSObject o) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| doubleValue | back to summary |
|---|---|
| public double doubleValue() Gets the floating-point value (double precision) of this string.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes.
| |
| escapeStringForASCII | back to summary |
|---|---|
| pack-priv static String escapeStringForASCII(String s) Escapes a string for use in ASCII property lists. | |
| escapeStringForXml | back to summary |
|---|---|
| pack-priv static String escapeStringForXml(String s) | |
| floatValue | back to summary |
|---|---|
| public float floatValue() Gets the floating-point value of this string.
| |
| getContent | back to summary |
|---|---|
| public String getContent() Gets the string content of this instance.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| intValue | back to summary |
|---|---|
| public int intValue() Gets the integer value of this string.
| |
| prepend | back to summary |
|---|---|
| public void prepend(String s) Prepends a string to this string.
| |
| prepend | back to summary |
|---|---|
| public void prepend(NSString s) Prepends a string to this string.
| |
| setContent | back to summary |
|---|---|
| public void setContent(String c) Sets the string content of this instance.
| |
| toASCII | back to summary |
|---|---|
| protected void toASCII(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object. The generated ASCII representation does not end with a newline. Complies with the Old-Style ASCII Property Lists definition.
| |
| toASCIIGnuStep | back to summary |
|---|---|
| protected void toASCIIGnuStep(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object in the GnuStep format. The generated ASCII representation does not end with a newline.
| |
| toBinary | back to summary |
|---|---|
| public void toBinary(BinaryPropertyListWriter out) throws IOException Implements abstract com. Doc from com. Generates the binary representation of the object.
| |
| toJavaObject | back to summary |
|---|---|
| public Object toJavaObject() Implements abstract com. Doc from com. Converts this NSObject into an equivalent object of the Java Runtime Environment.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non-
| |
| toXML | back to summary |
|---|---|
| pack-priv void toXML(StringBuilder xml, int level) Implements abstract com. Doc from com. Generates the XML representation of the object (without XML headers or enclosing plist-tags).
| |