sttp.attributes

package sttp.attributes

Members list

Type members

Classlikes

class AttributeKey[T](val typeName: String)

A key to be used in an AttributeMap. The key typically stores the full type name of the value of the attribute. Keys can be conveniently created using the AttributeKey[T] macro in the companion object.

A key to be used in an AttributeMap. The key typically stores the full type name of the value of the attribute. Keys can be conveniently created using the AttributeKey[T] macro in the companion object.

Type parameters

T

Type of the value of the attribute.

Value parameters

typeName

The fully qualified name of T.

Attributes

Companion
object
Supertypes
class Object
trait Matchable
class Any

Attributes

Companion
class
Supertypes
class Object
trait Matchable
class Any
Self type

Attributes

Supertypes
class Object
trait Matchable
class Any
Known subtypes
object AttributeKey
case class AttributeMap(storage: Map[String, Any])

A type-safe map from AttributeKey to values of types determined by the key.

A type-safe map from AttributeKey to values of types determined by the key.

An attribute is arbitrary data that is attached to some top-level sttp-defined objects. The data is not interpreted by the libraries in any way, and is passed as-is. However, built-in or user-provided extensions and integrations might use the attributes to provide their functionality.

Typically, you'll add attributes using an .attribute method on the sttp-defined object. Each attribute should correspond to a type. The type should be defined by the extension, which uses the attribute, and make it available for import.

Attributes

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

Attributes

Companion
class
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type