org.extex.unit.omega.mode
Class AbstractModeCode

java.lang.Object
  extended by org.extex.interpreter.type.AbstractCode
      extended by org.extex.unit.omega.mode.AbstractModeCode
All Implemented Interfaces:
java.io.Serializable, Code
Direct Known Subclasses:
DefaultInputMode, DefaultInputTranslation, DefaultOutputMode, DefaultOutputTranslation, InputMode, InputTranslation, NoDefaultInputMode, NoDefaultInputTranslation, NoDefaultOutputMode, NoDefaultOutputTranslation, OutputMode

public abstract class AbstractModeCode
extends AbstractCode

This is the abstract base class for primitives dealing with an input or output mode as defined by Omega.

Version:
$Revision:4411 $
Author:
Gerd Neugebauer
See Also:
Serialized Form

Field Summary
protected static java.lang.String DEFAULT_INPUT_MODE
          The constant INPUT_MODE contains the key for the input mode.
protected static java.lang.String DEFAULT_INPUT_TRANSLATION
          The constant DEFAULT_INPUT_TRANSLATION contains the key for the default input translation.
protected static java.lang.String DEFAULT_OUTPUT_MODE
          The constant OUTPUT_MODE contains the key for the output mode.
protected static java.lang.String DEFAULT_OUTPUT_TRANSLATION
          The constant DEFAULT_OUTPUT_TRANSLATION contains the key for the default output translation.
protected static java.lang.String INPUT_MODE
          The constant INPUT_MODE contains the key for the input mode.
protected static java.lang.String INPUT_TRANSLATION
          The constant INPUT_TRANSLATION contains the key for the input translation.
protected static java.lang.String OUTPUT_MODE
          The constant OUTPUT_MODE contains the key for the output mode.
protected static java.lang.String OUTPUT_TRANSLATION
          The constant OUTPUT_TRANSLATION contains the key for the output translation.
 
Fields inherited from class org.extex.interpreter.type.AbstractCode
serialVersionUID
 
Constructor Summary
AbstractModeCode(CodeToken token)
          Creates a new object.
 
Method Summary
protected  OmegaMode scanInputMode(Context context, TokenSource source)
          Scan the token source for a keyword describing an input mode.
protected  OmegaMode scanOutputMode(Context context, TokenSource source)
          Scan the token source for a keyword describing an input mode.
 
Methods inherited from class org.extex.interpreter.type.AbstractCode
execute, getLocalizer, getName, getToken, isIf, isOuter, readResolve, toString, toText, toText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_INPUT_MODE

protected static final java.lang.String DEFAULT_INPUT_MODE
The constant INPUT_MODE contains the key for the input mode.

See Also:
Constant Field Values

DEFAULT_INPUT_TRANSLATION

protected static final java.lang.String DEFAULT_INPUT_TRANSLATION
The constant DEFAULT_INPUT_TRANSLATION contains the key for the default input translation.

See Also:
Constant Field Values

DEFAULT_OUTPUT_MODE

protected static final java.lang.String DEFAULT_OUTPUT_MODE
The constant OUTPUT_MODE contains the key for the output mode.

See Also:
Constant Field Values

DEFAULT_OUTPUT_TRANSLATION

protected static final java.lang.String DEFAULT_OUTPUT_TRANSLATION
The constant DEFAULT_OUTPUT_TRANSLATION contains the key for the default output translation.

See Also:
Constant Field Values

INPUT_MODE

protected static final java.lang.String INPUT_MODE
The constant INPUT_MODE contains the key for the input mode.

See Also:
Constant Field Values

INPUT_TRANSLATION

protected static final java.lang.String INPUT_TRANSLATION
The constant INPUT_TRANSLATION contains the key for the input translation.

See Also:
Constant Field Values

OUTPUT_MODE

protected static final java.lang.String OUTPUT_MODE
The constant OUTPUT_MODE contains the key for the output mode.

See Also:
Constant Field Values

OUTPUT_TRANSLATION

protected static final java.lang.String OUTPUT_TRANSLATION
The constant OUTPUT_TRANSLATION contains the key for the output translation.

See Also:
Constant Field Values
Constructor Detail

AbstractModeCode

public AbstractModeCode(CodeToken token)
Creates a new object.

Parameters:
token - the initial token for the primitive
Method Detail

scanInputMode

protected OmegaMode scanInputMode(Context context,
                                  TokenSource source)
                           throws HelpingException
Scan the token source for a keyword describing an input mode.

Parameters:
context - the interpreter context
source - the source for new tokens
Returns:
mode
Throws:
HelpingException - in case of an error

scanOutputMode

protected OmegaMode scanOutputMode(Context context,
                                   TokenSource source)
                            throws HelpingException
Scan the token source for a keyword describing an input mode.

Parameters:
context - the interpreter context
source - the source for new tokens
Returns:
the mode
Throws:
HelpingException - in case of an error