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

com.dell.cpsd.hdp.capability.registry.api.Query Maven / Gradle / Ivy

Go to download

This repository contains the source code for the capability registry API. This API exposes the interface through which a consumer or provider interacts with the capability registry.

There is a newer version: 1.1.0
Show newest version

package com.dell.cpsd.hdp.capability.registry.api;

import java.util.ArrayList;
import java.util.List;
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({
    "identifier",
    "termsQueries"
})
public class Query {

    @JsonProperty("identifier")
    private String identifier;
    @JsonProperty("termsQueries")
    private List termsQueries = new ArrayList();

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

    /**
     * 
     * @param identifier
     * @param termsQueries
     */
    public Query(String identifier, List termsQueries) {
        super();
        this.identifier = identifier;
        this.termsQueries = termsQueries;
    }

    /**
     * 
     * @return
     *     The identifier
     */
    @JsonProperty("identifier")
    public String getIdentifier() {
        return identifier;
    }

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

    /**
     * 
     * @return
     *     The termsQueries
     */
    @JsonProperty("termsQueries")
    public List getTermsQueries() {
        return termsQueries;
    }

    /**
     * 
     * @param termsQueries
     *     The termsQueries
     */
    @JsonProperty("termsQueries")
    public void setTermsQueries(List termsQueries) {
        this.termsQueries = termsQueries;
    }

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

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

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

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy