All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dell.cpsd.hal.data.provider.api.VersionDatum Maven / Gradle / Ivy


package com.dell.cpsd.hal.data.provider.api;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({
    "type",
    "version"
})
public class VersionDatum {

    @JsonProperty("type")
    private String type;
    @JsonProperty("version")
    private String version;

    /**
     * No args constructor for use in serialization
     * 
     */
    public VersionDatum() {
    }

    /**
     * 
     * @param type
     * @param version
     */
    public VersionDatum(String type, String version) {
        super();
        this.type = type;
        this.version = version;
    }

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

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

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

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

    @Override
    public String toString() {
        return ToStringBuilder.reflectionToString(this);
    }

    @Override
    public int hashCode() {
        return new HashCodeBuilder().append(type).append(version).toHashCode();
    }

    @Override
    public boolean equals(Object other) {
        if (other == this) {
            return true;
        }
        if ((other instanceof VersionDatum) == false) {
            return false;
        }
        VersionDatum rhs = ((VersionDatum) other);
        return new EqualsBuilder().append(type, rhs.type).append(version, rhs.version).isEquals();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy