Adapting return type
This commit is contained in:
parent
07ec7d5f0d
commit
e67bc6de4c
@ -38,6 +38,10 @@ export interface IExportPropertyToOpenAPIParameters {
|
||||
readonly?: boolean
|
||||
}
|
||||
|
||||
export interface IExportFunctionToOpenAPIParameters {
|
||||
uri?: string
|
||||
}
|
||||
|
||||
/**
|
||||
* Decorator used to export a Class API over openAPI
|
||||
* @param options
|
||||
@ -102,21 +106,11 @@ export function exportPropertyToOpenAPI(options: IExportPropertyToOpenAPIParamet
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Defintion of a Functon.
|
||||
*/
|
||||
export type callable<T> = {
|
||||
(...args): T
|
||||
}
|
||||
|
||||
/**
|
||||
* Decorator, that will export the Function to a Dispatcher
|
||||
* @param func The Function
|
||||
* @param options The Options.
|
||||
*/
|
||||
export function exportFunctionToOpenAPI<T>(func: callable<T>, options: IExportPropertyToOpenAPIParameters) {
|
||||
|
||||
|
||||
|
||||
export function exportFunctionToOpenAPI<T>(func: T, options: IExportFunctionToOpenAPIParameters) {
|
||||
return func;
|
||||
}
|
Loading…
Reference in New Issue
Block a user