|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.sshtools.common.util.GeneralUtil
public final class GeneralUtil
Other utilities not worth their own class
| Constructor Summary | |
|---|---|
GeneralUtil()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
colorToString(java.awt.Color color)
Return a string representation of a color |
static java.lang.String |
encodeHTML(java.lang.String html)
This method will replace '&' with "&", '"' with """, '<' with "<" and '>' with ">". |
static java.lang.String |
numberToPaddedHexString(int number,
int size)
Convert a number to a zero padded hex string |
static java.awt.Color |
stringToColor(java.lang.String s)
Return a Color object given a string representation of it |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GeneralUtil()
| Method Detail |
|---|
public static java.lang.String encodeHTML(java.lang.String html)
html - html to encode
public static java.awt.Color stringToColor(java.lang.String s)
Color object given a string representation of it
color -
java.lang.IllegalArgumentException - if string in bad formatpublic static java.lang.String colorToString(java.awt.Color color)
color -
public static java.lang.String numberToPaddedHexString(int number,
int size)
int - number
java.lang.IllegalArgumentException - if number takes up more characters than
size
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||