UNPKG

584 BPlain TextView Raw
1import { obj, str, ObjectNode, ListNode } from 'graphql-mapping-template';
2
3/**
4 * The class that contains the resolver templates for interacting
5 * with the Relational Database data source.
6 */
7export class RelationalDBMappingTemplate {
8 /**
9 * Provided a SQL statement, creates the rds-query item resolver template.
10 *
11 * @param param0 - the SQL statement to use when querying the RDS cluster
12 */
13 public static rdsQuery({ statements }: { statements: ListNode }): ObjectNode {
14 return obj({
15 version: str('2018-05-29'),
16 statements: statements,
17 });
18 }
19}