com.github.raduciumag.shapeshift.server.ServerBuilder Maven / Gradle / Ivy
package com.github.raduciumag.shapeshift.server;
import com.github.raduciumag.shapeshift.config.ServerConfig;
import com.github.raduciumag.shapeshift.model.server.ServerType;
public abstract class ServerBuilder, C extends ServerConfig> {
protected final ServerType type;
protected ServerBuilder(final ServerType type) {
this.type = type;
}
public boolean canBuild(final ServerType type) {
if (this.type == null || type == null) {
return false;
}
return this.type == type;
}
public abstract S buildServer(C serverConfig);
}