Class AbstractTextType<T extends AbstractTextType<T>>
java.lang.Object
de.espirit.firstspirit.common.text.AbstractTextType<T>
- All Implemented Interfaces:
ValueOfContractor,Serializable,CharSequence,Comparable<T>
- Direct Known Subclasses:
Classname,Designator,GomButtonScriptReference,LanguageAbbreviation,ReferenceName
public abstract class AbstractTextType<T extends AbstractTextType<T>>
extends Object
implements CharSequence, Comparable<T>, Serializable, ValueOfContractor
Generic class for defining String-Facades.
- Since:
- 5.2.210803
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface de.espirit.common.text.ValueOfContractor
ValueOfContractor.Invoke -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncharcharAt(int index) Delegates toString.charAt(int).intcodePointAt(int index) Delegates toString.codePointAt(int).intcodePointBefore(int index) Delegates toString.codePointBefore(int).intcodePointCount(int beginIndex, int endIndex) Delegates toString.codePointCount(int, int).intDelegates toString.compareTo(String).intintDelegates toString.compareToIgnoreCase(String).Delegates toString.concat(String).booleanDelegates toString.contains(CharSequence).booleanDelegates toString.contentEquals(CharSequence).booleanDelegates toString.contentEquals(StringBuffer).booleancorrelatesTo(String string) Checks, if the given String correlates to this object's text.booleanDelegates toString.endsWith(String).booleanbooleanequalsIgnoreCase(String anotherString) Delegates toString.equalsIgnoreCase(String).byte[]getBytes()Delegates toString.getBytes().voidgetBytes(int srcBegin, int srcEnd, byte[] dst, int dstBegin) Delegates toString.getBytes(int, int, byte[], int).byte[]Delegates toString.getBytes(String).voidgetChars(int srcBegin, int srcEnd, char[] dst, int dstBegin) Delegates toString.getChars(int, int, char[], int).inthashCode()intindexOf(int ch) Delegates toString.indexOf(int).intindexOf(int ch, int fromIndex) Delegates toString.indexOf(int, int).intDelegates toString.indexOf(String).intDelegates toString.indexOf(String, int).intern()Delegates toString.intern().intlastIndexOf(int ch) Delegates toString.lastIndexOf(int).intlastIndexOf(int ch, int fromIndex) Delegates toString.lastIndexOf(int, int).intlastIndexOf(String str) Delegates toString.lastIndexOf(String).intlastIndexOf(String str, int fromIndex) Delegates toString.lastIndexOf(String, int).intlength()Delegates toString.length().booleanDelegates toString.matches(String).intoffsetByCodePoints(int index, int codePointOffset) Delegates toString.offsetByCodePoints(int, int).booleanregionMatches(boolean ignoreCase, int toffset, String other, int ooffset, int len) Delegates toString.regionMatches(boolean, int, String, int, int).booleanregionMatches(int toffset, String other, int ooffset, int len) Delegates toString.regionMatches(int, String, int, int).replace(char oldChar, char newChar) Delegates toString.replace(char, char).replace(CharSequence target, CharSequence replacement) Delegates toString.replace(CharSequence, CharSequence).replaceAll(String regex, String replacement) Delegates toString.replaceAll(String, String).replaceFirst(String regex, String replacement) Delegates toString.replaceFirst(String, String).String[]Delegates toString.split(String).String[]Delegates toString.split(String, int).booleanstartsWith(String prefix) Delegates toString.startsWith(String).booleanstartsWith(String prefix, int toffset) Delegates toString.startsWith(String, int).subSequence(int beginIndex, int endIndex) Delegates toString.subSequence(int, int).substring(int beginIndex) Delegates toString.substring(int).substring(int beginIndex, int endIndex) Delegates toString.substring(int, int).char[]Delegates toString.toCharArray().Delegates toString.toLowerCase().toLowerCase(Locale locale) Delegates toString.toLowerCase(Locale).toString()Delegates toString.toUpperCase().toUpperCase(Locale locale) Delegates toString.toUpperCase(Locale).trim()Delegates toString.trim().static AbstractTextType<?>Create an instance from String.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.CharSequence
chars, codePoints, isEmpty
-
Constructor Details
-
AbstractTextType
Construct an abstract text type. The given text must not benull!- Parameters:
text- The non-null text.- Throws:
NullPointerException- If the text is null.- Since:
- 5.2.210803
-
-
Method Details
-
correlatesTo
Checks, if the given String correlates to this object's text.- Parameters:
string- The string to test.- Returns:
true, iff the held text equals the given object, ignoring cases.- Since:
- 5.2.210803
-
compareTo
- Specified by:
compareToin interfaceComparable<T extends AbstractTextType<T>>- Since:
- 5.2.210803
-
valueOf
Create an instance from String.Note: The implementation at abstract level forces subclasses to fulfill the
ValueOfContractormarker. If a subclass does not hide this method, aMustImplementErroris thrown.- Parameters:
string- The string to create from.- Returns:
- The created instance or
null, iff the given string is null. - Throws:
IllegalArgumentException- If the given string does not match basic criteria for being a language abbreviation.- Since:
- 5.2.210803
-
charAt
public char charAt(int index) Delegates toString.charAt(int).- Specified by:
charAtin interfaceCharSequence- Since:
- 5.2.210803
-
codePointAt
public int codePointAt(int index) Delegates toString.codePointAt(int).- Since:
- 5.2.210803
-
codePointBefore
public int codePointBefore(int index) Delegates toString.codePointBefore(int).- Since:
- 5.2.210803
-
codePointCount
public int codePointCount(int beginIndex, int endIndex) Delegates toString.codePointCount(int, int).- Since:
- 5.2.210803
-
compareTo
Delegates toString.compareTo(String).- Since:
- 5.2.210803
-
compareToIgnoreCase
Delegates toString.compareToIgnoreCase(String).- Since:
- 5.2.210803
-
concat
Delegates toString.concat(String).- Since:
- 5.2.210803
-
contains
Delegates toString.contains(CharSequence).- Since:
- 5.2.210803
-
contentEquals
Delegates toString.contentEquals(CharSequence).- Since:
- 5.2.210803
-
contentEquals
Delegates toString.contentEquals(StringBuffer).- Since:
- 5.2.210803
-
endsWith
Delegates toString.endsWith(String).- Since:
- 5.2.210803
-
equals
-
equalsIgnoreCase
Delegates toString.equalsIgnoreCase(String).- Since:
- 5.2.210803
-
getBytes
public byte[] getBytes()Delegates toString.getBytes().- Since:
- 5.2.210803
-
getBytes
public void getBytes(int srcBegin, int srcEnd, byte[] dst, int dstBegin) Delegates toString.getBytes(int, int, byte[], int).- Since:
- 5.2.210803
-
getBytes
Delegates toString.getBytes(String).- Throws:
UnsupportedEncodingException- Since:
- 5.2.210803
-
getChars
public void getChars(int srcBegin, int srcEnd, char[] dst, int dstBegin) Delegates toString.getChars(int, int, char[], int).- Since:
- 5.2.210803
-
hashCode
public int hashCode() -
indexOf
public int indexOf(int ch, int fromIndex) Delegates toString.indexOf(int, int).- Since:
- 5.2.210803
-
indexOf
public int indexOf(int ch) Delegates toString.indexOf(int).- Since:
- 5.2.210803
-
indexOf
Delegates toString.indexOf(String, int).- Since:
- 5.2.210803
-
indexOf
Delegates toString.indexOf(String).- Since:
- 5.2.210803
-
intern
Delegates toString.intern().- Since:
- 5.2.210803
-
lastIndexOf
public int lastIndexOf(int ch, int fromIndex) Delegates toString.lastIndexOf(int, int).- Since:
- 5.2.210803
-
lastIndexOf
public int lastIndexOf(int ch) Delegates toString.lastIndexOf(int).- Since:
- 5.2.210803
-
lastIndexOf
Delegates toString.lastIndexOf(String, int).- Since:
- 5.2.210803
-
lastIndexOf
Delegates toString.lastIndexOf(String).- Since:
- 5.2.210803
-
length
public int length()Delegates toString.length().- Specified by:
lengthin interfaceCharSequence- Since:
- 5.2.210803
-
matches
Delegates toString.matches(String).- Since:
- 5.2.210803
-
offsetByCodePoints
public int offsetByCodePoints(int index, int codePointOffset) Delegates toString.offsetByCodePoints(int, int).- Since:
- 5.2.210803
-
regionMatches
Delegates toString.regionMatches(boolean, int, String, int, int).- Since:
- 5.2.210803
-
regionMatches
Delegates toString.regionMatches(int, String, int, int).- Since:
- 5.2.210803
-
replace
Delegates toString.replace(char, char).- Since:
- 5.2.210803
-
replace
Delegates toString.replace(CharSequence, CharSequence).- Since:
- 5.2.210803
-
replaceAll
Delegates toString.replaceAll(String, String).- Since:
- 5.2.210803
-
replaceFirst
Delegates toString.replaceFirst(String, String).- Since:
- 5.2.210803
-
split
Delegates toString.split(String, int).- Since:
- 5.2.210803
-
split
Delegates toString.split(String).- Since:
- 5.2.210803
-
startsWith
Delegates toString.startsWith(String, int).- Since:
- 5.2.210803
-
startsWith
Delegates toString.startsWith(String).- Since:
- 5.2.210803
-
subSequence
Delegates toString.subSequence(int, int).- Specified by:
subSequencein interfaceCharSequence- Since:
- 5.2.210803
-
substring
Delegates toString.substring(int, int).- Since:
- 5.2.210803
-
substring
Delegates toString.substring(int).- Since:
- 5.2.210803
-
toCharArray
public char[] toCharArray()Delegates toString.toCharArray().- Since:
- 5.2.210803
-
toLowerCase
Delegates toString.toLowerCase().- Since:
- 5.2.210803
-
toLowerCase
Delegates toString.toLowerCase(Locale).- Since:
- 5.2.210803
-
toString
- Specified by:
toStringin interfaceCharSequence- Overrides:
toStringin classObject
-
toUpperCase
Delegates toString.toUpperCase().- Since:
- 5.2.210803
-
toUpperCase
Delegates toString.toUpperCase(Locale).- Since:
- 5.2.210803
-
trim
Delegates toString.trim().- Since:
- 5.2.210803
-