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

graphql.kickstart.execution.DecoratedExecutionResult Maven / Gradle / Ivy

The newest version!
package graphql.kickstart.execution;

import graphql.ExecutionResult;
import graphql.GraphQLError;
import java.util.List;
import java.util.Map;
import lombok.RequiredArgsConstructor;
import org.reactivestreams.Publisher;

@RequiredArgsConstructor
class DecoratedExecutionResult implements ExecutionResult {

  private final ExecutionResult result;

  boolean isAsynchronous() {
    return result.getData() instanceof Publisher;
  }

  @Override
  public List getErrors() {
    return result.getErrors();
  }

  @Override
  public  T getData() {
    return result.getData();
  }

  @Override
  public boolean isDataPresent() {
    return result.isDataPresent();
  }

  @Override
  public Map getExtensions() {
    return result.getExtensions();
  }

  @Override
  public Map toSpecification() {
    return result.toSpecification();
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy