TypeSafeSDK.Question.Score (TypeSafeSDK v0.4.1)

Copy Markdown View Source

Strict Score on 2..10 ordered levels.

A level is a description or {label, description}. The pair is sent as a structured object and its label is restored on the semantic answer. Unknown JSON properties may be supplied through :extra without overriding core fields.

Summary

Types

t()

@type t() :: %TypeSafeSDK.Question.Score{
  extra: map(),
  instructions: term(),
  levels: list()
}

Functions

new(instructions, levels, opts \\ [])

@spec new(term(), list(), keyword()) :: {:ok, t()} | {:error, TypeSafeSDK.Error.t()}

new!(instructions, levels, opts \\ [])

@spec new!(term(), list(), keyword()) :: t()