Skip to content

Instantly share code, notes, and snippets.

@Tonel
Created July 26, 2020 13:56
Show Gist options
  • Select an option

  • Save Tonel/e308af570e251092b7ddfef97497eb19 to your computer and use it in GitHub Desktop.

Select an option

Save Tonel/e308af570e251092b7ddfef97497eb19 to your computer and use it in GitHub Desktop.
class AuthorDto {
@JsonProperty("id")
var id: Int? = null
@JsonProperty("name")
var name: String? = null
@JsonProperty("surname")
var surname: String? = null
@JsonProperty("birthDate")
@JsonFormat(pattern = "MM/dd/yyyy")
var birthDate: Date? = null
@JsonProperty("books")
var books: List<BookDto> = ArrayList()
}
class BookDto {
@JsonProperty("id")
var id: Int? = null
@JsonProperty("title")
var title: String? = null
@JsonProperty("releaseDate")
@JsonFormat(pattern = "MM/dd/yyyy")
var releaseDate: Date? = null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment