Skip to content

api.service.RouteDefinitionNormalizer

This service implements static methods suitable for normalizing route definitions found in runtime configuration for declaring plugin-specific routes, blueprint routes and custom routes in context of the application. It is heavily used while bootstrapping a Hitchy-based application and has no apparent value at runtime.

Static methods

Application()

This method is invoked with the raw definition of policy routes or controller routes found in the application's configuration. It is expected to return a set of route definitions suitable in context of the application. It may throw an exception on encountering unrecoverable issues with provided definition of routes.

INFO

This method has been named Custom() in versions before v1.4.0. In that version, the more useful name Application() has been introduced with the old name being still supported, but marked as deprecated.

Blueprint()

This method is invoked with the raw definition of blueprint routes found in a plugin's configuration. It is expected to return a list of route definitions. It may throw an exception on encountering unrecoverable issues with provided definition of routes.

Plugin()

This method is invoked with the raw definition of policy routes or controller routes found in a plugin's configuration. It is expected to return a set of route definitions suitable in context of a plugin. It may throw an exception on encountering unrecoverable issues with provided definition of routes.