de.dante.extex.backend.documentWriter.pdf
Class PdfNodeVisitor

java.lang.Object
  extended byde.dante.extex.backend.documentWriter.pdf.PdfNodeVisitor
All Implemented Interfaces:
NodeVisitor

public class PdfNodeVisitor
extends java.lang.Object
implements NodeVisitor

PDF NodeVisitor.

Version:
$Revision: 1.2 $
Author:
Michael Niedermair

Constructor Summary
PdfNodeVisitor(org.pdfbox.pdmodel.PDDocument doc, org.pdfbox.pdmodel.edit.PDPageContentStream cs, Dimen cx, Dimen cy)
          Create a new object.
 
Method Summary
 void setPaperheight(Dimen ph)
          Set the paper height.
 java.lang.Object visitAdjust(AdjustNode node, java.lang.Object value2)
          This method is called when an AdjustNode has been encountered.
 java.lang.Object visitAfterMath(AfterMathNode node, java.lang.Object value2)
          This method is called when an AfterMathNode has been encountered.
 java.lang.Object visitAlignedLeaders(AlignedLeadersNode node, java.lang.Object value2)
          This method is called when an AlignedLeadersNode has been encountered.
 java.lang.Object visitBeforeMath(BeforeMathNode node, java.lang.Object value2)
          This method is called when a BeforeMathNode has been encountered.
 java.lang.Object visitCenteredLeaders(CenteredLeadersNode node, java.lang.Object value)
          This method is called when a CenteredLeadersNode has been encountered.
 java.lang.Object visitChar(CharNode node, java.lang.Object value)
          This method is called when a CharNode has been encountered.
 java.lang.Object visitDiscretionary(DiscretionaryNode node, java.lang.Object value)
          This method is called when a DiscretionaryNode has been encountered.
 java.lang.Object visitExpandedLeaders(ExpandedLeadersNode node, java.lang.Object value)
          This method is called when an ExpandedLeadersNode has been encountered.
 java.lang.Object visitGlue(GlueNode node, java.lang.Object value)
          This method is called when a GlueNode has been encountered.
 java.lang.Object visitHorizontalList(HorizontalListNode node, java.lang.Object value)
          This method is called when a HorizontalListNode has been encountered.
 java.lang.Object visitInsertion(InsertionNode node, java.lang.Object value)
          This method is called when an InsertionNode has been encountered.
 java.lang.Object visitKern(KernNode node, java.lang.Object value)
          This method is called when a KernNode has been encountered.
 java.lang.Object visitLigature(LigatureNode node, java.lang.Object value)
          This method is called when a LigatureNode has been encountered.
 java.lang.Object visitMark(MarkNode node, java.lang.Object value)
          This method is called when a MarkNode has been encountered.
 java.lang.Object visitPenalty(PenaltyNode node, java.lang.Object value)
          This method is called when a PenaltyNode has been encountered.
 java.lang.Object visitRule(RuleNode node, java.lang.Object value)
          This method is called when a RuleNode has been encountered.
 java.lang.Object visitSpace(SpaceNode node, java.lang.Object value)
          This method is called when a SpaceNode has been encountered.
 java.lang.Object visitVerticalList(VerticalListNode node, java.lang.Object value)
          This method is called when a VerticalListNode has been encountered.
 java.lang.Object visitVirtualChar(VirtualCharNode node, java.lang.Object value)
          This method is called when a VirtualCharNode has been encountered.
 java.lang.Object visitWhatsIt(WhatsItNode node, java.lang.Object value)
          This method is called when a WhatsItNode has been encountered.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PdfNodeVisitor

public PdfNodeVisitor(org.pdfbox.pdmodel.PDDocument doc,
                      org.pdfbox.pdmodel.edit.PDPageContentStream cs,
                      Dimen cx,
                      Dimen cy)
Create a new object.

Parameters:
doc - the pdf document
cs - the pdf content stream
cx - the current x
cy - the current y
Method Detail

setPaperheight

public void setPaperheight(Dimen ph)
Set the paper height.

Parameters:
ph - The paper height to set.

visitAdjust

public java.lang.Object visitAdjust(AdjustNode node,
                                    java.lang.Object value2)
Description copied from interface: NodeVisitor
This method is called when an AdjustNode has been encountered.

Specified by:
visitAdjust in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value2 - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitAdjust(AdjustNode, java.lang.Object)

visitAfterMath

public java.lang.Object visitAfterMath(AfterMathNode node,
                                       java.lang.Object value2)
Description copied from interface: NodeVisitor
This method is called when an AfterMathNode has been encountered.

Specified by:
visitAfterMath in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value2 - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitAfterMath(AfterMathNode, java.lang.Object)

visitAlignedLeaders

public java.lang.Object visitAlignedLeaders(AlignedLeadersNode node,
                                            java.lang.Object value2)
Description copied from interface: NodeVisitor
This method is called when an AlignedLeadersNode has been encountered.

Specified by:
visitAlignedLeaders in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value2 - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitAlignedLeaders(AlignedLeadersNode, java.lang.Object)

