package io.vertx.ext.web.handler.graphql.impl;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import java.util.Map;
@JsonDeserialize(as = GraphQLQuery.class)
@JsonIgnoreProperties(ignoreUnknown = true)
public class GraphQLQuery implements GraphQLInput {
private String query;
private String operationName;
private Map<String, Object> variables;
public GraphQLQuery() {
}
public GraphQLQuery(String query, String operationName, Map<String, Object> variables) {
this.query = query;
this.operationName = operationName;
this.variables = variables;
}
public String getQuery() {
return query;
}
public GraphQLQuery setQuery(String query) {
this.query = query;
return this;
}
public String getOperationName() {
return operationName;
}
public GraphQLQuery setOperationName(String operationName) {
this.operationName = operationName;
return this;
}
public Map<String, Object> getVariables() {
return variables;
}
public GraphQLQuery setVariables(Map<String, Object> variables) {
this.variables = variables;
return this;
}
@Override
public String toString() {
return "GraphQLQuery{" +
"query='" + query + '\'' +
", operationName='" + operationName + '\'' +
", variables=" + variables +
'}';
}
}