MessageFlowTransformer

play.api.mvc.WebSocket.MessageFlowTransformer
See theMessageFlowTransformer companion object
trait MessageFlowTransformer[+In, -Out]

Transforms WebSocket message flows into message flows of another type.

The transformation may be more than just converting from one message to another, it may also produce messages, such as close messages with an appropriate error code if the message can't be consumed.

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Abstract methods

def transform(flow: Flow[In, Out, _]): Flow[Message, Message, _]

Transform the flow of In/Out messages into a flow of WebSocket messages.

Transform the flow of In/Out messages into a flow of WebSocket messages.

Attributes

Concrete methods

def contramap[NewOut](f: NewOut => Out): MessageFlowTransformer[In, NewOut]

Contramap the out type of this transformer.

Contramap the out type of this transformer.

Attributes

def map[NewIn](f: In => NewIn): MessageFlowTransformer[NewIn, Out]

Map the in type of this transformer.

Map the in type of this transformer.

Attributes

def map[NewIn, NewOut](f: In => NewIn, g: NewOut => Out): MessageFlowTransformer[NewIn, NewOut]

Map the in type and contramap the out type of this transformer.

Map the in type and contramap the out type of this transformer.

Attributes