mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-27 08:38:13 -07:00
clean up
This commit is contained in:
parent
f2aa5435ed
commit
93ea4eee5e
1 changed files with 10 additions and 12 deletions
|
@ -64,15 +64,13 @@ public class Pom @javax.inject.Inject constructor(@Assisted val id: String,
|
||||||
version = XPATH.compile("/project/version").evaluate(document)
|
version = XPATH.compile("/project/version").evaluate(document)
|
||||||
name = XPATH.compile("/project/name").evaluate(document)
|
name = XPATH.compile("/project/name").evaluate(document)
|
||||||
var repositoriesList = XPATH.compile("/project/repositories").evaluate(document, XPathConstants.NODESET) as NodeList
|
var repositoriesList = XPATH.compile("/project/repositories").evaluate(document, XPathConstants.NODESET) as NodeList
|
||||||
// if (repositoriesList.getLength() != 0) {
|
var repoElem = repositoriesList.item(0) as Element?
|
||||||
var elem = repositoriesList.item(0) as Element?
|
repositories = repoElem.childElements()
|
||||||
repositories = elem.childElements()
|
|
||||||
.map({ it.getElementsByTagName("url").item(0).textContent })
|
.map({ it.getElementsByTagName("url").item(0).textContent })
|
||||||
// }
|
|
||||||
|
|
||||||
val propertiesList = XPATH.compile("/project/properties").evaluate(document, XPathConstants.NODESET) as NodeList
|
val propertiesList = XPATH.compile("/project/properties").evaluate(document, XPathConstants.NODESET) as NodeList
|
||||||
/*var*/ elem = propertiesList.item(0) as Element?
|
var propsElem = propertiesList.item(0) as Element?
|
||||||
elem.childElements().forEach {
|
propsElem.childElements().forEach {
|
||||||
properties.put(it.nodeName, it.textContent)
|
properties.put(it.nodeName, it.textContent)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue