Last active
October 4, 2017 11:46
-
-
Save feroult/0538eb2de505772474f8afb84d411942 to your computer and use it in GitHub Desktop.
YAWP Kotlin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Endpoint(path = "/people") | |
class Person(@Id | |
var id: IdRef<Person>? = null, | |
var name: String? = null, | |
var age: Int? = null) | |
fun example() { | |
var person = Person(name = "John", age = 10) | |
print("${person.name} has ${person.age} years old") | |
yawp.save(person) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment