0% found this document useful (0 votes)
40 views

Example

This Java class defines an Example object that can be serialized and deserialized from JSON. It contains properties for type, version, previousFullVersion, downloadLinks, and timestamp. Getter and setter methods are included for each property. Additional arbitrary properties are also supported through a Map.

Uploaded by

Apócrifos Team
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views

Example

This Java class defines an Example object that can be serialized and deserialized from JSON. It contains properties for type, version, previousFullVersion, downloadLinks, and timestamp. Getter and setter methods are included for each property. Additional arbitrary properties are also supported through a Map.

Uploaded by

Apócrifos Team
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

package com.

example;

import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;

@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({
"type",
"version",
"previousFullVersion",
"downloadLinks",
"timestamp"
})
public class Example {

@JsonProperty("type")
private String type;
@JsonProperty("version")
private String version;
@JsonProperty("previousFullVersion")
private String previousFullVersion;
@JsonProperty("downloadLinks")
private List<DownloadLink> downloadLinks = null;
@JsonProperty("timestamp")
private String timestamp;
@JsonIgnore
private Map<String, Object> additionalProperties = new HashMap<String,
Object>();

@JsonProperty("type")
public String getType() {
return type;
}

@JsonProperty("type")
public void setType(String type) {
this.type = type;
}

@JsonProperty("version")
public String getVersion() {
return version;
}

@JsonProperty("version")
public void setVersion(String version) {
this.version = version;
}

@JsonProperty("previousFullVersion")
public String getPreviousFullVersion() {
return previousFullVersion;
}

@JsonProperty("previousFullVersion")
public void setPreviousFullVersion(String previousFullVersion) {
this.previousFullVersion = previousFullVersion;
}

@JsonProperty("downloadLinks")
public List<DownloadLink> getDownloadLinks() {
return downloadLinks;
}

@JsonProperty("downloadLinks")
public void setDownloadLinks(List<DownloadLink> downloadLinks) {
this.downloadLinks = downloadLinks;
}

@JsonProperty("timestamp")
public String getTimestamp() {
return timestamp;
}

@JsonProperty("timestamp")
public void setTimestamp(String timestamp) {
this.timestamp = timestamp;
}

@JsonAnyGetter
public Map<String, Object> getAdditionalProperties() {
return this.additionalProperties;
}

@JsonAnySetter
public void setAdditionalProperty(String name, Object value) {
this.additionalProperties.put(name, value);
}

You might also like