arlut.csd.Util
Class WordWrap
java.lang.Object
|
+--arlut.csd.Util.WordWrap
- public class WordWrap
- extends java.lang.Object
Handy word wrap module. This class provides the static
wrap()
method for word-wrapping text strings.
Used in the Ganymede client and server for utilitarian word-wrapping.
|
Field Summary |
(package private) static boolean |
debug
|
|
Method Summary |
static boolean |
isspace(char c)
|
static void |
main(java.lang.String[] args)
|
static java.lang.String |
wrap(java.lang.String inString,
int wrap_length)
|
static java.lang.String |
wrap(java.lang.String inString,
int wrap_length,
java.lang.String prepend)
This method takes a string and wraps it to a line length of no more than
wrap_length. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
debug
static final boolean debug
- See Also:
- Constant Field Values
WordWrap
public WordWrap()
wrap
public static java.lang.String wrap(java.lang.String inString,
int wrap_length,
java.lang.String prepend)
- This method takes a string and wraps it to a line length of no more than
wrap_length. If prepend is not null, each resulting line will be prefixed
with the prepend string. In that case, resultant line length will be no
more than wrap_length + prepend.length()
wrap
public static java.lang.String wrap(java.lang.String inString,
int wrap_length)
isspace
public static boolean isspace(char c)
main
public static void main(java.lang.String[] args)