SimpleRetrieval

uk.gov.hmrc.auth.core.retrieve.SimpleRetrieval
case class SimpleRetrieval[A](propertyName: String, valueReads: Reads[A]) extends Retrieval[A]

A Retrieval that will return only a single property on successful authorisation

Value parameters

propertyName

The name of the property to return from auth on success. Must be a supported property in auth.

valueReads

The JSON Reads to apply to the returned JSON property

Attributes

Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Retrieval[A]
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

def and[B](other: Retrieval[B]): Retrieval[A ~ B]

Allows simpler and more concise code for the lib user at the call site when authorising

Allows simpler and more concise code for the lib user at the call site when authorising

Value parameters

other

The Retrieval to be joined with this Retrieval

Attributes

Returns

A Retrieval[A ~ B] that contains this Retrieval and the one passed in

Inherited from:
Retrieval
def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product

Concrete fields

val propertyNames: Seq[String]

The properties to return from a successful authorise call. These have to be explicitly supported by the auth service being called

The properties to return from a successful authorise call. These have to be explicitly supported by the auth service being called

Attributes

Returns

A list of property names to return.

val reads: Reads[A]

The Reads that will be used upon the returned JSON

The Reads that will be used upon the returned JSON

Attributes

Returns

JSON Reads