|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.walluck.oscar.AIMUtil
AIM utilities.
Constructor Summary | |
AIMUtil()
|
Method Summary | |
static java.lang.String |
about()
Print about information. |
static byte[] |
byteArrayFromHexString(java.lang.String s)
Turn a hex string into the corresponding byte array. |
static java.lang.String |
byteArrayToHexString(byte[] b)
Turn a byte array into the corresponding string. |
static java.lang.String |
charsetAOLToJava(int charset)
Given a short value indicating the charset code, return the corresponding Java string indicating the charset. |
static java.lang.String |
charsetAOLToJava(java.lang.String charset)
Given a string indicating the charset, return the corresponding Java string indicating the charset. |
static java.lang.String |
convertHTMLToOSCAR(java.lang.String str)
Convert from HTML to OSCAR markup |
static java.lang.String |
convertOSCARToHTML(java.lang.String str)
Convert from OSCAR markup to HTML |
static java.lang.String |
dirAOLToSys(java.lang.String name)
Convert an AOL style directory name to system. |
static java.lang.String |
dirSysToAOL(java.lang.String name)
Convert a system style directory name to AOL. |
static java.lang.String |
extractRoomName(java.lang.String s)
Extract the name from a Chat name. |
static java.lang.String |
flapChannelToString(int channel)
Print the plain-text description of a FLAP channel. |
static java.lang.String |
getLibraryDate()
Get the library date. |
static java.lang.String |
getLibraryVersion()
Get the library version. |
static java.lang.String |
hexdump(byte[] data)
Returns a string representing a hex dump of the given byte array. |
static java.lang.String |
memInfo()
Print Java runtime memory information before and after garbage collection. |
static java.lang.String |
normalize(java.lang.String sn)
Normalizes a screenname (removes spaces and lowercases all letters). |
static java.lang.String |
parseProfileEncoding(java.lang.String enc)
Parse a profile encoding string. |
static java.lang.String |
prettyPrintTime(long time)
Convert the time elapsed in milliseconds to a pretty string. |
static java.lang.String |
snacErrorToString(int error)
Return the plain-text description of a SNAC error. |
static java.lang.String |
snacToString(int family,
int subtype)
Return the plain-text description of a SNAC given a family and subtype. |
static boolean |
snCmp(java.lang.String sn1,
java.lang.String sn2)
Checks two given screennames for equality. |
static int |
snLen(java.lang.String sn)
Return the length of the given screenname (ignoring spaces). |
static byte[] |
uuidToByteArray(java.lang.String uuid)
This lets us turn a UUID (Universally Uninque Identifier) string into a byte array. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AIMUtil()
Method Detail |
public static java.lang.String getLibraryVersion()
public static java.lang.String getLibraryDate()
public static int snLen(java.lang.String sn)
sn
- the screenname
public static java.lang.String normalize(java.lang.String sn)
sn
- the non-normalized screenname
public static boolean snCmp(java.lang.String sn1, java.lang.String sn2)
sn1
- the first screennamesn2
- the second screenname
public static byte[] byteArrayFromHexString(java.lang.String s)
s
- the hex string to convert
public static java.lang.String byteArrayToHexString(byte[] b)
b
- the byte array to convert
public static byte[] uuidToByteArray(java.lang.String uuid)
uuid
- the UUID string
public static java.lang.String about()
public static java.lang.String memInfo()
public static java.lang.String flapChannelToString(int channel)
channel
- the FLAP channel
String
valuepublic static java.lang.String snacToString(int family, int subtype)
family
- the SNAC familysubtype
- the SNAC subtype
public static java.lang.String snacErrorToString(int error)
error
- the error code
public static java.lang.String extractRoomName(java.lang.String s)
s
- the Chat name
public static java.lang.String dirAOLToSys(java.lang.String name)
name
- the filename
public static java.lang.String dirSysToAOL(java.lang.String name)
name
- the filename
public static java.lang.String prettyPrintTime(long time)
time
- the time elapsed in milliseconds
public static java.lang.String hexdump(byte[] data)
data
- the byte array of the data you want to hex dump
public static java.lang.String convertHTMLToOSCAR(java.lang.String str)
str
- the string to convert
public static java.lang.String convertOSCARToHTML(java.lang.String str)
str
- the string to convert
public static java.lang.String parseProfileEncoding(java.lang.String enc)
enc
- the profile encoding
public static java.lang.String charsetAOLToJava(int charset) throws java.io.UnsupportedEncodingException
charset
- the short value indicating the charset
java.io.UnsupportedEncodingException
- if an error occurspublic static java.lang.String charsetAOLToJava(java.lang.String charset) throws java.io.UnsupportedEncodingException
charset
- the string indicating the charset
java.io.UnsupportedEncodingException
- if an error occurs
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |