
vectorpipe.model.ChangesetComment.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vectorpipe_2.11 Show documentation
Show all versions of vectorpipe_2.11 Show documentation
Import OSM data and output to VectorTiles with GeoTrellis.
The newest version!
package vectorpipe.model
import java.sql.Timestamp
import org.joda.time.DateTime
case class ChangesetComment(date: Timestamp, user: String, uid: Long, body: String)
object ChangesetComment {
implicit def stringToTimestamp(s: String): Timestamp =
Timestamp.from(DateTime.parse(s).toDate.toInstant)
def fromXML(node: scala.xml.Node): ChangesetComment = {
val date = node \@ "date"
val user = node \@ "user"
val uid = (node \@ "uid").toLong
val body = (node \ "text").text
ChangesetComment(date, user, uid, body)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy