EnumOps

endpoints4s.algebra.JsonSchemas.EnumOps
final implicit class EnumOps[A](enumA: Enum[A]) extends JsonSchemaDocumentationOps[A]

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Type members

Types

type Self = Enum[A]

Value members

Concrete methods

def named(name: String): Enum[A]

Give a name to the schema

Give a name to the schema

  • Encoder and decoder interpreters ignore the name,
  • Documentation interpreters use that name to refer to this schema.

Attributes

Note

Names are used by documentation interpreters to construct references and the JSON schema specification requires these to be valid URI's. Consider using withTitle if you just want to override the heading displayed in documentation.

def withDescription(description: String): Enum[A]

Include a description of what this schema represents

Include a description of what this schema represents

  • Encoder and decoder interpreters ignore this description,
  • Documentation interpreters can show this description.

Value parameters

description

information about the values described by the schema

Attributes

def withExample(example: A): Enum[A]

Include an example of value in this schema

Include an example of value in this schema

  • Encoder and decoder interpreters ignore this value,
  • Documentation interpreters can show this example value.

Value parameters

example

Example value to attach to the schema

Attributes

def withTitle(title: String): Enum[A]

Include a title for the schema

Include a title for the schema

  • Encoder and decoder interpreters ignore the title,
  • Documentation interpreters can show this title.

Value parameters

title

short title to attach to the schema

Attributes