Skip to main content
Module

x/mandarinets/mod.ts>ResourceHandler

Mandarine.TS is a typescript, decorator-driven framework that allows you to create server-side applications. Mandarine.TS provides a range of built-in solutions such as Dependency Injection, Components, ORM and more. Under its umbrella, Mandarine.TS has 4 modules: Core, Data, Security and MVC, these modules will offer you the requirements to build a Mandarine-powered application.
Latest
class ResourceHandler
implements [[Mandarine.MandarineCore].IResourceHandler]
import { ResourceHandler } from "https://deno.land/x/mandarinets@v2.3.2/mod.ts";

This class works as a container for resource handlers. This class contains the paths where the resolver will be invoked. This class contains the locations where the resolver should look up for resources. This class contains the indexes of the paths. This class contains the resolver to be used when intercepting.

Properties

resourceCors: Mandarine.MandarineMVC.CorsMiddlewareOption | undefined
resourceHandlerIndex: Array<string> | undefined
resourceHandlerLocations: Array<string> | undefined
resourceHandlerPath: Array<RegExp> | undefined
resourceResolver: Mandarine.MandarineMVC.HTTPResolvers.ResourceResolver | undefined

Methods

addResourceCors(cors: Mandarine.MandarineMVC.CorsMiddlewareOption): ResourceHandler
addResourceHandler(...resourceHandlerPath: Array<RegExp>): ResourceHandler
addResourceHandlerIndex(...resourceHandlerIndex: Array<string>): ResourceHandler
addResourceHandlerLocation(...resourceHandlerLocations: Array<string>): ResourceHandler
addResourceResolver(resolver: Mandarine.MandarineMVC.HTTPResolvers.ResourceResolver): ResourceHandler