Class/Object

com.rayrobdod.json.builder

BuildableBuilder

Related Docs: object BuildableBuilder | package builder

Permalink

final case class BuildableBuilder[Key, Value, Subject](init: Subject, defaultKeyDef: KeyDef[Key, Value, Subject] = ..., keyDefs: Map[Key, KeyDef[Key, Value, Subject]] = ...) extends Builder[Key, Value, Subject] with Product with Serializable

A Builder which can be built piecewise.

TODO: mention how

Key

the key types

Value

the primitive value types

Subject

the type of object to build

init

The starting point of the folding process

defaultKeyDef

the KeyDef executed when no other keys exist

keyDefs

the mapping of known keys to actual applies

Source
BuildableBuilder.scala
Since

next

See also

Inspired by https://github.com/scopt/scopt/

Linear Supertypes
Serializable, Serializable, Product, Equals, Builder[Key, Value, Subject], AnyRef, Any
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. BuildableBuilder
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. Builder
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BuildableBuilder(init: Subject, defaultKeyDef: KeyDef[Key, Value, Subject] = ..., keyDefs: Map[Key, KeyDef[Key, Value, Subject]] = ...)

    Permalink

    init

    The starting point of the folding process

    defaultKeyDef

    the KeyDef executed when no other keys exist

    keyDefs

    the mapping of known keys to actual applies

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. def addDef(key: Key, fun: KeyDef[Key, Value, Subject]): BuildableBuilder[Key, Value, Subject]

    Permalink

    add a buildableBuilder that will be used upon recieving the given key

  5. def apply[Input](folding: Subject, key: Key, input: Input, parser: Parser[Key, Value, Input]): Either[(String, Int), Subject]

    Permalink

    folding

    the object to be added to. Must be either the return value of init or the return value of apply

    key

    the key of a key-value pair

    input

    the input to a parser

    parser

    a parser for turning input into a value

    returns

    # A scala.util.Right containing the built value, or # A scala.util.Left indicating an error message and error index

    Definition Classes
    BuildableBuilderBuilder
    See also

    Builder#apply

  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. val defaultKeyDef: KeyDef[Key, Value, Subject]

    Permalink

    the KeyDef executed when no other keys exist

  9. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  10. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  12. def ignoreUnknownKeys: BuildableBuilder[Key, Value, Subject]

    Permalink

    Change the defaultKeyDef to one that will pass subject through

  13. val init: Subject

    Permalink

    The starting point of the folding process

    The starting point of the folding process

    Definition Classes
    BuildableBuilderBuilder
  14. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  15. val keyDefs: Map[Key, KeyDef[Key, Value, Subject]]

    Permalink

    the mapping of known keys to actual applies

  16. final def mapKey[K2](implicit fun: (K2) ⇒ Key): Builder[K2, Value, Subject]

    Permalink

    Change the type of key that this builder requires

    Change the type of key that this builder requires

    Definition Classes
    Builder
    Version

    next

  17. final def mapValue[V2](implicit fun: (V2) ⇒ Value): Builder[Key, V2, Subject]

    Permalink

    Change the type of value that this builder requires

    Change the type of value that this builder requires

    Definition Classes
    Builder
    Version

    next

  18. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  19. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  20. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  21. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  22. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from Builder[Key, Value, Subject]

Inherited from AnyRef

Inherited from Any

Ungrouped