| java.lang.Object org.jfree.report.util.StringUtil
StringUtil | final public class StringUtil (Code) | | String utility functions. Provides functions to parse floats, ints and boolean values.
author: Thomas Morgner |
Method Summary | |
public static boolean | endsWithIgnoreCase(String base, String end) Helper functions to query a strings end portion. | public static boolean | parseBoolean(String attribute, boolean defaultValue) Parses the given string into a boolean value. | public static float | parseFloat(String value, float defaultValue) Parses the given string and returns the parsed integer value or the given default if
the parsing failed. | public static int | parseInt(String value, int defaultValue) Parses the given string and returns the parsed integer value or the given default if
the parsing failed. | public static boolean | startsWithIgnoreCase(String base, String start) Helper functions to query a strings start portion. |
endsWithIgnoreCase | public static boolean endsWithIgnoreCase(String base, String end)(Code) | | Helper functions to query a strings end portion. The comparison is case insensitive.
Parameters: base - the base string. Parameters: end - the ending text. true, if the string ends with the given ending text. |
parseBoolean | public static boolean parseBoolean(String attribute, boolean defaultValue)(Code) | | Parses the given string into a boolean value. This returns true, if the string's
value is "true".
Parameters: attribute - the string that should be parsed. Parameters: defaultValue - the default value, in case the string is null. the parsed value. |
parseFloat | public static float parseFloat(String value, float defaultValue)(Code) | | Parses the given string and returns the parsed integer value or the given default if
the parsing failed.
Parameters: value - the to be parsed string Parameters: defaultValue - the default value the parsed string. |
parseInt | public static int parseInt(String value, int defaultValue)(Code) | | Parses the given string and returns the parsed integer value or the given default if
the parsing failed.
Parameters: value - the to be parsed string Parameters: defaultValue - the default value the parsed string. |
startsWithIgnoreCase | public static boolean startsWithIgnoreCase(String base, String start)(Code) | | Helper functions to query a strings start portion. The comparison is case
insensitive.
Parameters: base - the base string. Parameters: start - the starting text. true, if the string starts with the given starting text. |
|
|