PackageNameGenerator

interface PackageNameGenerator

A PackageNameGenerator computes the package name for a given file. Files can be either

  • executable files containing operations and fragments

  • schema files containing type definitions or introspection json

Types

Link copied to clipboard
class FilePathAware(roots: Roots, rootPackageName: String = "") : PackageNameGenerator
Link copied to clipboard
class Flat(val packageName: String) : PackageNameGenerator

Functions

Link copied to clipboard
abstract fun packageName(filePath: String): String

This will be called with

Properties

Link copied to clipboard
abstract val version: String

A version that is used as input of the Gradle task. Since PackageNameGenerator cannot easily be serialized and influences the output of the task, we need a way to mark the task out-of-date when the implementation changes.

Inheritors

Link copied to clipboard
Link copied to clipboard