Package org.apache.fop.accessibility.fo
Class FO2StructureTreeConverter
java.lang.Object
org.apache.fop.fo.FOEventHandler
org.apache.fop.fo.DelegatingFOEventHandler
org.apache.fop.accessibility.fo.FO2StructureTreeConverter
Allows to create the structure tree of an FO document, by converting FO
events into appropriate structure tree events.
-
Field Summary
FieldsFields inherited from class org.apache.fop.fo.FOEventHandler
fontInfo, foUserAgent -
Constructor Summary
ConstructorsConstructorDescriptionFO2StructureTreeConverter(StructureTreeEventHandler structureTreeEventHandler, FOEventHandler delegate) Creates a new instance. -
Method Summary
Modifier and TypeMethodDescriptionvoidProcess a Character.voidcharacters(FOText foText) Process character data.voidvoidvoidvoidvoidendColumn(TableColumn tc) voidThis method is called to indicate the end of a document run.voidendExternalDocument(ExternalDocument document) Process the end of the external-document extension.voidvoidendFooter(TableFooter footer) voidendFootnote(Footnote footnote) Process the ending of a footnote.voidendFootnoteBody(FootnoteBody body) Process the ending of a footnote body.voidendHeader(TableHeader header) voidvoidProcess the end of an InstreamForeignObject.voidProcess the end of a Leader.voidProcess end of a Link.voidvoidendListBody(ListItemBody listItemBody) Process end of a ListBody.voidendListItem(ListItem li) voidendListLabel(ListItemLabel listItemLabel) Process end of a ListLabel.voidProcess end of a Markup.voidendPageNumber(PageNumber pagenum) voidendPageNumberCitation(PageNumberCitation pageCite) voidvoidendPageSequence(PageSequence pageSeq) voidendRetrieveMarker(RetrieveMarker retrieveMarker) Process the ending of a retrieve-marker.voidendRetrieveTableMarker(RetrieveTableMarker retrieveTableMarker) Process the ending of a retrieve-table-marker.voidCalled upon end of root element.voidvoidendStatic(StaticContent staticContent) Process end of a Static.voidvoidendWrapper(Wrapper wrapper) Process the ending of a wrapper.voidimage(ExternalGraphic eg) Process an ExternalGraphic.voidpageRef()Process a pageRef.voidrestoreState(RetrieveMarker retrieveMarker) Restore the state of this event handler as it was when the given fo:retrieve-marker element was processed.voidrestoreState(RetrieveTableMarker retrieveTableMarker) voidstartBlock(Block bl) voidvoidvoidvoidvoidThis method is called to indicate the start of a new document run.voidstartExternalDocument(ExternalDocument document) Process the start of the external-document extension.voidThis method is called to indicate the start of a new fo:flow or fo:static-content.voidstartFooter(TableFooter footer) voidstartFootnote(Footnote footnote) Process the start of a footnote.voidProcess the start of a footnote body.voidstartHeader(TableHeader header) voidstartInline(Inline inl) voidProcess the start of an InstreamForeignObject.voidProcess the start of a Leader.voidProcess start of a Link.voidvoidstartListBody(ListItemBody listItemBody) Process start of a ListBody.voidvoidstartListLabel(ListItemLabel listItemLabel) Process start of a ListLabel.voidProcess start of a Markup.voidstartPageNumber(PageNumber pagenum) voidstartPageNumberCitation(PageNumberCitation pageCite) voidvoidstartPageSequence(PageSequence pageSeq) voidstartRetrieveMarker(RetrieveMarker retrieveMarker) Process the start of a retrieve-marker.voidstartRetrieveTableMarker(RetrieveTableMarker retrieveTableMarker) Process the start of a retrieve-table-marker.voidCalled upon start of root element.voidvoidstartStatic(StaticContent staticContent) Process start of a Static.voidstartTable(Table tbl) voidstartWrapper(Wrapper wrapper) Process the start of a wrapper.Methods inherited from class org.apache.fop.fo.DelegatingFOEventHandler
getFontInfo, getResults, getUserAgent
-
Field Details
-
converter
The top of theconvertersstack.
-
-
Constructor Details
-
FO2StructureTreeConverter
public FO2StructureTreeConverter(StructureTreeEventHandler structureTreeEventHandler, FOEventHandler delegate) Creates a new instance.- Parameters:
structureTreeEventHandler- the object that will hold the structure treedelegate- the FO event handler that must be wrapped by this instance
-
-
Method Details
-
startDocument
Description copied from class:FOEventHandlerThis method is called to indicate the start of a new document run.- Overrides:
startDocumentin classDelegatingFOEventHandler- Throws:
SAXException- In case of a problem
-
endDocument
Description copied from class:FOEventHandlerThis method is called to indicate the end of a document run.- Overrides:
endDocumentin classDelegatingFOEventHandler- Throws:
SAXException- In case of a problem
-
startRoot
Description copied from class:FOEventHandlerCalled upon start of root element.- Overrides:
startRootin classDelegatingFOEventHandler- Parameters:
root- element
-
endRoot
Description copied from class:FOEventHandlerCalled upon end of root element.- Overrides:
endRootin classDelegatingFOEventHandler- Parameters:
root- element
-
startPageSequence
- Overrides:
startPageSequencein classDelegatingFOEventHandler- Parameters:
pageSeq- PageSequence that is starting.
-
endPageSequence
- Overrides:
endPageSequencein classDelegatingFOEventHandler- Parameters:
pageSeq- PageSequence that is ending.
-
startPageNumber
- Overrides:
startPageNumberin classDelegatingFOEventHandler- Parameters:
pagenum- PageNumber that is starting.
-
endPageNumber
- Overrides:
endPageNumberin classDelegatingFOEventHandler- Parameters:
pagenum- PageNumber that is ending.
-
startPageNumberCitation
- Overrides:
startPageNumberCitationin classDelegatingFOEventHandler- Parameters:
pageCite- PageNumberCitation that is starting.
-
endPageNumberCitation
- Overrides:
endPageNumberCitationin classDelegatingFOEventHandler- Parameters:
pageCite- PageNumberCitation that is ending.
-
startPageNumberCitationLast
- Overrides:
startPageNumberCitationLastin classDelegatingFOEventHandler- Parameters:
pageLast- PageNumberCitationLast that is starting.
-
endPageNumberCitationLast
- Overrides:
endPageNumberCitationLastin classDelegatingFOEventHandler- Parameters:
pageLast- PageNumberCitationLast that is ending.
-
startStatic
Description copied from class:FOEventHandlerProcess start of a Static.- Overrides:
startStaticin classDelegatingFOEventHandler- Parameters:
staticContent- StaticContent that is starting
-
endStatic
Description copied from class:FOEventHandlerProcess end of a Static.- Overrides:
endStaticin classDelegatingFOEventHandler- Parameters:
staticContent- StaticContent that is ending
-
startFlow
Description copied from class:FOEventHandlerThis method is called to indicate the start of a new fo:flow or fo:static-content. This method also handles fo:static-content tags, because the StaticContent class is derived from the Flow class.- Overrides:
startFlowin classDelegatingFOEventHandler- Parameters:
fl- Flow that is starting.
-
endFlow
- Overrides:
endFlowin classDelegatingFOEventHandler- Parameters:
fl- Flow that is ending.
-
startBlock
- Overrides:
startBlockin classDelegatingFOEventHandler- Parameters:
bl- Block that is starting.
-
endBlock
- Overrides:
endBlockin classDelegatingFOEventHandler- Parameters:
bl- Block that is ending.
-
startBlockContainer
- Overrides:
startBlockContainerin classDelegatingFOEventHandler- Parameters:
blc- BlockContainer that is starting.
-
endBlockContainer
- Overrides:
endBlockContainerin classDelegatingFOEventHandler- Parameters:
blc- BlockContainer that is ending.
-
startInline
- Overrides:
startInlinein classDelegatingFOEventHandler- Parameters:
inl- Inline that is starting.
-
endInline
- Overrides:
endInlinein classDelegatingFOEventHandler- Parameters:
inl- Inline that is ending.
-
startTable
- Overrides:
startTablein classDelegatingFOEventHandler- Parameters:
tbl- Table that is starting.
-
endTable
- Overrides:
endTablein classDelegatingFOEventHandler- Parameters:
tbl- Table that is ending.
-
startColumn
- Overrides:
startColumnin classDelegatingFOEventHandler- Parameters:
tc- TableColumn that is starting;
-
endColumn
- Overrides:
endColumnin classDelegatingFOEventHandler- Parameters:
tc- TableColumn that is ending;
-
startHeader
- Overrides:
startHeaderin classDelegatingFOEventHandler- Parameters:
header- TableHeader that is starting;
-
endHeader
- Overrides:
endHeaderin classDelegatingFOEventHandler- Parameters:
header- TableHeader that is ending.
-
startBody
- Overrides:
startBodyin classDelegatingFOEventHandler- Parameters:
body- TableBody that is starting.
-
endBody
- Overrides:
endBodyin classDelegatingFOEventHandler- Parameters:
body- TableBody that is ending.
-
startRow
- Overrides:
startRowin classDelegatingFOEventHandler- Parameters:
tr- TableRow that is starting.
-
endRow
- Overrides:
endRowin classDelegatingFOEventHandler- Parameters:
tr- TableRow that is ending.
-
startCell
- Overrides:
startCellin classDelegatingFOEventHandler- Parameters:
tc- TableCell that is starting.
-
endCell
- Overrides:
endCellin classDelegatingFOEventHandler- Parameters:
tc- TableCell that is ending.
-
startList
- Overrides:
startListin classDelegatingFOEventHandler- Parameters:
lb- ListBlock that is starting.
-
endList
- Overrides:
endListin classDelegatingFOEventHandler- Parameters:
lb- ListBlock that is ending.
-
startListItem
- Overrides:
startListItemin classDelegatingFOEventHandler- Parameters:
li- ListItem that is starting.
-
endListItem
- Overrides:
endListItemin classDelegatingFOEventHandler- Parameters:
li- ListItem that is ending.
-
startListLabel
Description copied from class:FOEventHandlerProcess start of a ListLabel.- Overrides:
startListLabelin classDelegatingFOEventHandler- Parameters:
listItemLabel- ListItemLabel that is starting
-
endListLabel
Description copied from class:FOEventHandlerProcess end of a ListLabel.- Overrides:
endListLabelin classDelegatingFOEventHandler- Parameters:
listItemLabel- ListItemLabel that is ending
-
startListBody
Description copied from class:FOEventHandlerProcess start of a ListBody.- Overrides:
startListBodyin classDelegatingFOEventHandler- Parameters:
listItemBody- ListItemBody that is starting
-
endListBody
Description copied from class:FOEventHandlerProcess end of a ListBody.- Overrides:
endListBodyin classDelegatingFOEventHandler- Parameters:
listItemBody- ListItemBody that is ending
-
startMarkup
public void startMarkup()Description copied from class:FOEventHandlerProcess start of a Markup.- Overrides:
startMarkupin classDelegatingFOEventHandler
-
endMarkup
public void endMarkup()Description copied from class:FOEventHandlerProcess end of a Markup.- Overrides:
endMarkupin classDelegatingFOEventHandler
-
startLink
Description copied from class:FOEventHandlerProcess start of a Link.- Overrides:
startLinkin classDelegatingFOEventHandler- Parameters:
basicLink- BasicLink that is starting
-
endLink
Description copied from class:FOEventHandlerProcess end of a Link.- Overrides:
endLinkin classDelegatingFOEventHandler- Parameters:
basicLink- BasicLink that is ending
-
image
Description copied from class:FOEventHandlerProcess an ExternalGraphic.- Overrides:
imagein classDelegatingFOEventHandler- Parameters:
eg- ExternalGraphic to process.
-
pageRef
public void pageRef()Description copied from class:FOEventHandlerProcess a pageRef.- Overrides:
pageRefin classDelegatingFOEventHandler
-
startInstreamForeignObject
Description copied from class:FOEventHandlerProcess the start of an InstreamForeignObject.- Overrides:
startInstreamForeignObjectin classDelegatingFOEventHandler- Parameters:
ifo- InstreamForeignObject that is starting
-
endInstreamForeignObject
Description copied from class:FOEventHandlerProcess the end of an InstreamForeignObject.- Overrides:
endInstreamForeignObjectin classDelegatingFOEventHandler- Parameters:
ifo- InstreamForeignObject that is ending
-
startFootnote
Description copied from class:FOEventHandlerProcess the start of a footnote.- Overrides:
startFootnotein classDelegatingFOEventHandler- Parameters:
footnote- Footnote that is starting
-
endFootnote
Description copied from class:FOEventHandlerProcess the ending of a footnote.- Overrides:
endFootnotein classDelegatingFOEventHandler- Parameters:
footnote- Footnote that is ending
-
startFootnoteBody
Description copied from class:FOEventHandlerProcess the start of a footnote body.- Overrides:
startFootnoteBodyin classDelegatingFOEventHandler- Parameters:
body- FootnoteBody that is starting
-
endFootnoteBody
Description copied from class:FOEventHandlerProcess the ending of a footnote body.- Overrides:
endFootnoteBodyin classDelegatingFOEventHandler- Parameters:
body- FootnoteBody that is ending
-
startLeader
Description copied from class:FOEventHandlerProcess the start of a Leader.- Overrides:
startLeaderin classDelegatingFOEventHandler- Parameters:
l- Leader that is starting
-
endLeader
Description copied from class:FOEventHandlerProcess the end of a Leader.- Overrides:
endLeaderin classDelegatingFOEventHandler- Parameters:
l- Leader that is ending
-
startWrapper
Description copied from class:FOEventHandlerProcess the start of a wrapper.- Overrides:
startWrapperin classDelegatingFOEventHandler- Parameters:
wrapper- wrapper that is starting
-
endWrapper
Description copied from class:FOEventHandlerProcess the ending of a wrapper.- Overrides:
endWrapperin classDelegatingFOEventHandler- Parameters:
wrapper- wrapper that is ending
-
startRetrieveMarker
Description copied from class:FOEventHandlerProcess the start of a retrieve-marker.- Overrides:
startRetrieveMarkerin classDelegatingFOEventHandler- Parameters:
retrieveMarker- the retrieve-marker that is starting
-
endRetrieveMarker
Description copied from class:FOEventHandlerProcess the ending of a retrieve-marker.- Overrides:
endRetrieveMarkerin classDelegatingFOEventHandler- Parameters:
retrieveMarker- the retrieve-marker that is ending
-
restoreState
Description copied from class:FOEventHandlerRestore the state of this event handler as it was when the given fo:retrieve-marker element was processed. This method is called at marker retrieval time, so that events for the marker descendants are fired within the proper context.The default implementation of this method does nothing.
- Overrides:
restoreStatein classDelegatingFOEventHandler- Parameters:
retrieveMarker- the fo:retrieve-marker element that is retrieving markers
-
startRetrieveTableMarker
Description copied from class:FOEventHandlerProcess the start of a retrieve-table-marker.- Overrides:
startRetrieveTableMarkerin classDelegatingFOEventHandler- Parameters:
retrieveTableMarker- the retrieve-table-marker that is starting
-
endRetrieveTableMarker
Description copied from class:FOEventHandlerProcess the ending of a retrieve-table-marker.- Overrides:
endRetrieveTableMarkerin classDelegatingFOEventHandler- Parameters:
retrieveTableMarker- the retrieve-table-marker that is ending
-
restoreState
Description copied from class:FOEventHandler- Overrides:
restoreStatein classDelegatingFOEventHandler
-
character
Description copied from class:FOEventHandlerProcess a Character.- Overrides:
characterin classDelegatingFOEventHandler- Parameters:
c- Character to process.
-
characters
Description copied from class:FOEventHandlerProcess character data.- Overrides:
charactersin classDelegatingFOEventHandler- Parameters:
foText- text to process
-
startExternalDocument
Description copied from class:FOEventHandlerProcess the start of the external-document extension.- Overrides:
startExternalDocumentin classDelegatingFOEventHandler- Parameters:
document- the external-document node
-
endExternalDocument
Description copied from class:FOEventHandlerProcess the end of the external-document extension.- Overrides:
endExternalDocumentin classDelegatingFOEventHandler- Parameters:
document- the external-document node
-