object Schema extends LowPrioritySchema with SchemaCompanionMacros with Serializable

Linear Supertypes
Serializable, Serializable, SchemaCompanionMacros, SchemaMagnoliaDerivation, LowPrioritySchema, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Schema
  2. Serializable
  3. Serializable
  4. SchemaCompanionMacros
  5. SchemaMagnoliaDerivation
  6. LowPrioritySchema
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. case class Explode(explode: Boolean) extends Product with Serializable

    Corresponds to OpenAPI's explode parameter which should be used for delimited values.

  2. case class SName(fullName: String, typeParameterShortNames: List[String] = Nil) extends Product with Serializable
  3. case class Title(value: String) extends Product with Serializable

    Corresponds to JsonSchema's title parameter which should be used for defining title of the object.

  4. type Typeclass[T] = Schema[T]
    Definition Classes
    SchemaMagnoliaDerivation

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. val ModifyCollectionElements: String
  5. def any[T]: Schema[T]

    A schema allowing anything: a number, string, object, etc.

    A schema allowing anything: a number, string, object, etc. A SCoproduct with no specified subtypes.

    See also

    anyObject

  6. def anyObject[T]: Schema[T]

    A schema allowing any object.

    A schema allowing any object. A SProduct with no specified fields.

    See also

    any

  7. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  8. def binary[T]: Schema[T]

    Creates a schema for type T, where the low-level representation is binary.

  9. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  10. macro def derived[T]: Schema[T]
    Definition Classes
    SchemaCompanionMacros
  11. macro def derivedEnumeration[T]: CreateDerivedEnumerationSchema[T]

    Creates a schema for an enumeration, where the validator is derived using sttp.tapir.Validator.derivedEnumeration.

    Creates a schema for an enumeration, where the validator is derived using sttp.tapir.Validator.derivedEnumeration. This requires that all subtypes of the sealed hierarchy T must be objects.

    This method cannot be implicit, as there's no way to constraint the type T to be a sealed trait / class enumeration, so that this would be invoked only when necessary.

    Definition Classes
    SchemaCompanionMacros
  12. implicit macro def derivedEnumerationValue[T <: Value]: Schema[T]

    Create a schema for an Enumeration, where the validator is created using the enumeration's values.

    Create a schema for an Enumeration, where the validator is created using the enumeration's values. The low-level representation of the enum is a String, and the enum values in the documentation will be encoded using .toString.

    Definition Classes
    SchemaCompanionMacros
  13. macro def derivedEnumerationValueCustomise[T <: Value]: CreateDerivedEnumerationSchema[T]

    Creates a schema for an Enumeration, where the validator is created using the enumeration's values.

    Creates a schema for an Enumeration, where the validator is created using the enumeration's values. Unlike the default derivedEnumerationValue method, which provides the schema implicitly, this variant allows customising how the schema is created. This is useful if the low-level representation of the schema is different than a String, or if the enumeration's values should be encoded in a different way than using .toString.

    Because of technical limitations of macros, the customisation arguments can't be given here directly, instead being delegated to CreateDerivedEnumerationSchema.

    Definition Classes
    SchemaCompanionMacros
  14. implicit def derivedSchema[T](implicit derived: Derived[Schema[T]]): Schema[T]
    Definition Classes
    LowPrioritySchema
  15. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  17. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  18. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  19. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  20. def join[T](ctx: ReadOnlyCaseClass[Schema, T])(implicit genericDerivationConfig: Configuration): Schema[T]
    Definition Classes
    SchemaMagnoliaDerivation
  21. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  22. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  23. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  24. macro def oneOfUsingField[E, V](extractor: (E) ⇒ V, asString: (V) ⇒ String)(mapping: (V, Schema[_])*)(implicit conf: Configuration, discriminatorSchema: Schema[V]): Schema[E]

    Create a coproduct schema (e.g.

    Create a coproduct schema (e.g. for a sealed trait), where the value of the discriminator between child types is a read of a field of the base type. The field, if not yet present, is added to each child schema.

    The schemas of the child types have to be provided explicitly with their value mappings in mapping.

    Note that if the discriminator value is some transformation of the child's type name (obtained using the implicit Configuration), the coproduct schema can be derived automatically or semi-automatically.

    discriminatorSchema

    The schema that is used when adding the discriminator as a field to child schemas (if it's not yet in the schema).

    Definition Classes
    SchemaCompanionMacros
  25. macro def oneOfWrapped[E](implicit conf: Configuration): Schema[E]

    Create a coproduct schema for a sealed trait or sealed abstract class, where to discriminate between child types a wrapper product is used.

    Create a coproduct schema for a sealed trait or sealed abstract class, where to discriminate between child types a wrapper product is used. The name of the sole field in this product corresponds to the type's name, transformed using the implicit Configuration.

    Definition Classes
    SchemaCompanionMacros
  26. implicit def schemaForArray[T](implicit arg0: Schema[T]): Schema[Array[T]]
  27. implicit val schemaForBigDecimal: Schema[BigDecimal]
  28. implicit val schemaForBigInt: Schema[BigInt]
  29. implicit val schemaForBoolean: Schema[Boolean]
  30. implicit val schemaForByte: Schema[Byte]
  31. implicit val schemaForByteArray: Schema[Array[Byte]]
  32. implicit val schemaForByteBuffer: Schema[ByteBuffer]
  33. implicit val schemaForDate: Schema[Date]
  34. implicit def schemaForDelimited[D <: String, T](implicit tSchema: Schema[T]): Schema[Delimited[D, T]]
  35. implicit val schemaForDouble: Schema[Double]
  36. implicit def schemaForEither[A, B](implicit sa: Schema[A], sb: Schema[B]): Schema[Either[A, B]]
  37. implicit val schemaForFile: Schema[tapir.TapirFile]
  38. implicit val schemaForFileRange: Schema[FileRange]
  39. implicit val schemaForFloat: Schema[Float]
  40. implicit val schemaForInputStream: Schema[InputStream]
  41. implicit val schemaForInputStreamRange: Schema[InputStreamRange]
  42. implicit val schemaForInstant: Schema[Instant]
  43. implicit val schemaForInt: Schema[Int]
  44. implicit def schemaForIterable[T, C[X] <: Iterable[X]](implicit arg0: Schema[T]): Schema[C[T]]
  45. implicit val schemaForJBigDecimal: Schema[BigDecimal]
  46. implicit val schemaForJBigInteger: Schema[BigInteger]
  47. implicit val schemaForJavaDuration: Schema[Duration]
  48. implicit val schemaForLocalDate: Schema[LocalDate]
  49. implicit val schemaForLocalDateTime: Schema[LocalDateTime]
  50. implicit val schemaForLocalTime: Schema[LocalTime]
  51. implicit val schemaForLong: Schema[Long]
  52. macro def schemaForMap[K, V](keyToString: (K) ⇒ String)(implicit arg0: Schema[V]): Schema[Map[K, V]]

    Create a schema for a map with arbitrary keys.

    Create a schema for a map with arbitrary keys. The schema for the keys K should be a string, however this cannot be verified at compile-time and is not verified at run-time.

    The given keyToString conversion function is used during validation.

    If you'd like this schema to be available as an implicit for a given type of keys, create an custom implicit, e.g.:

    case class MyKey(value: String) extends AnyVal
    implicit val schemaForMyMap = Schema.schemaForMap[MyKey, MyValue](_.value)
    Definition Classes
    SchemaCompanionMacros
  53. implicit macro def schemaForMap[V](implicit arg0: Schema[V]): Schema[Map[String, V]]
    Definition Classes
    SchemaCompanionMacros
  54. implicit val schemaForOffsetDateTime: Schema[OffsetDateTime]
  55. implicit val schemaForOffsetTime: Schema[OffsetTime]
  56. implicit def schemaForOption[T](implicit arg0: Schema[T]): Schema[Option[T]]
  57. implicit def schemaForPart[T](implicit arg0: Schema[T]): Schema[Part[T]]
  58. implicit val schemaForScalaDuration: Schema[Duration]
  59. implicit val schemaForShort: Schema[Short]
  60. implicit val schemaForString: Schema[String]
  61. implicit val schemaForUUID: Schema[UUID]
  62. implicit val schemaForUnit: Schema[Unit]
  63. implicit val schemaForZoneId: Schema[ZoneId]
  64. implicit val schemaForZoneOffset: Schema[ZoneOffset]
  65. implicit val schemaForZonedDateTime: Schema[ZonedDateTime]
  66. def split[T](ctx: SealedTrait[Schema, T])(implicit genericDerivationConfig: Configuration): Schema[T]
    Definition Classes
    SchemaMagnoliaDerivation
  67. def string[T]: Schema[T]

    Creates a schema for type T, where the low-level representation is a String.

  68. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  69. def toString(): String
    Definition Classes
    AnyRef → Any
  70. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  71. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  72. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  73. def wrapWithSingleFieldProduct[T](schema: Schema[T])(implicit conf: Configuration): Schema[T]

    Wraps the given schema with a single-field product, where a field computed using the implicit Configuration maps to schema.

    Wraps the given schema with a single-field product, where a field computed using the implicit Configuration maps to schema.

    The resulting schema has no name.

    Useful when generating one-of schemas for coproducts, where to discriminate between child types a wrapper product is used. To automatically derive such a schema for a sealed hierarchy, see Schema.oneOfWrapped.

  74. def wrapWithSingleFieldProduct[T](schema: Schema[T], fieldName: FieldName): Schema[T]

    Wraps the given schema with a single-field product, where fieldName maps to schema.

    Wraps the given schema with a single-field product, where fieldName maps to schema.

    The resulting schema has no name.

    Useful when generating one-of schemas for coproducts, where to discriminate between child types a wrapper product is used. To automatically derive such a schema for a sealed hierarchy, see Schema.oneOfWrapped.

  75. object Explode extends Serializable
  76. object SName extends Serializable
  77. object Title extends Serializable
  78. object annotations

    Annotations which are used during automatic schema derivation, or semi-automatic schema derivation using Schema.derived.

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated
    Deprecated

Inherited from Serializable

Inherited from Serializable

Inherited from SchemaCompanionMacros

Inherited from SchemaMagnoliaDerivation

Inherited from LowPrioritySchema

Inherited from AnyRef

Inherited from Any

Ungrouped