Package com.exedio.cope.util
Class CharSet
java.lang.Object
com.exedio.cope.util.CharSet
- All Implemented Interfaces:
Serializable
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final CharSet
static final CharSet
static final CharSet
static final CharSet
static final CharSet
static final CharSet
static final CharSet
static final CharSet
Deprecated.static final CharSet
allows only 7bit ASCII email characters (RFC5322/5321 without quoted strings and comments)static final CharSet
EMAIL_ASCII
plus all characters beyond 7bit ASCIIstatic final CharSet
allows only characters commonly used in email addresses; this is the same character set as previously available asCharSet.EMAIL
; please note that valid characters like + and & are not allowed in this charsetstatic final CharSet
static final CharSet
static final CharSet
-
Constructor Summary
ConstructorsConstructorDescriptionCharSet
(char from, char to) CharSet
(char from1, char to1, char from2, char to2) CharSet
(char from1, char to1, char from2, char to2, char from3, char to3) CharSet
(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4) CharSet
(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4, char from5, char to5) CharSet
(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4, char from5, char to5, char from6, char to6) -
Method Summary
Modifier and TypeMethodDescriptionboolean
contains
(char c) boolean
int
hashCode()
int
Returns the index of the first character in s, which this CharSet does not contain.int
Returns the index of the first character in s, which this CharSet does not contain.boolean
remove
(char from, char to) toString()
-
Field Details
-
ALPHA
-
ALPHA_UPPER
-
ALPHA_LOWER
-
ALPHA_NUMERIC
-
ALPHA_UPPER_NUMERIC
-
ALPHA_LOWER_NUMERIC
-
HEX_UPPER
-
HEX_LOWER
-
NUMERIC
-
DOMAIN
-
EMAIL_RESTRICTIVE
allows only characters commonly used in email addresses; this is the same character set as previously available asCharSet.EMAIL
; please note that valid characters like + and & are not allowed in this charset -
EMAIL_ASCII
allows only 7bit ASCII email characters (RFC5322/5321 without quoted strings and comments) -
EMAIL_INTERNATIONAL
EMAIL_ASCII
plus all characters beyond 7bit ASCII -
EMAIL
Deprecated.
-
-
Constructor Details
-
CharSet
public CharSet(char from, char to) -
CharSet
public CharSet(char from1, char to1, char from2, char to2) -
CharSet
public CharSet(char from1, char to1, char from2, char to2, char from3, char to3) -
CharSet
public CharSet(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4) -
CharSet
public CharSet(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4, char from5, char to5) -
CharSet
public CharSet(char from1, char to1, char from2, char to2, char from3, char to3, char from4, char to4, char from5, char to5, char from6, char to6)
-
-
Method Details
-
isSubsetOfAscii
public boolean isSubsetOfAscii() -
contains
public boolean contains(char c) -
indexOfNotContains
Returns the index of the first character in s, which this CharSet does not contain. Returns -1, if this CharSet contains all characters in s.This method is provided for binary backwards compatibility. It is equivalent to
indexOfNotContains(CharSequence)
. -
indexOfNotContains
Returns the index of the first character in s, which this CharSet does not contain. Returns -1, if this CharSet contains all characters in s. -
equals
-
hashCode
public int hashCode() -
toString
-
remove
-
getRegularExpression
-
getRegularExpressionForInvalid7BitChars
-
EMAIL_RESTRICTIVE
,EMAIL_ASCII
, orEMAIL_INTERNATIONAL
instead