final class Options extends Object
Modifier and Type | Field and Description |
---|---|
private Map<String,String> |
custom
Used custom mapping.
|
private static Map<String,String> |
DEFAULT_CUSTOM
Default custom mapping.
|
private static Language |
DEFAULT_LANG
Default language.
|
private static boolean |
DEFAULT_MAINTAIN_CASE
Default maintain case flag.
|
private static boolean |
DEFAULT_MARK
Default mark flag.
|
private static String |
DEFAULT_SEPARATOR
Default separator.
|
private static boolean |
DEFAULT_TITLE_CASE
Default title case flag.
|
private static Set<String> |
DEFAULT_TITLE_CASE_EXCLUDES
Default title case excludes.
|
private static int |
DEFAULT_TRUNCATE
Default truncate length.
|
private static boolean |
DEFAULT_URIC
Default URI characters flag.
|
private static boolean |
DEFAULT_URIC_WITHOUT_SLASH
Default URI characters without slash flag.
|
private Language |
language
Used language.
|
private boolean |
maintainCase
Used maintain case flag.
|
private boolean |
mark
Used mark flag.
|
private String |
separator
Used separator.
|
private boolean |
titleCase
Used title case flag.
|
private Set<String> |
titleCaseExclude
Used title case excludes.
|
private int |
truncate
Used truncate length.
|
private boolean |
uric
Used URI characters flag.
|
private boolean |
uricWithoutSlash
Used URI characters without slash flag.
|
private Validator |
validator
Validates input.
|
Constructor and Description |
---|
Options() |
Modifier and Type | Method and Description |
---|---|
(package private) Options |
copy()
Makes copy of the object.
|
(package private) Map<String,String> |
custom()
The custom mapping.
|
(package private) void |
custom(Map<String,String> withCustom)
Set custom mapping.
|
boolean |
equals(Object obj) |
int |
hashCode() |
(package private) Language |
language()
The language.
|
(package private) void |
language(Language withLanguage)
Set the language.
|
(package private) boolean |
maintainCase()
The maintain case flag.
|
(package private) void |
maintainCase(boolean withMaintainCase)
Set maintain case flag.
|
(package private) boolean |
mark()
The mark characters flag.
|
(package private) void |
mark(boolean withMark)
The mark characters flag.
|
(package private) void |
resetToDefaults()
Resets the object to the "factory settings".
|
(package private) String |
separator()
The separator.
|
(package private) void |
separator(String withSeparator)
Set the separator.
|
(package private) boolean |
titleCase()
The title case flag.
|
(package private) void |
titleCase(boolean withTitleCase)
Set title case flag.
|
(package private) Set<String> |
titleCaseExclude()
The words excluded from title case.
|
(package private) void |
titleCaseExclude(Set<String> withTitleCaseExclude)
Set words excluded from title case.
|
String |
toString() |
(package private) int |
truncate()
The truncate length.
|
(package private) void |
truncate(int withTruncate)
Set the truncate length.
|
(package private) boolean |
uric()
The URI characters flag.
|
(package private) void |
uric(boolean withUric)
Set URI characters flag.
|
(package private) boolean |
uricWithoutSlash()
The URI characters without slash flag.
|
(package private) void |
uricWithoutSlash(boolean withUricAndSlash)
Set URI characters without slash flag.
|
private static final String DEFAULT_SEPARATOR
private static final Language DEFAULT_LANG
private static final boolean DEFAULT_MAINTAIN_CASE
private static final boolean DEFAULT_TITLE_CASE
private static final Set<String> DEFAULT_TITLE_CASE_EXCLUDES
private static final int DEFAULT_TRUNCATE
private static final boolean DEFAULT_URIC
private static final boolean DEFAULT_URIC_WITHOUT_SLASH
private static final boolean DEFAULT_MARK
private final Validator validator
private String separator
private Language language
private boolean maintainCase
private boolean titleCase
private int truncate
private boolean uric
private boolean uricWithoutSlash
private boolean mark
String separator()
null
or emptyvoid separator(String withSeparator)
withSeparator
- must not be null
or emptyLanguage language()
null
void language(Language withLanguage)
withLanguage
- must not be null
boolean maintainCase()
void maintainCase(boolean withMaintainCase)
withMaintainCase
- maintainCase on or offboolean titleCase()
void titleCase(boolean withTitleCase)
withTitleCase
- on or offSet<String> titleCaseExclude()
null
, immutablevoid titleCaseExclude(Set<String> withTitleCaseExclude)
withTitleCaseExclude
- must not be null
, defensive copiedint truncate()
void truncate(int withTruncate)
withTruncate
- truncate must not be negativeboolean uric()
void uric(boolean withUric)
withUric
- uric on or offboolean uricWithoutSlash()
void uricWithoutSlash(boolean withUricAndSlash)
withUricAndSlash
- on or offboolean mark()
void mark(boolean withMark)
withMark
- on or offvoid custom(Map<String,String> withCustom)
withCustom
- must not be null
, defensive copiedOptions copy()
null
, always new instancevoid resetToDefaults()
Copyright © 2012 Sven Strittmatter. All Rights Reserved.