typenexus
Version:
TypeNexus is a good tool for API encapsulation and management. It provides a clean and lightweight way to package TypeORM functionality, helping you build applications faster while reducing template code redundancy and type conversion work.
39 lines (38 loc) • 1.12 kB
JavaScript
/**
* Response handler metadata.
*/
export class ResponseHandlerMetadata {
// -------------------------------------------------------------------------
// Properties
// -------------------------------------------------------------------------
/**
* Class on which's method decorator is set.
*/
target;
/**
* Method on which decorator is set.
*/
method;
/**
* Property type. See ResponsePropertyMetadataType for possible values.
*/
type;
/**
* Property value. Can be status code, content-type, header name, template name, etc.
*/
value;
/**
* Secondary property value. Can be header value for example.
*/
secondaryValue;
// -------------------------------------------------------------------------
// Constructor
// -------------------------------------------------------------------------
constructor(args) {
this.target = args.target;
this.method = args.method;
this.type = args.type;
this.value = args.value;
this.secondaryValue = args.secondaryValue;
}
}