Structures

The following structures are available globally.

  • Manages an application’s Environment such as .production, .development, and .testing. Enables to create a custom Environment and provides access to Environment variables.

    See more

    Declaration

    Swift

    public struct Environment
    extension Environment: Equatable
  • Resolves a Route for a Request and calls its handler method. Returns a .notFound Response if it can’t match any Routes. By default, the RoutingMiddleware is already registered for Chaqmoq applications. If you override the middleware property, make sure you add it explicitly. Keep in mind that it is almost always better to register the RoutingMiddleware at the end of Middleware stack.

    See more

    Declaration

    Swift

    public struct RoutingMiddleware : Middleware