FragmentUse

data class FragmentUse(val attachedFragment: Fragment, val parent: QueryElement?) : QueryElement

Represents a reference to a fragment in a field

See also

Constructors

Link copied to clipboard
constructor(attachedFragment: Fragment, parent: QueryElement?)

Properties

Link copied to clipboard

Name of the fragment to use

Link copied to clipboard
open override val parent: QueryElement?

Functions

Link copied to clipboard
fun field(name: String, init: Field.() -> Unit = {}): Field

Creates and register a Field as a child of the current QueryElement

Link copied to clipboard
open override fun toString(): String

Generates the GraphQL string for the fragment usage

Link copied to clipboard
fun typename()

Gets the name of the current type of the current QueryElement. Equivalent to __typename.