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

graphql.servlet.StaticGraphQLRootObjectBuilder Maven / Gradle / Ivy

The newest version!
package graphql.servlet;

import javax.servlet.http.HttpServletRequest;
import javax.websocket.server.HandshakeRequest;

public class StaticGraphQLRootObjectBuilder implements GraphQLRootObjectBuilder {

    private final Object rootObject;

    public StaticGraphQLRootObjectBuilder(Object rootObject) {
        this.rootObject = rootObject;
    }

    @Override
    public Object build(HttpServletRequest req) {
        return rootObject;
    }

    @Override
    public Object build(HandshakeRequest req) {
        return rootObject;
    }

    @Override
    public Object build() {
        return rootObject;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy