hirezapi.AbstractAPI Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of HiRezApi-common Show documentation
Show all versions of HiRezApi-common Show documentation
Java-Based API Wrapper for Hi-Rez Studios games.
The newest version!
package hirezapi;
import hirezapi.session.EnvironmentalSessionStorage;
import hirezapi.session.SessionStorage;
import lombok.AccessLevel;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import lombok.Setter;
@Getter
@Setter(AccessLevel.PROTECTED)
@RequiredArgsConstructor(access = AccessLevel.PROTECTED)
public abstract class AbstractAPI {
private final Platform platform;
private SessionStorage sessionStorage = new EnvironmentalSessionStorage();
public abstract T init(String devId, String authKey);
public abstract AbstractAPI sessionStorage(SessionStorage sessionStorage);
protected Configuration buildConfiguration(String devId, String authKey) {
return Configuration.of(platform, devId, authKey);
}
}