Field

smithy4s.schema.Field
See theField companion object
final case class Field[S, A](label: String, schema: Schema[A], get: S => A)

Represents a member of product type (case class)

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def addHints(newHints: Hint*): Field[S, A]
def contramap[S0](f: S0 => S): Field[S0, A]
def getUnlessDefault(s: S): Option[A]
final def hints: Hints

Returns all hints : the ones defined directly on the field, and the ones defined on the target of the field.

Returns all hints : the ones defined directly on the field, and the ones defined on the target of the field.

Attributes

def isDefaultValue(a: A): Boolean
final def memberHints: Hints

Returns the hints that are only relative to the field (typically derived from member-level traits)

Returns the hints that are only relative to the field (typically derived from member-level traits)

Attributes

Deprecated methods

final def instance: Schema[A]

Attributes

Deprecated
[Since version 0.18.0]

Inherited methods

Attributes

Inherited from:
Product

Attributes

Inherited from:
Product

Concrete fields

lazy val getDefaultValue: Option[A]