Schema
Data types and smart constructors which simplify the creation of schema values.
Attributes
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
Schema.type
Members list
Type members
Classlikes
Builder class used to construct a Absent property
Builder class used to construct a Absent property
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
Builder class used to construct a Constant property
Builder class used to construct a Constant property
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
Types
The type of free applicative values which are used to capture the structure of individual record properties.
The type of free applicative values which are used to capture the structure of individual record properties.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- O
-
The type of a Scala record - an object or a tuple, the property of which is being defined.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Attributes
The type of free applicative values which are used to capture the structure of record (product) types.
The type of free applicative values which are used to capture the structure of record (product) types.
Type parameters
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
- R
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. This is usually the type of a record - an object or a tuple.
Attributes
The type of an unannotated schema.
The type of an unannotated schema.
This is an alias for the HFix fixpoint applied to the SchemaF type constructor.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Attributes
Value members
Concrete methods
Smart constructor for absent Prop instances.
Smart constructor for absent Prop instances.
Type parameters
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Attributes
Convenience constructor for oneOf schema alternatives.
Convenience constructor for oneOf schema alternatives.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- J
-
The type of the base value which can be mapped into the
I
algebra. - P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- base
-
The schema for the
J
type - id
-
The unique identifier of the constructor
- subset
-
Prism between the sum type and the selected constructor.
Attributes
The unannotated empty record schema, representing a constant value.
The unannotated empty record schema, representing a constant value.
Type parameters
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Attributes
Smart constructor for constant Prop instances.
Smart constructor for constant Prop instances.
Type parameters
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Attributes
HAlgebra for primitive type constructor transformation.
HAlgebra for primitive type constructor transformation.
Attributes
Smart constructor for optional Prop instances.
Smart constructor for optional Prop instances.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- O
-
The type of a Scala record - an object or a tuple, the property of which is being defined.
- OI
-
hack for proper overload resolution
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- extract
-
Extract lens from the record type to the property's value
- fieldName
-
name of the record property
- valueSchema
-
schema for the record property's type
Attributes
Smart constructor for optional Prop instances.
Smart constructor for optional Prop instances.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- O
-
The type of a Scala record - an object or a tuple, the property of which is being defined.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- fieldName
-
name of the record property
- property
-
Property lens from the record type to the property's value
- valueSchema
-
schema for the record property's type
Attributes
Lifts a value in an algebra of primitives into an unannotated Schema
Lifts a value in an algebra of primitives into an unannotated Schema
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- p
-
a value of the
P
algebra
Attributes
- Returns
-
the newly constructed schema value
Smart constructor for required Prop instances, with a default provided for the case where a serialized form is missing the required field.
Smart constructor for required Prop instances, with a default provided for the case where a serialized form is missing the required field.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- O
-
The type of a Scala record - an object or a tuple, the property of which is being defined.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- default
-
Default value for use in the case that a serialized form is missing the required field.
- extract
-
Extract lens from the record type to the property's value
- fieldName
-
Name of the record property
- valueSchema
-
Schema for the record property's type
Attributes
Builds an un-annotated schema for a record type from the free applicative capture of that record's structure.
Builds an un-annotated schema for a record type from the free applicative capture of that record's structure.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- props
-
The free-applicative value that captures the structure of the record type.
Attributes
Smart constructor for required Prop instances.
Smart constructor for required Prop instances.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- O
-
The type of a Scala record - an object or a tuple, the property of which is being defined.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- extract
-
Extract lens from the record type to the property's value
- fieldName
-
name of the record property
- valueSchema
-
schema for the record property's type
Attributes
Lifts a SchemaF value into an unannotated Schema
Lifts a SchemaF value into an unannotated Schema
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.
Value parameters
- sf
-
The value to be annotated
Attributes
- Returns
-
the newly constructed schema value
Builds an un-annotated schema for the sum type I
from a list of alternatives.
Builds an un-annotated schema for the sum type I
from a list of alternatives.
Each alternative value in the list describes a single constructor of I
. For example, to construct the schema for scala.util.Either one would provide two alternatives, one for the Left
constructor and one for Right
.
This convenience constructor is unsafe in that the compiler will not prove that handling is present for every constructor of your sum type; however, it may sometimes be needed in the case that failures of the Scala compiler to correctly identify all the constructors of a sum type make it otherwise impossible to build a schema value.
Type parameters
- I
-
The type of the Scala value to be produced (or consumed) by an interpreter of the schema. Also known as the "index" type of the schema.
- P
-
The GADT type constructor for a sum type which defines the set of primitive types used in the schema.