Class AbstractOperatorDictionary
java.lang.Object
net.sourceforge.jeuclid.elements.support.operatordict.AbstractOperatorDictionary
- All Implemented Interfaces:
Serializable,OperatorDictionary
- Direct Known Subclasses:
OperatorDictionary2,OperatorDictionary3
public abstract class AbstractOperatorDictionary
extends Object
implements OperatorDictionary, Serializable
Read default values of operators from xml file.
- Version:
- $Revision: c75d8b379394 $
- See Also:
-
Field Summary
Fields inherited from interface net.sourceforge.jeuclid.elements.support.operatordict.OperatorDictionary
FORM_INFIX, FORM_POSTFIX, FORM_PREFIX, NAME_INFINITY, NAME_MEDIUMMATHSPACE, NAME_THICKMATHSPACE, NAME_THINMATHSPACE, NAME_VERYTHICKMATHSPACE, NAME_VERYTHINMATHSPACE, NAME_VERYVERYTHICKMATHSPACE, NAME_VERYVERYTHINMATHSPACE, VALUE_UNKNOWN -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static OperatorDictionarydeserialize(String path) Get the for singleton instance.getDefaultAttributeValue(String operator, String form, String attributeName) Determines default value of the operator attribute.protected abstract voidInitializes Dictionary.
-
Constructor Details
-
AbstractOperatorDictionary
protected AbstractOperatorDictionary()Default constructor.
-
-
Method Details
-
deserialize
Get the for singleton instance.- Parameters:
path- path for the serialized object.- Returns:
- an instance of OperatorDictionary.
-
initializeFromXML
protected abstract void initializeFromXML(Map<OperatorAttribute, Map<String, Map<OperatorForm, String>>> d) Initializes Dictionary.- Parameters:
d- the dictionary to initialize.
-
getDefaultAttributeValue
public String getDefaultAttributeValue(String operator, String form, String attributeName) throws UnknownAttributeException Determines default value of the operator attribute.- Specified by:
getDefaultAttributeValuein interfaceOperatorDictionary- Parameters:
operator- operator characterform- form stringattributeName- name of attribute- Returns:
- VALUE_UNKOWN or value from dict.
- Throws:
UnknownAttributeException- Raised, if wrong attributeName was provided.
-