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

com.exaroton.api.request.server.ServerRequest Maven / Gradle / Ivy

There is a newer version: 1.5.0
Show newest version
package com.exaroton.api.request.server;

import com.exaroton.api.APIRequest;
import com.exaroton.api.ExarotonClient;

import java.util.HashMap;

public abstract class ServerRequest extends APIRequest {

    private final String serverId;

    public ServerRequest(ExarotonClient client, String serverId) {
        super(client);
        if (serverId == null || serverId.length() == 0) throw new IllegalArgumentException("Invalid server id!");
        this.serverId = serverId;
    }

    @Override
    protected HashMap getData() {
        HashMap map = super.getData();
        map.put("id", this.serverId);
        return map;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy