|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.brains2b.typewriter.TypeWriterHelper
Helper library for TypeWriter
Constructor Summary | |
TypeWriterHelper()
|
Method Summary | |
static java.lang.String |
getClassName(java.lang.Class c)
get the name without the package from the class |
static java.lang.String |
getClassName(java.lang.String s)
get the name without the package from the String representing a class |
static java.lang.String |
getModifiers(int modifiers)
get a String representation for the sum of modifiers as defined in java.lang.reflect.Modifier
supports:
private
public
protected
final
static
|
static java.lang.String |
makeString(java.lang.String value)
make a String between quotes from the supplied String |
static java.lang.String |
spaces(int length)
create a String of length length filled with spaces There is a faster way to do this, by using a static char array to read from, but it is only slightly faster and consumes extra memory and more lines of code |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TypeWriterHelper()
Method Detail |
public static final java.lang.String getClassName(java.lang.Class c)
c
- Class, the class for which to retrieve the name
null
if class is nullpublic static final java.lang.String getClassName(java.lang.String s)
s
- String, the String representing a class for which to retrieve the name.
If no package is supplied the return value is same as the value offered
null
if String is null, or String is emptypublic static java.lang.String getModifiers(int modifiers)
java.lang.reflect.Modifier
modifiers
- int, sum of Modifier values from java.lang.reflect.Modifier
public static java.lang.String makeString(java.lang.String value)
value
- String, the value to make a String for
null
if the value is null or emptypublic static final java.lang.String spaces(int length)
There is a faster way to do this, by using a static char array to read from, but it is only slightly faster and consumes extra memory and more lines of code
length
- int, the length of the String of spaces
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |