class IntrospectionMapping extends ValueMapping[[β$1$]Either[Throwable, β$1$]]
- Source
- introspection.scala
- Alphabetic
- By Inheritance
- IntrospectionMapping
- ValueMapping
- ValueMappingLike
- Mapping
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- case class CursorField[T](fieldName: String, f: (Cursor) => Result[T], encoder: Encoder[T], required: List[String], hidden: Boolean)(implicit pos: SourcePos) extends FieldMapping with Product with Serializable
- Definition Classes
- Mapping
- case class Delegate(fieldName: String, mapping: Mapping[F], join: (Query, Cursor) => Result[Query] = ComponentElaborator.TrivialJoin)(implicit pos: SourcePos) extends FieldMapping with Product with Serializable
- Definition Classes
- Mapping
- case class EffectField(fieldName: String, handler: EffectHandler[F], required: List[String] = Nil, hidden: Boolean = false)(implicit pos: SourcePos) extends EffectMapping with Product with Serializable
- Definition Classes
- Mapping
- trait EffectMapping extends FieldMapping
Abstract type of field mappings with effects.
Abstract type of field mappings with effects.
- Definition Classes
- Mapping
- trait FieldMapping extends Product with Serializable
- Definition Classes
- Mapping
- case class FieldTransformCursor[T](underlying: Cursor, f: (T) => Result[T])(implicit evidence$2: ClassTag[T], evidence$3: TypeName[T]) extends ProxyCursor with Product with Serializable
Proxy
Cursor
which applies a function to the focus of an underlyingLeafCursor
.Proxy
Cursor
which applies a function to the focus of an underlyingLeafCursor
.- Definition Classes
- Mapping
- case class LeafCursor(context: Context, focus: Any, parent: Option[Cursor], env: Env) extends Cursor with Product with Serializable
Cursor positioned at a GraphQL result leaf
Cursor positioned at a GraphQL result leaf
- Definition Classes
- Mapping
- trait LeafMapping[T] extends TypeMapping
- Definition Classes
- Mapping
- abstract class ObjectMapping extends TypeMapping
- Definition Classes
- Mapping
- case class PrefixedMapping(tpe: Type, mappings: List[(List[String], ObjectMapping)])(implicit pos: SourcePos) extends TypeMapping with Product with Serializable
- Definition Classes
- Mapping
- case class PrimitiveField(fieldName: String, hidden: Boolean = false)(implicit pos: SourcePos) extends FieldMapping with Product with Serializable
- Definition Classes
- Mapping
- case class PrimitiveMapping(tpe: Type)(implicit pos: SourcePos) extends TypeMapping with Product with Serializable
- Definition Classes
- Mapping
- case class RootCursor(context: Context, parent: Option[Cursor], env: Env) extends AbstractCursor with Product with Serializable
Root
Cursor
focussed on the top level operation of a queryRoot
Cursor
focussed on the top level operation of a queryConstruction of mapping-specific cursors is handled by delegation to
mkCursorForField which is typically overridden in
Mappingsubtypes.
- Definition Classes
- Mapping
- case class RootEffect extends EffectMapping with Product with Serializable
Root effects can perform an intial effect prior to computing the resulting
Cursor
and effectiveQuery
.Root effects can perform an intial effect prior to computing the resulting
Cursor
and effectiveQuery
.These effects are used to perform initial effectful setup for a query or to perform the effect associated with a GraphQL mutation. Convenience methods are provided to cover the cases where only one of the query or the cursor are computed.
If only the query is computed the default root cursor for the mapping will be used. If only the cursor is computed the client query (after elaboration) is used unmodified ... in this case results of the performed effect can only be passed to the result construction stage via the environment associated with the returned cursor.
- Definition Classes
- Mapping
- case class RootStream extends EffectMapping with Product with Serializable
Root streams can perform an intial effect prior to emitting the resulting cursors and effective queries.
Root streams can perform an intial effect prior to emitting the resulting cursors and effective queries.
Stream effects are used for GraphQL subscriptions. Convenience methods are provided to cover the cases where only one of the query or the cursor are computed
If only the query is computed the default root cursor for the mapping will be used. If only the cursor is computed the client query (after elaboration) is used unmodified ... in this case results of the performed effect can only be passed to the result construction stage via the environment associated with the returned cursor.
- Definition Classes
- Mapping
- trait TypeMapping extends Product with Serializable
- Definition Classes
- Mapping
- case class ValueCursor(context: Context, focus: Any, parent: Option[Cursor], env: Env) extends Cursor with Product with Serializable
- Definition Classes
- ValueMappingLike
- case class ValueField[T](fieldName: String, f: (T) => Any, hidden: Boolean = false)(implicit pos: SourcePos) extends ValueFieldMapping[T] with Product with Serializable
- Definition Classes
- ValueMappingLike
- sealed trait ValueFieldMapping[T] extends FieldMapping
- Definition Classes
- ValueMappingLike
- case class ValueObjectMapping[T](tpe: Type, fieldMappings: List[ValueMappingLike.FieldMapping], classTag: ClassTag[T])(implicit pos: SourcePos) extends ObjectMapping with Product with Serializable
- Definition Classes
- ValueMappingLike
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- implicit val M: MonadThrow[[β$1$]Either[Throwable, β$1$]]
- Definition Classes
- ValueMapping → Mapping
- def ValueObjectMapping[T](tpe: Type, fieldMappings: List[ValueFieldMapping[T]])(implicit classTag: ClassTag[T], pos: SourcePos): ValueObjectMapping[T]
- Definition Classes
- ValueMappingLike
- val allTypes: List[NamedType]
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def combineAndRun(queries: List[(Query, Cursor)]): Either[Throwable, Result[List[ProtoJson]]]
Combine and execute multiple queries.
Combine and execute multiple queries.
Each query is interpreted in the context of the Cursor it is paired with. The result list is aligned with the argument query list. For each query at most one stage will be run and the corresponding result may contain deferred components.
Errors are aggregated across all the argument queries and are accumulated on the
Left
of the result.This method is typically called at the end of a stage to evaluate deferred subqueries in the result of that stage. These will be grouped by and passed jointly to the responsible mapping in the next stage using this method. Maappongs which are able to benefit from combining queries may do so by overriding this method to implement their specific combinging logic.
- Definition Classes
- Mapping
- def compileAndRun(text: String, name: Option[String] = None, untypedVars: Option[Json] = None, introspectionLevel: IntrospectionLevel = Full, env: Env = Env.empty)(implicit sc: Compiler[[β$1$]Either[Throwable, β$1$], [β$1$]Either[Throwable, β$1$]]): Either[Throwable, Json]
Compile and run a single GraphQL query or mutation.
Compile and run a single GraphQL query or mutation.
Yields a JSON response containing the result of the query or mutation.
- Definition Classes
- Mapping
- def compileAndRunSubscription(text: String, name: Option[String] = None, untypedVars: Option[Json] = None, introspectionLevel: IntrospectionLevel = Full, env: Env = Env.empty): Stream[[β$1$]Either[Throwable, β$1$], Json]
Compile and run a GraphQL subscription.
Compile and run a GraphQL subscription.
Yields a stream of JSON responses containing the results of the subscription.
- Definition Classes
- Mapping
- lazy val compiler: QueryCompiler
- Definition Classes
- Mapping
- def compilerPhases: List[Phase]
- Definition Classes
- Mapping
- lazy val componentElaborator: ComponentElaborator[[_]Either[Throwable, _]]
- Definition Classes
- Mapping
- def defaultRootCursor(query: Query, tpe: Type, parentCursor: Option[Cursor]): Either[Throwable, Result[(Query, Cursor)]]
Yields a
Cursor
focused on the top level operation type of the queryYields a
Cursor
focused on the top level operation type of the query- Definition Classes
- Mapping
- lazy val effectElaborator: EffectElaborator[[_]Either[Throwable, _]]
- Definition Classes
- Mapping
- def encoderForLeaf(tpe: Type): Option[Encoder[Any]]
Yields the
Encoder
associated with the provided type, if any.Yields the
Encoder
associated with the provided type, if any.- Definition Classes
- Mapping
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def fieldMapping(context: Context, fieldName: String): Option[FieldMapping]
Yields the
FieldMapping
associated withfieldName
incontext
, if any.Yields the
FieldMapping
associated withfieldName
incontext
, if any.- Definition Classes
- Mapping
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- val interpreter: QueryInterpreter[[β$1$]Either[Throwable, β$1$]]
- Definition Classes
- Mapping
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isLeaf(tpe: Type): Boolean
True if the supplied type is a leaf with respect to the GraphQL schema or mapping, false otherwise.
True if the supplied type is a leaf with respect to the GraphQL schema or mapping, false otherwise.
- Definition Classes
- Mapping
- def leafMapping[T](tpe: Type): Option[LeafMapping[T]]
Yields the
LeafMapping
associated with the provided type, if any.Yields the
LeafMapping
associated with the provided type, if any.- Definition Classes
- Mapping
- def mkCursor(context: Context, focus: Any, parent: Option[Cursor], env: Env): Cursor
- Definition Classes
- ValueMappingLike
- def mkCursorForField(parent: Cursor, fieldName: String, resultName: Option[String]): Result[Cursor]
Yields a
Cursor
suitable for traversing the query result corresponding to thefieldName
child ofparent
.Yields a
Cursor
suitable for traversing the query result corresponding to thefieldName
child ofparent
.This method is typically overridden in and delegated to by
Mapping
subtypes.- Definition Classes
- ValueMappingLike → Mapping
- def mkResponse(result: Result[Json]): Either[Throwable, Json]
Construct a GraphQL response from a
Result
.Construct a GraphQL response from a
Result
.- Definition Classes
- Mapping
- def mkResponse(data: Option[Json], errors: Chain[Problem]): Json
Construct a GraphQL response from the possibly absent result
data
and a collection of errors.Construct a GraphQL response from the possibly absent result
data
and a collection of errors.- Definition Classes
- Mapping
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def objectMapping(context: Context): Option[ObjectMapping]
Yields the
ObjectMapping
associated with the provided context, if any.Yields the
ObjectMapping
associated with the provided context, if any.- Definition Classes
- Mapping
- def rootEffect(context: Context, fieldName: String): Option[RootEffect]
Yields the
RootEffect
, if any, associated withfieldName
.Yields the
RootEffect
, if any, associated withfieldName
.- Definition Classes
- Mapping
- def rootStream(context: Context, fieldName: String): Option[RootStream]
Yields the
RootStream
, if any, associated withfieldName
.Yields the
RootStream
, if any, associated withfieldName
.- Definition Classes
- Mapping
- val schema: Schema
- Definition Classes
- IntrospectionMapping → Mapping
- val selectElaborator: SelectElaborator
- Definition Classes
- Mapping
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def typeMapping(tpe: NamedType): Option[TypeMapping]
Yields the
TypeMapping
associated with the provided type, if any.Yields the
TypeMapping
associated with the provided type, if any.- Definition Classes
- Mapping
- val typeMappings: List[TypeMapping]
- Definition Classes
- IntrospectionMapping → Mapping
- val validator: MappingValidator
- Definition Classes
- Mapping
- def valueCursor[T](path: Path, env: Env, t: T): Cursor
- Definition Classes
- ValueMappingLike
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- object CursorField extends Serializable
- Definition Classes
- Mapping
- object LeafMapping extends Serializable
- Definition Classes
- Mapping
- object ObjectMapping extends Serializable
- Definition Classes
- Mapping
- object RootEffect extends Serializable
- Definition Classes
- Mapping
- object RootStream extends Serializable
- Definition Classes
- Mapping
- object ValueField extends Serializable
- Definition Classes
- ValueMappingLike
- object ValueFieldMapping extends Serializable
- Definition Classes
- ValueMappingLike