all files / core/decorators/ timeout-decorator.js

100% Statements 8/8
100% Branches 2/2
100% Functions 2/2
100% Lines 8/8
1 2 3 4 5 6 7 8 9 10 11 12 13         
"use strict";
require("reflect-metadata");
var _metadata_keys_1 = require("./_metadata-keys");
function Timeout(timeoutInMs) {
    if (timeoutInMs <= 0) {
        throw new RangeError("Timeout period must be greater than 0.");
    }
    return function (target, propertyKey, descriptor) {
        Reflect.defineMetadata(_metadata_keys_1.TIMEOUT, timeoutInMs, target, propertyKey);
    };
}
exports.Timeout = Timeout;
//# sourceMappingURL=timeout-decorator.js.map