|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object components.XMLWriter
public class XMLWriter
XMLWriter is used to take a gamespace and a file or filename, and write the gamespace information to that file. It then verfies that the information is a validate gb_level schema. It is muttable.
Our output follows this format:
filname
: String //this is the file name of the output xml fileConstructor Summary | |
---|---|
XMLWriter()
|
Method Summary | |
---|---|
void |
writeMap(Element parent,
Map<String,String> m)
This takes a map, and an element, and writes every key value pair in map as attributes in that element |
void |
writeObjects(Element parent,
Set<GameObject> objs)
Formats objs for writing to xml |
void |
writeXML(GameSpace g,
File f)
This overloads writeXML. |
void |
writeXML(GameSpace g,
String name)
Given a namespace, and a filename, will write the information g to name in XMLFormat and make sure its a valid gb_level schema. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public XMLWriter()
Method Detail |
---|
public void writeXML(GameSpace g, File f) throws ParserConfigurationException, SAXException, IOException
IOException
SAXException
ParserConfigurationException
public void writeXML(GameSpace g, String name) throws ParserConfigurationException, SAXException, IOException
ParserConfigurationException
SAXException
IOException
public void writeObjects(Element parent, Set<GameObject> objs)
public void writeMap(Element parent, Map<String,String> m)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |