1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.GqlArgumentsHost = void 0;
|
4 | const execution_context_host_1 = require("@nestjs/core/helpers/execution-context-host");
|
5 | class GqlArgumentsHost extends execution_context_host_1.ExecutionContextHost {
|
6 | static create(context) {
|
7 | const type = context.getType();
|
8 | const gqlContext = new GqlArgumentsHost(context.getArgs());
|
9 | gqlContext.setType(type);
|
10 | return gqlContext;
|
11 | }
|
12 | getRoot() {
|
13 | return this.getArgByIndex(0);
|
14 | }
|
15 | getArgs() {
|
16 | return this.getArgByIndex(1);
|
17 | }
|
18 | getContext() {
|
19 | return this.getArgByIndex(2);
|
20 | }
|
21 | getInfo() {
|
22 | return this.getArgByIndex(3);
|
23 | }
|
24 | }
|
25 | exports.GqlArgumentsHost = GqlArgumentsHost;
|