org.extex.unit.tex.typesetter
Class AbstractHorizontalCode

java.lang.Object
  extended by org.extex.interpreter.type.AbstractCode
      extended by org.extex.unit.tex.typesetter.AbstractHorizontalCode
All Implemented Interfaces:
java.io.Serializable, Code
Direct Known Subclasses:
Hfi, Hfil, Hfill, Hfilneg, Hskip, Hss

public abstract class AbstractHorizontalCode
extends AbstractCode

This an abstract base class for primitives in horizontal mode.

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

Field Summary
protected static long serialVersionUID
          The constant serialVersionUID contains the id for serialization.
 
Constructor Summary
AbstractHorizontalCode(CodeToken token)
          Creates a new object.
 
Method Summary
protected  void ensureHorizontalMode(Typesetter typesetter)
          Check that the current mode is a horizontal mode and throw an exception if another mode is detected.
protected  void switchToHorizontalMode(Typesetter typesetter)
          Check that the current mode is a horizontal mode and open a new list maker if another mode is detected.
 
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

serialVersionUID

protected static final long serialVersionUID
The constant serialVersionUID contains the id for serialization.

See Also:
Constant Field Values
Constructor Detail

AbstractHorizontalCode

public AbstractHorizontalCode(CodeToken token)
Creates a new object.

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

ensureHorizontalMode

protected void ensureHorizontalMode(Typesetter typesetter)
                             throws HelpingException
Check that the current mode is a horizontal mode and throw an exception if another mode is detected.

Parameters:
typesetter - the typesetter to ask for the mode
Throws:
HelpingException - in case of an error

switchToHorizontalMode

protected void switchToHorizontalMode(Typesetter typesetter)
                               throws HelpingException,
                                      TypesetterException
Check that the current mode is a horizontal mode and open a new list maker if another mode is detected.

Parameters:
typesetter - the typesetter to ask for the mode
Throws:
HelpingException - in case of an error
TypesetterException - in case of an error in the typesetter