inversify-hapi-decorators
Advanced tools
Comparing version 0.0.5 to 0.0.6
import { interfaces } from "./interfaces"; | ||
import { RouteAdditionalConfigurationOptions } from "hapi"; | ||
export declare function Controller(path: string, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): (target: any) => void; | ||
export declare function Get(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Post(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Put(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Patch(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Head(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Delete(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Options(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Method(method: string, options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Controller(path: string, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): (target: any) => void; | ||
export declare function Get(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Post(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Put(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Patch(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Head(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Delete(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Options(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; | ||
export declare function Method(method: string, options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator; |
@@ -8,3 +8,3 @@ import * as hapi from "hapi"; | ||
path: string; | ||
config: RouteAdditionalConfigurationOptions; | ||
config?: RouteAdditionalConfigurationOptions; | ||
middleware: Middleware[]; | ||
@@ -25,3 +25,3 @@ target: any; | ||
method: string; | ||
config: RouteAdditionalConfigurationOptions; | ||
config?: RouteAdditionalConfigurationOptions; | ||
key: string; | ||
@@ -28,0 +28,0 @@ } |
{ | ||
"name": "inversify-hapi-decorators", | ||
"version": "0.0.5", | ||
"version": "0.0.6", | ||
"description": "Some utilities for the development of hapijs rest applications with Inversify", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -5,3 +5,3 @@ import { interfaces } from "./interfaces"; | ||
export function Controller(path: string, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]) { | ||
export function Controller(path: string, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]) { | ||
return function (target: any) { | ||
@@ -13,27 +13,27 @@ let metadata: interfaces.ControllerMetadata = {path, config, middleware, target}; | ||
export function Get(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Get(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("get", options, config, ...middleware); | ||
} | ||
export function Post(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Post(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("post", options, config, ...middleware); | ||
} | ||
export function Put(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Put(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("put", options, config, ...middleware); | ||
} | ||
export function Patch(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Patch(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("patch", options, config, ...middleware); | ||
} | ||
export function Head(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Head(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("head", options, config, ...middleware); | ||
} | ||
export function Delete(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Delete(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("delete", options, config, ...middleware); | ||
} | ||
export function Options(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
export function Options(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator { | ||
return Method("opts", options, config, ...middleware); | ||
@@ -45,3 +45,3 @@ } | ||
options: interfaces.RouteOptions, | ||
config: RouteAdditionalConfigurationOptions, | ||
config?: RouteAdditionalConfigurationOptions, | ||
...middleware: interfaces.Middleware[] | ||
@@ -48,0 +48,0 @@ ): interfaces.HandlerDecorator { |
@@ -11,3 +11,3 @@ import * as hapi from "hapi"; | ||
path: string; | ||
config: RouteAdditionalConfigurationOptions; | ||
config?: RouteAdditionalConfigurationOptions; | ||
middleware: Middleware[]; | ||
@@ -25,3 +25,3 @@ target: any; | ||
method: string; | ||
config: RouteAdditionalConfigurationOptions | ||
config?: RouteAdditionalConfigurationOptions | ||
key: string; | ||
@@ -28,0 +28,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
240761