|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.crosswire.jsword.book.sword.ConfigEntry
public class ConfigEntry
A ConfigEntry holds the value(s) for an entry of ConfigEntryType.
Distribution Licence: JSword is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2 as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. The License is available on the internet here, or by writing to: Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA The copyright to this program is held by it's authors. |
Licence
Field Summary | |
---|---|
private static Histogram |
histogram
A histogram for debugging. |
private String |
internal
|
private static Logger |
log
The log stream |
private String |
name
|
private ConfigEntryType |
type
|
private String |
value
|
private List |
values
|
Constructor Summary | |
---|---|
ConfigEntry(String moduleName,
ConfigEntryType aType,
String aValue)
Create a ConfigEntry directly with an initial value. |
|
ConfigEntry(String moduleName,
String aName)
Create a ConfigEntry whose type is not certain and whose value is not known. |
Method Summary | |
---|---|
void |
addValue(String aValue)
Add a value to the list of values for this ConfigEntry |
boolean |
allowsContinuation()
While most fields are single line or single value, some allow continuation. |
boolean |
allowsRTF()
RTF is allowed in a few config entries. |
static void |
dumpStatistics()
|
boolean |
equals(Object obj)
|
String |
getName()
Get the key of this ConfigEntry |
ConfigEntryType |
getType()
Get the type of this ConfigEntry |
Object |
getValue()
Get the value(s) of this ConfigEntry. |
private String |
handleRTF(String aValue)
|
int |
hashCode()
|
boolean |
isAllowed(String aValue)
Determines whether the string is allowed. |
boolean |
isSupported()
Determine whether this config entry is supported. |
boolean |
match(Object search)
Determine whether this Config entry matches the value. |
boolean |
mayRepeat()
Some keys can repeat. |
private List |
processLines(OSISUtil.ObjectFactory factory,
String aValue)
|
boolean |
reportDetails()
|
static void |
resetStatistics()
|
org.jdom.Element |
toOSIS()
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private static final Logger log
private static Histogram histogram
private ConfigEntryType type
private String internal
private String name
private List values
private String value
Constructor Detail |
---|
public ConfigEntry(String moduleName, String aName)
moduleName
- the internal name of the moduleaName
- the name of the ConfigEntry.public ConfigEntry(String moduleName, ConfigEntryType aType, String aValue)
moduleName
- the internal name of the moduleaType
- the kind of ConfigEntryaValue
- the initial value for the ConfigEntryMethod Detail |
---|
public String getName()
public ConfigEntryType getType()
public boolean isAllowed(String aValue)
aValue
-
public boolean allowsRTF()
public boolean allowsContinuation()
public boolean mayRepeat()
public boolean reportDetails()
public boolean isSupported()
public Object getValue()
public boolean match(Object search)
search
- the value to match against
public void addValue(String aValue)
public org.jdom.Element toOSIS()
public static void resetStatistics()
public static void dumpStatistics()
public boolean equals(Object obj)
equals
in class Object
public int hashCode()
hashCode
in class Object
public String toString()
toString
in class Object
private String handleRTF(String aValue)
private List processLines(OSISUtil.ObjectFactory factory, String aValue)
|
Copyright ? 2003-2004 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |