|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.cometway.email.EmailTools
public class EmailTools
Defines a set of static methods useful for parsing email information.
| Constructor Summary | |
|---|---|
EmailTools()
|
|
| Method Summary | |
|---|---|
static TextRange |
change(java.lang.String find,
java.lang.String replace,
TextRange t)
Does a case-sensitive find and replace within the specified com.cometway.text.TextRange. |
static TextRange |
change(java.lang.String find,
java.lang.String replace,
TextRange t,
boolean ignoreCase)
Does a find and replace within the specified com.cometway.text.TextRange. |
static java.lang.String |
fixForHTML(java.lang.String text)
Returns a String with greater-than (>), less-than (<), and carriage return (\n) characters changed for HTML compatibility (>, <, and respectively). |
static java.lang.String |
formatDouble(double value)
Formats a double value to 2 decimal places as a String. |
static java.lang.String |
formatDouble(double value,
boolean fixed)
Formats a double value to 2 decimal places as a String. |
static java.lang.String |
formatDouble(double value,
int places)
Formats a double value to the specified number of decimal places. |
static java.lang.String |
formatDouble(double value,
int places,
boolean fixed)
Formats a double value to the specified number of decimal places as a String. |
static java.lang.String |
formatWrap(java.lang.String s,
int width)
Word wraps the a String to the specified number of columns and returns the wrapped String. |
static Pair |
parseEmailAddress(java.lang.String email)
This method parses the specified String typically containing the text contents from an email message header (ie: "Bob Smith" |
static java.lang.String |
stripEnds(java.lang.String s)
Returns a String with surrounding symbols (ie: (), <>, "") removed from the specified String. |
static java.lang.String |
stripSpecialChars(java.lang.String s)
Removes any escaped ASCII characters that use the notation ascii_val; (ie: É) and returns the result as a String. |
static TextRange |
textBetween(java.lang.String b,
java.lang.String a,
StringTextBuffer s)
Returns a TextRange representing the text between before and after parameters within the specified com.cometway.text.StringTextBuffer. |
static TextRange |
textBetween(java.lang.String b,
java.lang.String a,
TextRange t)
Returns a TextRange representing the text between before and after parameters within the specified com.cometway.text.TextRange. |
static TextRange |
textBetween(java.lang.String b,
java.lang.String a,
TextRange t,
boolean ignoreCase)
Returns a TextRange representing the text between before and after parameters within the specified com.cometway.text.TextRange. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EmailTools()
| Method Detail |
|---|
public static TextRange change(java.lang.String find,
java.lang.String replace,
TextRange t)
public static TextRange change(java.lang.String find,
java.lang.String replace,
TextRange t,
boolean ignoreCase)
public static TextRange textBetween(java.lang.String b,
java.lang.String a,
TextRange t)
public static TextRange textBetween(java.lang.String b,
java.lang.String a,
StringTextBuffer s)
public static TextRange textBetween(java.lang.String b,
java.lang.String a,
TextRange t,
boolean ignoreCase)
public static java.lang.String formatWrap(java.lang.String s,
int width)
public static java.lang.String stripSpecialChars(java.lang.String s)
public static java.lang.String formatDouble(double value)
public static java.lang.String formatDouble(double value,
int places)
public static java.lang.String formatDouble(double value,
boolean fixed)
public static java.lang.String formatDouble(double value,
int places,
boolean fixed)
public static Pair parseEmailAddress(java.lang.String email)
public static java.lang.String stripEnds(java.lang.String s)
public static java.lang.String fixForHTML(java.lang.String text)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||