Class: notCRUDRouterSwitch

notCRUDRouterSwitch

Runs controller action by name that gets from URI params

new notCRUDRouterSwitch()

Members


<static> routesVariants

Variants of this action

Methods


<async, static> determineRoute(controller, params)

This function returns which of routes variant should be executed
Parameters:
Name Type Description
controller object instance of notController descendant
params Array.<string> params passed to router
Returns:
name of route variant
Type
Promise.<string>

<static> isRouteVariantValid(name)

Returns true if variant name is valid
Parameters:
Name Type Description
name string name of route variant
Returns:
Type
boolean

<async, static> route(controller, params)

Runs controller action or throws
Parameters:
Name Type Description
controller object instance of notController descendant
params Array.<string>