|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.palserv.XMidi.XM
Convert an XMidi file (XML) to a midi file.
This class can be used in two ways:
XM xm = new XM(args);
xm.xMidiToMidi();or invoke one of the two sub-methods:
Document xDoc = xMidiToDoc("blah.xmi");or
docToMidi(xDoc, "blah.mid");
Even though the XMidi format has a DTD (XMidi.dtd) associated with it, this program does quite a bit of its own validation. This may be somewhat redundant, but it will allow the program to work on an XMidi file which does not name a DTD. The validation forces many of the same things as the DTD, although there are differences.
Constructor Summary | |
XM(java.lang.String[] args)
public constructor Takes "command line" arguments. |
Method Summary | |
void |
docToMidi(org.w3c.dom.Document xDoc,
java.lang.String outFile)
Traverse a DOM structure and produce a MIDI file. |
static void |
main(java.lang.String[] args)
This method is for command line invocation. |
org.w3c.dom.Document |
xMidiToDoc(java.lang.String fid)
Read in a XMidi file (XML) and produce a DOM structure. |
void |
xMidiToMidi()
Convert an XMidi file (XML) to a midi file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public XM(java.lang.String[] args)
Util.getCmdLine
method for details.
Also, see the main package description
for details about external parsers.String[]
- args - command line arguments (as in main)Method Detail |
public void xMidiToMidi()
public org.w3c.dom.Document xMidiToDoc(java.lang.String fid)
String
- fid - name of input (XMidi) file.public void docToMidi(org.w3c.dom.Document xDoc, java.lang.String outFile)
Document
- xDoc - the DOM Document for the DOM structureString
- outFile - the file name of the output (MIDI) file.public static void main(java.lang.String[] args)
Util.getCmdLine
method for details of the command line syntax.String[]
- args - command line
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |