Package com.tailf.proto
Class ConfEString
Object
com.tailf.proto.ConfEObject
com.tailf.proto.ConfEString
- All Implemented Interfaces:
Serializable
,Cloneable
Provides a Java representation of E strings.
- See Also:
-
Constructor Summary
ConstructorDescriptionCreate an E string from a stream containing a string encoded in E external format.ConfEString
(String str) Create an E string from the given string. -
Method Summary
Modifier and TypeMethodDescriptionvoid
encode
(ConfOutputStream buf) Convert this string to the equivalent E external representation.boolean
Determine if two strings are equal.Get the actual string contained in this object.toString()
Get the printable version of the string contained in this object.Methods inherited from class com.tailf.proto.ConfEObject
clone, decode
-
Constructor Details
-
ConfEString
Create an E string from the given string. -
ConfEString
Create an E string from a stream containing a string encoded in E external format.- Parameters:
buf
- the stream containing the encoded string.- Throws:
ConfEDecodeException
- if the buffer does not contain a valid external representation of an E string.
-
-
Method Details
-
stringValue
Get the actual string contained in this object.- Returns:
- the raw string contained in this object, without regard to E quoting rules.
- See Also:
-
toString
Get the printable version of the string contained in this object.- Specified by:
toString
in classConfEObject
- Returns:
- the string contained in this object, quoted.
- See Also:
-
encode
Convert this string to the equivalent E external representation.- Specified by:
encode
in classConfEObject
- Parameters:
buf
- an output stream to which the encoded string should be written.
-
equals
Determine if two strings are equal. They are equal if they represent the same sequence of characters. This method can be used to compare ConfEStrings with each other and with Strings.- Specified by:
equals
in classConfEObject
- Parameters:
o
- the ConfEString or String to compare to.- Returns:
- true if the strings consist of the same sequence of characters, false otherwise.
-