net.kano.joscar
Class EncodedStringInfo

java.lang.Object
  extended bynet.kano.joscar.EncodedStringInfo

public final class EncodedStringInfo
extends java.lang.Object

A simple structure containing a block of data and the name of the charset that was used to encode that block of data from a text string.


Constructor Summary
EncodedStringInfo(java.lang.String charset, byte[] data)
          Creates a new EncodedStringInfo with the given properties.
 
Method Summary
 java.lang.String getCharset()
          Returns the name of the charset that encoded the associated data from a String.
 byte[] getData()
          The data block encoded from a String by the associated charset.
 ImEncodingParams getImEncoding()
          Returns an ImEncoding object that describes the charset used to encode the associated string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EncodedStringInfo

public EncodedStringInfo(java.lang.String charset,
                         byte[] data)
Creates a new EncodedStringInfo with the given properties.

Parameters:
charset - the character set used to encode the given data
data - the data encoded by the given character set
Method Detail

getCharset

public final java.lang.String getCharset()
Returns the name of the charset that encoded the associated data from a String.

Returns:
the name of the charset that encoded the associated data block

getImEncoding

public final ImEncodingParams getImEncoding()
Returns an ImEncoding object that describes the charset used to encode the associated string.

Returns:
an ImEncoding describing the charset that encoded the string associated with this EncodedStringInfo
See Also:
ImEncodedString

getData

public final byte[] getData()
The data block encoded from a String by the associated charset.

Returns:
the data block encoded by the associated charset