1 |
|
2 |
|
3 | import { __extends } from "tslib";
|
4 | import { ApiKeyCredentials } from "./apiKeyCredentials";
|
5 | var TopicCredentials = (function (_super) {
|
6 | __extends(TopicCredentials, _super);
|
7 | |
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 | function TopicCredentials(topicKey) {
|
14 | var _this = this;
|
15 | if (!topicKey || (topicKey && typeof topicKey !== "string")) {
|
16 | throw new Error("topicKey cannot be null or undefined and must be of type string.");
|
17 | }
|
18 | var options = {
|
19 | inHeader: {
|
20 | "aeg-sas-key": topicKey,
|
21 | },
|
22 | };
|
23 | _this = _super.call(this, options) || this;
|
24 | return _this;
|
25 | }
|
26 | return TopicCredentials;
|
27 | }(ApiKeyCredentials));
|
28 | export { TopicCredentials };
|
29 |
|
\ | No newline at end of file |