|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jmatchparser.util.csv.AbstractCSVWriter
net.sf.jmatchparser.util.csv.XMLCSVWriter
public class XMLCSVWriter
Class to create an XML file as if it was a CSV (Comma Separated Value) file.
Constructor Summary | |
---|---|
XMLCSVWriter(Node root,
String rowTag,
String... cellTags)
Create a new XMLCSVWriter that writes to the given DOM document. |
|
XMLCSVWriter(OutputStream out,
String rootTag,
String rowTag,
String... cellTags)
Create a new XMLCSVWriter that writes to the given DOM document. |
Method Summary | |
---|---|
void |
close()
Close this CSV writer. |
void |
flush()
Flush this CSV writer. |
void |
write(String... record)
Write a record (line) into this CSV file. |
Methods inherited from class net.sf.jmatchparser.util.csv.AbstractCSVWriter |
---|
write |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public XMLCSVWriter(Node root, String rowTag, String... cellTags)
XMLCSVWriter
that writes to the given DOM document.
Rows will become child elements given root element that have the row tag
as name, and cells will become children of the row, with the cell tags
(assigned round robin) as name.
root
- the root noderowTag
- the name of row elementscellTags
- the names of cell elementspublic XMLCSVWriter(OutputStream out, String rootTag, String rowTag, String... cellTags) throws ParserConfigurationException
XMLCSVWriter
that writes to the given DOM document.
Rows will become child elements of the document element that have the row
tag as name, and cells will become children of the row, with the cell
tags (assigned round robin) as name.
out
- Output stream to write torootTag
- the name of the root elementrowTag
- the name of row elementscellTags
- the names of cell elements
ParserConfigurationException
Method Detail |
---|
public void flush() throws IOException
AbstractCSVWriter
flush
in class AbstractCSVWriter
IOException
public void close() throws IOException
AbstractCSVWriter
close
in class AbstractCSVWriter
IOException
public void write(String... record) throws IOException
AbstractCSVWriter
write
in class AbstractCSVWriter
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |