UNPKG

inversify-express-utils

Version:

Some utilities for the development of express applications with Inversify

20 lines 668 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.JsonResult = void 0; const jsonContent_1 = require("../content/jsonContent"); const httpResponseMessage_1 = require("../httpResponseMessage"); class JsonResult { json; statusCode; constructor(json, statusCode) { this.json = json; this.statusCode = statusCode; } async executeAsync() { const response = new httpResponseMessage_1.HttpResponseMessage(this.statusCode); response.content = new jsonContent_1.JsonContent(this.json); return response; } } exports.JsonResult = JsonResult; //# sourceMappingURL=JsonResult.js.map