|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.aerith.misao.xml.IONode | +--net.aerith.misao.xml.relaxer.XmlReport | +--net.aerith.misao.xml.XmlReport
The XmlReport
is an application side implementation
of the class that the relaxer generated automatically.
In order to reduce the memory assumption, all the star data are converted into the internal data by masticateXml method after reading the XML file, and restored into the XML data by composeXml method.
Fields inherited from class net.aerith.misao.xml.relaxer.XmlReport |
data,
information,
parentRNode,
rContext,
system |
Constructor Summary | |
XmlReport()
|
Method Summary | |
void |
countStars()
Counts the number of stars. |
private static java.lang.String |
getAttribute(java.lang.String s)
Gets the attribute string in one line of the XML document. |
private static java.lang.String |
getContent(java.lang.String s)
Gets the content string in one line of the XML document. |
static XmlReport |
read(java.io.BufferedReader in,
Coor coor,
double radius)
Reads the XML report document with only star data around the specified R.A. |
void |
read(java.io.File file)
Reads this XML document from the specified file. |
void |
read(java.io.Reader in)
Reads this XML document from the specified reader. |
static XmlInformation |
readInformation(java.io.File file)
Reads only the information element in the XML document from the specified file. |
static XmlInformation |
readInformation(java.io.Reader in)
Reads only the information element in the XML document from the specified reader. |
static XmlStar |
readStar(java.io.BufferedReader in,
java.lang.String name)
Reads the star element in the XML report document with the specified name. |
void |
write(java.io.File file)
Writes this XML document to the specified file. |
void |
write(java.io.Writer out)
Writes this XML document to the specified writer. |
Methods inherited from class net.aerith.misao.xml.relaxer.XmlReport |
getData,
getInformation,
getParentRNode,
getRContext,
getRContextResolved,
getRNodes,
getSystem,
init,
isMatch,
isMatch,
isMatchHungry,
makeElement,
setData,
setInformation,
setParentRNode,
setRContext,
setSystem,
setup,
setup,
setup |
Methods inherited from class net.aerith.misao.xml.IONode |
translateFrom,
translateTo |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public XmlReport()
Method Detail |
public void read(java.io.Reader in) throws java.io.IOException
This method does not use the standard DOM parser, but runs faster and does not consume too much memory.
in
- the reader.public void read(java.io.File file) throws java.io.IOException
GZIPInputStream
.file
- the file.private static java.lang.String getContent(java.lang.String s)
s
- the one line string.private static java.lang.String getAttribute(java.lang.String s)
s
- the one line string.public static XmlInformation readInformation(java.io.File file) throws java.io.IOException, java.io.FileNotFoundException
GZIPInputStream
.file
- the XML document file.public static XmlInformation readInformation(java.io.Reader in) throws java.io.IOException
in
- the reader.public static XmlReport read(java.io.BufferedReader in, Coor coor, double radius) throws java.io.IOException
in
- the reader.coor
- the R.A. and Decl.radius
- the radius in degree.public static XmlStar readStar(java.io.BufferedReader in, java.lang.String name) throws java.io.IOException
in
- the reader.name
- the name.public void write(java.io.Writer out) throws java.io.IOException
out
- the writer.public void write(java.io.File file) throws java.io.IOException
GZIPOutputStream
.out
- the writer.public void countStars()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |