Router

korolev.Router
See theRouter companion object
final case class Router[F[_], S](fromState: PartialFunction[S, PathAndQuery], toState: PartialFunction[PathAndQuery, S => F[S]])

URL routing definition

Type parameters

F

A async control

S

Type of State

Value parameters

fromState

From current state to Uri

toState

From Uri to state

Attributes

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

Members list

Value members

Concrete methods

def ++(that: Router[F, S]): Router[F, S]

Compose two routers to one.

Compose two routers to one.

val articlesRouter = Router(...)
val authorsRouter = Router(...)
val router = articlesRouter ++ authorsRouter

Attributes

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product