mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-23 00:13:16 +00:00
パーサー更新
This commit is contained in:
parent
cd5a588545
commit
e5e1b3a2bb
|
@ -32,10 +32,7 @@ public class XmlMetaParserImpl implements XmlMetaParser{
|
||||||
|
|
||||||
XmlMetaModel meta = new XmlMetaModel();
|
XmlMetaModel meta = new XmlMetaModel();
|
||||||
|
|
||||||
meta.setTitle(rootElement.getElementsByTagName("title").item(0).getTextContent());
|
meta.setRevisionId(rootElement.getElementsByTagName("revisionId").item(0).getTextContent());
|
||||||
meta.setAuthor(rootElement.getElementsByTagName("author").item(0).getTextContent());
|
|
||||||
meta.setDescription(rootElement.getElementsByTagName("description").item(0).getTextContent());
|
|
||||||
meta.setDefaultBranch(rootElement.getElementsByTagName("defaultBranch").item(0).getTextContent());
|
|
||||||
|
|
||||||
ArrayList<XmlMetaPageModel> pages = new ArrayList<>();
|
ArrayList<XmlMetaPageModel> pages = new ArrayList<>();
|
||||||
for(int i = 0; i < rootElement.getElementsByTagName("pages").getLength(); i++) {
|
for(int i = 0; i < rootElement.getElementsByTagName("pages").getLength(); i++) {
|
||||||
|
@ -64,10 +61,7 @@ public class XmlMetaParserImpl implements XmlMetaParser{
|
||||||
|
|
||||||
Element rootElement = document.createElement("meta");
|
Element rootElement = document.createElement("meta");
|
||||||
|
|
||||||
appendElement(document, rootElement, "title", meta.getTitle());
|
appendElement(document, rootElement, "revisionId", meta.getRevisionId());
|
||||||
appendElement(document, rootElement, "author", meta.getAuthor());
|
|
||||||
appendElement(document, rootElement, "description", meta.getDescription());
|
|
||||||
appendElement(document, rootElement, "defaultBranch", meta.getDefaultBranch());
|
|
||||||
|
|
||||||
Element pagesElement = document.createElement("pages");
|
Element pagesElement = document.createElement("pages");
|
||||||
for(XmlMetaPageModel page : meta.getPages()) {
|
for(XmlMetaPageModel page : meta.getPages()) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user