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

graphql.kickstart.spring.error.ErrorHandlerSupplier Maven / Gradle / Ivy

package graphql.kickstart.spring.error;

import graphql.kickstart.execution.error.GraphQLErrorHandler;
import java.util.function.Supplier;

public class ErrorHandlerSupplier implements Supplier {

  private GraphQLErrorHandler errorHandler;

  public ErrorHandlerSupplier(GraphQLErrorHandler errorHandler) {
    this.errorHandler = errorHandler;
  }

  @Override
  public GraphQLErrorHandler get() {
    return errorHandler;
  }

  public boolean isPresent() {
    return errorHandler != null;
  }

  public void setErrorHandler(GraphQLErrorHandler errorHandler) {
    this.errorHandler = errorHandler;
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy