
io.github.cgi.zabbix.api.Request Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zabbix-api Show documentation
Show all versions of zabbix-api Show documentation
This is simple Zabbix API Client for Java.
It's fork of original client https://github.com/hengyunabc/zabbix-api
but with small changes in java version, dependencies, api contract, tests.
The newest version!
package io.github.cgi.zabbix.api;
import org.codehaus.jackson.map.ObjectMapper;
import java.util.HashMap;
import java.util.Map;
public class Request {
private String jsonrpc = "2.0";
private Map params = new HashMap();
private String method;
private String auth;
private Integer id;
public void putParam(String key, Object value) {
params.put(key, value);
}
public Object removeParam(String key) {
return params.remove(key);
}
public String getJsonrpc() {
return jsonrpc;
}
public void setJsonrpc(String jsonrpc) {
this.jsonrpc = jsonrpc;
}
public Map getParams() {
return params;
}
public void setParams(Map params) {
this.params = params;
}
public String getMethod() {
return method;
}
public void setMethod(String method) {
this.method = method;
}
public String getAuth() {
return auth;
}
public void setAuth(String auth) {
this.auth = auth;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
@Override
public String toString() {
return Utils.toJson(this);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy