Sum

made.Made.Sum
sealed trait Sum extends Made

Mirror for sum types (sealed traits and enums).

Produced by Made.derived when T is a sealed trait or enum.

Elems is a tuple of MadeSubElem and MadeSubSingletonElem representing the subtypes.

Attributes

See also
Graph
Supertypes
trait Made
class Object
trait Matchable
class Any

Members list

Type members

Inherited types

final type ElemLabels = Map[Elems, ExtractLabel]

Tuple of element labels, extracted from Elems via type-level mapping.

Tuple of element labels, extracted from Elems via type-level mapping.

Attributes

Inherited from:
Made
final type ElemTypes = Map[Elems, ExtractOf]

Tuple of element types, extracted from Elems via type-level mapping.

Tuple of element types, extracted from Elems via type-level mapping.

Attributes

Inherited from:
Made

Inherited and Abstract types

type Elems <: Tuple

Tuple of MadeElem subtypes representing constructor fields (for products) or subtypes (for sums).

Tuple of MadeElem subtypes representing constructor fields (for products) or subtypes (for sums).

Attributes

Inherited from:
Made

Tuple of GeneratedMadeElem for members annotated with @generated.

Tuple of GeneratedMadeElem for members annotated with @generated.

Attributes

Inherited from:
Made
type Label <: String

The simple name of T (or the override provided by @name).

The simple name of T (or the override provided by @name).

Attributes

Inherited from:
Made
type Metadata <: Tuple

Annotation metadata on T, represented as a Tuple of Meta @ann entries. When no MetaAnnotation annotations are present, Metadata = EmptyTuple. When annotations are present, Metadata becomes (Meta @Ann1, Meta @Ann2, ...). Query via hasAnnotation and getAnnotation.

Annotation metadata on T, represented as a Tuple of Meta @ann entries. When no MetaAnnotation annotations are present, Metadata = EmptyTuple. When annotations are present, Metadata becomes (Meta @Ann1, Meta @Ann2, ...). Query via hasAnnotation and getAnnotation.

Attributes

Inherited from:
Made
type Type

The mirrored type T.

The mirrored type T.

Attributes

Inherited from:
Made

Value members

Abstract methods

def ordinal(value: Type): Int

Returns the zero-based index of value's runtime subtype within Elems.

Returns the zero-based index of value's runtime subtype within Elems.

Attributes

Inherited and Abstract methods

def elems: Elems

Attributes

Inherited from:
Made

Attributes

Inherited from:
Made

Givens

Givens

A sum's Elems are all MadeSubElems; refines the base containsOnly MadeElem.

A sum's Elems are all MadeSubElems; refines the base containsOnly MadeElem.

Attributes

Inherited givens

ElemLabels is all Strings; path-dependent, so it stays in scope for the ElemLabels alias.

ElemLabels is all Strings; path-dependent, so it stays in scope for the ElemLabels alias.

Attributes

Inherited from:
Made

Path-dependent evidence: the mirror's Elems tuple is guaranteed by the deriver to be a tuple of MadeElems. Available wherever this Made instance is in scope so plural extensions like made.elems.hasAnnotations[A] summon evidence without explicit imports.

Path-dependent evidence: the mirror's Elems tuple is guaranteed by the deriver to be a tuple of MadeElems. Available wherever this Made instance is in scope so plural extensions like made.elems.hasAnnotations[A] summon evidence without explicit imports.

Attributes

Inherited from:
Made

Path-dependent evidence: the mirror's GeneratedElems tuple is a tuple of GeneratedMadeElems. Enables made.generatedElems.hasAnnotations[A] analogous to made.elems.hasAnnotations[A].

Path-dependent evidence: the mirror's GeneratedElems tuple is a tuple of GeneratedMadeElems. Enables made.generatedElems.hasAnnotations[A] analogous to made.elems.hasAnnotations[A].

Attributes

Inherited from:
Made

Path-dependent evidence: the mirror's Metadata tuple is a tuple of Meta (or Meta @ann) entries. Mirrors the guarantee for hasAnnotation[A] / getAnnotation[A].

Path-dependent evidence: the mirror's Metadata tuple is a tuple of Meta (or Meta @ann) entries. Mirrors the guarantee for hasAnnotation[A] / getAnnotation[A].

Attributes

Inherited from:
Made