Package org.apache.commons.cli
Class Util
java.lang.Object
org.apache.commons.cli.Util
Contains useful helper methods for classes within this package.
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final String[]
An empty immutableString
array. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
EMPTY_STRING_ARRAY
An empty immutableString
array.
-
-
Constructor Details
-
Util
Util()
-
-
Method Details
-
stripLeadingAndTrailingQuotes
Remove the leading and trailing quotes fromstr
. E.g. if str is '"one two"', then 'one two' is returned.- Parameters:
str
- The string from which the leading and trailing quotes should be removed.- Returns:
- The string without the leading and trailing quotes.
-
stripLeadingHyphens
Remove the hyphens from the beginning ofstr
and return the new String.- Parameters:
str
- The string from which the hyphens should be removed.- Returns:
- the new String.
-