visitBeforeMath

public java.lang.Object visitBeforeMath(BeforeMathNode node,
                                        java.lang.Object value2)
Description copied from interface: NodeVisitor
This method is called when a BeforeMathNode has been encountered.

Specified by:
visitBeforeMath in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value2 - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitBeforeMath(BeforeMathNode, java.lang.Object)

visitCenteredLeaders

public java.lang.Object visitCenteredLeaders(CenteredLeadersNode node,
                                             java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a CenteredLeadersNode has been encountered.

Specified by:
visitCenteredLeaders in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitCenteredLeaders(CenteredLeadersNode, java.lang.Object)

visitChar

public java.lang.Object visitChar(CharNode node,
                                  java.lang.Object value)
                           throws GeneralException
Description copied from interface: NodeVisitor
This method is called when a CharNode has been encountered.

Specified by:
visitChar in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
Throws:
GeneralException - in case of an error
See Also:
NodeVisitor.visitChar(CharNode, java.lang.Object)

visitDiscretionary

public java.lang.Object visitDiscretionary(DiscretionaryNode node,
                                           java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a DiscretionaryNode has been encountered.

Specified by:
visitDiscretionary in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitDiscretionary(DiscretionaryNode, java.lang.Object)

visitExpandedLeaders

public java.lang.Object visitExpandedLeaders(ExpandedLeadersNode node,
                                             java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when an ExpandedLeadersNode has been encountered.

Specified by:
visitExpandedLeaders in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitExpandedLeaders(ExpandedLeadersNode, java.lang.Object)

visitGlue

public java.lang.Object visitGlue(GlueNode node,
                                  java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a GlueNode has been encountered.

Specified by:
visitGlue in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitGlue(GlueNode, java.lang.Object)

visitHorizontalList

public java.lang.Object visitHorizontalList(HorizontalListNode node,
                                            java.lang.Object value)
                                     throws GeneralException
Description copied from interface: NodeVisitor
This method is called when a HorizontalListNode has been encountered.

Specified by:
visitHorizontalList in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
Throws:
GeneralException - in case of an error
See Also:
NodeVisitor.visitHorizontalList(HorizontalListNode, java.lang.Object)

visitInsertion

public java.lang.Object visitInsertion(InsertionNode node,
                                       java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when an InsertionNode has been encountered.

Specified by:
visitInsertion in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitInsertion(InsertionNode, java.lang.Object)

visitKern

public java.lang.Object visitKern(KernNode node,
                                  java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a KernNode has been encountered.

Specified by:
visitKern in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitKern(KernNode, java.lang.Object)

visitLigature

public java.lang.Object visitLigature(LigatureNode node,
                                      java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a LigatureNode has been encountered.

Specified by:
visitLigature in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitLigature(LigatureNode, java.lang.Object)

visitMark

public java.lang.Object visitMark(MarkNode node,
                                  java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a MarkNode has been encountered.

Specified by:
visitMark in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitMark(MarkNode, java.lang.Object)

visitPenalty

public java.lang.Object visitPenalty(PenaltyNode node,
                                     java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a PenaltyNode has been encountered.

Specified by:
visitPenalty in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitPenalty(PenaltyNode, java.lang.Object)

visitRule

public java.lang.Object visitRule(RuleNode node,
                                  java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a RuleNode has been encountered.

Specified by:
visitRule in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitRule(RuleNode, java.lang.Object)

visitSpace

public java.lang.Object visitSpace(SpaceNode node,
                                   java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a SpaceNode has been encountered.

Specified by:
visitSpace in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitSpace(SpaceNode, java.lang.Object)

visitVerticalList

public java.lang.Object visitVerticalList(VerticalListNode node,
                                          java.lang.Object value)
                                   throws GeneralException
Description copied from interface: NodeVisitor
This method is called when a VerticalListNode has been encountered.

Specified by:
visitVerticalList in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
Throws:
GeneralException - in case of an error
See Also:
NodeVisitor.visitVerticalList(VerticalListNode, java.lang.Object)

visitVirtualChar

public java.lang.Object visitVirtualChar(VirtualCharNode node,
                                         java.lang.Object value)
                                  throws GeneralException
Description copied from interface: NodeVisitor
This method is called when a VirtualCharNode has been encountered.

Specified by:
visitVirtualChar in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
Throws:
GeneralException - in case of an error
See Also:
NodeVisitor.visitVirtualChar( de.dante.extex.typesetter.type.node.VirtualCharNode, java.lang.Object)

visitWhatsIt

public java.lang.Object visitWhatsIt(WhatsItNode node,
                                     java.lang.Object value)
Description copied from interface: NodeVisitor
This method is called when a WhatsItNode has been encountered.

Specified by:
visitWhatsIt in interface NodeVisitor
Parameters:
node - the first parameter for the visitor is the node visited
value - the second parameter for the visitor
Returns:
the visitor specific value
See Also:
NodeVisitor.visitWhatsIt(WhatsItNode, java.lang.Object)