|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sourceforge.java.feednread.backend.exporter.OPMLExport
Exports a hierarchical Category structure to an xml JDOM
Document which can on his part be exported to a valid OPML 1.1 File.
| Field Summary | |
private static DateFormat |
DEFAULT_DATE_FORMATTER
The default DateFormat object to format dates. |
private static String |
GENERATOR_TEXT
The export generator text |
private static String |
OPML_VERSION
The OPML version used for export |
private Category |
rootCategory
The Category to export to OPML |
| Constructor Summary | |
OPMLExport(Category root)
Creates a new OPMLExport bound to the specified
Category.
|
|
| Method Summary | |
private void |
createBody(Element root)
Creates a default OPML body section. |
private Document |
createDocument()
Creates a default OPML Document.
|
private void |
createHead(Element root)
Creates a default OPML head section. |
void |
doExport(String fileName)
Exports the set rootCategory to a File with the
specified fileName.
|
protected void |
exportCategory(Category category,
Element parent)
Recursively exports the specified Category to
the specified parent Element.
|
protected void |
exportFavorite(Favorite favorite,
Element categoryOutline)
Exports the specified Favorite to the
specified categoryOutline Element.
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private static final String OPML_VERSION
The OPML version used for export
private static final String GENERATOR_TEXT
The export generator text
private static final DateFormat DEFAULT_DATE_FORMATTER
The default DateFormat object to format dates.
private Category rootCategory
The Category to export to OPML
| Constructor Detail |
public OPMLExport(Category root)
Creates a new OPMLExport bound to the specified
Category.
root - the Category to export| Method Detail |
private Document createDocument()
Creates a default OPML Document.
Documentprivate void createHead(Element root)
Creates a default OPML head section.
root - the OPML Document rootprivate void createBody(Element root)
Creates a default OPML body section.
root - the OPML Document root
protected void exportCategory(Category category,
Element parent)
Recursively exports the specified Category to
the specified parent Element.
category - the Category to exportparent - the parent Element to export the
specified Category to
protected void exportFavorite(Favorite favorite,
Element categoryOutline)
Exports the specified Favorite to the
specified categoryOutline Element.
favorite - the Favorite to exportcategoryOutline - the outline Element to
export the specified Favorite to
public void doExport(String fileName)
throws IOException
Exports the set rootCategory to a File with the
specified fileName.
fileName - the name of the file to export to
IOException - if the export failed due to an IO error
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||