|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.crosswire.jsword.book.CaseType
public abstract class CaseType
Types of Sentence Case.
for license details.
The copyright to this program is held by it's authors.
,
Serialized FormField Summary | |
---|---|
static CaseType |
LOWER
|
private String |
name
The name of the type |
private static int |
nextObj
|
private int |
obj
|
static CaseType |
SENTENCE
|
static CaseType |
UPPER
|
private static CaseType[] |
VALUES
|
Constructor Summary | |
---|---|
CaseType(String name)
Simple ctor |
Method Summary | |
---|---|
boolean |
equals(Object o)
Prevent subclasses from overriding canonical identity based Object methods |
static CaseType |
fromInteger(int i)
Lookup method to convert from an integer |
static CaseType |
fromString(String name)
Lookup method to convert from a String |
static CaseType |
getCase(String word)
What case is the specified word?. |
int |
hashCode()
Prevent subclasses from overriding canonical identity based Object methods |
(package private) Object |
readResolve()
|
abstract String |
setCase(String word)
|
int |
toInteger()
Get an integer representation for this CaseType |
protected static String |
toSentenceCase(String word)
Change to sentence case - ie first character in caps, the rest in lower. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final CaseType LOWER
public static final CaseType SENTENCE
public static final CaseType UPPER
private String name
private static int nextObj
private final int obj
private static final CaseType[] VALUES
Constructor Detail |
---|
public CaseType(String name)
Method Detail |
---|
public abstract String setCase(String word)
protected static String toSentenceCase(String word)
word
- The word to be manipulated
public static CaseType getCase(String word)
The issue here is that getCase("FreD") is undefined. Telling if this is SENTENCE (Tubal-Cain) or MIXED (really the case) is complex and would slow things down for a case that I don't believe happens with Bible text.
word
- The word to be tested
IllegalArgumentException
- is the word is nullpublic int toInteger()
public static CaseType fromString(String name)
public static CaseType fromInteger(int i)
public final boolean equals(Object o)
equals
in class Object
Object.equals(java.lang.Object)
public final int hashCode()
hashCode
in class Object
Object.hashCode()
public String toString()
toString
in class Object
Object readResolve()
|
Copyright ? 2003-2006 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |