diff --git a/.github/workflows/run-tests.yaml b/.github/workflows/run-tests.yaml index 78206e99..40149717 100644 --- a/.github/workflows/run-tests.yaml +++ b/.github/workflows/run-tests.yaml @@ -19,11 +19,11 @@ jobs: - name: deparser run: cd ./packages/deparser && yarn test - - name: enums - run: cd ./packages/enums && yarn test + - name: proto-parser + run: cd ./packages/proto-parser && yarn test - - name: types - run: cd ./packages/types && yarn test + - name: utils + run: cd ./packages/utils && yarn test - name: transform run: cd ./packages/transform && yarn test \ No newline at end of file diff --git a/__fixtures__/generated/generated.json b/__fixtures__/generated/generated.json index e83c1757..ad83d004 100644 --- a/__fixtures__/generated/generated.json +++ b/__fixtures__/generated/generated.json @@ -21148,6 +21148,8 @@ "misc/cascades-23.sql": "DROP TRANSFORM IF EXISTS FOR some_type LANGUAGE plpgsql CASCADE", "misc/cascades-24.sql": "ALTER TABLE some_table DROP COLUMN some_column CASCADE", "misc/cascades-25.sql": "ALTER TABLE some_table DROP CONSTRAINT some_constraint CASCADE", + "misc/booleans-cast-1.sql": "SELECT * FROM myschema.mytable WHERE a = TRUE", + "misc/booleans-cast-2.sql": "SELECT * FROM myschema.mytable WHERE a = CAST('t' AS boolean)", "latest/postgres/create_view-1.sql": "CREATE FUNCTION interpt_pp(path, path)\n RETURNS point\n AS 'regresslib'\n LANGUAGE C STRICT", "latest/postgres/create_view-2.sql": "CREATE TABLE real_city (\n\tpop\t\t\tint4,\n\tcname\t\ttext,\n\toutline \tpath\n)", "latest/postgres/create_view-3.sql": "COPY real_city FROM 'filename'", diff --git a/__fixtures__/generated/upstream-diff.json b/__fixtures__/generated/upstream-diff.json index 78af3411..a7d37f66 100644 --- a/__fixtures__/generated/upstream-diff.json +++ b/__fixtures__/generated/upstream-diff.json @@ -1071,6 +1071,18 @@ "original": "DROP SUBSCRIPTION IF EXISTS some_sub CASCADE", "upstream": "DROP SUBSCRIPTION IF EXISTS some_sub" }, + "misc/booleans-cast-1.sql": { + "original": "SELECT * FROM myschema.mytable WHERE a = TRUE", + "upstream": "SELECT * FROM myschema.mytable WHERE a = false" + }, + "misc/booleans-cast-2.sql": { + "original": "SELECT * FROM myschema.mytable WHERE a = CAST('t' AS boolean)", + "upstream": "SELECT * FROM myschema.mytable WHERE a = true" + }, + "misc/booleans-cast-3.sql": { + "original": "SELECT * FROM myschema.mytable WHERE a = 't'::boolean", + "upstream": "SELECT * FROM myschema.mytable WHERE a = true" + }, "latest/postgres/create_view-1.sql": { "original": "CREATE FUNCTION interpt_pp(path, path)\n RETURNS point\n AS 'regresslib'\n LANGUAGE C STRICT", "upstream": "CREATE FUNCTION interpt_pp(path, path) RETURNS point AS $$regresslib$$ LANGUAGE c CALLED ON NULL INPUT" diff --git a/__fixtures__/kitchen-sink/misc/booleans-cast.sql b/__fixtures__/kitchen-sink/misc/booleans-cast.sql new file mode 100644 index 00000000..556b8d51 --- /dev/null +++ b/__fixtures__/kitchen-sink/misc/booleans-cast.sql @@ -0,0 +1,3 @@ + SELECT * FROM myschema.mytable WHERE a = TRUE; + SELECT * FROM myschema.mytable WHERE a = CAST('t' AS boolean); + SELECT * FROM myschema.mytable WHERE a = 't'::boolean; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/bothEnabled/asts.ts b/__fixtures__/output/utils/astHelpers/bothEnabled/asts.ts new file mode 100644 index 00000000..002ec189 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/bothEnabled/asts.ts @@ -0,0 +1,2330 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): ParseResult { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return _j; + }, + scanResult(_p?: ScanResult): ScanResult { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return _j; + }, + integer(_p?: Integer): Integer { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return _j; + }, + float(_p?: Float): Float { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return _j; + }, + boolean(_p?: Boolean): Boolean { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return _j; + }, + string(_p?: String): String { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return _j; + }, + bitString(_p?: BitString): BitString { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return _j; + }, + list(_p?: List): List { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return _j; + }, + oidList(_p?: OidList): OidList { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return _j; + }, + intList(_p?: IntList): IntList { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return _j; + }, + aConst(_p?: A_Const): A_Const { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return _j; + }, + alias(_p?: Alias): Alias { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return _j; + }, + rangeVar(_p?: RangeVar): RangeVar { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableFunc(_p?: TableFunc): TableFunc { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return _j; + }, + intoClause(_p?: IntoClause): IntoClause { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return _j; + }, + var(_p?: Var): Var { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + param(_p?: Param): Param { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return _j; + }, + aggref(_p?: Aggref): Aggref { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return _j; + }, + groupingFunc(_p?: GroupingFunc): GroupingFunc { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowFunc(_p?: WindowFunc): WindowFunc { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return _j; + }, + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return _j; + }, + funcExpr(_p?: FuncExpr): FuncExpr { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return _j; + }, + opExpr(_p?: OpExpr): OpExpr { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + distinctExpr(_p?: DistinctExpr): DistinctExpr { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullIfExpr(_p?: NullIfExpr): NullIfExpr { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + boolExpr(_p?: BoolExpr): BoolExpr { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + subLink(_p?: SubLink): SubLink { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return _j; + }, + subPlan(_p?: SubPlan): SubPlan { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return _j; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return _j; + }, + fieldSelect(_p?: FieldSelect): FieldSelect { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return _j; + }, + fieldStore(_p?: FieldStore): FieldStore { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return _j; + }, + relabelType(_p?: RelabelType): RelabelType { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateExpr(_p?: CollateExpr): CollateExpr { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseExpr(_p?: CaseExpr): CaseExpr { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseWhen(_p?: CaseWhen): CaseWhen { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return _j; + }, + arrayExpr(_p?: ArrayExpr): ArrayExpr { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowExpr(_p?: RowExpr): RowExpr { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return _j; + }, + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + xmlExpr(_p?: XmlExpr): XmlExpr { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonFormat(_p?: JsonFormat): JsonFormat { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonReturning(_p?: JsonReturning): JsonReturning { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return _j; + }, + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return _j; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullTest(_p?: NullTest): NullTest { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return _j; + }, + booleanTest(_p?: BooleanTest): BooleanTest { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + setToDefault(_p?: SetToDefault): SetToDefault { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return _j; + }, + nextValueExpr(_p?: NextValueExpr): NextValueExpr { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return _j; + }, + inferenceElem(_p?: InferenceElem): InferenceElem { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return _j; + }, + targetEntry(_p?: TargetEntry): TargetEntry { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return _j; + }, + rangeTblRef(_p?: RangeTblRef): RangeTblRef { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + joinExpr(_p?: JoinExpr): JoinExpr { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + fromExpr(_p?: FromExpr): FromExpr { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return _j; + }, + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return _j; + }, + query(_p?: Query): Query { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + typeName(_p?: TypeName): TypeName { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnRef(_p?: ColumnRef): ColumnRef { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return _j; + }, + paramRef(_p?: ParamRef): ParamRef { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return _j; + }, + aExpr(_p?: A_Expr): A_Expr { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + typeCast(_p?: TypeCast): TypeCast { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateClause(_p?: CollateClause): CollateClause { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return _j; + }, + roleSpec(_p?: RoleSpec): RoleSpec { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return _j; + }, + funcCall(_p?: FuncCall): FuncCall { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + aStar(_p?: A_Star): A_Star { + const _j = {} as A_Star; + return _j; + }, + aIndices(_p?: A_Indices): A_Indices { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return _j; + }, + aIndirection(_p?: A_Indirection): A_Indirection { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return _j; + }, + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return _j; + }, + resTarget(_p?: ResTarget): ResTarget { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return _j; + }, + sortBy(_p?: SortBy): SortBy { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowDef(_p?: WindowDef): WindowDef { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeSubselect(_p?: RangeSubselect): RangeSubselect { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return _j; + }, + rangeFunction(_p?: RangeFunction): RangeFunction { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableSample(_p?: RangeTableSample): RangeTableSample { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnDef(_p?: ColumnDef): ColumnDef { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableLikeClause(_p?: TableLikeClause): TableLikeClause { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return _j; + }, + indexElem(_p?: IndexElem): IndexElem { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return _j; + }, + defElem(_p?: DefElem): DefElem { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return _j; + }, + lockingClause(_p?: LockingClause): LockingClause { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return _j; + }, + xmlSerialize(_p?: XmlSerialize): XmlSerialize { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionElem(_p?: PartitionElem): PartitionElem { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionSpec(_p?: PartitionSpec): PartitionSpec { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionCmd(_p?: PartitionCmd): PartitionCmd { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return _j; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return _j; + }, + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return _j; + }, + tableSampleClause(_p?: TableSampleClause): TableSampleClause { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return _j; + }, + withCheckOption(_p?: WithCheckOption): WithCheckOption { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return _j; + }, + sortGroupClause(_p?: SortGroupClause): SortGroupClause { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return _j; + }, + groupingSet(_p?: GroupingSet): GroupingSet { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowClause(_p?: WindowClause): WindowClause { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return _j; + }, + rowMarkClause(_p?: RowMarkClause): RowMarkClause { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return _j; + }, + withClause(_p?: WithClause): WithClause { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return _j; + }, + inferClause(_p?: InferClause): InferClause { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return _j; + }, + onConflictClause(_p?: OnConflictClause): OnConflictClause { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteSearchClause(_p?: CTESearchClause): CTESearchClause { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteCycleClause(_p?: CTECycleClause): CTECycleClause { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return _j; + }, + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return _j; + }, + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return _j; + }, + mergeAction(_p?: MergeAction): MergeAction { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return _j; + }, + triggerTransition(_p?: TriggerTransition): TriggerTransition { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return _j; + }, + jsonOutput(_p?: JsonOutput): JsonOutput { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return _j; + }, + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return _j; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return _j; + }, + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return _j; + }, + rawStmt(_p?: RawStmt): RawStmt { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + insertStmt(_p?: InsertStmt): InsertStmt { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return _j; + }, + deleteStmt(_p?: DeleteStmt): DeleteStmt { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + updateStmt(_p?: UpdateStmt): UpdateStmt { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + mergeStmt(_p?: MergeStmt): MergeStmt { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + selectStmt(_p?: SelectStmt): SelectStmt { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return _j; + }, + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return _j; + }, + returnStmt(_p?: ReturnStmt): ReturnStmt { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return _j; + }, + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return _j; + }, + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return _j; + }, + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return _j; + }, + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + grantStmt(_p?: GrantStmt): GrantStmt { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return _j; + }, + accessPriv(_p?: AccessPriv): AccessPriv { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return _j; + }, + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + copyStmt(_p?: CopyStmt): CopyStmt { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return _j; + }, + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return _j; + }, + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + createStmt(_p?: CreateStmt): CreateStmt { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + constraint(_p?: Constraint): Constraint { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return _j; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return _j; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return _j; + }, + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return _j; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return _j; + }, + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return _j; + }, + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return _j; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return _j; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return _j; + }, + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return _j; + }, + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + defineStmt(_p?: DefineStmt): DefineStmt { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return _j; + }, + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return _j; + }, + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return _j; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return _j; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return _j; + }, + dropStmt(_p?: DropStmt): DropStmt { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + truncateStmt(_p?: TruncateStmt): TruncateStmt { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + commentStmt(_p?: CommentStmt): CommentStmt { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return _j; + }, + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return _j; + }, + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return _j; + }, + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return _j; + }, + fetchStmt(_p?: FetchStmt): FetchStmt { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return _j; + }, + indexStmt(_p?: IndexStmt): IndexStmt { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return _j; + }, + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + statsElem(_p?: StatsElem): StatsElem { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return _j; + }, + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return _j; + }, + functionParameter(_p?: FunctionParameter): FunctionParameter { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return _j; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return _j; + }, + doStmt(_p?: DoStmt): DoStmt { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return _j; + }, + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + callStmt(_p?: CallStmt): CallStmt { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return _j; + }, + callContext(_p?: CallContext): CallContext { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + renameStmt(_p?: RenameStmt): RenameStmt { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return _j; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return _j; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return _j; + }, + ruleStmt(_p?: RuleStmt): RuleStmt { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + notifyStmt(_p?: NotifyStmt): NotifyStmt { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return _j; + }, + listenStmt(_p?: ListenStmt): ListenStmt { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + transactionStmt(_p?: TransactionStmt): TransactionStmt { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return _j; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return _j; + }, + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return _j; + }, + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return _j; + }, + viewStmt(_p?: ViewStmt): ViewStmt { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return _j; + }, + loadStmt(_p?: LoadStmt): LoadStmt { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return _j; + }, + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return _j; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropdbStmt(_p?: DropdbStmt): DropdbStmt { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + clusterStmt(_p?: ClusterStmt): ClusterStmt { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return _j; + }, + vacuumStmt(_p?: VacuumStmt): VacuumStmt { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return _j; + }, + vacuumRelation(_p?: VacuumRelation): VacuumRelation { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return _j; + }, + explainStmt(_p?: ExplainStmt): ExplainStmt { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return _j; + }, + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return _j; + }, + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { + const _j = {} as CheckPointStmt; + return _j; + }, + discardStmt(_p?: DiscardStmt): DiscardStmt { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return _j; + }, + lockStmt(_p?: LockStmt): LockStmt { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return _j; + }, + reindexStmt(_p?: ReindexStmt): ReindexStmt { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return _j; + }, + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return _j; + }, + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return _j; + }, + prepareStmt(_p?: PrepareStmt): PrepareStmt { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return _j; + }, + executeStmt(_p?: ExecuteStmt): ExecuteStmt { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return _j; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return _j; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + publicationTable(_p?: PublicationTable): PublicationTable { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return _j; + }, + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return _j; + }, + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return _j; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return _j; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + scanToken(_p?: ScanToken): ScanToken { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return _j; + } +}; \ No newline at end of file diff --git a/packages/types/src/types.ts b/__fixtures__/output/utils/astHelpers/bothEnabled/types.ts similarity index 91% rename from packages/types/src/types.ts rename to __fixtures__/output/utils/astHelpers/bothEnabled/types.ts index 9c2e0635..cf5f2c36 100644 --- a/packages/types/src/types.ts +++ b/__fixtures__/output/utils/astHelpers/bothEnabled/types.ts @@ -1,9 +1,9 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@latest. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ -import { QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, JsonQuotes, JsonTableColumnType, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OverridingKind, OnCommitAction, TableFuncType, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, JsonWrapper, JsonBehaviorType, JsonExprOp, NullTestType, BoolTestType, MergeMatchKind, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; export type Node = { ParseResult: ParseResult; } | { @@ -44,10 +44,6 @@ export type Node = { GroupingFunc: GroupingFunc; } | { WindowFunc: WindowFunc; -} | { - WindowFuncRunCondition: WindowFuncRunCondition; -} | { - MergeSupportFunc: MergeSupportFunc; } | { SubscriptingRef: SubscriptingRef; } | { @@ -114,22 +110,10 @@ export type Node = { JsonConstructorExpr: JsonConstructorExpr; } | { JsonIsPredicate: JsonIsPredicate; -} | { - JsonBehavior: JsonBehavior; -} | { - JsonExpr: JsonExpr; -} | { - JsonTablePath: JsonTablePath; -} | { - JsonTablePathScan: JsonTablePathScan; -} | { - JsonTableSiblingJoin: JsonTableSiblingJoin; } | { NullTest: NullTest; } | { BooleanTest: BooleanTest; -} | { - MergeAction: MergeAction; } | { CoerceToDomain: CoerceToDomain; } | { @@ -216,8 +200,6 @@ export type Node = { PartitionBoundSpec: PartitionBoundSpec; } | { PartitionRangeDatum: PartitionRangeDatum; -} | { - SinglePartitionSpec: SinglePartitionSpec; } | { PartitionCmd: PartitionCmd; } | { @@ -252,28 +234,14 @@ export type Node = { CommonTableExpr: CommonTableExpr; } | { MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; } | { TriggerTransition: TriggerTransition; } | { JsonOutput: JsonOutput; -} | { - JsonArgument: JsonArgument; -} | { - JsonFuncExpr: JsonFuncExpr; -} | { - JsonTablePathSpec: JsonTablePathSpec; -} | { - JsonTable: JsonTable; -} | { - JsonTableColumn: JsonTableColumn; } | { JsonKeyValue: JsonKeyValue; -} | { - JsonParseExpr: JsonParseExpr; -} | { - JsonScalarExpr: JsonScalarExpr; -} | { - JsonSerializeExpr: JsonSerializeExpr; } | { JsonObjectConstructor: JsonObjectConstructor; } | { @@ -602,7 +570,6 @@ export interface RangeVar { location?: number; } export interface TableFunc { - functype?: TableFuncType; ns_uris?: Node[]; ns_names?: Node[]; docexpr?: Node; @@ -613,10 +580,7 @@ export interface TableFunc { colcollations?: Node[]; colexprs?: Node[]; coldefexprs?: Node[]; - colvalexprs?: Node[]; - passingvalexprs?: Node[]; notnulls?: bigint[]; - plan?: Node; ordinalitycol?: number; location?: number; } @@ -686,25 +650,11 @@ export interface WindowFunc { inputcollid?: number; args?: Node[]; aggfilter?: Node; - runCondition?: Node[]; winref?: number; winstar?: boolean; winagg?: boolean; location?: number; } -export interface WindowFuncRunCondition { - xpr?: Node; - opno?: number; - inputcollid?: number; - wfunc_left?: boolean; - arg?: Node; -} -export interface MergeSupportFunc { - xpr?: Node; - msftype?: number; - msfcollid?: number; - location?: number; -} export interface SubscriptingRef { xpr?: Node; refcontainertype?: number; @@ -983,47 +933,6 @@ export interface JsonIsPredicate { unique_keys?: boolean; location?: number; } -export interface JsonBehavior { - btype?: JsonBehaviorType; - expr?: Node; - coerce?: boolean; - location?: number; -} -export interface JsonExpr { - xpr?: Node; - op?: JsonExprOp; - column_name?: string; - formatted_expr?: Node; - format?: JsonFormat; - path_spec?: Node; - returning?: JsonReturning; - passing_names?: Node[]; - passing_values?: Node[]; - on_empty?: JsonBehavior; - on_error?: JsonBehavior; - use_io_coercion?: boolean; - use_json_coercion?: boolean; - wrapper?: JsonWrapper; - omit_quotes?: boolean; - collation?: number; - location?: number; -} -export interface JsonTablePath { - name?: string; -} -export interface JsonTablePathScan { - plan?: Node; - path?: JsonTablePath; - errorOnError?: boolean; - child?: Node; - colMin?: number; - colMax?: number; -} -export interface JsonTableSiblingJoin { - plan?: Node; - lplan?: Node; - rplan?: Node; -} export interface NullTest { xpr?: Node; arg?: Node; @@ -1037,14 +946,6 @@ export interface BooleanTest { booltesttype?: BoolTestType; location?: number; } -export interface MergeAction { - matchKind?: MergeMatchKind; - commandType?: CmdType; - override?: OverridingKind; - qual?: Node; - targetList?: Node[]; - updateColnos?: Node[]; -} export interface CoerceToDomain { xpr?: Node; arg?: Node; @@ -1144,8 +1045,7 @@ export interface Query { rteperminfos?: Node[]; jointree?: FromExpr; mergeActionList?: Node[]; - mergeTargetRelation?: number; - mergeJoinCondition?: Node; + mergeUseOuterJoin?: boolean; targetList?: Node[]; override?: OverridingKind; onConflict?: OnConflictExpr; @@ -1382,22 +1282,18 @@ export interface PartitionRangeDatum { value?: Node; location?: number; } -export interface SinglePartitionSpec {} export interface PartitionCmd { name?: RangeVar; bound?: PartitionBoundSpec; concurrent?: boolean; } export interface RangeTblEntry { - alias?: Alias; - eref?: Alias; rtekind?: RTEKind; relid?: number; - inh?: boolean; relkind?: string; rellockmode?: number; - perminfoindex?: number; tablesample?: TableSampleClause; + perminfoindex?: number; subquery?: Query; security_barrier?: boolean; jointype?: JoinType; @@ -1418,7 +1314,10 @@ export interface RangeTblEntry { colcollations?: Node[]; enrname?: string; enrtuples?: number; + alias?: Alias; + eref?: Alias; lateral?: boolean; + inh?: boolean; inFromCl?: boolean; securityQuals?: Node[]; } @@ -1472,6 +1371,7 @@ export interface WindowClause { frameOptions?: number; startOffset?: Node; endOffset?: Node; + runCondition?: Node[]; startInRangeFunc?: number; endInRangeFunc?: number; inRangeColl?: number; @@ -1538,13 +1438,21 @@ export interface CommonTableExpr { ctecolcollations?: Node[]; } export interface MergeWhenClause { - matchKind?: MergeMatchKind; + matched?: boolean; commandType?: CmdType; override?: OverridingKind; condition?: Node; targetList?: Node[]; values?: Node[]; } +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} export interface TriggerTransition { name?: string; isNew?: boolean; @@ -1554,72 +1462,10 @@ export interface JsonOutput { typeName?: TypeName; returning?: JsonReturning; } -export interface JsonArgument { - val?: JsonValueExpr; - name?: string; -} -export interface JsonFuncExpr { - op?: JsonExprOp; - column_name?: string; - context_item?: JsonValueExpr; - pathspec?: Node; - passing?: Node[]; - output?: JsonOutput; - on_empty?: JsonBehavior; - on_error?: JsonBehavior; - wrapper?: JsonWrapper; - quotes?: JsonQuotes; - location?: number; -} -export interface JsonTablePathSpec { - string?: Node; - name?: string; - name_location?: number; - location?: number; -} -export interface JsonTable { - context_item?: JsonValueExpr; - pathspec?: JsonTablePathSpec; - passing?: Node[]; - columns?: Node[]; - on_error?: JsonBehavior; - alias?: Alias; - lateral?: boolean; - location?: number; -} -export interface JsonTableColumn { - coltype?: JsonTableColumnType; - name?: string; - typeName?: TypeName; - pathspec?: JsonTablePathSpec; - format?: JsonFormat; - wrapper?: JsonWrapper; - quotes?: JsonQuotes; - columns?: Node[]; - on_empty?: JsonBehavior; - on_error?: JsonBehavior; - location?: number; -} export interface JsonKeyValue { key?: Node; value?: JsonValueExpr; } -export interface JsonParseExpr { - expr?: JsonValueExpr; - output?: JsonOutput; - unique_keys?: boolean; - location?: number; -} -export interface JsonScalarExpr { - expr?: Node; - output?: JsonOutput; - location?: number; -} -export interface JsonSerializeExpr { - expr?: JsonValueExpr; - output?: JsonOutput; - location?: number; -} export interface JsonObjectConstructor { exprs?: Node[]; output?: JsonOutput; @@ -1692,7 +1538,6 @@ export interface MergeStmt { sourceRelation?: Node; joinCondition?: Node; mergeWhenClauses?: Node[]; - returningList?: Node[]; withClause?: WithClause; } export interface SelectStmt { @@ -1845,13 +1690,11 @@ export interface Constraint { conname?: string; deferrable?: boolean; initdeferred?: boolean; - skip_validation?: boolean; - initially_valid?: boolean; + location?: number; is_no_inherit?: boolean; raw_expr?: Node; cooked_expr?: string; generated_when?: string; - inhcount?: number; nulls_not_distinct?: boolean; keys?: Node[]; including?: Node[]; @@ -1871,7 +1714,8 @@ export interface Constraint { fk_del_set_cols?: Node[]; old_conpfeqop?: Node[]; old_pktable_oid?: number; - location?: number; + skip_validation?: boolean; + initially_valid?: boolean; } export interface CreateTableSpaceStmt { tablespacename?: string; @@ -2170,7 +2014,7 @@ export interface StatsElem { } export interface AlterStatsStmt { defnames?: Node[]; - stxstattarget?: Node; + stxstattarget?: number; missing_ok?: boolean; } export interface CreateFunctionStmt { @@ -2273,7 +2117,6 @@ export interface TransactionStmt { savepoint_name?: string; gid?: string; chain?: boolean; - location?: number; } export interface CompositeTypeStmt { typevar?: RangeVar; @@ -2411,8 +2254,6 @@ export interface ExecuteStmt { } export interface DeallocateStmt { name?: string; - isall?: boolean; - location?: number; } export interface DropOwnedStmt { roles?: Node[]; diff --git a/__fixtures__/output/utils/astHelpers/bothEnabled/wrapped-asts.ts b/__fixtures__/output/utils/astHelpers/bothEnabled/wrapped-asts.ts new file mode 100644 index 00000000..313b2223 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/bothEnabled/wrapped-asts.ts @@ -0,0 +1,3350 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +}; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/enabled/asts.ts b/__fixtures__/output/utils/astHelpers/enabled/asts.ts index 776a88fe..002ec189 100644 --- a/__fixtures__/output/utils/astHelpers/enabled/asts.ts +++ b/__fixtures__/output/utils/astHelpers/enabled/asts.ts @@ -6,131 +6,59 @@ import _o from "nested-obj"; import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; export default { - parseResult(_p?: ParseResult, isNode?: boolean): ParseResult | { - ParseResult: ParseResult; - } { + parseResult(_p?: ParseResult): ParseResult { const _j = {} as ParseResult; _o.set(_j, "version", _p?.version); _o.set(_j, "stmts", _p?.stmts); - if (isNode) { - return { - ParseResult: _j - }; - } return _j; }, - scanResult(_p?: ScanResult, isNode?: boolean): ScanResult | { - ScanResult: ScanResult; - } { + scanResult(_p?: ScanResult): ScanResult { const _j = {} as ScanResult; _o.set(_j, "version", _p?.version); _o.set(_j, "tokens", _p?.tokens); - if (isNode) { - return { - ScanResult: _j - }; - } return _j; }, - integer(_p?: Integer, isNode?: boolean): Integer | { - Integer: Integer; - } { + integer(_p?: Integer): Integer { const _j = {} as Integer; _o.set(_j, "ival", _p?.ival); - if (isNode) { - return { - Integer: _j - }; - } return _j; }, - float(_p?: Float, isNode?: boolean): Float | { - Float: Float; - } { + float(_p?: Float): Float { const _j = {} as Float; _o.set(_j, "fval", _p?.fval); - if (isNode) { - return { - Float: _j - }; - } return _j; }, - boolean(_p?: Boolean, isNode?: boolean): Boolean | { - Boolean: Boolean; - } { + boolean(_p?: Boolean): Boolean { const _j = {} as Boolean; _o.set(_j, "boolval", _p?.boolval); - if (isNode) { - return { - Boolean: _j - }; - } return _j; }, - string(_p?: String, isNode?: boolean): String | { - String: String; - } { + string(_p?: String): String { const _j = {} as String; _o.set(_j, "sval", _p?.sval); - if (isNode) { - return { - String: _j - }; - } return _j; }, - bitString(_p?: BitString, isNode?: boolean): BitString | { - BitString: BitString; - } { + bitString(_p?: BitString): BitString { const _j = {} as BitString; _o.set(_j, "bsval", _p?.bsval); - if (isNode) { - return { - BitString: _j - }; - } return _j; }, - list(_p?: List, isNode?: boolean): List | { - List: List; - } { + list(_p?: List): List { const _j = {} as List; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - List: _j - }; - } return _j; }, - oidList(_p?: OidList, isNode?: boolean): OidList | { - OidList: OidList; - } { + oidList(_p?: OidList): OidList { const _j = {} as OidList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - OidList: _j - }; - } return _j; }, - intList(_p?: IntList, isNode?: boolean): IntList | { - IntList: IntList; - } { + intList(_p?: IntList): IntList { const _j = {} as IntList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - IntList: _j - }; - } return _j; }, - aConst(_p?: A_Const, isNode?: boolean): A_Const | { - A_Const: A_Const; - } { + aConst(_p?: A_Const): A_Const { const _j = {} as A_Const; _o.set(_j, "ival", _p?.ival); _o.set(_j, "fval", _p?.fval); @@ -139,29 +67,15 @@ export default { _o.set(_j, "bsval", _p?.bsval); _o.set(_j, "isnull", _p?.isnull); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Const: _j - }; - } return _j; }, - alias(_p?: Alias, isNode?: boolean): Alias | { - Alias: Alias; - } { + alias(_p?: Alias): Alias { const _j = {} as Alias; _o.set(_j, "aliasname", _p?.aliasname); _o.set(_j, "colnames", _p?.colnames); - if (isNode) { - return { - Alias: _j - }; - } return _j; }, - rangeVar(_p?: RangeVar, isNode?: boolean): RangeVar | { - RangeVar: RangeVar; - } { + rangeVar(_p?: RangeVar): RangeVar { const _j = {} as RangeVar; _o.set(_j, "catalogname", _p?.catalogname); _o.set(_j, "schemaname", _p?.schemaname); @@ -170,16 +84,9 @@ export default { _o.set(_j, "relpersistence", _p?.relpersistence); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeVar: _j - }; - } return _j; }, - tableFunc(_p?: TableFunc, isNode?: boolean): TableFunc | { - TableFunc: TableFunc; - } { + tableFunc(_p?: TableFunc): TableFunc { const _j = {} as TableFunc; _o.set(_j, "ns_uris", _p?.ns_uris); _o.set(_j, "ns_names", _p?.ns_names); @@ -194,16 +101,9 @@ export default { _o.set(_j, "notnulls", _p?.notnulls); _o.set(_j, "ordinalitycol", _p?.ordinalitycol); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TableFunc: _j - }; - } return _j; }, - intoClause(_p?: IntoClause, isNode?: boolean): IntoClause | { - IntoClause: IntoClause; - } { + intoClause(_p?: IntoClause): IntoClause { const _j = {} as IntoClause; _o.set(_j, "rel", _p?.rel); _o.set(_j, "colNames", _p?.colNames); @@ -213,16 +113,9 @@ export default { _o.set(_j, "tableSpaceName", _p?.tableSpaceName); _o.set(_j, "viewQuery", _p?.viewQuery); _o.set(_j, "skipData", _p?.skipData); - if (isNode) { - return { - IntoClause: _j - }; - } return _j; }, - var(_p?: Var, isNode?: boolean): Var | { - Var: Var; - } { + var(_p?: Var): Var { const _j = {} as Var; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "varno", _p?.varno); @@ -233,16 +126,9 @@ export default { _o.set(_j, "varnullingrels", _p?.varnullingrels); _o.set(_j, "varlevelsup", _p?.varlevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Var: _j - }; - } return _j; }, - param(_p?: Param, isNode?: boolean): Param | { - Param: Param; - } { + param(_p?: Param): Param { const _j = {} as Param; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "paramkind", _p?.paramkind); @@ -251,16 +137,9 @@ export default { _o.set(_j, "paramtypmod", _p?.paramtypmod); _o.set(_j, "paramcollid", _p?.paramcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Param: _j - }; - } return _j; }, - aggref(_p?: Aggref, isNode?: boolean): Aggref | { - Aggref: Aggref; - } { + aggref(_p?: Aggref): Aggref { const _j = {} as Aggref; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "aggfnoid", _p?.aggfnoid); @@ -281,32 +160,18 @@ export default { _o.set(_j, "aggno", _p?.aggno); _o.set(_j, "aggtransno", _p?.aggtransno); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Aggref: _j - }; - } return _j; }, - groupingFunc(_p?: GroupingFunc, isNode?: boolean): GroupingFunc | { - GroupingFunc: GroupingFunc; - } { + groupingFunc(_p?: GroupingFunc): GroupingFunc { const _j = {} as GroupingFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); _o.set(_j, "refs", _p?.refs); _o.set(_j, "agglevelsup", _p?.agglevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingFunc: _j - }; - } return _j; }, - windowFunc(_p?: WindowFunc, isNode?: boolean): WindowFunc | { - WindowFunc: WindowFunc; - } { + windowFunc(_p?: WindowFunc): WindowFunc { const _j = {} as WindowFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "winfnoid", _p?.winfnoid); @@ -319,16 +184,9 @@ export default { _o.set(_j, "winstar", _p?.winstar); _o.set(_j, "winagg", _p?.winagg); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowFunc: _j - }; - } return _j; }, - subscriptingRef(_p?: SubscriptingRef, isNode?: boolean): SubscriptingRef | { - SubscriptingRef: SubscriptingRef; - } { + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { const _j = {} as SubscriptingRef; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "refcontainertype", _p?.refcontainertype); @@ -340,16 +198,9 @@ export default { _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); _o.set(_j, "refexpr", _p?.refexpr); _o.set(_j, "refassgnexpr", _p?.refassgnexpr); - if (isNode) { - return { - SubscriptingRef: _j - }; - } return _j; }, - funcExpr(_p?: FuncExpr, isNode?: boolean): FuncExpr | { - FuncExpr: FuncExpr; - } { + funcExpr(_p?: FuncExpr): FuncExpr { const _j = {} as FuncExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "funcid", _p?.funcid); @@ -361,32 +212,18 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncExpr: _j - }; - } return _j; }, - namedArgExpr(_p?: NamedArgExpr, isNode?: boolean): NamedArgExpr | { - NamedArgExpr: NamedArgExpr; - } { + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { const _j = {} as NamedArgExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "name", _p?.name); _o.set(_j, "argnumber", _p?.argnumber); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NamedArgExpr: _j - }; - } return _j; }, - opExpr(_p?: OpExpr, isNode?: boolean): OpExpr | { - OpExpr: OpExpr; - } { + opExpr(_p?: OpExpr): OpExpr { const _j = {} as OpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -396,16 +233,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OpExpr: _j - }; - } return _j; }, - distinctExpr(_p?: DistinctExpr, isNode?: boolean): DistinctExpr | { - DistinctExpr: DistinctExpr; - } { + distinctExpr(_p?: DistinctExpr): DistinctExpr { const _j = {} as DistinctExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -415,16 +245,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DistinctExpr: _j - }; - } return _j; }, - nullIfExpr(_p?: NullIfExpr, isNode?: boolean): NullIfExpr | { - NullIfExpr: NullIfExpr; - } { + nullIfExpr(_p?: NullIfExpr): NullIfExpr { const _j = {} as NullIfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -434,16 +257,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullIfExpr: _j - }; - } return _j; }, - scalarArrayOpExpr(_p?: ScalarArrayOpExpr, isNode?: boolean): ScalarArrayOpExpr | { - ScalarArrayOpExpr: ScalarArrayOpExpr; - } { + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { const _j = {} as ScalarArrayOpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -451,31 +267,17 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ScalarArrayOpExpr: _j - }; - } return _j; }, - boolExpr(_p?: BoolExpr, isNode?: boolean): BoolExpr | { - BoolExpr: BoolExpr; - } { + boolExpr(_p?: BoolExpr): BoolExpr { const _j = {} as BoolExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "boolop", _p?.boolop); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BoolExpr: _j - }; - } return _j; }, - subLink(_p?: SubLink, isNode?: boolean): SubLink | { - SubLink: SubLink; - } { + subLink(_p?: SubLink): SubLink { const _j = {} as SubLink; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -484,16 +286,9 @@ export default { _o.set(_j, "operName", _p?.operName); _o.set(_j, "subselect", _p?.subselect); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SubLink: _j - }; - } return _j; }, - subPlan(_p?: SubPlan, isNode?: boolean): SubPlan | { - SubPlan: SubPlan; - } { + subPlan(_p?: SubPlan): SubPlan { const _j = {} as SubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -512,29 +307,15 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "startup_cost", _p?.startup_cost); _o.set(_j, "per_call_cost", _p?.per_call_cost); - if (isNode) { - return { - SubPlan: _j - }; - } return _j; }, - alternativeSubPlan(_p?: AlternativeSubPlan, isNode?: boolean): AlternativeSubPlan | { - AlternativeSubPlan: AlternativeSubPlan; - } { + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { const _j = {} as AlternativeSubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subplans", _p?.subplans); - if (isNode) { - return { - AlternativeSubPlan: _j - }; - } return _j; }, - fieldSelect(_p?: FieldSelect, isNode?: boolean): FieldSelect | { - FieldSelect: FieldSelect; - } { + fieldSelect(_p?: FieldSelect): FieldSelect { const _j = {} as FieldSelect; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -542,32 +323,18 @@ export default { _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "resulttypmod", _p?.resulttypmod); _o.set(_j, "resultcollid", _p?.resultcollid); - if (isNode) { - return { - FieldSelect: _j - }; - } return _j; }, - fieldStore(_p?: FieldStore, isNode?: boolean): FieldStore | { - FieldStore: FieldStore; - } { + fieldStore(_p?: FieldStore): FieldStore { const _j = {} as FieldStore; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "newvals", _p?.newvals); _o.set(_j, "fieldnums", _p?.fieldnums); _o.set(_j, "resulttype", _p?.resulttype); - if (isNode) { - return { - FieldStore: _j - }; - } return _j; }, - relabelType(_p?: RelabelType, isNode?: boolean): RelabelType | { - RelabelType: RelabelType; - } { + relabelType(_p?: RelabelType): RelabelType { const _j = {} as RelabelType; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -576,16 +343,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "relabelformat", _p?.relabelformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RelabelType: _j - }; - } return _j; }, - coerceViaio(_p?: CoerceViaIO, isNode?: boolean): CoerceViaIO | { - CoerceViaIO: CoerceViaIO; - } { + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { const _j = {} as CoerceViaIO; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -593,16 +353,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceViaIO: _j - }; - } return _j; }, - arrayCoerceExpr(_p?: ArrayCoerceExpr, isNode?: boolean): ArrayCoerceExpr | { - ArrayCoerceExpr: ArrayCoerceExpr; - } { + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { const _j = {} as ArrayCoerceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -612,47 +365,26 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayCoerceExpr: _j - }; - } return _j; }, - convertRowtypeExpr(_p?: ConvertRowtypeExpr, isNode?: boolean): ConvertRowtypeExpr | { - ConvertRowtypeExpr: ConvertRowtypeExpr; - } { + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { const _j = {} as ConvertRowtypeExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "convertformat", _p?.convertformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ConvertRowtypeExpr: _j - }; - } return _j; }, - collateExpr(_p?: CollateExpr, isNode?: boolean): CollateExpr | { - CollateExpr: CollateExpr; - } { + collateExpr(_p?: CollateExpr): CollateExpr { const _j = {} as CollateExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "collOid", _p?.collOid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateExpr: _j - }; - } return _j; }, - caseExpr(_p?: CaseExpr, isNode?: boolean): CaseExpr | { - CaseExpr: CaseExpr; - } { + caseExpr(_p?: CaseExpr): CaseExpr { const _j = {} as CaseExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "casetype", _p?.casetype); @@ -661,46 +393,25 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "defresult", _p?.defresult); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseExpr: _j - }; - } return _j; }, - caseWhen(_p?: CaseWhen, isNode?: boolean): CaseWhen | { - CaseWhen: CaseWhen; - } { + caseWhen(_p?: CaseWhen): CaseWhen { const _j = {} as CaseWhen; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "result", _p?.result); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseWhen: _j - }; - } return _j; }, - caseTestExpr(_p?: CaseTestExpr, isNode?: boolean): CaseTestExpr | { - CaseTestExpr: CaseTestExpr; - } { + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { const _j = {} as CaseTestExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); - if (isNode) { - return { - CaseTestExpr: _j - }; - } return _j; }, - arrayExpr(_p?: ArrayExpr, isNode?: boolean): ArrayExpr | { - ArrayExpr: ArrayExpr; - } { + arrayExpr(_p?: ArrayExpr): ArrayExpr { const _j = {} as ArrayExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "array_typeid", _p?.array_typeid); @@ -709,16 +420,9 @@ export default { _o.set(_j, "elements", _p?.elements); _o.set(_j, "multidims", _p?.multidims); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayExpr: _j - }; - } return _j; }, - rowExpr(_p?: RowExpr, isNode?: boolean): RowExpr | { - RowExpr: RowExpr; - } { + rowExpr(_p?: RowExpr): RowExpr { const _j = {} as RowExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); @@ -726,16 +430,9 @@ export default { _o.set(_j, "row_format", _p?.row_format); _o.set(_j, "colnames", _p?.colnames); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RowExpr: _j - }; - } return _j; }, - rowCompareExpr(_p?: RowCompareExpr, isNode?: boolean): RowCompareExpr | { - RowCompareExpr: RowCompareExpr; - } { + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { const _j = {} as RowCompareExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "rctype", _p?.rctype); @@ -744,32 +441,18 @@ export default { _o.set(_j, "inputcollids", _p?.inputcollids); _o.set(_j, "largs", _p?.largs); _o.set(_j, "rargs", _p?.rargs); - if (isNode) { - return { - RowCompareExpr: _j - }; - } return _j; }, - coalesceExpr(_p?: CoalesceExpr, isNode?: boolean): CoalesceExpr | { - CoalesceExpr: CoalesceExpr; - } { + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { const _j = {} as CoalesceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "coalescetype", _p?.coalescetype); _o.set(_j, "coalescecollid", _p?.coalescecollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoalesceExpr: _j - }; - } return _j; }, - minMaxExpr(_p?: MinMaxExpr, isNode?: boolean): MinMaxExpr | { - MinMaxExpr: MinMaxExpr; - } { + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { const _j = {} as MinMaxExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "minmaxtype", _p?.minmaxtype); @@ -778,32 +461,18 @@ export default { _o.set(_j, "op", _p?.op); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MinMaxExpr: _j - }; - } return _j; }, - sqlValueFunction(_p?: SQLValueFunction, isNode?: boolean): SQLValueFunction | { - SQLValueFunction: SQLValueFunction; - } { + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { const _j = {} as SQLValueFunction; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SQLValueFunction: _j - }; - } return _j; }, - xmlExpr(_p?: XmlExpr, isNode?: boolean): XmlExpr | { - XmlExpr: XmlExpr; - } { + xmlExpr(_p?: XmlExpr): XmlExpr { const _j = {} as XmlExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -816,58 +485,30 @@ export default { _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlExpr: _j - }; - } return _j; }, - jsonFormat(_p?: JsonFormat, isNode?: boolean): JsonFormat | { - JsonFormat: JsonFormat; - } { + jsonFormat(_p?: JsonFormat): JsonFormat { const _j = {} as JsonFormat; _o.set(_j, "format_type", _p?.format_type); _o.set(_j, "encoding", _p?.encoding); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFormat: _j - }; - } return _j; }, - jsonReturning(_p?: JsonReturning, isNode?: boolean): JsonReturning | { - JsonReturning: JsonReturning; - } { + jsonReturning(_p?: JsonReturning): JsonReturning { const _j = {} as JsonReturning; _o.set(_j, "format", _p?.format); _o.set(_j, "typid", _p?.typid); _o.set(_j, "typmod", _p?.typmod); - if (isNode) { - return { - JsonReturning: _j - }; - } return _j; }, - jsonValueExpr(_p?: JsonValueExpr, isNode?: boolean): JsonValueExpr | { - JsonValueExpr: JsonValueExpr; - } { + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { const _j = {} as JsonValueExpr; _o.set(_j, "raw_expr", _p?.raw_expr); _o.set(_j, "formatted_expr", _p?.formatted_expr); _o.set(_j, "format", _p?.format); - if (isNode) { - return { - JsonValueExpr: _j - }; - } return _j; }, - jsonConstructorExpr(_p?: JsonConstructorExpr, isNode?: boolean): JsonConstructorExpr | { - JsonConstructorExpr: JsonConstructorExpr; - } { + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { const _j = {} as JsonConstructorExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "type", _p?.type); @@ -878,63 +519,35 @@ export default { _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonConstructorExpr: _j - }; - } return _j; }, - jsonIsPredicate(_p?: JsonIsPredicate, isNode?: boolean): JsonIsPredicate | { - JsonIsPredicate: JsonIsPredicate; - } { + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { const _j = {} as JsonIsPredicate; _o.set(_j, "expr", _p?.expr); _o.set(_j, "format", _p?.format); _o.set(_j, "item_type", _p?.item_type); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonIsPredicate: _j - }; - } return _j; }, - nullTest(_p?: NullTest, isNode?: boolean): NullTest | { - NullTest: NullTest; - } { + nullTest(_p?: NullTest): NullTest { const _j = {} as NullTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "nulltesttype", _p?.nulltesttype); _o.set(_j, "argisrow", _p?.argisrow); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullTest: _j - }; - } return _j; }, - booleanTest(_p?: BooleanTest, isNode?: boolean): BooleanTest | { - BooleanTest: BooleanTest; - } { + booleanTest(_p?: BooleanTest): BooleanTest { const _j = {} as BooleanTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "booltesttype", _p?.booltesttype); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BooleanTest: _j - }; - } return _j; }, - coerceToDomain(_p?: CoerceToDomain, isNode?: boolean): CoerceToDomain | { - CoerceToDomain: CoerceToDomain; - } { + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { const _j = {} as CoerceToDomain; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -943,92 +556,50 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coercionformat", _p?.coercionformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomain: _j - }; - } return _j; }, - coerceToDomainValue(_p?: CoerceToDomainValue, isNode?: boolean): CoerceToDomainValue | { - CoerceToDomainValue: CoerceToDomainValue; - } { + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { const _j = {} as CoerceToDomainValue; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomainValue: _j - }; - } return _j; }, - setToDefault(_p?: SetToDefault, isNode?: boolean): SetToDefault | { - SetToDefault: SetToDefault; - } { + setToDefault(_p?: SetToDefault): SetToDefault { const _j = {} as SetToDefault; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SetToDefault: _j - }; - } return _j; }, - currentOfExpr(_p?: CurrentOfExpr, isNode?: boolean): CurrentOfExpr | { - CurrentOfExpr: CurrentOfExpr; - } { + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { const _j = {} as CurrentOfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "cvarno", _p?.cvarno); _o.set(_j, "cursor_name", _p?.cursor_name); _o.set(_j, "cursor_param", _p?.cursor_param); - if (isNode) { - return { - CurrentOfExpr: _j - }; - } return _j; }, - nextValueExpr(_p?: NextValueExpr, isNode?: boolean): NextValueExpr | { - NextValueExpr: NextValueExpr; - } { + nextValueExpr(_p?: NextValueExpr): NextValueExpr { const _j = {} as NextValueExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "seqid", _p?.seqid); _o.set(_j, "typeId", _p?.typeId); - if (isNode) { - return { - NextValueExpr: _j - }; - } return _j; }, - inferenceElem(_p?: InferenceElem, isNode?: boolean): InferenceElem | { - InferenceElem: InferenceElem; - } { + inferenceElem(_p?: InferenceElem): InferenceElem { const _j = {} as InferenceElem; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "infercollid", _p?.infercollid); _o.set(_j, "inferopclass", _p?.inferopclass); - if (isNode) { - return { - InferenceElem: _j - }; - } return _j; }, - targetEntry(_p?: TargetEntry, isNode?: boolean): TargetEntry | { - TargetEntry: TargetEntry; - } { + targetEntry(_p?: TargetEntry): TargetEntry { const _j = {} as TargetEntry; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); @@ -1038,28 +609,14 @@ export default { _o.set(_j, "resorigtbl", _p?.resorigtbl); _o.set(_j, "resorigcol", _p?.resorigcol); _o.set(_j, "resjunk", _p?.resjunk); - if (isNode) { - return { - TargetEntry: _j - }; - } return _j; }, - rangeTblRef(_p?: RangeTblRef, isNode?: boolean): RangeTblRef | { - RangeTblRef: RangeTblRef; - } { + rangeTblRef(_p?: RangeTblRef): RangeTblRef { const _j = {} as RangeTblRef; _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - RangeTblRef: _j - }; - } return _j; }, - joinExpr(_p?: JoinExpr, isNode?: boolean): JoinExpr | { - JoinExpr: JoinExpr; - } { + joinExpr(_p?: JoinExpr): JoinExpr { const _j = {} as JoinExpr; _o.set(_j, "jointype", _p?.jointype); _o.set(_j, "isNatural", _p?.isNatural); @@ -1070,29 +627,15 @@ export default { _o.set(_j, "quals", _p?.quals); _o.set(_j, "alias", _p?.alias); _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - JoinExpr: _j - }; - } return _j; }, - fromExpr(_p?: FromExpr, isNode?: boolean): FromExpr | { - FromExpr: FromExpr; - } { + fromExpr(_p?: FromExpr): FromExpr { const _j = {} as FromExpr; _o.set(_j, "fromlist", _p?.fromlist); _o.set(_j, "quals", _p?.quals); - if (isNode) { - return { - FromExpr: _j - }; - } return _j; }, - onConflictExpr(_p?: OnConflictExpr, isNode?: boolean): OnConflictExpr | { - OnConflictExpr: OnConflictExpr; - } { + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { const _j = {} as OnConflictExpr; _o.set(_j, "action", _p?.action); _o.set(_j, "arbiterElems", _p?.arbiterElems); @@ -1102,16 +645,9 @@ export default { _o.set(_j, "onConflictWhere", _p?.onConflictWhere); _o.set(_j, "exclRelIndex", _p?.exclRelIndex); _o.set(_j, "exclRelTlist", _p?.exclRelTlist); - if (isNode) { - return { - OnConflictExpr: _j - }; - } return _j; }, - query(_p?: Query, isNode?: boolean): Query | { - Query: Query; - } { + query(_p?: Query): Query { const _j = {} as Query; _o.set(_j, "commandType", _p?.commandType); _o.set(_j, "querySource", _p?.querySource); @@ -1154,16 +690,9 @@ export default { _o.set(_j, "withCheckOptions", _p?.withCheckOptions); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - Query: _j - }; - } return _j; }, - typeName(_p?: TypeName, isNode?: boolean): TypeName | { - TypeName: TypeName; - } { + typeName(_p?: TypeName): TypeName { const _j = {} as TypeName; _o.set(_j, "names", _p?.names); _o.set(_j, "typeOid", _p?.typeOid); @@ -1173,100 +702,51 @@ export default { _o.set(_j, "typemod", _p?.typemod); _o.set(_j, "arrayBounds", _p?.arrayBounds); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeName: _j - }; - } return _j; }, - columnRef(_p?: ColumnRef, isNode?: boolean): ColumnRef | { - ColumnRef: ColumnRef; - } { + columnRef(_p?: ColumnRef): ColumnRef { const _j = {} as ColumnRef; _o.set(_j, "fields", _p?.fields); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnRef: _j - }; - } return _j; }, - paramRef(_p?: ParamRef, isNode?: boolean): ParamRef | { - ParamRef: ParamRef; - } { + paramRef(_p?: ParamRef): ParamRef { const _j = {} as ParamRef; _o.set(_j, "number", _p?.number); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ParamRef: _j - }; - } return _j; }, - aExpr(_p?: A_Expr, isNode?: boolean): A_Expr | { - A_Expr: A_Expr; - } { + aExpr(_p?: A_Expr): A_Expr { const _j = {} as A_Expr; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "lexpr", _p?.lexpr); _o.set(_j, "rexpr", _p?.rexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Expr: _j - }; - } return _j; }, - typeCast(_p?: TypeCast, isNode?: boolean): TypeCast | { - TypeCast: TypeCast; - } { + typeCast(_p?: TypeCast): TypeCast { const _j = {} as TypeCast; _o.set(_j, "arg", _p?.arg); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeCast: _j - }; - } return _j; }, - collateClause(_p?: CollateClause, isNode?: boolean): CollateClause | { - CollateClause: CollateClause; - } { + collateClause(_p?: CollateClause): CollateClause { const _j = {} as CollateClause; _o.set(_j, "arg", _p?.arg); _o.set(_j, "collname", _p?.collname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateClause: _j - }; - } return _j; }, - roleSpec(_p?: RoleSpec, isNode?: boolean): RoleSpec | { - RoleSpec: RoleSpec; - } { + roleSpec(_p?: RoleSpec): RoleSpec { const _j = {} as RoleSpec; _o.set(_j, "roletype", _p?.roletype); _o.set(_j, "rolename", _p?.rolename); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RoleSpec: _j - }; - } return _j; }, - funcCall(_p?: FuncCall, isNode?: boolean): FuncCall | { - FuncCall: FuncCall; - } { + funcCall(_p?: FuncCall): FuncCall { const _j = {} as FuncCall; _o.set(_j, "funcname", _p?.funcname); _o.set(_j, "args", _p?.args); @@ -1279,112 +759,56 @@ export default { _o.set(_j, "func_variadic", _p?.func_variadic); _o.set(_j, "funcformat", _p?.funcformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncCall: _j - }; - } return _j; }, - aStar(_p?: A_Star, isNode?: boolean): A_Star | { - A_Star: A_Star; - } { + aStar(_p?: A_Star): A_Star { const _j = {} as A_Star; - if (isNode) { - return { - A_Star: _j - }; - } return _j; }, - aIndices(_p?: A_Indices, isNode?: boolean): A_Indices | { - A_Indices: A_Indices; - } { + aIndices(_p?: A_Indices): A_Indices { const _j = {} as A_Indices; _o.set(_j, "is_slice", _p?.is_slice); _o.set(_j, "lidx", _p?.lidx); _o.set(_j, "uidx", _p?.uidx); - if (isNode) { - return { - A_Indices: _j - }; - } return _j; }, - aIndirection(_p?: A_Indirection, isNode?: boolean): A_Indirection | { - A_Indirection: A_Indirection; - } { + aIndirection(_p?: A_Indirection): A_Indirection { const _j = {} as A_Indirection; _o.set(_j, "arg", _p?.arg); _o.set(_j, "indirection", _p?.indirection); - if (isNode) { - return { - A_Indirection: _j - }; - } return _j; }, - aArrayExpr(_p?: A_ArrayExpr, isNode?: boolean): A_ArrayExpr | { - A_ArrayExpr: A_ArrayExpr; - } { + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { const _j = {} as A_ArrayExpr; _o.set(_j, "elements", _p?.elements); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_ArrayExpr: _j - }; - } return _j; }, - resTarget(_p?: ResTarget, isNode?: boolean): ResTarget | { - ResTarget: ResTarget; - } { + resTarget(_p?: ResTarget): ResTarget { const _j = {} as ResTarget; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ResTarget: _j - }; - } return _j; }, - multiAssignRef(_p?: MultiAssignRef, isNode?: boolean): MultiAssignRef | { - MultiAssignRef: MultiAssignRef; - } { + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { const _j = {} as MultiAssignRef; _o.set(_j, "source", _p?.source); _o.set(_j, "colno", _p?.colno); _o.set(_j, "ncolumns", _p?.ncolumns); - if (isNode) { - return { - MultiAssignRef: _j - }; - } return _j; }, - sortBy(_p?: SortBy, isNode?: boolean): SortBy | { - SortBy: SortBy; - } { + sortBy(_p?: SortBy): SortBy { const _j = {} as SortBy; _o.set(_j, "node", _p?.node); _o.set(_j, "sortby_dir", _p?.sortby_dir); _o.set(_j, "sortby_nulls", _p?.sortby_nulls); _o.set(_j, "useOp", _p?.useOp); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SortBy: _j - }; - } return _j; }, - windowDef(_p?: WindowDef, isNode?: boolean): WindowDef | { - WindowDef: WindowDef; - } { + windowDef(_p?: WindowDef): WindowDef { const _j = {} as WindowDef; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1394,30 +818,16 @@ export default { _o.set(_j, "startOffset", _p?.startOffset); _o.set(_j, "endOffset", _p?.endOffset); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowDef: _j - }; - } return _j; }, - rangeSubselect(_p?: RangeSubselect, isNode?: boolean): RangeSubselect | { - RangeSubselect: RangeSubselect; - } { + rangeSubselect(_p?: RangeSubselect): RangeSubselect { const _j = {} as RangeSubselect; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "subquery", _p?.subquery); _o.set(_j, "alias", _p?.alias); - if (isNode) { - return { - RangeSubselect: _j - }; - } return _j; }, - rangeFunction(_p?: RangeFunction, isNode?: boolean): RangeFunction | { - RangeFunction: RangeFunction; - } { + rangeFunction(_p?: RangeFunction): RangeFunction { const _j = {} as RangeFunction; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "ordinality", _p?.ordinality); @@ -1425,16 +835,9 @@ export default { _o.set(_j, "functions", _p?.functions); _o.set(_j, "alias", _p?.alias); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - RangeFunction: _j - }; - } return _j; }, - rangeTableFunc(_p?: RangeTableFunc, isNode?: boolean): RangeTableFunc | { - RangeTableFunc: RangeTableFunc; - } { + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { const _j = {} as RangeTableFunc; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "docexpr", _p?.docexpr); @@ -1443,16 +846,9 @@ export default { _o.set(_j, "columns", _p?.columns); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFunc: _j - }; - } return _j; }, - rangeTableFuncCol(_p?: RangeTableFuncCol, isNode?: boolean): RangeTableFuncCol | { - RangeTableFuncCol: RangeTableFuncCol; - } { + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { const _j = {} as RangeTableFuncCol; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1461,32 +857,18 @@ export default { _o.set(_j, "colexpr", _p?.colexpr); _o.set(_j, "coldefexpr", _p?.coldefexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFuncCol: _j - }; - } return _j; }, - rangeTableSample(_p?: RangeTableSample, isNode?: boolean): RangeTableSample | { - RangeTableSample: RangeTableSample; - } { + rangeTableSample(_p?: RangeTableSample): RangeTableSample { const _j = {} as RangeTableSample; _o.set(_j, "relation", _p?.relation); _o.set(_j, "method", _p?.method); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableSample: _j - }; - } return _j; }, - columnDef(_p?: ColumnDef, isNode?: boolean): ColumnDef | { - ColumnDef: ColumnDef; - } { + columnDef(_p?: ColumnDef): ColumnDef { const _j = {} as ColumnDef; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1507,30 +889,16 @@ export default { _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "fdwoptions", _p?.fdwoptions); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnDef: _j - }; - } return _j; }, - tableLikeClause(_p?: TableLikeClause, isNode?: boolean): TableLikeClause | { - TableLikeClause: TableLikeClause; - } { + tableLikeClause(_p?: TableLikeClause): TableLikeClause { const _j = {} as TableLikeClause; _o.set(_j, "relation", _p?.relation); _o.set(_j, "options", _p?.options); _o.set(_j, "relationOid", _p?.relationOid); - if (isNode) { - return { - TableLikeClause: _j - }; - } return _j; }, - indexElem(_p?: IndexElem, isNode?: boolean): IndexElem | { - IndexElem: IndexElem; - } { + indexElem(_p?: IndexElem): IndexElem { const _j = {} as IndexElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); @@ -1540,92 +908,50 @@ export default { _o.set(_j, "opclassopts", _p?.opclassopts); _o.set(_j, "ordering", _p?.ordering); _o.set(_j, "nulls_ordering", _p?.nulls_ordering); - if (isNode) { - return { - IndexElem: _j - }; - } return _j; }, - defElem(_p?: DefElem, isNode?: boolean): DefElem | { - DefElem: DefElem; - } { + defElem(_p?: DefElem): DefElem { const _j = {} as DefElem; _o.set(_j, "defnamespace", _p?.defnamespace); _o.set(_j, "defname", _p?.defname); _o.set(_j, "arg", _p?.arg); _o.set(_j, "defaction", _p?.defaction); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DefElem: _j - }; - } return _j; }, - lockingClause(_p?: LockingClause, isNode?: boolean): LockingClause | { - LockingClause: LockingClause; - } { + lockingClause(_p?: LockingClause): LockingClause { const _j = {} as LockingClause; _o.set(_j, "lockedRels", _p?.lockedRels); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); - if (isNode) { - return { - LockingClause: _j - }; - } return _j; }, - xmlSerialize(_p?: XmlSerialize, isNode?: boolean): XmlSerialize | { - XmlSerialize: XmlSerialize; - } { + xmlSerialize(_p?: XmlSerialize): XmlSerialize { const _j = {} as XmlSerialize; _o.set(_j, "xmloption", _p?.xmloption); _o.set(_j, "expr", _p?.expr); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "indent", _p?.indent); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlSerialize: _j - }; - } return _j; }, - partitionElem(_p?: PartitionElem, isNode?: boolean): PartitionElem | { - PartitionElem: PartitionElem; - } { + partitionElem(_p?: PartitionElem): PartitionElem { const _j = {} as PartitionElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); _o.set(_j, "collation", _p?.collation); _o.set(_j, "opclass", _p?.opclass); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionElem: _j - }; - } return _j; }, - partitionSpec(_p?: PartitionSpec, isNode?: boolean): PartitionSpec | { - PartitionSpec: PartitionSpec; - } { + partitionSpec(_p?: PartitionSpec): PartitionSpec { const _j = {} as PartitionSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "partParams", _p?.partParams); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionSpec: _j - }; - } return _j; }, - partitionBoundSpec(_p?: PartitionBoundSpec, isNode?: boolean): PartitionBoundSpec | { - PartitionBoundSpec: PartitionBoundSpec; - } { + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { const _j = {} as PartitionBoundSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "is_default", _p?.is_default); @@ -1635,44 +961,23 @@ export default { _o.set(_j, "lowerdatums", _p?.lowerdatums); _o.set(_j, "upperdatums", _p?.upperdatums); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionBoundSpec: _j - }; - } return _j; }, - partitionRangeDatum(_p?: PartitionRangeDatum, isNode?: boolean): PartitionRangeDatum | { - PartitionRangeDatum: PartitionRangeDatum; - } { + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { const _j = {} as PartitionRangeDatum; _o.set(_j, "kind", _p?.kind); _o.set(_j, "value", _p?.value); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionRangeDatum: _j - }; - } return _j; }, - partitionCmd(_p?: PartitionCmd, isNode?: boolean): PartitionCmd | { - PartitionCmd: PartitionCmd; - } { + partitionCmd(_p?: PartitionCmd): PartitionCmd { const _j = {} as PartitionCmd; _o.set(_j, "name", _p?.name); _o.set(_j, "bound", _p?.bound); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - PartitionCmd: _j - }; - } return _j; }, - rangeTblEntry(_p?: RangeTblEntry, isNode?: boolean): RangeTblEntry | { - RangeTblEntry: RangeTblEntry; - } { + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { const _j = {} as RangeTblEntry; _o.set(_j, "rtekind", _p?.rtekind); _o.set(_j, "relid", _p?.relid); @@ -1706,16 +1011,9 @@ export default { _o.set(_j, "inh", _p?.inh); _o.set(_j, "inFromCl", _p?.inFromCl); _o.set(_j, "securityQuals", _p?.securityQuals); - if (isNode) { - return { - RangeTblEntry: _j - }; - } return _j; }, - rtePermissionInfo(_p?: RTEPermissionInfo, isNode?: boolean): RTEPermissionInfo | { - RTEPermissionInfo: RTEPermissionInfo; - } { + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { const _j = {} as RTEPermissionInfo; _o.set(_j, "relid", _p?.relid); _o.set(_j, "inh", _p?.inh); @@ -1724,16 +1022,9 @@ export default { _o.set(_j, "selectedCols", _p?.selectedCols); _o.set(_j, "insertedCols", _p?.insertedCols); _o.set(_j, "updatedCols", _p?.updatedCols); - if (isNode) { - return { - RTEPermissionInfo: _j - }; - } return _j; }, - rangeTblFunction(_p?: RangeTblFunction, isNode?: boolean): RangeTblFunction | { - RangeTblFunction: RangeTblFunction; - } { + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { const _j = {} as RangeTblFunction; _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "funccolcount", _p?.funccolcount); @@ -1742,76 +1033,41 @@ export default { _o.set(_j, "funccoltypmods", _p?.funccoltypmods); _o.set(_j, "funccolcollations", _p?.funccolcollations); _o.set(_j, "funcparams", _p?.funcparams); - if (isNode) { - return { - RangeTblFunction: _j - }; - } return _j; }, - tableSampleClause(_p?: TableSampleClause, isNode?: boolean): TableSampleClause | { - TableSampleClause: TableSampleClause; - } { + tableSampleClause(_p?: TableSampleClause): TableSampleClause { const _j = {} as TableSampleClause; _o.set(_j, "tsmhandler", _p?.tsmhandler); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); - if (isNode) { - return { - TableSampleClause: _j - }; - } return _j; }, - withCheckOption(_p?: WithCheckOption, isNode?: boolean): WithCheckOption | { - WithCheckOption: WithCheckOption; - } { + withCheckOption(_p?: WithCheckOption): WithCheckOption { const _j = {} as WithCheckOption; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relname", _p?.relname); _o.set(_j, "polname", _p?.polname); _o.set(_j, "qual", _p?.qual); _o.set(_j, "cascaded", _p?.cascaded); - if (isNode) { - return { - WithCheckOption: _j - }; - } return _j; }, - sortGroupClause(_p?: SortGroupClause, isNode?: boolean): SortGroupClause | { - SortGroupClause: SortGroupClause; - } { + sortGroupClause(_p?: SortGroupClause): SortGroupClause { const _j = {} as SortGroupClause; _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); _o.set(_j, "eqop", _p?.eqop); _o.set(_j, "sortop", _p?.sortop); _o.set(_j, "nulls_first", _p?.nulls_first); _o.set(_j, "hashable", _p?.hashable); - if (isNode) { - return { - SortGroupClause: _j - }; - } return _j; }, - groupingSet(_p?: GroupingSet, isNode?: boolean): GroupingSet | { - GroupingSet: GroupingSet; - } { + groupingSet(_p?: GroupingSet): GroupingSet { const _j = {} as GroupingSet; _o.set(_j, "kind", _p?.kind); _o.set(_j, "content", _p?.content); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingSet: _j - }; - } return _j; }, - windowClause(_p?: WindowClause, isNode?: boolean): WindowClause | { - WindowClause: WindowClause; - } { + windowClause(_p?: WindowClause): WindowClause { const _j = {} as WindowClause; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1828,91 +1084,49 @@ export default { _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); _o.set(_j, "winref", _p?.winref); _o.set(_j, "copiedOrder", _p?.copiedOrder); - if (isNode) { - return { - WindowClause: _j - }; - } return _j; }, - rowMarkClause(_p?: RowMarkClause, isNode?: boolean): RowMarkClause | { - RowMarkClause: RowMarkClause; - } { + rowMarkClause(_p?: RowMarkClause): RowMarkClause { const _j = {} as RowMarkClause; _o.set(_j, "rti", _p?.rti); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); _o.set(_j, "pushedDown", _p?.pushedDown); - if (isNode) { - return { - RowMarkClause: _j - }; - } return _j; }, - withClause(_p?: WithClause, isNode?: boolean): WithClause | { - WithClause: WithClause; - } { + withClause(_p?: WithClause): WithClause { const _j = {} as WithClause; _o.set(_j, "ctes", _p?.ctes); _o.set(_j, "recursive", _p?.recursive); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WithClause: _j - }; - } return _j; }, - inferClause(_p?: InferClause, isNode?: boolean): InferClause | { - InferClause: InferClause; - } { + inferClause(_p?: InferClause): InferClause { const _j = {} as InferClause; _o.set(_j, "indexElems", _p?.indexElems); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "conname", _p?.conname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - InferClause: _j - }; - } return _j; }, - onConflictClause(_p?: OnConflictClause, isNode?: boolean): OnConflictClause | { - OnConflictClause: OnConflictClause; - } { + onConflictClause(_p?: OnConflictClause): OnConflictClause { const _j = {} as OnConflictClause; _o.set(_j, "action", _p?.action); _o.set(_j, "infer", _p?.infer); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OnConflictClause: _j - }; - } return _j; }, - cteSearchClause(_p?: CTESearchClause, isNode?: boolean): CTESearchClause | { - CTESearchClause: CTESearchClause; - } { + cteSearchClause(_p?: CTESearchClause): CTESearchClause { const _j = {} as CTESearchClause; _o.set(_j, "search_col_list", _p?.search_col_list); _o.set(_j, "search_breadth_first", _p?.search_breadth_first); _o.set(_j, "search_seq_column", _p?.search_seq_column); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CTESearchClause: _j - }; - } return _j; }, - cteCycleClause(_p?: CTECycleClause, isNode?: boolean): CTECycleClause | { - CTECycleClause: CTECycleClause; - } { + cteCycleClause(_p?: CTECycleClause): CTECycleClause { const _j = {} as CTECycleClause; _o.set(_j, "cycle_col_list", _p?.cycle_col_list); _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); @@ -1924,16 +1138,9 @@ export default { _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); - if (isNode) { - return { - CTECycleClause: _j - }; - } return _j; }, - commonTableExpr(_p?: CommonTableExpr, isNode?: boolean): CommonTableExpr | { - CommonTableExpr: CommonTableExpr; - } { + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { const _j = {} as CommonTableExpr; _o.set(_j, "ctename", _p?.ctename); _o.set(_j, "aliascolnames", _p?.aliascolnames); @@ -1948,16 +1155,9 @@ export default { _o.set(_j, "ctecoltypes", _p?.ctecoltypes); _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); _o.set(_j, "ctecolcollations", _p?.ctecolcollations); - if (isNode) { - return { - CommonTableExpr: _j - }; - } return _j; }, - mergeWhenClause(_p?: MergeWhenClause, isNode?: boolean): MergeWhenClause | { - MergeWhenClause: MergeWhenClause; - } { + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { const _j = {} as MergeWhenClause; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -1965,16 +1165,9 @@ export default { _o.set(_j, "condition", _p?.condition); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "values", _p?.values); - if (isNode) { - return { - MergeWhenClause: _j - }; - } return _j; }, - mergeAction(_p?: MergeAction, isNode?: boolean): MergeAction | { - MergeAction: MergeAction; - } { + mergeAction(_p?: MergeAction): MergeAction { const _j = {} as MergeAction; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -1982,162 +1175,85 @@ export default { _o.set(_j, "qual", _p?.qual); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "updateColnos", _p?.updateColnos); - if (isNode) { - return { - MergeAction: _j - }; - } return _j; }, - triggerTransition(_p?: TriggerTransition, isNode?: boolean): TriggerTransition | { - TriggerTransition: TriggerTransition; - } { + triggerTransition(_p?: TriggerTransition): TriggerTransition { const _j = {} as TriggerTransition; _o.set(_j, "name", _p?.name); _o.set(_j, "isNew", _p?.isNew); _o.set(_j, "isTable", _p?.isTable); - if (isNode) { - return { - TriggerTransition: _j - }; - } return _j; }, - jsonOutput(_p?: JsonOutput, isNode?: boolean): JsonOutput | { - JsonOutput: JsonOutput; - } { + jsonOutput(_p?: JsonOutput): JsonOutput { const _j = {} as JsonOutput; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "returning", _p?.returning); - if (isNode) { - return { - JsonOutput: _j - }; - } return _j; }, - jsonKeyValue(_p?: JsonKeyValue, isNode?: boolean): JsonKeyValue | { - JsonKeyValue: JsonKeyValue; - } { + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { const _j = {} as JsonKeyValue; _o.set(_j, "key", _p?.key); _o.set(_j, "value", _p?.value); - if (isNode) { - return { - JsonKeyValue: _j - }; - } return _j; }, - jsonObjectConstructor(_p?: JsonObjectConstructor, isNode?: boolean): JsonObjectConstructor | { - JsonObjectConstructor: JsonObjectConstructor; - } { + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { const _j = {} as JsonObjectConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonObjectConstructor: _j - }; - } return _j; }, - jsonArrayConstructor(_p?: JsonArrayConstructor, isNode?: boolean): JsonArrayConstructor | { - JsonArrayConstructor: JsonArrayConstructor; - } { + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { const _j = {} as JsonArrayConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayConstructor: _j - }; - } return _j; }, - jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor, isNode?: boolean): JsonArrayQueryConstructor | { - JsonArrayQueryConstructor: JsonArrayQueryConstructor; - } { + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { const _j = {} as JsonArrayQueryConstructor; _o.set(_j, "query", _p?.query); _o.set(_j, "output", _p?.output); _o.set(_j, "format", _p?.format); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayQueryConstructor: _j - }; - } return _j; }, - jsonAggConstructor(_p?: JsonAggConstructor, isNode?: boolean): JsonAggConstructor | { - JsonAggConstructor: JsonAggConstructor; - } { + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { const _j = {} as JsonAggConstructor; _o.set(_j, "output", _p?.output); _o.set(_j, "agg_filter", _p?.agg_filter); _o.set(_j, "agg_order", _p?.agg_order); _o.set(_j, "over", _p?.over); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonAggConstructor: _j - }; - } return _j; }, - jsonObjectAgg(_p?: JsonObjectAgg, isNode?: boolean): JsonObjectAgg | { - JsonObjectAgg: JsonObjectAgg; - } { + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { const _j = {} as JsonObjectAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); - if (isNode) { - return { - JsonObjectAgg: _j - }; - } return _j; }, - jsonArrayAgg(_p?: JsonArrayAgg, isNode?: boolean): JsonArrayAgg | { - JsonArrayAgg: JsonArrayAgg; - } { + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { const _j = {} as JsonArrayAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); - if (isNode) { - return { - JsonArrayAgg: _j - }; - } return _j; }, - rawStmt(_p?: RawStmt, isNode?: boolean): RawStmt | { - RawStmt: RawStmt; - } { + rawStmt(_p?: RawStmt): RawStmt { const _j = {} as RawStmt; _o.set(_j, "stmt", _p?.stmt); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - RawStmt: _j - }; - } return _j; }, - insertStmt(_p?: InsertStmt, isNode?: boolean): InsertStmt | { - InsertStmt: InsertStmt; - } { + insertStmt(_p?: InsertStmt): InsertStmt { const _j = {} as InsertStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cols", _p?.cols); @@ -2146,32 +1262,18 @@ export default { _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); _o.set(_j, "override", _p?.override); - if (isNode) { - return { - InsertStmt: _j - }; - } return _j; }, - deleteStmt(_p?: DeleteStmt, isNode?: boolean): DeleteStmt | { - DeleteStmt: DeleteStmt; - } { + deleteStmt(_p?: DeleteStmt): DeleteStmt { const _j = {} as DeleteStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "usingClause", _p?.usingClause); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - DeleteStmt: _j - }; - } return _j; }, - updateStmt(_p?: UpdateStmt, isNode?: boolean): UpdateStmt | { - UpdateStmt: UpdateStmt; - } { + updateStmt(_p?: UpdateStmt): UpdateStmt { const _j = {} as UpdateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "targetList", _p?.targetList); @@ -2179,32 +1281,18 @@ export default { _o.set(_j, "fromClause", _p?.fromClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - UpdateStmt: _j - }; - } return _j; }, - mergeStmt(_p?: MergeStmt, isNode?: boolean): MergeStmt | { - MergeStmt: MergeStmt; - } { + mergeStmt(_p?: MergeStmt): MergeStmt { const _j = {} as MergeStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "sourceRelation", _p?.sourceRelation); _o.set(_j, "joinCondition", _p?.joinCondition); _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - MergeStmt: _j - }; - } return _j; }, - selectStmt(_p?: SelectStmt, isNode?: boolean): SelectStmt | { - SelectStmt: SelectStmt; - } { + selectStmt(_p?: SelectStmt): SelectStmt { const _j = {} as SelectStmt; _o.set(_j, "distinctClause", _p?.distinctClause); _o.set(_j, "intoClause", _p?.intoClause); @@ -2226,16 +1314,9 @@ export default { _o.set(_j, "all", _p?.all); _o.set(_j, "larg", _p?.larg); _o.set(_j, "rarg", _p?.rarg); - if (isNode) { - return { - SelectStmt: _j - }; - } return _j; }, - setOperationStmt(_p?: SetOperationStmt, isNode?: boolean): SetOperationStmt | { - SetOperationStmt: SetOperationStmt; - } { + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { const _j = {} as SetOperationStmt; _o.set(_j, "op", _p?.op); _o.set(_j, "all", _p?.all); @@ -2245,87 +1326,45 @@ export default { _o.set(_j, "colTypmods", _p?.colTypmods); _o.set(_j, "colCollations", _p?.colCollations); _o.set(_j, "groupClauses", _p?.groupClauses); - if (isNode) { - return { - SetOperationStmt: _j - }; - } return _j; }, - returnStmt(_p?: ReturnStmt, isNode?: boolean): ReturnStmt | { - ReturnStmt: ReturnStmt; - } { + returnStmt(_p?: ReturnStmt): ReturnStmt { const _j = {} as ReturnStmt; _o.set(_j, "returnval", _p?.returnval); - if (isNode) { - return { - ReturnStmt: _j - }; - } return _j; }, - plAssignStmt(_p?: PLAssignStmt, isNode?: boolean): PLAssignStmt | { - PLAssignStmt: PLAssignStmt; - } { + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { const _j = {} as PLAssignStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "nnames", _p?.nnames); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PLAssignStmt: _j - }; - } return _j; }, - createSchemaStmt(_p?: CreateSchemaStmt, isNode?: boolean): CreateSchemaStmt | { - CreateSchemaStmt: CreateSchemaStmt; - } { + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { const _j = {} as CreateSchemaStmt; _o.set(_j, "schemaname", _p?.schemaname); _o.set(_j, "authrole", _p?.authrole); _o.set(_j, "schemaElts", _p?.schemaElts); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSchemaStmt: _j - }; - } return _j; }, - alterTableStmt(_p?: AlterTableStmt, isNode?: boolean): AlterTableStmt | { - AlterTableStmt: AlterTableStmt; - } { + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { const _j = {} as AlterTableStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cmds", _p?.cmds); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTableStmt: _j - }; - } return _j; }, - replicaIdentityStmt(_p?: ReplicaIdentityStmt, isNode?: boolean): ReplicaIdentityStmt | { - ReplicaIdentityStmt: ReplicaIdentityStmt; - } { + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { const _j = {} as ReplicaIdentityStmt; _o.set(_j, "identity_type", _p?.identity_type); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - ReplicaIdentityStmt: _j - }; - } return _j; }, - alterTableCmd(_p?: AlterTableCmd, isNode?: boolean): AlterTableCmd | { - AlterTableCmd: AlterTableCmd; - } { + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { const _j = {} as AlterTableCmd; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "name", _p?.name); @@ -2335,28 +1374,14 @@ export default { _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "recurse", _p?.recurse); - if (isNode) { - return { - AlterTableCmd: _j - }; - } return _j; }, - alterCollationStmt(_p?: AlterCollationStmt, isNode?: boolean): AlterCollationStmt | { - AlterCollationStmt: AlterCollationStmt; - } { + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { const _j = {} as AlterCollationStmt; _o.set(_j, "collname", _p?.collname); - if (isNode) { - return { - AlterCollationStmt: _j - }; - } return _j; }, - alterDomainStmt(_p?: AlterDomainStmt, isNode?: boolean): AlterDomainStmt | { - AlterDomainStmt: AlterDomainStmt; - } { + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { const _j = {} as AlterDomainStmt; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "typeName", _p?.typeName); @@ -2364,16 +1389,9 @@ export default { _o.set(_j, "def", _p?.def); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterDomainStmt: _j - }; - } return _j; }, - grantStmt(_p?: GrantStmt, isNode?: boolean): GrantStmt | { - GrantStmt: GrantStmt; - } { + grantStmt(_p?: GrantStmt): GrantStmt { const _j = {} as GrantStmt; _o.set(_j, "is_grant", _p?.is_grant); _o.set(_j, "targtype", _p?.targtype); @@ -2384,44 +1402,23 @@ export default { _o.set(_j, "grant_option", _p?.grant_option); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantStmt: _j - }; - } return _j; }, - objectWithArgs(_p?: ObjectWithArgs, isNode?: boolean): ObjectWithArgs | { - ObjectWithArgs: ObjectWithArgs; - } { + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { const _j = {} as ObjectWithArgs; _o.set(_j, "objname", _p?.objname); _o.set(_j, "objargs", _p?.objargs); _o.set(_j, "objfuncargs", _p?.objfuncargs); _o.set(_j, "args_unspecified", _p?.args_unspecified); - if (isNode) { - return { - ObjectWithArgs: _j - }; - } return _j; }, - accessPriv(_p?: AccessPriv, isNode?: boolean): AccessPriv | { - AccessPriv: AccessPriv; - } { + accessPriv(_p?: AccessPriv): AccessPriv { const _j = {} as AccessPriv; _o.set(_j, "priv_name", _p?.priv_name); _o.set(_j, "cols", _p?.cols); - if (isNode) { - return { - AccessPriv: _j - }; - } return _j; }, - grantRoleStmt(_p?: GrantRoleStmt, isNode?: boolean): GrantRoleStmt | { - GrantRoleStmt: GrantRoleStmt; - } { + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { const _j = {} as GrantRoleStmt; _o.set(_j, "granted_roles", _p?.granted_roles); _o.set(_j, "grantee_roles", _p?.grantee_roles); @@ -2429,29 +1426,15 @@ export default { _o.set(_j, "opt", _p?.opt); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantRoleStmt: _j - }; - } return _j; }, - alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt, isNode?: boolean): AlterDefaultPrivilegesStmt | { - AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; - } { + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { const _j = {} as AlterDefaultPrivilegesStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterDefaultPrivilegesStmt: _j - }; - } return _j; }, - copyStmt(_p?: CopyStmt, isNode?: boolean): CopyStmt | { - CopyStmt: CopyStmt; - } { + copyStmt(_p?: CopyStmt): CopyStmt { const _j = {} as CopyStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "query", _p?.query); @@ -2461,43 +1444,22 @@ export default { _o.set(_j, "filename", _p?.filename); _o.set(_j, "options", _p?.options); _o.set(_j, "whereClause", _p?.whereClause); - if (isNode) { - return { - CopyStmt: _j - }; - } return _j; }, - variableSetStmt(_p?: VariableSetStmt, isNode?: boolean): VariableSetStmt | { - VariableSetStmt: VariableSetStmt; - } { + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { const _j = {} as VariableSetStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "args", _p?.args); _o.set(_j, "is_local", _p?.is_local); - if (isNode) { - return { - VariableSetStmt: _j - }; - } return _j; }, - variableShowStmt(_p?: VariableShowStmt, isNode?: boolean): VariableShowStmt | { - VariableShowStmt: VariableShowStmt; - } { + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { const _j = {} as VariableShowStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - VariableShowStmt: _j - }; - } return _j; }, - createStmt(_p?: CreateStmt, isNode?: boolean): CreateStmt | { - CreateStmt: CreateStmt; - } { + createStmt(_p?: CreateStmt): CreateStmt { const _j = {} as CreateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "tableElts", _p?.tableElts); @@ -2511,16 +1473,9 @@ export default { _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "accessMethod", _p?.accessMethod); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStmt: _j - }; - } return _j; }, - constraint(_p?: Constraint, isNode?: boolean): Constraint | { - Constraint: Constraint; - } { + constraint(_p?: Constraint): Constraint { const _j = {} as Constraint; _o.set(_j, "contype", _p?.contype); _o.set(_j, "conname", _p?.conname); @@ -2552,144 +1507,74 @@ export default { _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); _o.set(_j, "skip_validation", _p?.skip_validation); _o.set(_j, "initially_valid", _p?.initially_valid); - if (isNode) { - return { - Constraint: _j - }; - } return _j; }, - createTableSpaceStmt(_p?: CreateTableSpaceStmt, isNode?: boolean): CreateTableSpaceStmt | { - CreateTableSpaceStmt: CreateTableSpaceStmt; - } { + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { const _j = {} as CreateTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "owner", _p?.owner); _o.set(_j, "location", _p?.location); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateTableSpaceStmt: _j - }; - } return _j; }, - dropTableSpaceStmt(_p?: DropTableSpaceStmt, isNode?: boolean): DropTableSpaceStmt | { - DropTableSpaceStmt: DropTableSpaceStmt; - } { + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { const _j = {} as DropTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropTableSpaceStmt: _j - }; - } return _j; }, - alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt, isNode?: boolean): AlterTableSpaceOptionsStmt | { - AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; - } { + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { const _j = {} as AlterTableSpaceOptionsStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "options", _p?.options); _o.set(_j, "isReset", _p?.isReset); - if (isNode) { - return { - AlterTableSpaceOptionsStmt: _j - }; - } return _j; }, - alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt, isNode?: boolean): AlterTableMoveAllStmt | { - AlterTableMoveAllStmt: AlterTableMoveAllStmt; - } { + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { const _j = {} as AlterTableMoveAllStmt; _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "roles", _p?.roles); _o.set(_j, "new_tablespacename", _p?.new_tablespacename); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - AlterTableMoveAllStmt: _j - }; - } return _j; }, - createExtensionStmt(_p?: CreateExtensionStmt, isNode?: boolean): CreateExtensionStmt | { - CreateExtensionStmt: CreateExtensionStmt; - } { + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { const _j = {} as CreateExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateExtensionStmt: _j - }; - } return _j; }, - alterExtensionStmt(_p?: AlterExtensionStmt, isNode?: boolean): AlterExtensionStmt | { - AlterExtensionStmt: AlterExtensionStmt; - } { + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { const _j = {} as AlterExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterExtensionStmt: _j - }; - } return _j; }, - alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt, isNode?: boolean): AlterExtensionContentsStmt | { - AlterExtensionContentsStmt: AlterExtensionContentsStmt; - } { + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { const _j = {} as AlterExtensionContentsStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "action", _p?.action); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); - if (isNode) { - return { - AlterExtensionContentsStmt: _j - }; - } return _j; }, - createFdwStmt(_p?: CreateFdwStmt, isNode?: boolean): CreateFdwStmt | { - CreateFdwStmt: CreateFdwStmt; - } { + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { const _j = {} as CreateFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateFdwStmt: _j - }; - } return _j; }, - alterFdwStmt(_p?: AlterFdwStmt, isNode?: boolean): AlterFdwStmt | { - AlterFdwStmt: AlterFdwStmt; - } { + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { const _j = {} as AlterFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterFdwStmt: _j - }; - } return _j; }, - createForeignServerStmt(_p?: CreateForeignServerStmt, isNode?: boolean): CreateForeignServerStmt | { - CreateForeignServerStmt: CreateForeignServerStmt; - } { + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { const _j = {} as CreateForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "servertype", _p?.servertype); @@ -2697,88 +1582,46 @@ export default { _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignServerStmt: _j - }; - } return _j; }, - alterForeignServerStmt(_p?: AlterForeignServerStmt, isNode?: boolean): AlterForeignServerStmt | { - AlterForeignServerStmt: AlterForeignServerStmt; - } { + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { const _j = {} as AlterForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "version", _p?.version); _o.set(_j, "options", _p?.options); _o.set(_j, "has_version", _p?.has_version); - if (isNode) { - return { - AlterForeignServerStmt: _j - }; - } return _j; }, - createForeignTableStmt(_p?: CreateForeignTableStmt, isNode?: boolean): CreateForeignTableStmt | { - CreateForeignTableStmt: CreateForeignTableStmt; - } { + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { const _j = {} as CreateForeignTableStmt; _o.set(_j, "base", _p?.base); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignTableStmt: _j - }; - } return _j; }, - createUserMappingStmt(_p?: CreateUserMappingStmt, isNode?: boolean): CreateUserMappingStmt | { - CreateUserMappingStmt: CreateUserMappingStmt; - } { + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { const _j = {} as CreateUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateUserMappingStmt: _j - }; - } return _j; }, - alterUserMappingStmt(_p?: AlterUserMappingStmt, isNode?: boolean): AlterUserMappingStmt | { - AlterUserMappingStmt: AlterUserMappingStmt; - } { + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { const _j = {} as AlterUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterUserMappingStmt: _j - }; - } return _j; }, - dropUserMappingStmt(_p?: DropUserMappingStmt, isNode?: boolean): DropUserMappingStmt | { - DropUserMappingStmt: DropUserMappingStmt; - } { + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { const _j = {} as DropUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropUserMappingStmt: _j - }; - } return _j; }, - importForeignSchemaStmt(_p?: ImportForeignSchemaStmt, isNode?: boolean): ImportForeignSchemaStmt | { - ImportForeignSchemaStmt: ImportForeignSchemaStmt; - } { + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { const _j = {} as ImportForeignSchemaStmt; _o.set(_j, "server_name", _p?.server_name); _o.set(_j, "remote_schema", _p?.remote_schema); @@ -2786,16 +1629,9 @@ export default { _o.set(_j, "list_type", _p?.list_type); _o.set(_j, "table_list", _p?.table_list); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ImportForeignSchemaStmt: _j - }; - } return _j; }, - createPolicyStmt(_p?: CreatePolicyStmt, isNode?: boolean): CreatePolicyStmt | { - CreatePolicyStmt: CreatePolicyStmt; - } { + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { const _j = {} as CreatePolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); @@ -2804,46 +1640,25 @@ export default { _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - CreatePolicyStmt: _j - }; - } return _j; }, - alterPolicyStmt(_p?: AlterPolicyStmt, isNode?: boolean): AlterPolicyStmt | { - AlterPolicyStmt: AlterPolicyStmt; - } { + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { const _j = {} as AlterPolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - AlterPolicyStmt: _j - }; - } return _j; }, - createAmStmt(_p?: CreateAmStmt, isNode?: boolean): CreateAmStmt | { - CreateAmStmt: CreateAmStmt; - } { + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { const _j = {} as CreateAmStmt; _o.set(_j, "amname", _p?.amname); _o.set(_j, "handler_name", _p?.handler_name); _o.set(_j, "amtype", _p?.amtype); - if (isNode) { - return { - CreateAmStmt: _j - }; - } return _j; }, - createTrigStmt(_p?: CreateTrigStmt, isNode?: boolean): CreateTrigStmt | { - CreateTrigStmt: CreateTrigStmt; - } { + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { const _j = {} as CreateTrigStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "isconstraint", _p?.isconstraint); @@ -2860,44 +1675,23 @@ export default { _o.set(_j, "deferrable", _p?.deferrable); _o.set(_j, "initdeferred", _p?.initdeferred); _o.set(_j, "constrrel", _p?.constrrel); - if (isNode) { - return { - CreateTrigStmt: _j - }; - } return _j; }, - createEventTrigStmt(_p?: CreateEventTrigStmt, isNode?: boolean): CreateEventTrigStmt | { - CreateEventTrigStmt: CreateEventTrigStmt; - } { + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { const _j = {} as CreateEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "eventname", _p?.eventname); _o.set(_j, "whenclause", _p?.whenclause); _o.set(_j, "funcname", _p?.funcname); - if (isNode) { - return { - CreateEventTrigStmt: _j - }; - } return _j; }, - alterEventTrigStmt(_p?: AlterEventTrigStmt, isNode?: boolean): AlterEventTrigStmt | { - AlterEventTrigStmt: AlterEventTrigStmt; - } { + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { const _j = {} as AlterEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "tgenabled", _p?.tgenabled); - if (isNode) { - return { - AlterEventTrigStmt: _j - }; - } return _j; }, - createpLangStmt(_p?: CreatePLangStmt, isNode?: boolean): CreatePLangStmt | { - CreatePLangStmt: CreatePLangStmt; - } { + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { const _j = {} as CreatePLangStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "plname", _p?.plname); @@ -2905,102 +1699,53 @@ export default { _o.set(_j, "plinline", _p?.plinline); _o.set(_j, "plvalidator", _p?.plvalidator); _o.set(_j, "pltrusted", _p?.pltrusted); - if (isNode) { - return { - CreatePLangStmt: _j - }; - } return _j; }, - createRoleStmt(_p?: CreateRoleStmt, isNode?: boolean): CreateRoleStmt | { - CreateRoleStmt: CreateRoleStmt; - } { + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { const _j = {} as CreateRoleStmt; _o.set(_j, "stmt_type", _p?.stmt_type); _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateRoleStmt: _j - }; - } return _j; }, - alterRoleStmt(_p?: AlterRoleStmt, isNode?: boolean): AlterRoleStmt | { - AlterRoleStmt: AlterRoleStmt; - } { + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { const _j = {} as AlterRoleStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterRoleStmt: _j - }; - } return _j; }, - alterRoleSetStmt(_p?: AlterRoleSetStmt, isNode?: boolean): AlterRoleSetStmt | { - AlterRoleSetStmt: AlterRoleSetStmt; - } { + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { const _j = {} as AlterRoleSetStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "database", _p?.database); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterRoleSetStmt: _j - }; - } return _j; }, - dropRoleStmt(_p?: DropRoleStmt, isNode?: boolean): DropRoleStmt | { - DropRoleStmt: DropRoleStmt; - } { + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { const _j = {} as DropRoleStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropRoleStmt: _j - }; - } return _j; }, - createSeqStmt(_p?: CreateSeqStmt, isNode?: boolean): CreateSeqStmt | { - CreateSeqStmt: CreateSeqStmt; - } { + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { const _j = {} as CreateSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "ownerId", _p?.ownerId); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSeqStmt: _j - }; - } return _j; }, - alterSeqStmt(_p?: AlterSeqStmt, isNode?: boolean): AlterSeqStmt | { - AlterSeqStmt: AlterSeqStmt; - } { + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { const _j = {} as AlterSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterSeqStmt: _j - }; - } return _j; }, - defineStmt(_p?: DefineStmt, isNode?: boolean): DefineStmt | { - DefineStmt: DefineStmt; - } { + defineStmt(_p?: DefineStmt): DefineStmt { const _j = {} as DefineStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "oldstyle", _p?.oldstyle); @@ -3009,31 +1754,17 @@ export default { _o.set(_j, "definition", _p?.definition); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - DefineStmt: _j - }; - } return _j; }, - createDomainStmt(_p?: CreateDomainStmt, isNode?: boolean): CreateDomainStmt | { - CreateDomainStmt: CreateDomainStmt; - } { + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { const _j = {} as CreateDomainStmt; _o.set(_j, "domainname", _p?.domainname); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "collClause", _p?.collClause); _o.set(_j, "constraints", _p?.constraints); - if (isNode) { - return { - CreateDomainStmt: _j - }; - } return _j; }, - createOpClassStmt(_p?: CreateOpClassStmt, isNode?: boolean): CreateOpClassStmt | { - CreateOpClassStmt: CreateOpClassStmt; - } { + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { const _j = {} as CreateOpClassStmt; _o.set(_j, "opclassname", _p?.opclassname); _o.set(_j, "opfamilyname", _p?.opfamilyname); @@ -3041,16 +1772,9 @@ export default { _o.set(_j, "datatype", _p?.datatype); _o.set(_j, "items", _p?.items); _o.set(_j, "isDefault", _p?.isDefault); - if (isNode) { - return { - CreateOpClassStmt: _j - }; - } return _j; }, - createOpClassItem(_p?: CreateOpClassItem, isNode?: boolean): CreateOpClassItem | { - CreateOpClassItem: CreateOpClassItem; - } { + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { const _j = {} as CreateOpClassItem; _o.set(_j, "itemtype", _p?.itemtype); _o.set(_j, "name", _p?.name); @@ -3058,144 +1782,74 @@ export default { _o.set(_j, "order_family", _p?.order_family); _o.set(_j, "class_args", _p?.class_args); _o.set(_j, "storedtype", _p?.storedtype); - if (isNode) { - return { - CreateOpClassItem: _j - }; - } return _j; }, - createOpFamilyStmt(_p?: CreateOpFamilyStmt, isNode?: boolean): CreateOpFamilyStmt | { - CreateOpFamilyStmt: CreateOpFamilyStmt; - } { + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { const _j = {} as CreateOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); - if (isNode) { - return { - CreateOpFamilyStmt: _j - }; - } return _j; }, - alterOpFamilyStmt(_p?: AlterOpFamilyStmt, isNode?: boolean): AlterOpFamilyStmt | { - AlterOpFamilyStmt: AlterOpFamilyStmt; - } { + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { const _j = {} as AlterOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); _o.set(_j, "isDrop", _p?.isDrop); _o.set(_j, "items", _p?.items); - if (isNode) { - return { - AlterOpFamilyStmt: _j - }; - } return _j; }, - dropStmt(_p?: DropStmt, isNode?: boolean): DropStmt | { - DropStmt: DropStmt; - } { + dropStmt(_p?: DropStmt): DropStmt { const _j = {} as DropStmt; _o.set(_j, "objects", _p?.objects); _o.set(_j, "removeType", _p?.removeType); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - DropStmt: _j - }; - } return _j; }, - truncateStmt(_p?: TruncateStmt, isNode?: boolean): TruncateStmt | { - TruncateStmt: TruncateStmt; - } { + truncateStmt(_p?: TruncateStmt): TruncateStmt { const _j = {} as TruncateStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "restart_seqs", _p?.restart_seqs); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - TruncateStmt: _j - }; - } return _j; }, - commentStmt(_p?: CommentStmt, isNode?: boolean): CommentStmt | { - CommentStmt: CommentStmt; - } { + commentStmt(_p?: CommentStmt): CommentStmt { const _j = {} as CommentStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "comment", _p?.comment); - if (isNode) { - return { - CommentStmt: _j - }; - } return _j; }, - secLabelStmt(_p?: SecLabelStmt, isNode?: boolean): SecLabelStmt | { - SecLabelStmt: SecLabelStmt; - } { + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { const _j = {} as SecLabelStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "provider", _p?.provider); _o.set(_j, "label", _p?.label); - if (isNode) { - return { - SecLabelStmt: _j - }; - } return _j; }, - declareCursorStmt(_p?: DeclareCursorStmt, isNode?: boolean): DeclareCursorStmt | { - DeclareCursorStmt: DeclareCursorStmt; - } { + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { const _j = {} as DeclareCursorStmt; _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "options", _p?.options); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - DeclareCursorStmt: _j - }; - } return _j; }, - closePortalStmt(_p?: ClosePortalStmt, isNode?: boolean): ClosePortalStmt | { - ClosePortalStmt: ClosePortalStmt; - } { + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { const _j = {} as ClosePortalStmt; _o.set(_j, "portalname", _p?.portalname); - if (isNode) { - return { - ClosePortalStmt: _j - }; - } return _j; }, - fetchStmt(_p?: FetchStmt, isNode?: boolean): FetchStmt | { - FetchStmt: FetchStmt; - } { + fetchStmt(_p?: FetchStmt): FetchStmt { const _j = {} as FetchStmt; _o.set(_j, "direction", _p?.direction); _o.set(_j, "howMany", _p?.howMany); _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "ismove", _p?.ismove); - if (isNode) { - return { - FetchStmt: _j - }; - } return _j; }, - indexStmt(_p?: IndexStmt, isNode?: boolean): IndexStmt | { - IndexStmt: IndexStmt; - } { + indexStmt(_p?: IndexStmt): IndexStmt { const _j = {} as IndexStmt; _o.set(_j, "idxname", _p?.idxname); _o.set(_j, "relation", _p?.relation); @@ -3221,16 +1875,9 @@ export default { _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); - if (isNode) { - return { - IndexStmt: _j - }; - } return _j; }, - createStatsStmt(_p?: CreateStatsStmt, isNode?: boolean): CreateStatsStmt | { - CreateStatsStmt: CreateStatsStmt; - } { + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { const _j = {} as CreateStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stat_types", _p?.stat_types); @@ -3239,43 +1886,22 @@ export default { _o.set(_j, "stxcomment", _p?.stxcomment); _o.set(_j, "transformed", _p?.transformed); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStatsStmt: _j - }; - } return _j; }, - statsElem(_p?: StatsElem, isNode?: boolean): StatsElem | { - StatsElem: StatsElem; - } { + statsElem(_p?: StatsElem): StatsElem { const _j = {} as StatsElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); - if (isNode) { - return { - StatsElem: _j - }; - } return _j; }, - alterStatsStmt(_p?: AlterStatsStmt, isNode?: boolean): AlterStatsStmt | { - AlterStatsStmt: AlterStatsStmt; - } { + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { const _j = {} as AlterStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stxstattarget", _p?.stxstattarget); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterStatsStmt: _j - }; - } return _j; }, - createFunctionStmt(_p?: CreateFunctionStmt, isNode?: boolean): CreateFunctionStmt | { - CreateFunctionStmt: CreateFunctionStmt; - } { + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { const _j = {} as CreateFunctionStmt; _o.set(_j, "is_procedure", _p?.is_procedure); _o.set(_j, "replace", _p?.replace); @@ -3284,98 +1910,49 @@ export default { _o.set(_j, "returnType", _p?.returnType); _o.set(_j, "options", _p?.options); _o.set(_j, "sql_body", _p?.sql_body); - if (isNode) { - return { - CreateFunctionStmt: _j - }; - } return _j; }, - functionParameter(_p?: FunctionParameter, isNode?: boolean): FunctionParameter | { - FunctionParameter: FunctionParameter; - } { + functionParameter(_p?: FunctionParameter): FunctionParameter { const _j = {} as FunctionParameter; _o.set(_j, "name", _p?.name); _o.set(_j, "argType", _p?.argType); _o.set(_j, "mode", _p?.mode); _o.set(_j, "defexpr", _p?.defexpr); - if (isNode) { - return { - FunctionParameter: _j - }; - } return _j; }, - alterFunctionStmt(_p?: AlterFunctionStmt, isNode?: boolean): AlterFunctionStmt | { - AlterFunctionStmt: AlterFunctionStmt; - } { + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { const _j = {} as AlterFunctionStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "func", _p?.func); _o.set(_j, "actions", _p?.actions); - if (isNode) { - return { - AlterFunctionStmt: _j - }; - } return _j; }, - doStmt(_p?: DoStmt, isNode?: boolean): DoStmt | { - DoStmt: DoStmt; - } { + doStmt(_p?: DoStmt): DoStmt { const _j = {} as DoStmt; _o.set(_j, "args", _p?.args); - if (isNode) { - return { - DoStmt: _j - }; - } return _j; }, - inlineCodeBlock(_p?: InlineCodeBlock, isNode?: boolean): InlineCodeBlock | { - InlineCodeBlock: InlineCodeBlock; - } { + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { const _j = {} as InlineCodeBlock; _o.set(_j, "source_text", _p?.source_text); _o.set(_j, "langOid", _p?.langOid); _o.set(_j, "langIsTrusted", _p?.langIsTrusted); _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - InlineCodeBlock: _j - }; - } return _j; }, - callStmt(_p?: CallStmt, isNode?: boolean): CallStmt | { - CallStmt: CallStmt; - } { + callStmt(_p?: CallStmt): CallStmt { const _j = {} as CallStmt; _o.set(_j, "funccall", _p?.funccall); _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "outargs", _p?.outargs); - if (isNode) { - return { - CallStmt: _j - }; - } return _j; }, - callContext(_p?: CallContext, isNode?: boolean): CallContext | { - CallContext: CallContext; - } { + callContext(_p?: CallContext): CallContext { const _j = {} as CallContext; _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - CallContext: _j - }; - } return _j; }, - renameStmt(_p?: RenameStmt, isNode?: boolean): RenameStmt | { - RenameStmt: RenameStmt; - } { + renameStmt(_p?: RenameStmt): RenameStmt { const _j = {} as RenameStmt; _o.set(_j, "renameType", _p?.renameType); _o.set(_j, "relationType", _p?.relationType); @@ -3385,89 +1962,47 @@ export default { _o.set(_j, "newname", _p?.newname); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - RenameStmt: _j - }; - } return _j; }, - alterObjectDependsStmt(_p?: AlterObjectDependsStmt, isNode?: boolean): AlterObjectDependsStmt | { - AlterObjectDependsStmt: AlterObjectDependsStmt; - } { + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { const _j = {} as AlterObjectDependsStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "extname", _p?.extname); _o.set(_j, "remove", _p?.remove); - if (isNode) { - return { - AlterObjectDependsStmt: _j - }; - } return _j; }, - alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt, isNode?: boolean): AlterObjectSchemaStmt | { - AlterObjectSchemaStmt: AlterObjectSchemaStmt; - } { + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { const _j = {} as AlterObjectSchemaStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newschema", _p?.newschema); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterObjectSchemaStmt: _j - }; - } return _j; }, - alterOwnerStmt(_p?: AlterOwnerStmt, isNode?: boolean): AlterOwnerStmt | { - AlterOwnerStmt: AlterOwnerStmt; - } { + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { const _j = {} as AlterOwnerStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newowner", _p?.newowner); - if (isNode) { - return { - AlterOwnerStmt: _j - }; - } return _j; }, - alterOperatorStmt(_p?: AlterOperatorStmt, isNode?: boolean): AlterOperatorStmt | { - AlterOperatorStmt: AlterOperatorStmt; - } { + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { const _j = {} as AlterOperatorStmt; _o.set(_j, "opername", _p?.opername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterOperatorStmt: _j - }; - } return _j; }, - alterTypeStmt(_p?: AlterTypeStmt, isNode?: boolean): AlterTypeStmt | { - AlterTypeStmt: AlterTypeStmt; - } { + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { const _j = {} as AlterTypeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTypeStmt: _j - }; - } return _j; }, - ruleStmt(_p?: RuleStmt, isNode?: boolean): RuleStmt | { - RuleStmt: RuleStmt; - } { + ruleStmt(_p?: RuleStmt): RuleStmt { const _j = {} as RuleStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "rulename", _p?.rulename); @@ -3476,108 +2011,52 @@ export default { _o.set(_j, "instead", _p?.instead); _o.set(_j, "actions", _p?.actions); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - RuleStmt: _j - }; - } return _j; }, - notifyStmt(_p?: NotifyStmt, isNode?: boolean): NotifyStmt | { - NotifyStmt: NotifyStmt; - } { + notifyStmt(_p?: NotifyStmt): NotifyStmt { const _j = {} as NotifyStmt; _o.set(_j, "conditionname", _p?.conditionname); _o.set(_j, "payload", _p?.payload); - if (isNode) { - return { - NotifyStmt: _j - }; - } return _j; }, - listenStmt(_p?: ListenStmt, isNode?: boolean): ListenStmt | { - ListenStmt: ListenStmt; - } { + listenStmt(_p?: ListenStmt): ListenStmt { const _j = {} as ListenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - ListenStmt: _j - }; - } return _j; }, - unlistenStmt(_p?: UnlistenStmt, isNode?: boolean): UnlistenStmt | { - UnlistenStmt: UnlistenStmt; - } { + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { const _j = {} as UnlistenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - UnlistenStmt: _j - }; - } return _j; }, - transactionStmt(_p?: TransactionStmt, isNode?: boolean): TransactionStmt | { - TransactionStmt: TransactionStmt; - } { + transactionStmt(_p?: TransactionStmt): TransactionStmt { const _j = {} as TransactionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "options", _p?.options); _o.set(_j, "savepoint_name", _p?.savepoint_name); _o.set(_j, "gid", _p?.gid); _o.set(_j, "chain", _p?.chain); - if (isNode) { - return { - TransactionStmt: _j - }; - } return _j; }, - compositeTypeStmt(_p?: CompositeTypeStmt, isNode?: boolean): CompositeTypeStmt | { - CompositeTypeStmt: CompositeTypeStmt; - } { + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { const _j = {} as CompositeTypeStmt; _o.set(_j, "typevar", _p?.typevar); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - CompositeTypeStmt: _j - }; - } return _j; }, - createEnumStmt(_p?: CreateEnumStmt, isNode?: boolean): CreateEnumStmt | { - CreateEnumStmt: CreateEnumStmt; - } { + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { const _j = {} as CreateEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "vals", _p?.vals); - if (isNode) { - return { - CreateEnumStmt: _j - }; - } return _j; }, - createRangeStmt(_p?: CreateRangeStmt, isNode?: boolean): CreateRangeStmt | { - CreateRangeStmt: CreateRangeStmt; - } { + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { const _j = {} as CreateRangeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - CreateRangeStmt: _j - }; - } return _j; }, - alterEnumStmt(_p?: AlterEnumStmt, isNode?: boolean): AlterEnumStmt | { - AlterEnumStmt: AlterEnumStmt; - } { + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { const _j = {} as AlterEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "oldVal", _p?.oldVal); @@ -3585,16 +2064,9 @@ export default { _o.set(_j, "newValNeighbor", _p?.newValNeighbor); _o.set(_j, "newValIsAfter", _p?.newValIsAfter); _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); - if (isNode) { - return { - AlterEnumStmt: _j - }; - } return _j; }, - viewStmt(_p?: ViewStmt, isNode?: boolean): ViewStmt | { - ViewStmt: ViewStmt; - } { + viewStmt(_p?: ViewStmt): ViewStmt { const _j = {} as ViewStmt; _o.set(_j, "view", _p?.view); _o.set(_j, "aliases", _p?.aliases); @@ -3602,381 +2074,185 @@ export default { _o.set(_j, "replace", _p?.replace); _o.set(_j, "options", _p?.options); _o.set(_j, "withCheckOption", _p?.withCheckOption); - if (isNode) { - return { - ViewStmt: _j - }; - } return _j; }, - loadStmt(_p?: LoadStmt, isNode?: boolean): LoadStmt | { - LoadStmt: LoadStmt; - } { + loadStmt(_p?: LoadStmt): LoadStmt { const _j = {} as LoadStmt; _o.set(_j, "filename", _p?.filename); - if (isNode) { - return { - LoadStmt: _j - }; - } return _j; }, - createdbStmt(_p?: CreatedbStmt, isNode?: boolean): CreatedbStmt | { - CreatedbStmt: CreatedbStmt; - } { + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { const _j = {} as CreatedbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreatedbStmt: _j - }; - } return _j; }, - alterDatabaseStmt(_p?: AlterDatabaseStmt, isNode?: boolean): AlterDatabaseStmt | { - AlterDatabaseStmt: AlterDatabaseStmt; - } { + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { const _j = {} as AlterDatabaseStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterDatabaseStmt: _j - }; - } return _j; }, - alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt, isNode?: boolean): AlterDatabaseRefreshCollStmt | { - AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; - } { + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { const _j = {} as AlterDatabaseRefreshCollStmt; _o.set(_j, "dbname", _p?.dbname); - if (isNode) { - return { - AlterDatabaseRefreshCollStmt: _j - }; - } return _j; }, - alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt, isNode?: boolean): AlterDatabaseSetStmt | { - AlterDatabaseSetStmt: AlterDatabaseSetStmt; - } { + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { const _j = {} as AlterDatabaseSetStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterDatabaseSetStmt: _j - }; - } return _j; }, - dropdbStmt(_p?: DropdbStmt, isNode?: boolean): DropdbStmt | { - DropdbStmt: DropdbStmt; - } { + dropdbStmt(_p?: DropdbStmt): DropdbStmt { const _j = {} as DropdbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - DropdbStmt: _j - }; - } return _j; }, - alterSystemStmt(_p?: AlterSystemStmt, isNode?: boolean): AlterSystemStmt | { - AlterSystemStmt: AlterSystemStmt; - } { + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { const _j = {} as AlterSystemStmt; _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterSystemStmt: _j - }; - } return _j; }, - clusterStmt(_p?: ClusterStmt, isNode?: boolean): ClusterStmt | { - ClusterStmt: ClusterStmt; - } { + clusterStmt(_p?: ClusterStmt): ClusterStmt { const _j = {} as ClusterStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "indexname", _p?.indexname); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ClusterStmt: _j - }; - } return _j; }, - vacuumStmt(_p?: VacuumStmt, isNode?: boolean): VacuumStmt | { - VacuumStmt: VacuumStmt; - } { + vacuumStmt(_p?: VacuumStmt): VacuumStmt { const _j = {} as VacuumStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "rels", _p?.rels); _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); - if (isNode) { - return { - VacuumStmt: _j - }; - } return _j; }, - vacuumRelation(_p?: VacuumRelation, isNode?: boolean): VacuumRelation | { - VacuumRelation: VacuumRelation; - } { + vacuumRelation(_p?: VacuumRelation): VacuumRelation { const _j = {} as VacuumRelation; _o.set(_j, "relation", _p?.relation); _o.set(_j, "oid", _p?.oid); _o.set(_j, "va_cols", _p?.va_cols); - if (isNode) { - return { - VacuumRelation: _j - }; - } return _j; }, - explainStmt(_p?: ExplainStmt, isNode?: boolean): ExplainStmt | { - ExplainStmt: ExplainStmt; - } { + explainStmt(_p?: ExplainStmt): ExplainStmt { const _j = {} as ExplainStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ExplainStmt: _j - }; - } return _j; }, - createTableAsStmt(_p?: CreateTableAsStmt, isNode?: boolean): CreateTableAsStmt | { - CreateTableAsStmt: CreateTableAsStmt; - } { + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { const _j = {} as CreateTableAsStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "into", _p?.into); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "is_select_into", _p?.is_select_into); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateTableAsStmt: _j - }; - } return _j; }, - refreshMatViewStmt(_p?: RefreshMatViewStmt, isNode?: boolean): RefreshMatViewStmt | { - RefreshMatViewStmt: RefreshMatViewStmt; - } { + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { const _j = {} as RefreshMatViewStmt; _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "skipData", _p?.skipData); _o.set(_j, "relation", _p?.relation); - if (isNode) { - return { - RefreshMatViewStmt: _j - }; - } return _j; }, - checkPointStmt(_p?: CheckPointStmt, isNode?: boolean): CheckPointStmt | { - CheckPointStmt: CheckPointStmt; - } { + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { const _j = {} as CheckPointStmt; - if (isNode) { - return { - CheckPointStmt: _j - }; - } return _j; }, - discardStmt(_p?: DiscardStmt, isNode?: boolean): DiscardStmt | { - DiscardStmt: DiscardStmt; - } { + discardStmt(_p?: DiscardStmt): DiscardStmt { const _j = {} as DiscardStmt; _o.set(_j, "target", _p?.target); - if (isNode) { - return { - DiscardStmt: _j - }; - } return _j; }, - lockStmt(_p?: LockStmt, isNode?: boolean): LockStmt | { - LockStmt: LockStmt; - } { + lockStmt(_p?: LockStmt): LockStmt { const _j = {} as LockStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "mode", _p?.mode); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - LockStmt: _j - }; - } return _j; }, - constraintsSetStmt(_p?: ConstraintsSetStmt, isNode?: boolean): ConstraintsSetStmt | { - ConstraintsSetStmt: ConstraintsSetStmt; - } { + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { const _j = {} as ConstraintsSetStmt; _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "deferred", _p?.deferred); - if (isNode) { - return { - ConstraintsSetStmt: _j - }; - } return _j; }, - reindexStmt(_p?: ReindexStmt, isNode?: boolean): ReindexStmt | { - ReindexStmt: ReindexStmt; - } { + reindexStmt(_p?: ReindexStmt): ReindexStmt { const _j = {} as ReindexStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relation", _p?.relation); _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ReindexStmt: _j - }; - } return _j; }, - createConversionStmt(_p?: CreateConversionStmt, isNode?: boolean): CreateConversionStmt | { - CreateConversionStmt: CreateConversionStmt; - } { + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { const _j = {} as CreateConversionStmt; _o.set(_j, "conversion_name", _p?.conversion_name); _o.set(_j, "for_encoding_name", _p?.for_encoding_name); _o.set(_j, "to_encoding_name", _p?.to_encoding_name); _o.set(_j, "func_name", _p?.func_name); _o.set(_j, "def", _p?.def); - if (isNode) { - return { - CreateConversionStmt: _j - }; - } return _j; }, - createCastStmt(_p?: CreateCastStmt, isNode?: boolean): CreateCastStmt | { - CreateCastStmt: CreateCastStmt; - } { + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { const _j = {} as CreateCastStmt; _o.set(_j, "sourcetype", _p?.sourcetype); _o.set(_j, "targettype", _p?.targettype); _o.set(_j, "func", _p?.func); _o.set(_j, "context", _p?.context); _o.set(_j, "inout", _p?.inout); - if (isNode) { - return { - CreateCastStmt: _j - }; - } return _j; }, - createTransformStmt(_p?: CreateTransformStmt, isNode?: boolean): CreateTransformStmt | { - CreateTransformStmt: CreateTransformStmt; - } { + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { const _j = {} as CreateTransformStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "type_name", _p?.type_name); _o.set(_j, "lang", _p?.lang); _o.set(_j, "fromsql", _p?.fromsql); _o.set(_j, "tosql", _p?.tosql); - if (isNode) { - return { - CreateTransformStmt: _j - }; - } return _j; }, - prepareStmt(_p?: PrepareStmt, isNode?: boolean): PrepareStmt | { - PrepareStmt: PrepareStmt; - } { + prepareStmt(_p?: PrepareStmt): PrepareStmt { const _j = {} as PrepareStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "argtypes", _p?.argtypes); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - PrepareStmt: _j - }; - } return _j; }, - executeStmt(_p?: ExecuteStmt, isNode?: boolean): ExecuteStmt | { - ExecuteStmt: ExecuteStmt; - } { + executeStmt(_p?: ExecuteStmt): ExecuteStmt { const _j = {} as ExecuteStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ExecuteStmt: _j - }; - } return _j; }, - deallocateStmt(_p?: DeallocateStmt, isNode?: boolean): DeallocateStmt | { - DeallocateStmt: DeallocateStmt; - } { + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { const _j = {} as DeallocateStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - DeallocateStmt: _j - }; - } return _j; }, - dropOwnedStmt(_p?: DropOwnedStmt, isNode?: boolean): DropOwnedStmt | { - DropOwnedStmt: DropOwnedStmt; - } { + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { const _j = {} as DropOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropOwnedStmt: _j - }; - } return _j; }, - reassignOwnedStmt(_p?: ReassignOwnedStmt, isNode?: boolean): ReassignOwnedStmt | { - ReassignOwnedStmt: ReassignOwnedStmt; - } { + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { const _j = {} as ReassignOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "newrole", _p?.newrole); - if (isNode) { - return { - ReassignOwnedStmt: _j - }; - } return _j; }, - altertsDictionaryStmt(_p?: AlterTSDictionaryStmt, isNode?: boolean): AlterTSDictionaryStmt | { - AlterTSDictionaryStmt: AlterTSDictionaryStmt; - } { + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { const _j = {} as AlterTSDictionaryStmt; _o.set(_j, "dictname", _p?.dictname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTSDictionaryStmt: _j - }; - } return _j; }, - altertsConfigurationStmt(_p?: AlterTSConfigurationStmt, isNode?: boolean): AlterTSConfigurationStmt | { - AlterTSConfigurationStmt: AlterTSConfigurationStmt; - } { + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { const _j = {} as AlterTSConfigurationStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "cfgname", _p?.cfgname); @@ -3985,131 +2261,70 @@ export default { _o.set(_j, "override", _p?.override); _o.set(_j, "replace", _p?.replace); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTSConfigurationStmt: _j - }; - } return _j; }, - publicationTable(_p?: PublicationTable, isNode?: boolean): PublicationTable | { - PublicationTable: PublicationTable; - } { + publicationTable(_p?: PublicationTable): PublicationTable { const _j = {} as PublicationTable; _o.set(_j, "relation", _p?.relation); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "columns", _p?.columns); - if (isNode) { - return { - PublicationTable: _j - }; - } return _j; }, - publicationObjSpec(_p?: PublicationObjSpec, isNode?: boolean): PublicationObjSpec | { - PublicationObjSpec: PublicationObjSpec; - } { + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { const _j = {} as PublicationObjSpec; _o.set(_j, "pubobjtype", _p?.pubobjtype); _o.set(_j, "name", _p?.name); _o.set(_j, "pubtable", _p?.pubtable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PublicationObjSpec: _j - }; - } return _j; }, - createPublicationStmt(_p?: CreatePublicationStmt, isNode?: boolean): CreatePublicationStmt | { - CreatePublicationStmt: CreatePublicationStmt; - } { + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { const _j = {} as CreatePublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); - if (isNode) { - return { - CreatePublicationStmt: _j - }; - } return _j; }, - alterPublicationStmt(_p?: AlterPublicationStmt, isNode?: boolean): AlterPublicationStmt | { - AlterPublicationStmt: AlterPublicationStmt; - } { + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { const _j = {} as AlterPublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterPublicationStmt: _j - }; - } return _j; }, - createSubscriptionStmt(_p?: CreateSubscriptionStmt, isNode?: boolean): CreateSubscriptionStmt | { - CreateSubscriptionStmt: CreateSubscriptionStmt; - } { + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { const _j = {} as CreateSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateSubscriptionStmt: _j - }; - } return _j; }, - alterSubscriptionStmt(_p?: AlterSubscriptionStmt, isNode?: boolean): AlterSubscriptionStmt | { - AlterSubscriptionStmt: AlterSubscriptionStmt; - } { + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { const _j = {} as AlterSubscriptionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterSubscriptionStmt: _j - }; - } return _j; }, - dropSubscriptionStmt(_p?: DropSubscriptionStmt, isNode?: boolean): DropSubscriptionStmt | { - DropSubscriptionStmt: DropSubscriptionStmt; - } { + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { const _j = {} as DropSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropSubscriptionStmt: _j - }; - } return _j; }, - scanToken(_p?: ScanToken, isNode?: boolean): ScanToken | { - ScanToken: ScanToken; - } { + scanToken(_p?: ScanToken): ScanToken { const _j = {} as ScanToken; _o.set(_j, "start", _p?.start); _o.set(_j, "end", _p?.end); _o.set(_j, "token", _p?.token); _o.set(_j, "keywordKind", _p?.keywordKind); - if (isNode) { - return { - ScanToken: _j - }; - } return _j; } }; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/inlineNestedObj/asts.ts b/__fixtures__/output/utils/astHelpers/inlineNestedObj/asts.ts index c13d4197..cba1a5b2 100644 --- a/__fixtures__/output/utils/astHelpers/inlineNestedObj/asts.ts +++ b/__fixtures__/output/utils/astHelpers/inlineNestedObj/asts.ts @@ -6,131 +6,59 @@ import _o from "./path-obj"; import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; export default { - parseResult(_p?: ParseResult, isNode?: boolean): ParseResult | { - ParseResult: ParseResult; - } { + parseResult(_p?: ParseResult): ParseResult { const _j = {} as ParseResult; _o.set(_j, "version", _p?.version); _o.set(_j, "stmts", _p?.stmts); - if (isNode) { - return { - ParseResult: _j - }; - } return _j; }, - scanResult(_p?: ScanResult, isNode?: boolean): ScanResult | { - ScanResult: ScanResult; - } { + scanResult(_p?: ScanResult): ScanResult { const _j = {} as ScanResult; _o.set(_j, "version", _p?.version); _o.set(_j, "tokens", _p?.tokens); - if (isNode) { - return { - ScanResult: _j - }; - } return _j; }, - integer(_p?: Integer, isNode?: boolean): Integer | { - Integer: Integer; - } { + integer(_p?: Integer): Integer { const _j = {} as Integer; _o.set(_j, "ival", _p?.ival); - if (isNode) { - return { - Integer: _j - }; - } return _j; }, - float(_p?: Float, isNode?: boolean): Float | { - Float: Float; - } { + float(_p?: Float): Float { const _j = {} as Float; _o.set(_j, "fval", _p?.fval); - if (isNode) { - return { - Float: _j - }; - } return _j; }, - boolean(_p?: Boolean, isNode?: boolean): Boolean | { - Boolean: Boolean; - } { + boolean(_p?: Boolean): Boolean { const _j = {} as Boolean; _o.set(_j, "boolval", _p?.boolval); - if (isNode) { - return { - Boolean: _j - }; - } return _j; }, - string(_p?: String, isNode?: boolean): String | { - String: String; - } { + string(_p?: String): String { const _j = {} as String; _o.set(_j, "sval", _p?.sval); - if (isNode) { - return { - String: _j - }; - } return _j; }, - bitString(_p?: BitString, isNode?: boolean): BitString | { - BitString: BitString; - } { + bitString(_p?: BitString): BitString { const _j = {} as BitString; _o.set(_j, "bsval", _p?.bsval); - if (isNode) { - return { - BitString: _j - }; - } return _j; }, - list(_p?: List, isNode?: boolean): List | { - List: List; - } { + list(_p?: List): List { const _j = {} as List; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - List: _j - }; - } return _j; }, - oidList(_p?: OidList, isNode?: boolean): OidList | { - OidList: OidList; - } { + oidList(_p?: OidList): OidList { const _j = {} as OidList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - OidList: _j - }; - } return _j; }, - intList(_p?: IntList, isNode?: boolean): IntList | { - IntList: IntList; - } { + intList(_p?: IntList): IntList { const _j = {} as IntList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - IntList: _j - }; - } return _j; }, - aConst(_p?: A_Const, isNode?: boolean): A_Const | { - A_Const: A_Const; - } { + aConst(_p?: A_Const): A_Const { const _j = {} as A_Const; _o.set(_j, "ival", _p?.ival); _o.set(_j, "fval", _p?.fval); @@ -139,29 +67,15 @@ export default { _o.set(_j, "bsval", _p?.bsval); _o.set(_j, "isnull", _p?.isnull); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Const: _j - }; - } return _j; }, - alias(_p?: Alias, isNode?: boolean): Alias | { - Alias: Alias; - } { + alias(_p?: Alias): Alias { const _j = {} as Alias; _o.set(_j, "aliasname", _p?.aliasname); _o.set(_j, "colnames", _p?.colnames); - if (isNode) { - return { - Alias: _j - }; - } return _j; }, - rangeVar(_p?: RangeVar, isNode?: boolean): RangeVar | { - RangeVar: RangeVar; - } { + rangeVar(_p?: RangeVar): RangeVar { const _j = {} as RangeVar; _o.set(_j, "catalogname", _p?.catalogname); _o.set(_j, "schemaname", _p?.schemaname); @@ -170,16 +84,9 @@ export default { _o.set(_j, "relpersistence", _p?.relpersistence); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeVar: _j - }; - } return _j; }, - tableFunc(_p?: TableFunc, isNode?: boolean): TableFunc | { - TableFunc: TableFunc; - } { + tableFunc(_p?: TableFunc): TableFunc { const _j = {} as TableFunc; _o.set(_j, "ns_uris", _p?.ns_uris); _o.set(_j, "ns_names", _p?.ns_names); @@ -194,16 +101,9 @@ export default { _o.set(_j, "notnulls", _p?.notnulls); _o.set(_j, "ordinalitycol", _p?.ordinalitycol); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TableFunc: _j - }; - } return _j; }, - intoClause(_p?: IntoClause, isNode?: boolean): IntoClause | { - IntoClause: IntoClause; - } { + intoClause(_p?: IntoClause): IntoClause { const _j = {} as IntoClause; _o.set(_j, "rel", _p?.rel); _o.set(_j, "colNames", _p?.colNames); @@ -213,16 +113,9 @@ export default { _o.set(_j, "tableSpaceName", _p?.tableSpaceName); _o.set(_j, "viewQuery", _p?.viewQuery); _o.set(_j, "skipData", _p?.skipData); - if (isNode) { - return { - IntoClause: _j - }; - } return _j; }, - var(_p?: Var, isNode?: boolean): Var | { - Var: Var; - } { + var(_p?: Var): Var { const _j = {} as Var; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "varno", _p?.varno); @@ -233,16 +126,9 @@ export default { _o.set(_j, "varnullingrels", _p?.varnullingrels); _o.set(_j, "varlevelsup", _p?.varlevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Var: _j - }; - } return _j; }, - param(_p?: Param, isNode?: boolean): Param | { - Param: Param; - } { + param(_p?: Param): Param { const _j = {} as Param; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "paramkind", _p?.paramkind); @@ -251,16 +137,9 @@ export default { _o.set(_j, "paramtypmod", _p?.paramtypmod); _o.set(_j, "paramcollid", _p?.paramcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Param: _j - }; - } return _j; }, - aggref(_p?: Aggref, isNode?: boolean): Aggref | { - Aggref: Aggref; - } { + aggref(_p?: Aggref): Aggref { const _j = {} as Aggref; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "aggfnoid", _p?.aggfnoid); @@ -281,32 +160,18 @@ export default { _o.set(_j, "aggno", _p?.aggno); _o.set(_j, "aggtransno", _p?.aggtransno); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Aggref: _j - }; - } return _j; }, - groupingFunc(_p?: GroupingFunc, isNode?: boolean): GroupingFunc | { - GroupingFunc: GroupingFunc; - } { + groupingFunc(_p?: GroupingFunc): GroupingFunc { const _j = {} as GroupingFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); _o.set(_j, "refs", _p?.refs); _o.set(_j, "agglevelsup", _p?.agglevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingFunc: _j - }; - } return _j; }, - windowFunc(_p?: WindowFunc, isNode?: boolean): WindowFunc | { - WindowFunc: WindowFunc; - } { + windowFunc(_p?: WindowFunc): WindowFunc { const _j = {} as WindowFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "winfnoid", _p?.winfnoid); @@ -319,16 +184,9 @@ export default { _o.set(_j, "winstar", _p?.winstar); _o.set(_j, "winagg", _p?.winagg); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowFunc: _j - }; - } return _j; }, - subscriptingRef(_p?: SubscriptingRef, isNode?: boolean): SubscriptingRef | { - SubscriptingRef: SubscriptingRef; - } { + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { const _j = {} as SubscriptingRef; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "refcontainertype", _p?.refcontainertype); @@ -340,16 +198,9 @@ export default { _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); _o.set(_j, "refexpr", _p?.refexpr); _o.set(_j, "refassgnexpr", _p?.refassgnexpr); - if (isNode) { - return { - SubscriptingRef: _j - }; - } return _j; }, - funcExpr(_p?: FuncExpr, isNode?: boolean): FuncExpr | { - FuncExpr: FuncExpr; - } { + funcExpr(_p?: FuncExpr): FuncExpr { const _j = {} as FuncExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "funcid", _p?.funcid); @@ -361,32 +212,18 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncExpr: _j - }; - } return _j; }, - namedArgExpr(_p?: NamedArgExpr, isNode?: boolean): NamedArgExpr | { - NamedArgExpr: NamedArgExpr; - } { + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { const _j = {} as NamedArgExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "name", _p?.name); _o.set(_j, "argnumber", _p?.argnumber); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NamedArgExpr: _j - }; - } return _j; }, - opExpr(_p?: OpExpr, isNode?: boolean): OpExpr | { - OpExpr: OpExpr; - } { + opExpr(_p?: OpExpr): OpExpr { const _j = {} as OpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -396,16 +233,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OpExpr: _j - }; - } return _j; }, - distinctExpr(_p?: DistinctExpr, isNode?: boolean): DistinctExpr | { - DistinctExpr: DistinctExpr; - } { + distinctExpr(_p?: DistinctExpr): DistinctExpr { const _j = {} as DistinctExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -415,16 +245,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DistinctExpr: _j - }; - } return _j; }, - nullIfExpr(_p?: NullIfExpr, isNode?: boolean): NullIfExpr | { - NullIfExpr: NullIfExpr; - } { + nullIfExpr(_p?: NullIfExpr): NullIfExpr { const _j = {} as NullIfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -434,16 +257,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullIfExpr: _j - }; - } return _j; }, - scalarArrayOpExpr(_p?: ScalarArrayOpExpr, isNode?: boolean): ScalarArrayOpExpr | { - ScalarArrayOpExpr: ScalarArrayOpExpr; - } { + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { const _j = {} as ScalarArrayOpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -451,31 +267,17 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ScalarArrayOpExpr: _j - }; - } return _j; }, - boolExpr(_p?: BoolExpr, isNode?: boolean): BoolExpr | { - BoolExpr: BoolExpr; - } { + boolExpr(_p?: BoolExpr): BoolExpr { const _j = {} as BoolExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "boolop", _p?.boolop); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BoolExpr: _j - }; - } return _j; }, - subLink(_p?: SubLink, isNode?: boolean): SubLink | { - SubLink: SubLink; - } { + subLink(_p?: SubLink): SubLink { const _j = {} as SubLink; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -484,16 +286,9 @@ export default { _o.set(_j, "operName", _p?.operName); _o.set(_j, "subselect", _p?.subselect); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SubLink: _j - }; - } return _j; }, - subPlan(_p?: SubPlan, isNode?: boolean): SubPlan | { - SubPlan: SubPlan; - } { + subPlan(_p?: SubPlan): SubPlan { const _j = {} as SubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -512,29 +307,15 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "startup_cost", _p?.startup_cost); _o.set(_j, "per_call_cost", _p?.per_call_cost); - if (isNode) { - return { - SubPlan: _j - }; - } return _j; }, - alternativeSubPlan(_p?: AlternativeSubPlan, isNode?: boolean): AlternativeSubPlan | { - AlternativeSubPlan: AlternativeSubPlan; - } { + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { const _j = {} as AlternativeSubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subplans", _p?.subplans); - if (isNode) { - return { - AlternativeSubPlan: _j - }; - } return _j; }, - fieldSelect(_p?: FieldSelect, isNode?: boolean): FieldSelect | { - FieldSelect: FieldSelect; - } { + fieldSelect(_p?: FieldSelect): FieldSelect { const _j = {} as FieldSelect; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -542,32 +323,18 @@ export default { _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "resulttypmod", _p?.resulttypmod); _o.set(_j, "resultcollid", _p?.resultcollid); - if (isNode) { - return { - FieldSelect: _j - }; - } return _j; }, - fieldStore(_p?: FieldStore, isNode?: boolean): FieldStore | { - FieldStore: FieldStore; - } { + fieldStore(_p?: FieldStore): FieldStore { const _j = {} as FieldStore; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "newvals", _p?.newvals); _o.set(_j, "fieldnums", _p?.fieldnums); _o.set(_j, "resulttype", _p?.resulttype); - if (isNode) { - return { - FieldStore: _j - }; - } return _j; }, - relabelType(_p?: RelabelType, isNode?: boolean): RelabelType | { - RelabelType: RelabelType; - } { + relabelType(_p?: RelabelType): RelabelType { const _j = {} as RelabelType; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -576,16 +343,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "relabelformat", _p?.relabelformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RelabelType: _j - }; - } return _j; }, - coerceViaio(_p?: CoerceViaIO, isNode?: boolean): CoerceViaIO | { - CoerceViaIO: CoerceViaIO; - } { + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { const _j = {} as CoerceViaIO; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -593,16 +353,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceViaIO: _j - }; - } return _j; }, - arrayCoerceExpr(_p?: ArrayCoerceExpr, isNode?: boolean): ArrayCoerceExpr | { - ArrayCoerceExpr: ArrayCoerceExpr; - } { + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { const _j = {} as ArrayCoerceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -612,47 +365,26 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayCoerceExpr: _j - }; - } return _j; }, - convertRowtypeExpr(_p?: ConvertRowtypeExpr, isNode?: boolean): ConvertRowtypeExpr | { - ConvertRowtypeExpr: ConvertRowtypeExpr; - } { + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { const _j = {} as ConvertRowtypeExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "convertformat", _p?.convertformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ConvertRowtypeExpr: _j - }; - } return _j; }, - collateExpr(_p?: CollateExpr, isNode?: boolean): CollateExpr | { - CollateExpr: CollateExpr; - } { + collateExpr(_p?: CollateExpr): CollateExpr { const _j = {} as CollateExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "collOid", _p?.collOid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateExpr: _j - }; - } return _j; }, - caseExpr(_p?: CaseExpr, isNode?: boolean): CaseExpr | { - CaseExpr: CaseExpr; - } { + caseExpr(_p?: CaseExpr): CaseExpr { const _j = {} as CaseExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "casetype", _p?.casetype); @@ -661,46 +393,25 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "defresult", _p?.defresult); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseExpr: _j - }; - } return _j; }, - caseWhen(_p?: CaseWhen, isNode?: boolean): CaseWhen | { - CaseWhen: CaseWhen; - } { + caseWhen(_p?: CaseWhen): CaseWhen { const _j = {} as CaseWhen; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "result", _p?.result); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseWhen: _j - }; - } return _j; }, - caseTestExpr(_p?: CaseTestExpr, isNode?: boolean): CaseTestExpr | { - CaseTestExpr: CaseTestExpr; - } { + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { const _j = {} as CaseTestExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); - if (isNode) { - return { - CaseTestExpr: _j - }; - } return _j; }, - arrayExpr(_p?: ArrayExpr, isNode?: boolean): ArrayExpr | { - ArrayExpr: ArrayExpr; - } { + arrayExpr(_p?: ArrayExpr): ArrayExpr { const _j = {} as ArrayExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "array_typeid", _p?.array_typeid); @@ -709,16 +420,9 @@ export default { _o.set(_j, "elements", _p?.elements); _o.set(_j, "multidims", _p?.multidims); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayExpr: _j - }; - } return _j; }, - rowExpr(_p?: RowExpr, isNode?: boolean): RowExpr | { - RowExpr: RowExpr; - } { + rowExpr(_p?: RowExpr): RowExpr { const _j = {} as RowExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); @@ -726,16 +430,9 @@ export default { _o.set(_j, "row_format", _p?.row_format); _o.set(_j, "colnames", _p?.colnames); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RowExpr: _j - }; - } return _j; }, - rowCompareExpr(_p?: RowCompareExpr, isNode?: boolean): RowCompareExpr | { - RowCompareExpr: RowCompareExpr; - } { + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { const _j = {} as RowCompareExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "rctype", _p?.rctype); @@ -744,32 +441,18 @@ export default { _o.set(_j, "inputcollids", _p?.inputcollids); _o.set(_j, "largs", _p?.largs); _o.set(_j, "rargs", _p?.rargs); - if (isNode) { - return { - RowCompareExpr: _j - }; - } return _j; }, - coalesceExpr(_p?: CoalesceExpr, isNode?: boolean): CoalesceExpr | { - CoalesceExpr: CoalesceExpr; - } { + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { const _j = {} as CoalesceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "coalescetype", _p?.coalescetype); _o.set(_j, "coalescecollid", _p?.coalescecollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoalesceExpr: _j - }; - } return _j; }, - minMaxExpr(_p?: MinMaxExpr, isNode?: boolean): MinMaxExpr | { - MinMaxExpr: MinMaxExpr; - } { + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { const _j = {} as MinMaxExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "minmaxtype", _p?.minmaxtype); @@ -778,32 +461,18 @@ export default { _o.set(_j, "op", _p?.op); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MinMaxExpr: _j - }; - } return _j; }, - sqlValueFunction(_p?: SQLValueFunction, isNode?: boolean): SQLValueFunction | { - SQLValueFunction: SQLValueFunction; - } { + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { const _j = {} as SQLValueFunction; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SQLValueFunction: _j - }; - } return _j; }, - xmlExpr(_p?: XmlExpr, isNode?: boolean): XmlExpr | { - XmlExpr: XmlExpr; - } { + xmlExpr(_p?: XmlExpr): XmlExpr { const _j = {} as XmlExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -816,58 +485,30 @@ export default { _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlExpr: _j - }; - } return _j; }, - jsonFormat(_p?: JsonFormat, isNode?: boolean): JsonFormat | { - JsonFormat: JsonFormat; - } { + jsonFormat(_p?: JsonFormat): JsonFormat { const _j = {} as JsonFormat; _o.set(_j, "format_type", _p?.format_type); _o.set(_j, "encoding", _p?.encoding); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFormat: _j - }; - } return _j; }, - jsonReturning(_p?: JsonReturning, isNode?: boolean): JsonReturning | { - JsonReturning: JsonReturning; - } { + jsonReturning(_p?: JsonReturning): JsonReturning { const _j = {} as JsonReturning; _o.set(_j, "format", _p?.format); _o.set(_j, "typid", _p?.typid); _o.set(_j, "typmod", _p?.typmod); - if (isNode) { - return { - JsonReturning: _j - }; - } return _j; }, - jsonValueExpr(_p?: JsonValueExpr, isNode?: boolean): JsonValueExpr | { - JsonValueExpr: JsonValueExpr; - } { + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { const _j = {} as JsonValueExpr; _o.set(_j, "raw_expr", _p?.raw_expr); _o.set(_j, "formatted_expr", _p?.formatted_expr); _o.set(_j, "format", _p?.format); - if (isNode) { - return { - JsonValueExpr: _j - }; - } return _j; }, - jsonConstructorExpr(_p?: JsonConstructorExpr, isNode?: boolean): JsonConstructorExpr | { - JsonConstructorExpr: JsonConstructorExpr; - } { + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { const _j = {} as JsonConstructorExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "type", _p?.type); @@ -878,63 +519,35 @@ export default { _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonConstructorExpr: _j - }; - } return _j; }, - jsonIsPredicate(_p?: JsonIsPredicate, isNode?: boolean): JsonIsPredicate | { - JsonIsPredicate: JsonIsPredicate; - } { + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { const _j = {} as JsonIsPredicate; _o.set(_j, "expr", _p?.expr); _o.set(_j, "format", _p?.format); _o.set(_j, "item_type", _p?.item_type); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonIsPredicate: _j - }; - } return _j; }, - nullTest(_p?: NullTest, isNode?: boolean): NullTest | { - NullTest: NullTest; - } { + nullTest(_p?: NullTest): NullTest { const _j = {} as NullTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "nulltesttype", _p?.nulltesttype); _o.set(_j, "argisrow", _p?.argisrow); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullTest: _j - }; - } return _j; }, - booleanTest(_p?: BooleanTest, isNode?: boolean): BooleanTest | { - BooleanTest: BooleanTest; - } { + booleanTest(_p?: BooleanTest): BooleanTest { const _j = {} as BooleanTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "booltesttype", _p?.booltesttype); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BooleanTest: _j - }; - } return _j; }, - coerceToDomain(_p?: CoerceToDomain, isNode?: boolean): CoerceToDomain | { - CoerceToDomain: CoerceToDomain; - } { + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { const _j = {} as CoerceToDomain; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -943,92 +556,50 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coercionformat", _p?.coercionformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomain: _j - }; - } return _j; }, - coerceToDomainValue(_p?: CoerceToDomainValue, isNode?: boolean): CoerceToDomainValue | { - CoerceToDomainValue: CoerceToDomainValue; - } { + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { const _j = {} as CoerceToDomainValue; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomainValue: _j - }; - } return _j; }, - setToDefault(_p?: SetToDefault, isNode?: boolean): SetToDefault | { - SetToDefault: SetToDefault; - } { + setToDefault(_p?: SetToDefault): SetToDefault { const _j = {} as SetToDefault; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SetToDefault: _j - }; - } return _j; }, - currentOfExpr(_p?: CurrentOfExpr, isNode?: boolean): CurrentOfExpr | { - CurrentOfExpr: CurrentOfExpr; - } { + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { const _j = {} as CurrentOfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "cvarno", _p?.cvarno); _o.set(_j, "cursor_name", _p?.cursor_name); _o.set(_j, "cursor_param", _p?.cursor_param); - if (isNode) { - return { - CurrentOfExpr: _j - }; - } return _j; }, - nextValueExpr(_p?: NextValueExpr, isNode?: boolean): NextValueExpr | { - NextValueExpr: NextValueExpr; - } { + nextValueExpr(_p?: NextValueExpr): NextValueExpr { const _j = {} as NextValueExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "seqid", _p?.seqid); _o.set(_j, "typeId", _p?.typeId); - if (isNode) { - return { - NextValueExpr: _j - }; - } return _j; }, - inferenceElem(_p?: InferenceElem, isNode?: boolean): InferenceElem | { - InferenceElem: InferenceElem; - } { + inferenceElem(_p?: InferenceElem): InferenceElem { const _j = {} as InferenceElem; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "infercollid", _p?.infercollid); _o.set(_j, "inferopclass", _p?.inferopclass); - if (isNode) { - return { - InferenceElem: _j - }; - } return _j; }, - targetEntry(_p?: TargetEntry, isNode?: boolean): TargetEntry | { - TargetEntry: TargetEntry; - } { + targetEntry(_p?: TargetEntry): TargetEntry { const _j = {} as TargetEntry; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); @@ -1038,28 +609,14 @@ export default { _o.set(_j, "resorigtbl", _p?.resorigtbl); _o.set(_j, "resorigcol", _p?.resorigcol); _o.set(_j, "resjunk", _p?.resjunk); - if (isNode) { - return { - TargetEntry: _j - }; - } return _j; }, - rangeTblRef(_p?: RangeTblRef, isNode?: boolean): RangeTblRef | { - RangeTblRef: RangeTblRef; - } { + rangeTblRef(_p?: RangeTblRef): RangeTblRef { const _j = {} as RangeTblRef; _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - RangeTblRef: _j - }; - } return _j; }, - joinExpr(_p?: JoinExpr, isNode?: boolean): JoinExpr | { - JoinExpr: JoinExpr; - } { + joinExpr(_p?: JoinExpr): JoinExpr { const _j = {} as JoinExpr; _o.set(_j, "jointype", _p?.jointype); _o.set(_j, "isNatural", _p?.isNatural); @@ -1070,29 +627,15 @@ export default { _o.set(_j, "quals", _p?.quals); _o.set(_j, "alias", _p?.alias); _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - JoinExpr: _j - }; - } return _j; }, - fromExpr(_p?: FromExpr, isNode?: boolean): FromExpr | { - FromExpr: FromExpr; - } { + fromExpr(_p?: FromExpr): FromExpr { const _j = {} as FromExpr; _o.set(_j, "fromlist", _p?.fromlist); _o.set(_j, "quals", _p?.quals); - if (isNode) { - return { - FromExpr: _j - }; - } return _j; }, - onConflictExpr(_p?: OnConflictExpr, isNode?: boolean): OnConflictExpr | { - OnConflictExpr: OnConflictExpr; - } { + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { const _j = {} as OnConflictExpr; _o.set(_j, "action", _p?.action); _o.set(_j, "arbiterElems", _p?.arbiterElems); @@ -1102,16 +645,9 @@ export default { _o.set(_j, "onConflictWhere", _p?.onConflictWhere); _o.set(_j, "exclRelIndex", _p?.exclRelIndex); _o.set(_j, "exclRelTlist", _p?.exclRelTlist); - if (isNode) { - return { - OnConflictExpr: _j - }; - } return _j; }, - query(_p?: Query, isNode?: boolean): Query | { - Query: Query; - } { + query(_p?: Query): Query { const _j = {} as Query; _o.set(_j, "commandType", _p?.commandType); _o.set(_j, "querySource", _p?.querySource); @@ -1154,16 +690,9 @@ export default { _o.set(_j, "withCheckOptions", _p?.withCheckOptions); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - Query: _j - }; - } return _j; }, - typeName(_p?: TypeName, isNode?: boolean): TypeName | { - TypeName: TypeName; - } { + typeName(_p?: TypeName): TypeName { const _j = {} as TypeName; _o.set(_j, "names", _p?.names); _o.set(_j, "typeOid", _p?.typeOid); @@ -1173,100 +702,51 @@ export default { _o.set(_j, "typemod", _p?.typemod); _o.set(_j, "arrayBounds", _p?.arrayBounds); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeName: _j - }; - } return _j; }, - columnRef(_p?: ColumnRef, isNode?: boolean): ColumnRef | { - ColumnRef: ColumnRef; - } { + columnRef(_p?: ColumnRef): ColumnRef { const _j = {} as ColumnRef; _o.set(_j, "fields", _p?.fields); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnRef: _j - }; - } return _j; }, - paramRef(_p?: ParamRef, isNode?: boolean): ParamRef | { - ParamRef: ParamRef; - } { + paramRef(_p?: ParamRef): ParamRef { const _j = {} as ParamRef; _o.set(_j, "number", _p?.number); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ParamRef: _j - }; - } return _j; }, - aExpr(_p?: A_Expr, isNode?: boolean): A_Expr | { - A_Expr: A_Expr; - } { + aExpr(_p?: A_Expr): A_Expr { const _j = {} as A_Expr; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "lexpr", _p?.lexpr); _o.set(_j, "rexpr", _p?.rexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Expr: _j - }; - } return _j; }, - typeCast(_p?: TypeCast, isNode?: boolean): TypeCast | { - TypeCast: TypeCast; - } { + typeCast(_p?: TypeCast): TypeCast { const _j = {} as TypeCast; _o.set(_j, "arg", _p?.arg); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeCast: _j - }; - } return _j; }, - collateClause(_p?: CollateClause, isNode?: boolean): CollateClause | { - CollateClause: CollateClause; - } { + collateClause(_p?: CollateClause): CollateClause { const _j = {} as CollateClause; _o.set(_j, "arg", _p?.arg); _o.set(_j, "collname", _p?.collname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateClause: _j - }; - } return _j; }, - roleSpec(_p?: RoleSpec, isNode?: boolean): RoleSpec | { - RoleSpec: RoleSpec; - } { + roleSpec(_p?: RoleSpec): RoleSpec { const _j = {} as RoleSpec; _o.set(_j, "roletype", _p?.roletype); _o.set(_j, "rolename", _p?.rolename); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RoleSpec: _j - }; - } return _j; }, - funcCall(_p?: FuncCall, isNode?: boolean): FuncCall | { - FuncCall: FuncCall; - } { + funcCall(_p?: FuncCall): FuncCall { const _j = {} as FuncCall; _o.set(_j, "funcname", _p?.funcname); _o.set(_j, "args", _p?.args); @@ -1279,112 +759,56 @@ export default { _o.set(_j, "func_variadic", _p?.func_variadic); _o.set(_j, "funcformat", _p?.funcformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncCall: _j - }; - } return _j; }, - aStar(_p?: A_Star, isNode?: boolean): A_Star | { - A_Star: A_Star; - } { + aStar(_p?: A_Star): A_Star { const _j = {} as A_Star; - if (isNode) { - return { - A_Star: _j - }; - } return _j; }, - aIndices(_p?: A_Indices, isNode?: boolean): A_Indices | { - A_Indices: A_Indices; - } { + aIndices(_p?: A_Indices): A_Indices { const _j = {} as A_Indices; _o.set(_j, "is_slice", _p?.is_slice); _o.set(_j, "lidx", _p?.lidx); _o.set(_j, "uidx", _p?.uidx); - if (isNode) { - return { - A_Indices: _j - }; - } return _j; }, - aIndirection(_p?: A_Indirection, isNode?: boolean): A_Indirection | { - A_Indirection: A_Indirection; - } { + aIndirection(_p?: A_Indirection): A_Indirection { const _j = {} as A_Indirection; _o.set(_j, "arg", _p?.arg); _o.set(_j, "indirection", _p?.indirection); - if (isNode) { - return { - A_Indirection: _j - }; - } return _j; }, - aArrayExpr(_p?: A_ArrayExpr, isNode?: boolean): A_ArrayExpr | { - A_ArrayExpr: A_ArrayExpr; - } { + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { const _j = {} as A_ArrayExpr; _o.set(_j, "elements", _p?.elements); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_ArrayExpr: _j - }; - } return _j; }, - resTarget(_p?: ResTarget, isNode?: boolean): ResTarget | { - ResTarget: ResTarget; - } { + resTarget(_p?: ResTarget): ResTarget { const _j = {} as ResTarget; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ResTarget: _j - }; - } return _j; }, - multiAssignRef(_p?: MultiAssignRef, isNode?: boolean): MultiAssignRef | { - MultiAssignRef: MultiAssignRef; - } { + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { const _j = {} as MultiAssignRef; _o.set(_j, "source", _p?.source); _o.set(_j, "colno", _p?.colno); _o.set(_j, "ncolumns", _p?.ncolumns); - if (isNode) { - return { - MultiAssignRef: _j - }; - } return _j; }, - sortBy(_p?: SortBy, isNode?: boolean): SortBy | { - SortBy: SortBy; - } { + sortBy(_p?: SortBy): SortBy { const _j = {} as SortBy; _o.set(_j, "node", _p?.node); _o.set(_j, "sortby_dir", _p?.sortby_dir); _o.set(_j, "sortby_nulls", _p?.sortby_nulls); _o.set(_j, "useOp", _p?.useOp); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SortBy: _j - }; - } return _j; }, - windowDef(_p?: WindowDef, isNode?: boolean): WindowDef | { - WindowDef: WindowDef; - } { + windowDef(_p?: WindowDef): WindowDef { const _j = {} as WindowDef; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1394,30 +818,16 @@ export default { _o.set(_j, "startOffset", _p?.startOffset); _o.set(_j, "endOffset", _p?.endOffset); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowDef: _j - }; - } return _j; }, - rangeSubselect(_p?: RangeSubselect, isNode?: boolean): RangeSubselect | { - RangeSubselect: RangeSubselect; - } { + rangeSubselect(_p?: RangeSubselect): RangeSubselect { const _j = {} as RangeSubselect; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "subquery", _p?.subquery); _o.set(_j, "alias", _p?.alias); - if (isNode) { - return { - RangeSubselect: _j - }; - } return _j; }, - rangeFunction(_p?: RangeFunction, isNode?: boolean): RangeFunction | { - RangeFunction: RangeFunction; - } { + rangeFunction(_p?: RangeFunction): RangeFunction { const _j = {} as RangeFunction; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "ordinality", _p?.ordinality); @@ -1425,16 +835,9 @@ export default { _o.set(_j, "functions", _p?.functions); _o.set(_j, "alias", _p?.alias); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - RangeFunction: _j - }; - } return _j; }, - rangeTableFunc(_p?: RangeTableFunc, isNode?: boolean): RangeTableFunc | { - RangeTableFunc: RangeTableFunc; - } { + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { const _j = {} as RangeTableFunc; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "docexpr", _p?.docexpr); @@ -1443,16 +846,9 @@ export default { _o.set(_j, "columns", _p?.columns); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFunc: _j - }; - } return _j; }, - rangeTableFuncCol(_p?: RangeTableFuncCol, isNode?: boolean): RangeTableFuncCol | { - RangeTableFuncCol: RangeTableFuncCol; - } { + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { const _j = {} as RangeTableFuncCol; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1461,32 +857,18 @@ export default { _o.set(_j, "colexpr", _p?.colexpr); _o.set(_j, "coldefexpr", _p?.coldefexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFuncCol: _j - }; - } return _j; }, - rangeTableSample(_p?: RangeTableSample, isNode?: boolean): RangeTableSample | { - RangeTableSample: RangeTableSample; - } { + rangeTableSample(_p?: RangeTableSample): RangeTableSample { const _j = {} as RangeTableSample; _o.set(_j, "relation", _p?.relation); _o.set(_j, "method", _p?.method); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableSample: _j - }; - } return _j; }, - columnDef(_p?: ColumnDef, isNode?: boolean): ColumnDef | { - ColumnDef: ColumnDef; - } { + columnDef(_p?: ColumnDef): ColumnDef { const _j = {} as ColumnDef; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1507,30 +889,16 @@ export default { _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "fdwoptions", _p?.fdwoptions); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnDef: _j - }; - } return _j; }, - tableLikeClause(_p?: TableLikeClause, isNode?: boolean): TableLikeClause | { - TableLikeClause: TableLikeClause; - } { + tableLikeClause(_p?: TableLikeClause): TableLikeClause { const _j = {} as TableLikeClause; _o.set(_j, "relation", _p?.relation); _o.set(_j, "options", _p?.options); _o.set(_j, "relationOid", _p?.relationOid); - if (isNode) { - return { - TableLikeClause: _j - }; - } return _j; }, - indexElem(_p?: IndexElem, isNode?: boolean): IndexElem | { - IndexElem: IndexElem; - } { + indexElem(_p?: IndexElem): IndexElem { const _j = {} as IndexElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); @@ -1540,92 +908,50 @@ export default { _o.set(_j, "opclassopts", _p?.opclassopts); _o.set(_j, "ordering", _p?.ordering); _o.set(_j, "nulls_ordering", _p?.nulls_ordering); - if (isNode) { - return { - IndexElem: _j - }; - } return _j; }, - defElem(_p?: DefElem, isNode?: boolean): DefElem | { - DefElem: DefElem; - } { + defElem(_p?: DefElem): DefElem { const _j = {} as DefElem; _o.set(_j, "defnamespace", _p?.defnamespace); _o.set(_j, "defname", _p?.defname); _o.set(_j, "arg", _p?.arg); _o.set(_j, "defaction", _p?.defaction); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DefElem: _j - }; - } return _j; }, - lockingClause(_p?: LockingClause, isNode?: boolean): LockingClause | { - LockingClause: LockingClause; - } { + lockingClause(_p?: LockingClause): LockingClause { const _j = {} as LockingClause; _o.set(_j, "lockedRels", _p?.lockedRels); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); - if (isNode) { - return { - LockingClause: _j - }; - } return _j; }, - xmlSerialize(_p?: XmlSerialize, isNode?: boolean): XmlSerialize | { - XmlSerialize: XmlSerialize; - } { + xmlSerialize(_p?: XmlSerialize): XmlSerialize { const _j = {} as XmlSerialize; _o.set(_j, "xmloption", _p?.xmloption); _o.set(_j, "expr", _p?.expr); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "indent", _p?.indent); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlSerialize: _j - }; - } return _j; }, - partitionElem(_p?: PartitionElem, isNode?: boolean): PartitionElem | { - PartitionElem: PartitionElem; - } { + partitionElem(_p?: PartitionElem): PartitionElem { const _j = {} as PartitionElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); _o.set(_j, "collation", _p?.collation); _o.set(_j, "opclass", _p?.opclass); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionElem: _j - }; - } return _j; }, - partitionSpec(_p?: PartitionSpec, isNode?: boolean): PartitionSpec | { - PartitionSpec: PartitionSpec; - } { + partitionSpec(_p?: PartitionSpec): PartitionSpec { const _j = {} as PartitionSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "partParams", _p?.partParams); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionSpec: _j - }; - } return _j; }, - partitionBoundSpec(_p?: PartitionBoundSpec, isNode?: boolean): PartitionBoundSpec | { - PartitionBoundSpec: PartitionBoundSpec; - } { + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { const _j = {} as PartitionBoundSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "is_default", _p?.is_default); @@ -1635,44 +961,23 @@ export default { _o.set(_j, "lowerdatums", _p?.lowerdatums); _o.set(_j, "upperdatums", _p?.upperdatums); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionBoundSpec: _j - }; - } return _j; }, - partitionRangeDatum(_p?: PartitionRangeDatum, isNode?: boolean): PartitionRangeDatum | { - PartitionRangeDatum: PartitionRangeDatum; - } { + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { const _j = {} as PartitionRangeDatum; _o.set(_j, "kind", _p?.kind); _o.set(_j, "value", _p?.value); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionRangeDatum: _j - }; - } return _j; }, - partitionCmd(_p?: PartitionCmd, isNode?: boolean): PartitionCmd | { - PartitionCmd: PartitionCmd; - } { + partitionCmd(_p?: PartitionCmd): PartitionCmd { const _j = {} as PartitionCmd; _o.set(_j, "name", _p?.name); _o.set(_j, "bound", _p?.bound); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - PartitionCmd: _j - }; - } return _j; }, - rangeTblEntry(_p?: RangeTblEntry, isNode?: boolean): RangeTblEntry | { - RangeTblEntry: RangeTblEntry; - } { + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { const _j = {} as RangeTblEntry; _o.set(_j, "rtekind", _p?.rtekind); _o.set(_j, "relid", _p?.relid); @@ -1706,16 +1011,9 @@ export default { _o.set(_j, "inh", _p?.inh); _o.set(_j, "inFromCl", _p?.inFromCl); _o.set(_j, "securityQuals", _p?.securityQuals); - if (isNode) { - return { - RangeTblEntry: _j - }; - } return _j; }, - rtePermissionInfo(_p?: RTEPermissionInfo, isNode?: boolean): RTEPermissionInfo | { - RTEPermissionInfo: RTEPermissionInfo; - } { + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { const _j = {} as RTEPermissionInfo; _o.set(_j, "relid", _p?.relid); _o.set(_j, "inh", _p?.inh); @@ -1724,16 +1022,9 @@ export default { _o.set(_j, "selectedCols", _p?.selectedCols); _o.set(_j, "insertedCols", _p?.insertedCols); _o.set(_j, "updatedCols", _p?.updatedCols); - if (isNode) { - return { - RTEPermissionInfo: _j - }; - } return _j; }, - rangeTblFunction(_p?: RangeTblFunction, isNode?: boolean): RangeTblFunction | { - RangeTblFunction: RangeTblFunction; - } { + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { const _j = {} as RangeTblFunction; _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "funccolcount", _p?.funccolcount); @@ -1742,76 +1033,41 @@ export default { _o.set(_j, "funccoltypmods", _p?.funccoltypmods); _o.set(_j, "funccolcollations", _p?.funccolcollations); _o.set(_j, "funcparams", _p?.funcparams); - if (isNode) { - return { - RangeTblFunction: _j - }; - } return _j; }, - tableSampleClause(_p?: TableSampleClause, isNode?: boolean): TableSampleClause | { - TableSampleClause: TableSampleClause; - } { + tableSampleClause(_p?: TableSampleClause): TableSampleClause { const _j = {} as TableSampleClause; _o.set(_j, "tsmhandler", _p?.tsmhandler); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); - if (isNode) { - return { - TableSampleClause: _j - }; - } return _j; }, - withCheckOption(_p?: WithCheckOption, isNode?: boolean): WithCheckOption | { - WithCheckOption: WithCheckOption; - } { + withCheckOption(_p?: WithCheckOption): WithCheckOption { const _j = {} as WithCheckOption; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relname", _p?.relname); _o.set(_j, "polname", _p?.polname); _o.set(_j, "qual", _p?.qual); _o.set(_j, "cascaded", _p?.cascaded); - if (isNode) { - return { - WithCheckOption: _j - }; - } return _j; }, - sortGroupClause(_p?: SortGroupClause, isNode?: boolean): SortGroupClause | { - SortGroupClause: SortGroupClause; - } { + sortGroupClause(_p?: SortGroupClause): SortGroupClause { const _j = {} as SortGroupClause; _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); _o.set(_j, "eqop", _p?.eqop); _o.set(_j, "sortop", _p?.sortop); _o.set(_j, "nulls_first", _p?.nulls_first); _o.set(_j, "hashable", _p?.hashable); - if (isNode) { - return { - SortGroupClause: _j - }; - } return _j; }, - groupingSet(_p?: GroupingSet, isNode?: boolean): GroupingSet | { - GroupingSet: GroupingSet; - } { + groupingSet(_p?: GroupingSet): GroupingSet { const _j = {} as GroupingSet; _o.set(_j, "kind", _p?.kind); _o.set(_j, "content", _p?.content); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingSet: _j - }; - } return _j; }, - windowClause(_p?: WindowClause, isNode?: boolean): WindowClause | { - WindowClause: WindowClause; - } { + windowClause(_p?: WindowClause): WindowClause { const _j = {} as WindowClause; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1828,91 +1084,49 @@ export default { _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); _o.set(_j, "winref", _p?.winref); _o.set(_j, "copiedOrder", _p?.copiedOrder); - if (isNode) { - return { - WindowClause: _j - }; - } return _j; }, - rowMarkClause(_p?: RowMarkClause, isNode?: boolean): RowMarkClause | { - RowMarkClause: RowMarkClause; - } { + rowMarkClause(_p?: RowMarkClause): RowMarkClause { const _j = {} as RowMarkClause; _o.set(_j, "rti", _p?.rti); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); _o.set(_j, "pushedDown", _p?.pushedDown); - if (isNode) { - return { - RowMarkClause: _j - }; - } return _j; }, - withClause(_p?: WithClause, isNode?: boolean): WithClause | { - WithClause: WithClause; - } { + withClause(_p?: WithClause): WithClause { const _j = {} as WithClause; _o.set(_j, "ctes", _p?.ctes); _o.set(_j, "recursive", _p?.recursive); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WithClause: _j - }; - } return _j; }, - inferClause(_p?: InferClause, isNode?: boolean): InferClause | { - InferClause: InferClause; - } { + inferClause(_p?: InferClause): InferClause { const _j = {} as InferClause; _o.set(_j, "indexElems", _p?.indexElems); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "conname", _p?.conname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - InferClause: _j - }; - } return _j; }, - onConflictClause(_p?: OnConflictClause, isNode?: boolean): OnConflictClause | { - OnConflictClause: OnConflictClause; - } { + onConflictClause(_p?: OnConflictClause): OnConflictClause { const _j = {} as OnConflictClause; _o.set(_j, "action", _p?.action); _o.set(_j, "infer", _p?.infer); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OnConflictClause: _j - }; - } return _j; }, - cteSearchClause(_p?: CTESearchClause, isNode?: boolean): CTESearchClause | { - CTESearchClause: CTESearchClause; - } { + cteSearchClause(_p?: CTESearchClause): CTESearchClause { const _j = {} as CTESearchClause; _o.set(_j, "search_col_list", _p?.search_col_list); _o.set(_j, "search_breadth_first", _p?.search_breadth_first); _o.set(_j, "search_seq_column", _p?.search_seq_column); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CTESearchClause: _j - }; - } return _j; }, - cteCycleClause(_p?: CTECycleClause, isNode?: boolean): CTECycleClause | { - CTECycleClause: CTECycleClause; - } { + cteCycleClause(_p?: CTECycleClause): CTECycleClause { const _j = {} as CTECycleClause; _o.set(_j, "cycle_col_list", _p?.cycle_col_list); _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); @@ -1924,16 +1138,9 @@ export default { _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); - if (isNode) { - return { - CTECycleClause: _j - }; - } return _j; }, - commonTableExpr(_p?: CommonTableExpr, isNode?: boolean): CommonTableExpr | { - CommonTableExpr: CommonTableExpr; - } { + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { const _j = {} as CommonTableExpr; _o.set(_j, "ctename", _p?.ctename); _o.set(_j, "aliascolnames", _p?.aliascolnames); @@ -1948,16 +1155,9 @@ export default { _o.set(_j, "ctecoltypes", _p?.ctecoltypes); _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); _o.set(_j, "ctecolcollations", _p?.ctecolcollations); - if (isNode) { - return { - CommonTableExpr: _j - }; - } return _j; }, - mergeWhenClause(_p?: MergeWhenClause, isNode?: boolean): MergeWhenClause | { - MergeWhenClause: MergeWhenClause; - } { + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { const _j = {} as MergeWhenClause; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -1965,16 +1165,9 @@ export default { _o.set(_j, "condition", _p?.condition); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "values", _p?.values); - if (isNode) { - return { - MergeWhenClause: _j - }; - } return _j; }, - mergeAction(_p?: MergeAction, isNode?: boolean): MergeAction | { - MergeAction: MergeAction; - } { + mergeAction(_p?: MergeAction): MergeAction { const _j = {} as MergeAction; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -1982,162 +1175,85 @@ export default { _o.set(_j, "qual", _p?.qual); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "updateColnos", _p?.updateColnos); - if (isNode) { - return { - MergeAction: _j - }; - } return _j; }, - triggerTransition(_p?: TriggerTransition, isNode?: boolean): TriggerTransition | { - TriggerTransition: TriggerTransition; - } { + triggerTransition(_p?: TriggerTransition): TriggerTransition { const _j = {} as TriggerTransition; _o.set(_j, "name", _p?.name); _o.set(_j, "isNew", _p?.isNew); _o.set(_j, "isTable", _p?.isTable); - if (isNode) { - return { - TriggerTransition: _j - }; - } return _j; }, - jsonOutput(_p?: JsonOutput, isNode?: boolean): JsonOutput | { - JsonOutput: JsonOutput; - } { + jsonOutput(_p?: JsonOutput): JsonOutput { const _j = {} as JsonOutput; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "returning", _p?.returning); - if (isNode) { - return { - JsonOutput: _j - }; - } return _j; }, - jsonKeyValue(_p?: JsonKeyValue, isNode?: boolean): JsonKeyValue | { - JsonKeyValue: JsonKeyValue; - } { + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { const _j = {} as JsonKeyValue; _o.set(_j, "key", _p?.key); _o.set(_j, "value", _p?.value); - if (isNode) { - return { - JsonKeyValue: _j - }; - } return _j; }, - jsonObjectConstructor(_p?: JsonObjectConstructor, isNode?: boolean): JsonObjectConstructor | { - JsonObjectConstructor: JsonObjectConstructor; - } { + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { const _j = {} as JsonObjectConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonObjectConstructor: _j - }; - } return _j; }, - jsonArrayConstructor(_p?: JsonArrayConstructor, isNode?: boolean): JsonArrayConstructor | { - JsonArrayConstructor: JsonArrayConstructor; - } { + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { const _j = {} as JsonArrayConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayConstructor: _j - }; - } return _j; }, - jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor, isNode?: boolean): JsonArrayQueryConstructor | { - JsonArrayQueryConstructor: JsonArrayQueryConstructor; - } { + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { const _j = {} as JsonArrayQueryConstructor; _o.set(_j, "query", _p?.query); _o.set(_j, "output", _p?.output); _o.set(_j, "format", _p?.format); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayQueryConstructor: _j - }; - } return _j; }, - jsonAggConstructor(_p?: JsonAggConstructor, isNode?: boolean): JsonAggConstructor | { - JsonAggConstructor: JsonAggConstructor; - } { + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { const _j = {} as JsonAggConstructor; _o.set(_j, "output", _p?.output); _o.set(_j, "agg_filter", _p?.agg_filter); _o.set(_j, "agg_order", _p?.agg_order); _o.set(_j, "over", _p?.over); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonAggConstructor: _j - }; - } return _j; }, - jsonObjectAgg(_p?: JsonObjectAgg, isNode?: boolean): JsonObjectAgg | { - JsonObjectAgg: JsonObjectAgg; - } { + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { const _j = {} as JsonObjectAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); - if (isNode) { - return { - JsonObjectAgg: _j - }; - } return _j; }, - jsonArrayAgg(_p?: JsonArrayAgg, isNode?: boolean): JsonArrayAgg | { - JsonArrayAgg: JsonArrayAgg; - } { + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { const _j = {} as JsonArrayAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); - if (isNode) { - return { - JsonArrayAgg: _j - }; - } return _j; }, - rawStmt(_p?: RawStmt, isNode?: boolean): RawStmt | { - RawStmt: RawStmt; - } { + rawStmt(_p?: RawStmt): RawStmt { const _j = {} as RawStmt; _o.set(_j, "stmt", _p?.stmt); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - RawStmt: _j - }; - } return _j; }, - insertStmt(_p?: InsertStmt, isNode?: boolean): InsertStmt | { - InsertStmt: InsertStmt; - } { + insertStmt(_p?: InsertStmt): InsertStmt { const _j = {} as InsertStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cols", _p?.cols); @@ -2146,32 +1262,18 @@ export default { _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); _o.set(_j, "override", _p?.override); - if (isNode) { - return { - InsertStmt: _j - }; - } return _j; }, - deleteStmt(_p?: DeleteStmt, isNode?: boolean): DeleteStmt | { - DeleteStmt: DeleteStmt; - } { + deleteStmt(_p?: DeleteStmt): DeleteStmt { const _j = {} as DeleteStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "usingClause", _p?.usingClause); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - DeleteStmt: _j - }; - } return _j; }, - updateStmt(_p?: UpdateStmt, isNode?: boolean): UpdateStmt | { - UpdateStmt: UpdateStmt; - } { + updateStmt(_p?: UpdateStmt): UpdateStmt { const _j = {} as UpdateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "targetList", _p?.targetList); @@ -2179,32 +1281,18 @@ export default { _o.set(_j, "fromClause", _p?.fromClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - UpdateStmt: _j - }; - } return _j; }, - mergeStmt(_p?: MergeStmt, isNode?: boolean): MergeStmt | { - MergeStmt: MergeStmt; - } { + mergeStmt(_p?: MergeStmt): MergeStmt { const _j = {} as MergeStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "sourceRelation", _p?.sourceRelation); _o.set(_j, "joinCondition", _p?.joinCondition); _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - MergeStmt: _j - }; - } return _j; }, - selectStmt(_p?: SelectStmt, isNode?: boolean): SelectStmt | { - SelectStmt: SelectStmt; - } { + selectStmt(_p?: SelectStmt): SelectStmt { const _j = {} as SelectStmt; _o.set(_j, "distinctClause", _p?.distinctClause); _o.set(_j, "intoClause", _p?.intoClause); @@ -2226,16 +1314,9 @@ export default { _o.set(_j, "all", _p?.all); _o.set(_j, "larg", _p?.larg); _o.set(_j, "rarg", _p?.rarg); - if (isNode) { - return { - SelectStmt: _j - }; - } return _j; }, - setOperationStmt(_p?: SetOperationStmt, isNode?: boolean): SetOperationStmt | { - SetOperationStmt: SetOperationStmt; - } { + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { const _j = {} as SetOperationStmt; _o.set(_j, "op", _p?.op); _o.set(_j, "all", _p?.all); @@ -2245,87 +1326,45 @@ export default { _o.set(_j, "colTypmods", _p?.colTypmods); _o.set(_j, "colCollations", _p?.colCollations); _o.set(_j, "groupClauses", _p?.groupClauses); - if (isNode) { - return { - SetOperationStmt: _j - }; - } return _j; }, - returnStmt(_p?: ReturnStmt, isNode?: boolean): ReturnStmt | { - ReturnStmt: ReturnStmt; - } { + returnStmt(_p?: ReturnStmt): ReturnStmt { const _j = {} as ReturnStmt; _o.set(_j, "returnval", _p?.returnval); - if (isNode) { - return { - ReturnStmt: _j - }; - } return _j; }, - plAssignStmt(_p?: PLAssignStmt, isNode?: boolean): PLAssignStmt | { - PLAssignStmt: PLAssignStmt; - } { + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { const _j = {} as PLAssignStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "nnames", _p?.nnames); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PLAssignStmt: _j - }; - } return _j; }, - createSchemaStmt(_p?: CreateSchemaStmt, isNode?: boolean): CreateSchemaStmt | { - CreateSchemaStmt: CreateSchemaStmt; - } { + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { const _j = {} as CreateSchemaStmt; _o.set(_j, "schemaname", _p?.schemaname); _o.set(_j, "authrole", _p?.authrole); _o.set(_j, "schemaElts", _p?.schemaElts); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSchemaStmt: _j - }; - } return _j; }, - alterTableStmt(_p?: AlterTableStmt, isNode?: boolean): AlterTableStmt | { - AlterTableStmt: AlterTableStmt; - } { + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { const _j = {} as AlterTableStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cmds", _p?.cmds); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTableStmt: _j - }; - } return _j; }, - replicaIdentityStmt(_p?: ReplicaIdentityStmt, isNode?: boolean): ReplicaIdentityStmt | { - ReplicaIdentityStmt: ReplicaIdentityStmt; - } { + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { const _j = {} as ReplicaIdentityStmt; _o.set(_j, "identity_type", _p?.identity_type); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - ReplicaIdentityStmt: _j - }; - } return _j; }, - alterTableCmd(_p?: AlterTableCmd, isNode?: boolean): AlterTableCmd | { - AlterTableCmd: AlterTableCmd; - } { + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { const _j = {} as AlterTableCmd; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "name", _p?.name); @@ -2335,28 +1374,14 @@ export default { _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "recurse", _p?.recurse); - if (isNode) { - return { - AlterTableCmd: _j - }; - } return _j; }, - alterCollationStmt(_p?: AlterCollationStmt, isNode?: boolean): AlterCollationStmt | { - AlterCollationStmt: AlterCollationStmt; - } { + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { const _j = {} as AlterCollationStmt; _o.set(_j, "collname", _p?.collname); - if (isNode) { - return { - AlterCollationStmt: _j - }; - } return _j; }, - alterDomainStmt(_p?: AlterDomainStmt, isNode?: boolean): AlterDomainStmt | { - AlterDomainStmt: AlterDomainStmt; - } { + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { const _j = {} as AlterDomainStmt; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "typeName", _p?.typeName); @@ -2364,16 +1389,9 @@ export default { _o.set(_j, "def", _p?.def); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterDomainStmt: _j - }; - } return _j; }, - grantStmt(_p?: GrantStmt, isNode?: boolean): GrantStmt | { - GrantStmt: GrantStmt; - } { + grantStmt(_p?: GrantStmt): GrantStmt { const _j = {} as GrantStmt; _o.set(_j, "is_grant", _p?.is_grant); _o.set(_j, "targtype", _p?.targtype); @@ -2384,44 +1402,23 @@ export default { _o.set(_j, "grant_option", _p?.grant_option); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantStmt: _j - }; - } return _j; }, - objectWithArgs(_p?: ObjectWithArgs, isNode?: boolean): ObjectWithArgs | { - ObjectWithArgs: ObjectWithArgs; - } { + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { const _j = {} as ObjectWithArgs; _o.set(_j, "objname", _p?.objname); _o.set(_j, "objargs", _p?.objargs); _o.set(_j, "objfuncargs", _p?.objfuncargs); _o.set(_j, "args_unspecified", _p?.args_unspecified); - if (isNode) { - return { - ObjectWithArgs: _j - }; - } return _j; }, - accessPriv(_p?: AccessPriv, isNode?: boolean): AccessPriv | { - AccessPriv: AccessPriv; - } { + accessPriv(_p?: AccessPriv): AccessPriv { const _j = {} as AccessPriv; _o.set(_j, "priv_name", _p?.priv_name); _o.set(_j, "cols", _p?.cols); - if (isNode) { - return { - AccessPriv: _j - }; - } return _j; }, - grantRoleStmt(_p?: GrantRoleStmt, isNode?: boolean): GrantRoleStmt | { - GrantRoleStmt: GrantRoleStmt; - } { + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { const _j = {} as GrantRoleStmt; _o.set(_j, "granted_roles", _p?.granted_roles); _o.set(_j, "grantee_roles", _p?.grantee_roles); @@ -2429,29 +1426,15 @@ export default { _o.set(_j, "opt", _p?.opt); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantRoleStmt: _j - }; - } return _j; }, - alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt, isNode?: boolean): AlterDefaultPrivilegesStmt | { - AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; - } { + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { const _j = {} as AlterDefaultPrivilegesStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterDefaultPrivilegesStmt: _j - }; - } return _j; }, - copyStmt(_p?: CopyStmt, isNode?: boolean): CopyStmt | { - CopyStmt: CopyStmt; - } { + copyStmt(_p?: CopyStmt): CopyStmt { const _j = {} as CopyStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "query", _p?.query); @@ -2461,43 +1444,22 @@ export default { _o.set(_j, "filename", _p?.filename); _o.set(_j, "options", _p?.options); _o.set(_j, "whereClause", _p?.whereClause); - if (isNode) { - return { - CopyStmt: _j - }; - } return _j; }, - variableSetStmt(_p?: VariableSetStmt, isNode?: boolean): VariableSetStmt | { - VariableSetStmt: VariableSetStmt; - } { + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { const _j = {} as VariableSetStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "args", _p?.args); _o.set(_j, "is_local", _p?.is_local); - if (isNode) { - return { - VariableSetStmt: _j - }; - } return _j; }, - variableShowStmt(_p?: VariableShowStmt, isNode?: boolean): VariableShowStmt | { - VariableShowStmt: VariableShowStmt; - } { + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { const _j = {} as VariableShowStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - VariableShowStmt: _j - }; - } return _j; }, - createStmt(_p?: CreateStmt, isNode?: boolean): CreateStmt | { - CreateStmt: CreateStmt; - } { + createStmt(_p?: CreateStmt): CreateStmt { const _j = {} as CreateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "tableElts", _p?.tableElts); @@ -2511,16 +1473,9 @@ export default { _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "accessMethod", _p?.accessMethod); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStmt: _j - }; - } return _j; }, - constraint(_p?: Constraint, isNode?: boolean): Constraint | { - Constraint: Constraint; - } { + constraint(_p?: Constraint): Constraint { const _j = {} as Constraint; _o.set(_j, "contype", _p?.contype); _o.set(_j, "conname", _p?.conname); @@ -2552,144 +1507,74 @@ export default { _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); _o.set(_j, "skip_validation", _p?.skip_validation); _o.set(_j, "initially_valid", _p?.initially_valid); - if (isNode) { - return { - Constraint: _j - }; - } return _j; }, - createTableSpaceStmt(_p?: CreateTableSpaceStmt, isNode?: boolean): CreateTableSpaceStmt | { - CreateTableSpaceStmt: CreateTableSpaceStmt; - } { + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { const _j = {} as CreateTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "owner", _p?.owner); _o.set(_j, "location", _p?.location); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateTableSpaceStmt: _j - }; - } return _j; }, - dropTableSpaceStmt(_p?: DropTableSpaceStmt, isNode?: boolean): DropTableSpaceStmt | { - DropTableSpaceStmt: DropTableSpaceStmt; - } { + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { const _j = {} as DropTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropTableSpaceStmt: _j - }; - } return _j; }, - alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt, isNode?: boolean): AlterTableSpaceOptionsStmt | { - AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; - } { + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { const _j = {} as AlterTableSpaceOptionsStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "options", _p?.options); _o.set(_j, "isReset", _p?.isReset); - if (isNode) { - return { - AlterTableSpaceOptionsStmt: _j - }; - } return _j; }, - alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt, isNode?: boolean): AlterTableMoveAllStmt | { - AlterTableMoveAllStmt: AlterTableMoveAllStmt; - } { + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { const _j = {} as AlterTableMoveAllStmt; _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "roles", _p?.roles); _o.set(_j, "new_tablespacename", _p?.new_tablespacename); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - AlterTableMoveAllStmt: _j - }; - } return _j; }, - createExtensionStmt(_p?: CreateExtensionStmt, isNode?: boolean): CreateExtensionStmt | { - CreateExtensionStmt: CreateExtensionStmt; - } { + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { const _j = {} as CreateExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateExtensionStmt: _j - }; - } return _j; }, - alterExtensionStmt(_p?: AlterExtensionStmt, isNode?: boolean): AlterExtensionStmt | { - AlterExtensionStmt: AlterExtensionStmt; - } { + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { const _j = {} as AlterExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterExtensionStmt: _j - }; - } return _j; }, - alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt, isNode?: boolean): AlterExtensionContentsStmt | { - AlterExtensionContentsStmt: AlterExtensionContentsStmt; - } { + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { const _j = {} as AlterExtensionContentsStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "action", _p?.action); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); - if (isNode) { - return { - AlterExtensionContentsStmt: _j - }; - } return _j; }, - createFdwStmt(_p?: CreateFdwStmt, isNode?: boolean): CreateFdwStmt | { - CreateFdwStmt: CreateFdwStmt; - } { + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { const _j = {} as CreateFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateFdwStmt: _j - }; - } return _j; }, - alterFdwStmt(_p?: AlterFdwStmt, isNode?: boolean): AlterFdwStmt | { - AlterFdwStmt: AlterFdwStmt; - } { + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { const _j = {} as AlterFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterFdwStmt: _j - }; - } return _j; }, - createForeignServerStmt(_p?: CreateForeignServerStmt, isNode?: boolean): CreateForeignServerStmt | { - CreateForeignServerStmt: CreateForeignServerStmt; - } { + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { const _j = {} as CreateForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "servertype", _p?.servertype); @@ -2697,88 +1582,46 @@ export default { _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignServerStmt: _j - }; - } return _j; }, - alterForeignServerStmt(_p?: AlterForeignServerStmt, isNode?: boolean): AlterForeignServerStmt | { - AlterForeignServerStmt: AlterForeignServerStmt; - } { + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { const _j = {} as AlterForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "version", _p?.version); _o.set(_j, "options", _p?.options); _o.set(_j, "has_version", _p?.has_version); - if (isNode) { - return { - AlterForeignServerStmt: _j - }; - } return _j; }, - createForeignTableStmt(_p?: CreateForeignTableStmt, isNode?: boolean): CreateForeignTableStmt | { - CreateForeignTableStmt: CreateForeignTableStmt; - } { + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { const _j = {} as CreateForeignTableStmt; _o.set(_j, "base", _p?.base); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignTableStmt: _j - }; - } return _j; }, - createUserMappingStmt(_p?: CreateUserMappingStmt, isNode?: boolean): CreateUserMappingStmt | { - CreateUserMappingStmt: CreateUserMappingStmt; - } { + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { const _j = {} as CreateUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateUserMappingStmt: _j - }; - } return _j; }, - alterUserMappingStmt(_p?: AlterUserMappingStmt, isNode?: boolean): AlterUserMappingStmt | { - AlterUserMappingStmt: AlterUserMappingStmt; - } { + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { const _j = {} as AlterUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterUserMappingStmt: _j - }; - } return _j; }, - dropUserMappingStmt(_p?: DropUserMappingStmt, isNode?: boolean): DropUserMappingStmt | { - DropUserMappingStmt: DropUserMappingStmt; - } { + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { const _j = {} as DropUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropUserMappingStmt: _j - }; - } return _j; }, - importForeignSchemaStmt(_p?: ImportForeignSchemaStmt, isNode?: boolean): ImportForeignSchemaStmt | { - ImportForeignSchemaStmt: ImportForeignSchemaStmt; - } { + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { const _j = {} as ImportForeignSchemaStmt; _o.set(_j, "server_name", _p?.server_name); _o.set(_j, "remote_schema", _p?.remote_schema); @@ -2786,16 +1629,9 @@ export default { _o.set(_j, "list_type", _p?.list_type); _o.set(_j, "table_list", _p?.table_list); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ImportForeignSchemaStmt: _j - }; - } return _j; }, - createPolicyStmt(_p?: CreatePolicyStmt, isNode?: boolean): CreatePolicyStmt | { - CreatePolicyStmt: CreatePolicyStmt; - } { + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { const _j = {} as CreatePolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); @@ -2804,46 +1640,25 @@ export default { _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - CreatePolicyStmt: _j - }; - } return _j; }, - alterPolicyStmt(_p?: AlterPolicyStmt, isNode?: boolean): AlterPolicyStmt | { - AlterPolicyStmt: AlterPolicyStmt; - } { + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { const _j = {} as AlterPolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - AlterPolicyStmt: _j - }; - } return _j; }, - createAmStmt(_p?: CreateAmStmt, isNode?: boolean): CreateAmStmt | { - CreateAmStmt: CreateAmStmt; - } { + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { const _j = {} as CreateAmStmt; _o.set(_j, "amname", _p?.amname); _o.set(_j, "handler_name", _p?.handler_name); _o.set(_j, "amtype", _p?.amtype); - if (isNode) { - return { - CreateAmStmt: _j - }; - } return _j; }, - createTrigStmt(_p?: CreateTrigStmt, isNode?: boolean): CreateTrigStmt | { - CreateTrigStmt: CreateTrigStmt; - } { + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { const _j = {} as CreateTrigStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "isconstraint", _p?.isconstraint); @@ -2860,44 +1675,23 @@ export default { _o.set(_j, "deferrable", _p?.deferrable); _o.set(_j, "initdeferred", _p?.initdeferred); _o.set(_j, "constrrel", _p?.constrrel); - if (isNode) { - return { - CreateTrigStmt: _j - }; - } return _j; }, - createEventTrigStmt(_p?: CreateEventTrigStmt, isNode?: boolean): CreateEventTrigStmt | { - CreateEventTrigStmt: CreateEventTrigStmt; - } { + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { const _j = {} as CreateEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "eventname", _p?.eventname); _o.set(_j, "whenclause", _p?.whenclause); _o.set(_j, "funcname", _p?.funcname); - if (isNode) { - return { - CreateEventTrigStmt: _j - }; - } return _j; }, - alterEventTrigStmt(_p?: AlterEventTrigStmt, isNode?: boolean): AlterEventTrigStmt | { - AlterEventTrigStmt: AlterEventTrigStmt; - } { + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { const _j = {} as AlterEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "tgenabled", _p?.tgenabled); - if (isNode) { - return { - AlterEventTrigStmt: _j - }; - } return _j; }, - createpLangStmt(_p?: CreatePLangStmt, isNode?: boolean): CreatePLangStmt | { - CreatePLangStmt: CreatePLangStmt; - } { + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { const _j = {} as CreatePLangStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "plname", _p?.plname); @@ -2905,102 +1699,53 @@ export default { _o.set(_j, "plinline", _p?.plinline); _o.set(_j, "plvalidator", _p?.plvalidator); _o.set(_j, "pltrusted", _p?.pltrusted); - if (isNode) { - return { - CreatePLangStmt: _j - }; - } return _j; }, - createRoleStmt(_p?: CreateRoleStmt, isNode?: boolean): CreateRoleStmt | { - CreateRoleStmt: CreateRoleStmt; - } { + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { const _j = {} as CreateRoleStmt; _o.set(_j, "stmt_type", _p?.stmt_type); _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateRoleStmt: _j - }; - } return _j; }, - alterRoleStmt(_p?: AlterRoleStmt, isNode?: boolean): AlterRoleStmt | { - AlterRoleStmt: AlterRoleStmt; - } { + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { const _j = {} as AlterRoleStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterRoleStmt: _j - }; - } return _j; }, - alterRoleSetStmt(_p?: AlterRoleSetStmt, isNode?: boolean): AlterRoleSetStmt | { - AlterRoleSetStmt: AlterRoleSetStmt; - } { + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { const _j = {} as AlterRoleSetStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "database", _p?.database); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterRoleSetStmt: _j - }; - } return _j; }, - dropRoleStmt(_p?: DropRoleStmt, isNode?: boolean): DropRoleStmt | { - DropRoleStmt: DropRoleStmt; - } { + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { const _j = {} as DropRoleStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropRoleStmt: _j - }; - } return _j; }, - createSeqStmt(_p?: CreateSeqStmt, isNode?: boolean): CreateSeqStmt | { - CreateSeqStmt: CreateSeqStmt; - } { + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { const _j = {} as CreateSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "ownerId", _p?.ownerId); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSeqStmt: _j - }; - } return _j; }, - alterSeqStmt(_p?: AlterSeqStmt, isNode?: boolean): AlterSeqStmt | { - AlterSeqStmt: AlterSeqStmt; - } { + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { const _j = {} as AlterSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterSeqStmt: _j - }; - } return _j; }, - defineStmt(_p?: DefineStmt, isNode?: boolean): DefineStmt | { - DefineStmt: DefineStmt; - } { + defineStmt(_p?: DefineStmt): DefineStmt { const _j = {} as DefineStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "oldstyle", _p?.oldstyle); @@ -3009,31 +1754,17 @@ export default { _o.set(_j, "definition", _p?.definition); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - DefineStmt: _j - }; - } return _j; }, - createDomainStmt(_p?: CreateDomainStmt, isNode?: boolean): CreateDomainStmt | { - CreateDomainStmt: CreateDomainStmt; - } { + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { const _j = {} as CreateDomainStmt; _o.set(_j, "domainname", _p?.domainname); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "collClause", _p?.collClause); _o.set(_j, "constraints", _p?.constraints); - if (isNode) { - return { - CreateDomainStmt: _j - }; - } return _j; }, - createOpClassStmt(_p?: CreateOpClassStmt, isNode?: boolean): CreateOpClassStmt | { - CreateOpClassStmt: CreateOpClassStmt; - } { + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { const _j = {} as CreateOpClassStmt; _o.set(_j, "opclassname", _p?.opclassname); _o.set(_j, "opfamilyname", _p?.opfamilyname); @@ -3041,16 +1772,9 @@ export default { _o.set(_j, "datatype", _p?.datatype); _o.set(_j, "items", _p?.items); _o.set(_j, "isDefault", _p?.isDefault); - if (isNode) { - return { - CreateOpClassStmt: _j - }; - } return _j; }, - createOpClassItem(_p?: CreateOpClassItem, isNode?: boolean): CreateOpClassItem | { - CreateOpClassItem: CreateOpClassItem; - } { + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { const _j = {} as CreateOpClassItem; _o.set(_j, "itemtype", _p?.itemtype); _o.set(_j, "name", _p?.name); @@ -3058,144 +1782,74 @@ export default { _o.set(_j, "order_family", _p?.order_family); _o.set(_j, "class_args", _p?.class_args); _o.set(_j, "storedtype", _p?.storedtype); - if (isNode) { - return { - CreateOpClassItem: _j - }; - } return _j; }, - createOpFamilyStmt(_p?: CreateOpFamilyStmt, isNode?: boolean): CreateOpFamilyStmt | { - CreateOpFamilyStmt: CreateOpFamilyStmt; - } { + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { const _j = {} as CreateOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); - if (isNode) { - return { - CreateOpFamilyStmt: _j - }; - } return _j; }, - alterOpFamilyStmt(_p?: AlterOpFamilyStmt, isNode?: boolean): AlterOpFamilyStmt | { - AlterOpFamilyStmt: AlterOpFamilyStmt; - } { + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { const _j = {} as AlterOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); _o.set(_j, "isDrop", _p?.isDrop); _o.set(_j, "items", _p?.items); - if (isNode) { - return { - AlterOpFamilyStmt: _j - }; - } return _j; }, - dropStmt(_p?: DropStmt, isNode?: boolean): DropStmt | { - DropStmt: DropStmt; - } { + dropStmt(_p?: DropStmt): DropStmt { const _j = {} as DropStmt; _o.set(_j, "objects", _p?.objects); _o.set(_j, "removeType", _p?.removeType); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - DropStmt: _j - }; - } return _j; }, - truncateStmt(_p?: TruncateStmt, isNode?: boolean): TruncateStmt | { - TruncateStmt: TruncateStmt; - } { + truncateStmt(_p?: TruncateStmt): TruncateStmt { const _j = {} as TruncateStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "restart_seqs", _p?.restart_seqs); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - TruncateStmt: _j - }; - } return _j; }, - commentStmt(_p?: CommentStmt, isNode?: boolean): CommentStmt | { - CommentStmt: CommentStmt; - } { + commentStmt(_p?: CommentStmt): CommentStmt { const _j = {} as CommentStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "comment", _p?.comment); - if (isNode) { - return { - CommentStmt: _j - }; - } return _j; }, - secLabelStmt(_p?: SecLabelStmt, isNode?: boolean): SecLabelStmt | { - SecLabelStmt: SecLabelStmt; - } { + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { const _j = {} as SecLabelStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "provider", _p?.provider); _o.set(_j, "label", _p?.label); - if (isNode) { - return { - SecLabelStmt: _j - }; - } return _j; }, - declareCursorStmt(_p?: DeclareCursorStmt, isNode?: boolean): DeclareCursorStmt | { - DeclareCursorStmt: DeclareCursorStmt; - } { + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { const _j = {} as DeclareCursorStmt; _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "options", _p?.options); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - DeclareCursorStmt: _j - }; - } return _j; }, - closePortalStmt(_p?: ClosePortalStmt, isNode?: boolean): ClosePortalStmt | { - ClosePortalStmt: ClosePortalStmt; - } { + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { const _j = {} as ClosePortalStmt; _o.set(_j, "portalname", _p?.portalname); - if (isNode) { - return { - ClosePortalStmt: _j - }; - } return _j; }, - fetchStmt(_p?: FetchStmt, isNode?: boolean): FetchStmt | { - FetchStmt: FetchStmt; - } { + fetchStmt(_p?: FetchStmt): FetchStmt { const _j = {} as FetchStmt; _o.set(_j, "direction", _p?.direction); _o.set(_j, "howMany", _p?.howMany); _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "ismove", _p?.ismove); - if (isNode) { - return { - FetchStmt: _j - }; - } return _j; }, - indexStmt(_p?: IndexStmt, isNode?: boolean): IndexStmt | { - IndexStmt: IndexStmt; - } { + indexStmt(_p?: IndexStmt): IndexStmt { const _j = {} as IndexStmt; _o.set(_j, "idxname", _p?.idxname); _o.set(_j, "relation", _p?.relation); @@ -3221,16 +1875,9 @@ export default { _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); - if (isNode) { - return { - IndexStmt: _j - }; - } return _j; }, - createStatsStmt(_p?: CreateStatsStmt, isNode?: boolean): CreateStatsStmt | { - CreateStatsStmt: CreateStatsStmt; - } { + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { const _j = {} as CreateStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stat_types", _p?.stat_types); @@ -3239,43 +1886,22 @@ export default { _o.set(_j, "stxcomment", _p?.stxcomment); _o.set(_j, "transformed", _p?.transformed); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStatsStmt: _j - }; - } return _j; }, - statsElem(_p?: StatsElem, isNode?: boolean): StatsElem | { - StatsElem: StatsElem; - } { + statsElem(_p?: StatsElem): StatsElem { const _j = {} as StatsElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); - if (isNode) { - return { - StatsElem: _j - }; - } return _j; }, - alterStatsStmt(_p?: AlterStatsStmt, isNode?: boolean): AlterStatsStmt | { - AlterStatsStmt: AlterStatsStmt; - } { + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { const _j = {} as AlterStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stxstattarget", _p?.stxstattarget); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterStatsStmt: _j - }; - } return _j; }, - createFunctionStmt(_p?: CreateFunctionStmt, isNode?: boolean): CreateFunctionStmt | { - CreateFunctionStmt: CreateFunctionStmt; - } { + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { const _j = {} as CreateFunctionStmt; _o.set(_j, "is_procedure", _p?.is_procedure); _o.set(_j, "replace", _p?.replace); @@ -3284,98 +1910,49 @@ export default { _o.set(_j, "returnType", _p?.returnType); _o.set(_j, "options", _p?.options); _o.set(_j, "sql_body", _p?.sql_body); - if (isNode) { - return { - CreateFunctionStmt: _j - }; - } return _j; }, - functionParameter(_p?: FunctionParameter, isNode?: boolean): FunctionParameter | { - FunctionParameter: FunctionParameter; - } { + functionParameter(_p?: FunctionParameter): FunctionParameter { const _j = {} as FunctionParameter; _o.set(_j, "name", _p?.name); _o.set(_j, "argType", _p?.argType); _o.set(_j, "mode", _p?.mode); _o.set(_j, "defexpr", _p?.defexpr); - if (isNode) { - return { - FunctionParameter: _j - }; - } return _j; }, - alterFunctionStmt(_p?: AlterFunctionStmt, isNode?: boolean): AlterFunctionStmt | { - AlterFunctionStmt: AlterFunctionStmt; - } { + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { const _j = {} as AlterFunctionStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "func", _p?.func); _o.set(_j, "actions", _p?.actions); - if (isNode) { - return { - AlterFunctionStmt: _j - }; - } return _j; }, - doStmt(_p?: DoStmt, isNode?: boolean): DoStmt | { - DoStmt: DoStmt; - } { + doStmt(_p?: DoStmt): DoStmt { const _j = {} as DoStmt; _o.set(_j, "args", _p?.args); - if (isNode) { - return { - DoStmt: _j - }; - } return _j; }, - inlineCodeBlock(_p?: InlineCodeBlock, isNode?: boolean): InlineCodeBlock | { - InlineCodeBlock: InlineCodeBlock; - } { + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { const _j = {} as InlineCodeBlock; _o.set(_j, "source_text", _p?.source_text); _o.set(_j, "langOid", _p?.langOid); _o.set(_j, "langIsTrusted", _p?.langIsTrusted); _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - InlineCodeBlock: _j - }; - } return _j; }, - callStmt(_p?: CallStmt, isNode?: boolean): CallStmt | { - CallStmt: CallStmt; - } { + callStmt(_p?: CallStmt): CallStmt { const _j = {} as CallStmt; _o.set(_j, "funccall", _p?.funccall); _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "outargs", _p?.outargs); - if (isNode) { - return { - CallStmt: _j - }; - } return _j; }, - callContext(_p?: CallContext, isNode?: boolean): CallContext | { - CallContext: CallContext; - } { + callContext(_p?: CallContext): CallContext { const _j = {} as CallContext; _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - CallContext: _j - }; - } return _j; }, - renameStmt(_p?: RenameStmt, isNode?: boolean): RenameStmt | { - RenameStmt: RenameStmt; - } { + renameStmt(_p?: RenameStmt): RenameStmt { const _j = {} as RenameStmt; _o.set(_j, "renameType", _p?.renameType); _o.set(_j, "relationType", _p?.relationType); @@ -3385,89 +1962,47 @@ export default { _o.set(_j, "newname", _p?.newname); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - RenameStmt: _j - }; - } return _j; }, - alterObjectDependsStmt(_p?: AlterObjectDependsStmt, isNode?: boolean): AlterObjectDependsStmt | { - AlterObjectDependsStmt: AlterObjectDependsStmt; - } { + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { const _j = {} as AlterObjectDependsStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "extname", _p?.extname); _o.set(_j, "remove", _p?.remove); - if (isNode) { - return { - AlterObjectDependsStmt: _j - }; - } return _j; }, - alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt, isNode?: boolean): AlterObjectSchemaStmt | { - AlterObjectSchemaStmt: AlterObjectSchemaStmt; - } { + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { const _j = {} as AlterObjectSchemaStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newschema", _p?.newschema); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterObjectSchemaStmt: _j - }; - } return _j; }, - alterOwnerStmt(_p?: AlterOwnerStmt, isNode?: boolean): AlterOwnerStmt | { - AlterOwnerStmt: AlterOwnerStmt; - } { + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { const _j = {} as AlterOwnerStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newowner", _p?.newowner); - if (isNode) { - return { - AlterOwnerStmt: _j - }; - } return _j; }, - alterOperatorStmt(_p?: AlterOperatorStmt, isNode?: boolean): AlterOperatorStmt | { - AlterOperatorStmt: AlterOperatorStmt; - } { + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { const _j = {} as AlterOperatorStmt; _o.set(_j, "opername", _p?.opername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterOperatorStmt: _j - }; - } return _j; }, - alterTypeStmt(_p?: AlterTypeStmt, isNode?: boolean): AlterTypeStmt | { - AlterTypeStmt: AlterTypeStmt; - } { + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { const _j = {} as AlterTypeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTypeStmt: _j - }; - } return _j; }, - ruleStmt(_p?: RuleStmt, isNode?: boolean): RuleStmt | { - RuleStmt: RuleStmt; - } { + ruleStmt(_p?: RuleStmt): RuleStmt { const _j = {} as RuleStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "rulename", _p?.rulename); @@ -3476,108 +2011,52 @@ export default { _o.set(_j, "instead", _p?.instead); _o.set(_j, "actions", _p?.actions); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - RuleStmt: _j - }; - } return _j; }, - notifyStmt(_p?: NotifyStmt, isNode?: boolean): NotifyStmt | { - NotifyStmt: NotifyStmt; - } { + notifyStmt(_p?: NotifyStmt): NotifyStmt { const _j = {} as NotifyStmt; _o.set(_j, "conditionname", _p?.conditionname); _o.set(_j, "payload", _p?.payload); - if (isNode) { - return { - NotifyStmt: _j - }; - } return _j; }, - listenStmt(_p?: ListenStmt, isNode?: boolean): ListenStmt | { - ListenStmt: ListenStmt; - } { + listenStmt(_p?: ListenStmt): ListenStmt { const _j = {} as ListenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - ListenStmt: _j - }; - } return _j; }, - unlistenStmt(_p?: UnlistenStmt, isNode?: boolean): UnlistenStmt | { - UnlistenStmt: UnlistenStmt; - } { + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { const _j = {} as UnlistenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - UnlistenStmt: _j - }; - } return _j; }, - transactionStmt(_p?: TransactionStmt, isNode?: boolean): TransactionStmt | { - TransactionStmt: TransactionStmt; - } { + transactionStmt(_p?: TransactionStmt): TransactionStmt { const _j = {} as TransactionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "options", _p?.options); _o.set(_j, "savepoint_name", _p?.savepoint_name); _o.set(_j, "gid", _p?.gid); _o.set(_j, "chain", _p?.chain); - if (isNode) { - return { - TransactionStmt: _j - }; - } return _j; }, - compositeTypeStmt(_p?: CompositeTypeStmt, isNode?: boolean): CompositeTypeStmt | { - CompositeTypeStmt: CompositeTypeStmt; - } { + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { const _j = {} as CompositeTypeStmt; _o.set(_j, "typevar", _p?.typevar); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - CompositeTypeStmt: _j - }; - } return _j; }, - createEnumStmt(_p?: CreateEnumStmt, isNode?: boolean): CreateEnumStmt | { - CreateEnumStmt: CreateEnumStmt; - } { + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { const _j = {} as CreateEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "vals", _p?.vals); - if (isNode) { - return { - CreateEnumStmt: _j - }; - } return _j; }, - createRangeStmt(_p?: CreateRangeStmt, isNode?: boolean): CreateRangeStmt | { - CreateRangeStmt: CreateRangeStmt; - } { + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { const _j = {} as CreateRangeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - CreateRangeStmt: _j - }; - } return _j; }, - alterEnumStmt(_p?: AlterEnumStmt, isNode?: boolean): AlterEnumStmt | { - AlterEnumStmt: AlterEnumStmt; - } { + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { const _j = {} as AlterEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "oldVal", _p?.oldVal); @@ -3585,16 +2064,9 @@ export default { _o.set(_j, "newValNeighbor", _p?.newValNeighbor); _o.set(_j, "newValIsAfter", _p?.newValIsAfter); _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); - if (isNode) { - return { - AlterEnumStmt: _j - }; - } return _j; }, - viewStmt(_p?: ViewStmt, isNode?: boolean): ViewStmt | { - ViewStmt: ViewStmt; - } { + viewStmt(_p?: ViewStmt): ViewStmt { const _j = {} as ViewStmt; _o.set(_j, "view", _p?.view); _o.set(_j, "aliases", _p?.aliases); @@ -3602,381 +2074,185 @@ export default { _o.set(_j, "replace", _p?.replace); _o.set(_j, "options", _p?.options); _o.set(_j, "withCheckOption", _p?.withCheckOption); - if (isNode) { - return { - ViewStmt: _j - }; - } return _j; }, - loadStmt(_p?: LoadStmt, isNode?: boolean): LoadStmt | { - LoadStmt: LoadStmt; - } { + loadStmt(_p?: LoadStmt): LoadStmt { const _j = {} as LoadStmt; _o.set(_j, "filename", _p?.filename); - if (isNode) { - return { - LoadStmt: _j - }; - } return _j; }, - createdbStmt(_p?: CreatedbStmt, isNode?: boolean): CreatedbStmt | { - CreatedbStmt: CreatedbStmt; - } { + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { const _j = {} as CreatedbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreatedbStmt: _j - }; - } return _j; }, - alterDatabaseStmt(_p?: AlterDatabaseStmt, isNode?: boolean): AlterDatabaseStmt | { - AlterDatabaseStmt: AlterDatabaseStmt; - } { + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { const _j = {} as AlterDatabaseStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterDatabaseStmt: _j - }; - } return _j; }, - alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt, isNode?: boolean): AlterDatabaseRefreshCollStmt | { - AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; - } { + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { const _j = {} as AlterDatabaseRefreshCollStmt; _o.set(_j, "dbname", _p?.dbname); - if (isNode) { - return { - AlterDatabaseRefreshCollStmt: _j - }; - } return _j; }, - alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt, isNode?: boolean): AlterDatabaseSetStmt | { - AlterDatabaseSetStmt: AlterDatabaseSetStmt; - } { + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { const _j = {} as AlterDatabaseSetStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterDatabaseSetStmt: _j - }; - } return _j; }, - dropdbStmt(_p?: DropdbStmt, isNode?: boolean): DropdbStmt | { - DropdbStmt: DropdbStmt; - } { + dropdbStmt(_p?: DropdbStmt): DropdbStmt { const _j = {} as DropdbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - DropdbStmt: _j - }; - } return _j; }, - alterSystemStmt(_p?: AlterSystemStmt, isNode?: boolean): AlterSystemStmt | { - AlterSystemStmt: AlterSystemStmt; - } { + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { const _j = {} as AlterSystemStmt; _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterSystemStmt: _j - }; - } return _j; }, - clusterStmt(_p?: ClusterStmt, isNode?: boolean): ClusterStmt | { - ClusterStmt: ClusterStmt; - } { + clusterStmt(_p?: ClusterStmt): ClusterStmt { const _j = {} as ClusterStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "indexname", _p?.indexname); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ClusterStmt: _j - }; - } return _j; }, - vacuumStmt(_p?: VacuumStmt, isNode?: boolean): VacuumStmt | { - VacuumStmt: VacuumStmt; - } { + vacuumStmt(_p?: VacuumStmt): VacuumStmt { const _j = {} as VacuumStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "rels", _p?.rels); _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); - if (isNode) { - return { - VacuumStmt: _j - }; - } return _j; }, - vacuumRelation(_p?: VacuumRelation, isNode?: boolean): VacuumRelation | { - VacuumRelation: VacuumRelation; - } { + vacuumRelation(_p?: VacuumRelation): VacuumRelation { const _j = {} as VacuumRelation; _o.set(_j, "relation", _p?.relation); _o.set(_j, "oid", _p?.oid); _o.set(_j, "va_cols", _p?.va_cols); - if (isNode) { - return { - VacuumRelation: _j - }; - } return _j; }, - explainStmt(_p?: ExplainStmt, isNode?: boolean): ExplainStmt | { - ExplainStmt: ExplainStmt; - } { + explainStmt(_p?: ExplainStmt): ExplainStmt { const _j = {} as ExplainStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ExplainStmt: _j - }; - } return _j; }, - createTableAsStmt(_p?: CreateTableAsStmt, isNode?: boolean): CreateTableAsStmt | { - CreateTableAsStmt: CreateTableAsStmt; - } { + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { const _j = {} as CreateTableAsStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "into", _p?.into); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "is_select_into", _p?.is_select_into); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateTableAsStmt: _j - }; - } return _j; }, - refreshMatViewStmt(_p?: RefreshMatViewStmt, isNode?: boolean): RefreshMatViewStmt | { - RefreshMatViewStmt: RefreshMatViewStmt; - } { + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { const _j = {} as RefreshMatViewStmt; _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "skipData", _p?.skipData); _o.set(_j, "relation", _p?.relation); - if (isNode) { - return { - RefreshMatViewStmt: _j - }; - } return _j; }, - checkPointStmt(_p?: CheckPointStmt, isNode?: boolean): CheckPointStmt | { - CheckPointStmt: CheckPointStmt; - } { + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { const _j = {} as CheckPointStmt; - if (isNode) { - return { - CheckPointStmt: _j - }; - } return _j; }, - discardStmt(_p?: DiscardStmt, isNode?: boolean): DiscardStmt | { - DiscardStmt: DiscardStmt; - } { + discardStmt(_p?: DiscardStmt): DiscardStmt { const _j = {} as DiscardStmt; _o.set(_j, "target", _p?.target); - if (isNode) { - return { - DiscardStmt: _j - }; - } return _j; }, - lockStmt(_p?: LockStmt, isNode?: boolean): LockStmt | { - LockStmt: LockStmt; - } { + lockStmt(_p?: LockStmt): LockStmt { const _j = {} as LockStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "mode", _p?.mode); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - LockStmt: _j - }; - } return _j; }, - constraintsSetStmt(_p?: ConstraintsSetStmt, isNode?: boolean): ConstraintsSetStmt | { - ConstraintsSetStmt: ConstraintsSetStmt; - } { + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { const _j = {} as ConstraintsSetStmt; _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "deferred", _p?.deferred); - if (isNode) { - return { - ConstraintsSetStmt: _j - }; - } return _j; }, - reindexStmt(_p?: ReindexStmt, isNode?: boolean): ReindexStmt | { - ReindexStmt: ReindexStmt; - } { + reindexStmt(_p?: ReindexStmt): ReindexStmt { const _j = {} as ReindexStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relation", _p?.relation); _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ReindexStmt: _j - }; - } return _j; }, - createConversionStmt(_p?: CreateConversionStmt, isNode?: boolean): CreateConversionStmt | { - CreateConversionStmt: CreateConversionStmt; - } { + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { const _j = {} as CreateConversionStmt; _o.set(_j, "conversion_name", _p?.conversion_name); _o.set(_j, "for_encoding_name", _p?.for_encoding_name); _o.set(_j, "to_encoding_name", _p?.to_encoding_name); _o.set(_j, "func_name", _p?.func_name); _o.set(_j, "def", _p?.def); - if (isNode) { - return { - CreateConversionStmt: _j - }; - } return _j; }, - createCastStmt(_p?: CreateCastStmt, isNode?: boolean): CreateCastStmt | { - CreateCastStmt: CreateCastStmt; - } { + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { const _j = {} as CreateCastStmt; _o.set(_j, "sourcetype", _p?.sourcetype); _o.set(_j, "targettype", _p?.targettype); _o.set(_j, "func", _p?.func); _o.set(_j, "context", _p?.context); _o.set(_j, "inout", _p?.inout); - if (isNode) { - return { - CreateCastStmt: _j - }; - } return _j; }, - createTransformStmt(_p?: CreateTransformStmt, isNode?: boolean): CreateTransformStmt | { - CreateTransformStmt: CreateTransformStmt; - } { + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { const _j = {} as CreateTransformStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "type_name", _p?.type_name); _o.set(_j, "lang", _p?.lang); _o.set(_j, "fromsql", _p?.fromsql); _o.set(_j, "tosql", _p?.tosql); - if (isNode) { - return { - CreateTransformStmt: _j - }; - } return _j; }, - prepareStmt(_p?: PrepareStmt, isNode?: boolean): PrepareStmt | { - PrepareStmt: PrepareStmt; - } { + prepareStmt(_p?: PrepareStmt): PrepareStmt { const _j = {} as PrepareStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "argtypes", _p?.argtypes); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - PrepareStmt: _j - }; - } return _j; }, - executeStmt(_p?: ExecuteStmt, isNode?: boolean): ExecuteStmt | { - ExecuteStmt: ExecuteStmt; - } { + executeStmt(_p?: ExecuteStmt): ExecuteStmt { const _j = {} as ExecuteStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ExecuteStmt: _j - }; - } return _j; }, - deallocateStmt(_p?: DeallocateStmt, isNode?: boolean): DeallocateStmt | { - DeallocateStmt: DeallocateStmt; - } { + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { const _j = {} as DeallocateStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - DeallocateStmt: _j - }; - } return _j; }, - dropOwnedStmt(_p?: DropOwnedStmt, isNode?: boolean): DropOwnedStmt | { - DropOwnedStmt: DropOwnedStmt; - } { + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { const _j = {} as DropOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropOwnedStmt: _j - }; - } return _j; }, - reassignOwnedStmt(_p?: ReassignOwnedStmt, isNode?: boolean): ReassignOwnedStmt | { - ReassignOwnedStmt: ReassignOwnedStmt; - } { + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { const _j = {} as ReassignOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "newrole", _p?.newrole); - if (isNode) { - return { - ReassignOwnedStmt: _j - }; - } return _j; }, - altertsDictionaryStmt(_p?: AlterTSDictionaryStmt, isNode?: boolean): AlterTSDictionaryStmt | { - AlterTSDictionaryStmt: AlterTSDictionaryStmt; - } { + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { const _j = {} as AlterTSDictionaryStmt; _o.set(_j, "dictname", _p?.dictname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTSDictionaryStmt: _j - }; - } return _j; }, - altertsConfigurationStmt(_p?: AlterTSConfigurationStmt, isNode?: boolean): AlterTSConfigurationStmt | { - AlterTSConfigurationStmt: AlterTSConfigurationStmt; - } { + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { const _j = {} as AlterTSConfigurationStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "cfgname", _p?.cfgname); @@ -3985,131 +2261,70 @@ export default { _o.set(_j, "override", _p?.override); _o.set(_j, "replace", _p?.replace); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTSConfigurationStmt: _j - }; - } return _j; }, - publicationTable(_p?: PublicationTable, isNode?: boolean): PublicationTable | { - PublicationTable: PublicationTable; - } { + publicationTable(_p?: PublicationTable): PublicationTable { const _j = {} as PublicationTable; _o.set(_j, "relation", _p?.relation); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "columns", _p?.columns); - if (isNode) { - return { - PublicationTable: _j - }; - } return _j; }, - publicationObjSpec(_p?: PublicationObjSpec, isNode?: boolean): PublicationObjSpec | { - PublicationObjSpec: PublicationObjSpec; - } { + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { const _j = {} as PublicationObjSpec; _o.set(_j, "pubobjtype", _p?.pubobjtype); _o.set(_j, "name", _p?.name); _o.set(_j, "pubtable", _p?.pubtable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PublicationObjSpec: _j - }; - } return _j; }, - createPublicationStmt(_p?: CreatePublicationStmt, isNode?: boolean): CreatePublicationStmt | { - CreatePublicationStmt: CreatePublicationStmt; - } { + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { const _j = {} as CreatePublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); - if (isNode) { - return { - CreatePublicationStmt: _j - }; - } return _j; }, - alterPublicationStmt(_p?: AlterPublicationStmt, isNode?: boolean): AlterPublicationStmt | { - AlterPublicationStmt: AlterPublicationStmt; - } { + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { const _j = {} as AlterPublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterPublicationStmt: _j - }; - } return _j; }, - createSubscriptionStmt(_p?: CreateSubscriptionStmt, isNode?: boolean): CreateSubscriptionStmt | { - CreateSubscriptionStmt: CreateSubscriptionStmt; - } { + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { const _j = {} as CreateSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateSubscriptionStmt: _j - }; - } return _j; }, - alterSubscriptionStmt(_p?: AlterSubscriptionStmt, isNode?: boolean): AlterSubscriptionStmt | { - AlterSubscriptionStmt: AlterSubscriptionStmt; - } { + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { const _j = {} as AlterSubscriptionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterSubscriptionStmt: _j - }; - } return _j; }, - dropSubscriptionStmt(_p?: DropSubscriptionStmt, isNode?: boolean): DropSubscriptionStmt | { - DropSubscriptionStmt: DropSubscriptionStmt; - } { + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { const _j = {} as DropSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropSubscriptionStmt: _j - }; - } return _j; }, - scanToken(_p?: ScanToken, isNode?: boolean): ScanToken | { - ScanToken: ScanToken; - } { + scanToken(_p?: ScanToken): ScanToken { const _j = {} as ScanToken; _o.set(_j, "start", _p?.start); _o.set(_j, "end", _p?.end); _o.set(_j, "token", _p?.token); _o.set(_j, "keywordKind", _p?.keywordKind); - if (isNode) { - return { - ScanToken: _j - }; - } return _j; } }; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/unwrappedHelpers/asts.ts b/__fixtures__/output/utils/astHelpers/unwrappedHelpers/asts.ts new file mode 100644 index 00000000..002ec189 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/unwrappedHelpers/asts.ts @@ -0,0 +1,2330 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): ParseResult { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return _j; + }, + scanResult(_p?: ScanResult): ScanResult { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return _j; + }, + integer(_p?: Integer): Integer { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return _j; + }, + float(_p?: Float): Float { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return _j; + }, + boolean(_p?: Boolean): Boolean { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return _j; + }, + string(_p?: String): String { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return _j; + }, + bitString(_p?: BitString): BitString { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return _j; + }, + list(_p?: List): List { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return _j; + }, + oidList(_p?: OidList): OidList { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return _j; + }, + intList(_p?: IntList): IntList { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return _j; + }, + aConst(_p?: A_Const): A_Const { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return _j; + }, + alias(_p?: Alias): Alias { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return _j; + }, + rangeVar(_p?: RangeVar): RangeVar { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableFunc(_p?: TableFunc): TableFunc { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return _j; + }, + intoClause(_p?: IntoClause): IntoClause { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return _j; + }, + var(_p?: Var): Var { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + param(_p?: Param): Param { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return _j; + }, + aggref(_p?: Aggref): Aggref { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return _j; + }, + groupingFunc(_p?: GroupingFunc): GroupingFunc { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowFunc(_p?: WindowFunc): WindowFunc { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return _j; + }, + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return _j; + }, + funcExpr(_p?: FuncExpr): FuncExpr { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return _j; + }, + opExpr(_p?: OpExpr): OpExpr { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + distinctExpr(_p?: DistinctExpr): DistinctExpr { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullIfExpr(_p?: NullIfExpr): NullIfExpr { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + boolExpr(_p?: BoolExpr): BoolExpr { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + subLink(_p?: SubLink): SubLink { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return _j; + }, + subPlan(_p?: SubPlan): SubPlan { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return _j; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return _j; + }, + fieldSelect(_p?: FieldSelect): FieldSelect { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return _j; + }, + fieldStore(_p?: FieldStore): FieldStore { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return _j; + }, + relabelType(_p?: RelabelType): RelabelType { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateExpr(_p?: CollateExpr): CollateExpr { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseExpr(_p?: CaseExpr): CaseExpr { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseWhen(_p?: CaseWhen): CaseWhen { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return _j; + }, + arrayExpr(_p?: ArrayExpr): ArrayExpr { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowExpr(_p?: RowExpr): RowExpr { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return _j; + }, + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + xmlExpr(_p?: XmlExpr): XmlExpr { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonFormat(_p?: JsonFormat): JsonFormat { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonReturning(_p?: JsonReturning): JsonReturning { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return _j; + }, + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return _j; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullTest(_p?: NullTest): NullTest { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return _j; + }, + booleanTest(_p?: BooleanTest): BooleanTest { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + setToDefault(_p?: SetToDefault): SetToDefault { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return _j; + }, + nextValueExpr(_p?: NextValueExpr): NextValueExpr { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return _j; + }, + inferenceElem(_p?: InferenceElem): InferenceElem { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return _j; + }, + targetEntry(_p?: TargetEntry): TargetEntry { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return _j; + }, + rangeTblRef(_p?: RangeTblRef): RangeTblRef { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + joinExpr(_p?: JoinExpr): JoinExpr { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + fromExpr(_p?: FromExpr): FromExpr { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return _j; + }, + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return _j; + }, + query(_p?: Query): Query { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + typeName(_p?: TypeName): TypeName { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnRef(_p?: ColumnRef): ColumnRef { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return _j; + }, + paramRef(_p?: ParamRef): ParamRef { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return _j; + }, + aExpr(_p?: A_Expr): A_Expr { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + typeCast(_p?: TypeCast): TypeCast { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateClause(_p?: CollateClause): CollateClause { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return _j; + }, + roleSpec(_p?: RoleSpec): RoleSpec { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return _j; + }, + funcCall(_p?: FuncCall): FuncCall { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + aStar(_p?: A_Star): A_Star { + const _j = {} as A_Star; + return _j; + }, + aIndices(_p?: A_Indices): A_Indices { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return _j; + }, + aIndirection(_p?: A_Indirection): A_Indirection { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return _j; + }, + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return _j; + }, + resTarget(_p?: ResTarget): ResTarget { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return _j; + }, + sortBy(_p?: SortBy): SortBy { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowDef(_p?: WindowDef): WindowDef { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeSubselect(_p?: RangeSubselect): RangeSubselect { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return _j; + }, + rangeFunction(_p?: RangeFunction): RangeFunction { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableSample(_p?: RangeTableSample): RangeTableSample { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnDef(_p?: ColumnDef): ColumnDef { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableLikeClause(_p?: TableLikeClause): TableLikeClause { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return _j; + }, + indexElem(_p?: IndexElem): IndexElem { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return _j; + }, + defElem(_p?: DefElem): DefElem { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return _j; + }, + lockingClause(_p?: LockingClause): LockingClause { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return _j; + }, + xmlSerialize(_p?: XmlSerialize): XmlSerialize { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionElem(_p?: PartitionElem): PartitionElem { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionSpec(_p?: PartitionSpec): PartitionSpec { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionCmd(_p?: PartitionCmd): PartitionCmd { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return _j; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return _j; + }, + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return _j; + }, + tableSampleClause(_p?: TableSampleClause): TableSampleClause { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return _j; + }, + withCheckOption(_p?: WithCheckOption): WithCheckOption { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return _j; + }, + sortGroupClause(_p?: SortGroupClause): SortGroupClause { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return _j; + }, + groupingSet(_p?: GroupingSet): GroupingSet { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowClause(_p?: WindowClause): WindowClause { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return _j; + }, + rowMarkClause(_p?: RowMarkClause): RowMarkClause { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return _j; + }, + withClause(_p?: WithClause): WithClause { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return _j; + }, + inferClause(_p?: InferClause): InferClause { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return _j; + }, + onConflictClause(_p?: OnConflictClause): OnConflictClause { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteSearchClause(_p?: CTESearchClause): CTESearchClause { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteCycleClause(_p?: CTECycleClause): CTECycleClause { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return _j; + }, + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return _j; + }, + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return _j; + }, + mergeAction(_p?: MergeAction): MergeAction { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return _j; + }, + triggerTransition(_p?: TriggerTransition): TriggerTransition { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return _j; + }, + jsonOutput(_p?: JsonOutput): JsonOutput { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return _j; + }, + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return _j; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return _j; + }, + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return _j; + }, + rawStmt(_p?: RawStmt): RawStmt { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + insertStmt(_p?: InsertStmt): InsertStmt { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return _j; + }, + deleteStmt(_p?: DeleteStmt): DeleteStmt { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + updateStmt(_p?: UpdateStmt): UpdateStmt { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + mergeStmt(_p?: MergeStmt): MergeStmt { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + selectStmt(_p?: SelectStmt): SelectStmt { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return _j; + }, + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return _j; + }, + returnStmt(_p?: ReturnStmt): ReturnStmt { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return _j; + }, + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return _j; + }, + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return _j; + }, + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return _j; + }, + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + grantStmt(_p?: GrantStmt): GrantStmt { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return _j; + }, + accessPriv(_p?: AccessPriv): AccessPriv { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return _j; + }, + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + copyStmt(_p?: CopyStmt): CopyStmt { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return _j; + }, + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return _j; + }, + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + createStmt(_p?: CreateStmt): CreateStmt { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + constraint(_p?: Constraint): Constraint { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return _j; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return _j; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return _j; + }, + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return _j; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return _j; + }, + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return _j; + }, + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return _j; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return _j; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return _j; + }, + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return _j; + }, + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + defineStmt(_p?: DefineStmt): DefineStmt { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return _j; + }, + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return _j; + }, + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return _j; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return _j; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return _j; + }, + dropStmt(_p?: DropStmt): DropStmt { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + truncateStmt(_p?: TruncateStmt): TruncateStmt { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + commentStmt(_p?: CommentStmt): CommentStmt { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return _j; + }, + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return _j; + }, + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return _j; + }, + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return _j; + }, + fetchStmt(_p?: FetchStmt): FetchStmt { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return _j; + }, + indexStmt(_p?: IndexStmt): IndexStmt { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return _j; + }, + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + statsElem(_p?: StatsElem): StatsElem { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return _j; + }, + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return _j; + }, + functionParameter(_p?: FunctionParameter): FunctionParameter { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return _j; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return _j; + }, + doStmt(_p?: DoStmt): DoStmt { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return _j; + }, + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + callStmt(_p?: CallStmt): CallStmt { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return _j; + }, + callContext(_p?: CallContext): CallContext { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + renameStmt(_p?: RenameStmt): RenameStmt { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return _j; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return _j; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return _j; + }, + ruleStmt(_p?: RuleStmt): RuleStmt { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + notifyStmt(_p?: NotifyStmt): NotifyStmt { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return _j; + }, + listenStmt(_p?: ListenStmt): ListenStmt { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + transactionStmt(_p?: TransactionStmt): TransactionStmt { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return _j; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return _j; + }, + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return _j; + }, + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return _j; + }, + viewStmt(_p?: ViewStmt): ViewStmt { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return _j; + }, + loadStmt(_p?: LoadStmt): LoadStmt { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return _j; + }, + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return _j; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropdbStmt(_p?: DropdbStmt): DropdbStmt { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + clusterStmt(_p?: ClusterStmt): ClusterStmt { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return _j; + }, + vacuumStmt(_p?: VacuumStmt): VacuumStmt { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return _j; + }, + vacuumRelation(_p?: VacuumRelation): VacuumRelation { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return _j; + }, + explainStmt(_p?: ExplainStmt): ExplainStmt { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return _j; + }, + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return _j; + }, + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { + const _j = {} as CheckPointStmt; + return _j; + }, + discardStmt(_p?: DiscardStmt): DiscardStmt { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return _j; + }, + lockStmt(_p?: LockStmt): LockStmt { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return _j; + }, + reindexStmt(_p?: ReindexStmt): ReindexStmt { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return _j; + }, + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return _j; + }, + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return _j; + }, + prepareStmt(_p?: PrepareStmt): PrepareStmt { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return _j; + }, + executeStmt(_p?: ExecuteStmt): ExecuteStmt { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return _j; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return _j; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + publicationTable(_p?: PublicationTable): PublicationTable { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return _j; + }, + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return _j; + }, + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return _j; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return _j; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + scanToken(_p?: ScanToken): ScanToken { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return _j; + } +}; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/unwrappedHelpers/types.ts b/__fixtures__/output/utils/astHelpers/unwrappedHelpers/types.ts new file mode 100644 index 00000000..cf5f2c36 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/unwrappedHelpers/types.ts @@ -0,0 +1,2326 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +export type Node = { + ParseResult: ParseResult; +} | { + ScanResult: ScanResult; +} | { + Integer: Integer; +} | { + Float: Float; +} | { + Boolean: Boolean; +} | { + String: String; +} | { + BitString: BitString; +} | { + List: List; +} | { + OidList: OidList; +} | { + IntList: IntList; +} | { + A_Const: A_Const; +} | { + Alias: Alias; +} | { + RangeVar: RangeVar; +} | { + TableFunc: TableFunc; +} | { + IntoClause: IntoClause; +} | { + Var: Var; +} | { + Param: Param; +} | { + Aggref: Aggref; +} | { + GroupingFunc: GroupingFunc; +} | { + WindowFunc: WindowFunc; +} | { + SubscriptingRef: SubscriptingRef; +} | { + FuncExpr: FuncExpr; +} | { + NamedArgExpr: NamedArgExpr; +} | { + OpExpr: OpExpr; +} | { + DistinctExpr: DistinctExpr; +} | { + NullIfExpr: NullIfExpr; +} | { + ScalarArrayOpExpr: ScalarArrayOpExpr; +} | { + BoolExpr: BoolExpr; +} | { + SubLink: SubLink; +} | { + SubPlan: SubPlan; +} | { + AlternativeSubPlan: AlternativeSubPlan; +} | { + FieldSelect: FieldSelect; +} | { + FieldStore: FieldStore; +} | { + RelabelType: RelabelType; +} | { + CoerceViaIO: CoerceViaIO; +} | { + ArrayCoerceExpr: ArrayCoerceExpr; +} | { + ConvertRowtypeExpr: ConvertRowtypeExpr; +} | { + CollateExpr: CollateExpr; +} | { + CaseExpr: CaseExpr; +} | { + CaseWhen: CaseWhen; +} | { + CaseTestExpr: CaseTestExpr; +} | { + ArrayExpr: ArrayExpr; +} | { + RowExpr: RowExpr; +} | { + RowCompareExpr: RowCompareExpr; +} | { + CoalesceExpr: CoalesceExpr; +} | { + MinMaxExpr: MinMaxExpr; +} | { + SQLValueFunction: SQLValueFunction; +} | { + XmlExpr: XmlExpr; +} | { + JsonFormat: JsonFormat; +} | { + JsonReturning: JsonReturning; +} | { + JsonValueExpr: JsonValueExpr; +} | { + JsonConstructorExpr: JsonConstructorExpr; +} | { + JsonIsPredicate: JsonIsPredicate; +} | { + NullTest: NullTest; +} | { + BooleanTest: BooleanTest; +} | { + CoerceToDomain: CoerceToDomain; +} | { + CoerceToDomainValue: CoerceToDomainValue; +} | { + SetToDefault: SetToDefault; +} | { + CurrentOfExpr: CurrentOfExpr; +} | { + NextValueExpr: NextValueExpr; +} | { + InferenceElem: InferenceElem; +} | { + TargetEntry: TargetEntry; +} | { + RangeTblRef: RangeTblRef; +} | { + JoinExpr: JoinExpr; +} | { + FromExpr: FromExpr; +} | { + OnConflictExpr: OnConflictExpr; +} | { + Query: Query; +} | { + TypeName: TypeName; +} | { + ColumnRef: ColumnRef; +} | { + ParamRef: ParamRef; +} | { + A_Expr: A_Expr; +} | { + TypeCast: TypeCast; +} | { + CollateClause: CollateClause; +} | { + RoleSpec: RoleSpec; +} | { + FuncCall: FuncCall; +} | { + A_Star: A_Star; +} | { + A_Indices: A_Indices; +} | { + A_Indirection: A_Indirection; +} | { + A_ArrayExpr: A_ArrayExpr; +} | { + ResTarget: ResTarget; +} | { + MultiAssignRef: MultiAssignRef; +} | { + SortBy: SortBy; +} | { + WindowDef: WindowDef; +} | { + RangeSubselect: RangeSubselect; +} | { + RangeFunction: RangeFunction; +} | { + RangeTableFunc: RangeTableFunc; +} | { + RangeTableFuncCol: RangeTableFuncCol; +} | { + RangeTableSample: RangeTableSample; +} | { + ColumnDef: ColumnDef; +} | { + TableLikeClause: TableLikeClause; +} | { + IndexElem: IndexElem; +} | { + DefElem: DefElem; +} | { + LockingClause: LockingClause; +} | { + XmlSerialize: XmlSerialize; +} | { + PartitionElem: PartitionElem; +} | { + PartitionSpec: PartitionSpec; +} | { + PartitionBoundSpec: PartitionBoundSpec; +} | { + PartitionRangeDatum: PartitionRangeDatum; +} | { + PartitionCmd: PartitionCmd; +} | { + RangeTblEntry: RangeTblEntry; +} | { + RTEPermissionInfo: RTEPermissionInfo; +} | { + RangeTblFunction: RangeTblFunction; +} | { + TableSampleClause: TableSampleClause; +} | { + WithCheckOption: WithCheckOption; +} | { + SortGroupClause: SortGroupClause; +} | { + GroupingSet: GroupingSet; +} | { + WindowClause: WindowClause; +} | { + RowMarkClause: RowMarkClause; +} | { + WithClause: WithClause; +} | { + InferClause: InferClause; +} | { + OnConflictClause: OnConflictClause; +} | { + CTESearchClause: CTESearchClause; +} | { + CTECycleClause: CTECycleClause; +} | { + CommonTableExpr: CommonTableExpr; +} | { + MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; +} | { + TriggerTransition: TriggerTransition; +} | { + JsonOutput: JsonOutput; +} | { + JsonKeyValue: JsonKeyValue; +} | { + JsonObjectConstructor: JsonObjectConstructor; +} | { + JsonArrayConstructor: JsonArrayConstructor; +} | { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; +} | { + JsonAggConstructor: JsonAggConstructor; +} | { + JsonObjectAgg: JsonObjectAgg; +} | { + JsonArrayAgg: JsonArrayAgg; +} | { + RawStmt: RawStmt; +} | { + InsertStmt: InsertStmt; +} | { + DeleteStmt: DeleteStmt; +} | { + UpdateStmt: UpdateStmt; +} | { + MergeStmt: MergeStmt; +} | { + SelectStmt: SelectStmt; +} | { + SetOperationStmt: SetOperationStmt; +} | { + ReturnStmt: ReturnStmt; +} | { + PLAssignStmt: PLAssignStmt; +} | { + CreateSchemaStmt: CreateSchemaStmt; +} | { + AlterTableStmt: AlterTableStmt; +} | { + ReplicaIdentityStmt: ReplicaIdentityStmt; +} | { + AlterTableCmd: AlterTableCmd; +} | { + AlterCollationStmt: AlterCollationStmt; +} | { + AlterDomainStmt: AlterDomainStmt; +} | { + GrantStmt: GrantStmt; +} | { + ObjectWithArgs: ObjectWithArgs; +} | { + AccessPriv: AccessPriv; +} | { + GrantRoleStmt: GrantRoleStmt; +} | { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; +} | { + CopyStmt: CopyStmt; +} | { + VariableSetStmt: VariableSetStmt; +} | { + VariableShowStmt: VariableShowStmt; +} | { + CreateStmt: CreateStmt; +} | { + Constraint: Constraint; +} | { + CreateTableSpaceStmt: CreateTableSpaceStmt; +} | { + DropTableSpaceStmt: DropTableSpaceStmt; +} | { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; +} | { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; +} | { + CreateExtensionStmt: CreateExtensionStmt; +} | { + AlterExtensionStmt: AlterExtensionStmt; +} | { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; +} | { + CreateFdwStmt: CreateFdwStmt; +} | { + AlterFdwStmt: AlterFdwStmt; +} | { + CreateForeignServerStmt: CreateForeignServerStmt; +} | { + AlterForeignServerStmt: AlterForeignServerStmt; +} | { + CreateForeignTableStmt: CreateForeignTableStmt; +} | { + CreateUserMappingStmt: CreateUserMappingStmt; +} | { + AlterUserMappingStmt: AlterUserMappingStmt; +} | { + DropUserMappingStmt: DropUserMappingStmt; +} | { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; +} | { + CreatePolicyStmt: CreatePolicyStmt; +} | { + AlterPolicyStmt: AlterPolicyStmt; +} | { + CreateAmStmt: CreateAmStmt; +} | { + CreateTrigStmt: CreateTrigStmt; +} | { + CreateEventTrigStmt: CreateEventTrigStmt; +} | { + AlterEventTrigStmt: AlterEventTrigStmt; +} | { + CreatePLangStmt: CreatePLangStmt; +} | { + CreateRoleStmt: CreateRoleStmt; +} | { + AlterRoleStmt: AlterRoleStmt; +} | { + AlterRoleSetStmt: AlterRoleSetStmt; +} | { + DropRoleStmt: DropRoleStmt; +} | { + CreateSeqStmt: CreateSeqStmt; +} | { + AlterSeqStmt: AlterSeqStmt; +} | { + DefineStmt: DefineStmt; +} | { + CreateDomainStmt: CreateDomainStmt; +} | { + CreateOpClassStmt: CreateOpClassStmt; +} | { + CreateOpClassItem: CreateOpClassItem; +} | { + CreateOpFamilyStmt: CreateOpFamilyStmt; +} | { + AlterOpFamilyStmt: AlterOpFamilyStmt; +} | { + DropStmt: DropStmt; +} | { + TruncateStmt: TruncateStmt; +} | { + CommentStmt: CommentStmt; +} | { + SecLabelStmt: SecLabelStmt; +} | { + DeclareCursorStmt: DeclareCursorStmt; +} | { + ClosePortalStmt: ClosePortalStmt; +} | { + FetchStmt: FetchStmt; +} | { + IndexStmt: IndexStmt; +} | { + CreateStatsStmt: CreateStatsStmt; +} | { + StatsElem: StatsElem; +} | { + AlterStatsStmt: AlterStatsStmt; +} | { + CreateFunctionStmt: CreateFunctionStmt; +} | { + FunctionParameter: FunctionParameter; +} | { + AlterFunctionStmt: AlterFunctionStmt; +} | { + DoStmt: DoStmt; +} | { + InlineCodeBlock: InlineCodeBlock; +} | { + CallStmt: CallStmt; +} | { + CallContext: CallContext; +} | { + RenameStmt: RenameStmt; +} | { + AlterObjectDependsStmt: AlterObjectDependsStmt; +} | { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; +} | { + AlterOwnerStmt: AlterOwnerStmt; +} | { + AlterOperatorStmt: AlterOperatorStmt; +} | { + AlterTypeStmt: AlterTypeStmt; +} | { + RuleStmt: RuleStmt; +} | { + NotifyStmt: NotifyStmt; +} | { + ListenStmt: ListenStmt; +} | { + UnlistenStmt: UnlistenStmt; +} | { + TransactionStmt: TransactionStmt; +} | { + CompositeTypeStmt: CompositeTypeStmt; +} | { + CreateEnumStmt: CreateEnumStmt; +} | { + CreateRangeStmt: CreateRangeStmt; +} | { + AlterEnumStmt: AlterEnumStmt; +} | { + ViewStmt: ViewStmt; +} | { + LoadStmt: LoadStmt; +} | { + CreatedbStmt: CreatedbStmt; +} | { + AlterDatabaseStmt: AlterDatabaseStmt; +} | { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; +} | { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; +} | { + DropdbStmt: DropdbStmt; +} | { + AlterSystemStmt: AlterSystemStmt; +} | { + ClusterStmt: ClusterStmt; +} | { + VacuumStmt: VacuumStmt; +} | { + VacuumRelation: VacuumRelation; +} | { + ExplainStmt: ExplainStmt; +} | { + CreateTableAsStmt: CreateTableAsStmt; +} | { + RefreshMatViewStmt: RefreshMatViewStmt; +} | { + CheckPointStmt: CheckPointStmt; +} | { + DiscardStmt: DiscardStmt; +} | { + LockStmt: LockStmt; +} | { + ConstraintsSetStmt: ConstraintsSetStmt; +} | { + ReindexStmt: ReindexStmt; +} | { + CreateConversionStmt: CreateConversionStmt; +} | { + CreateCastStmt: CreateCastStmt; +} | { + CreateTransformStmt: CreateTransformStmt; +} | { + PrepareStmt: PrepareStmt; +} | { + ExecuteStmt: ExecuteStmt; +} | { + DeallocateStmt: DeallocateStmt; +} | { + DropOwnedStmt: DropOwnedStmt; +} | { + ReassignOwnedStmt: ReassignOwnedStmt; +} | { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; +} | { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; +} | { + PublicationTable: PublicationTable; +} | { + PublicationObjSpec: PublicationObjSpec; +} | { + CreatePublicationStmt: CreatePublicationStmt; +} | { + AlterPublicationStmt: AlterPublicationStmt; +} | { + CreateSubscriptionStmt: CreateSubscriptionStmt; +} | { + AlterSubscriptionStmt: AlterSubscriptionStmt; +} | { + DropSubscriptionStmt: DropSubscriptionStmt; +} | { + ScanToken: ScanToken; +}; +export interface ParseResult { + version?: number; + stmts?: RawStmt[]; +} +export interface ScanResult { + version?: number; + tokens?: ScanToken[]; +} +export interface Integer { + ival?: number; +} +export interface Float { + fval?: string; +} +export interface Boolean { + boolval?: boolean; +} +export interface String { + sval?: string; +} +export interface BitString { + bsval?: string; +} +export interface List { + items?: Node[]; +} +export interface OidList { + items?: Node[]; +} +export interface IntList { + items?: Node[]; +} +export interface A_Const { + ival?: Integer; + fval?: Float; + boolval?: Boolean; + sval?: String; + bsval?: BitString; + isnull?: boolean; + location?: number; +} +export interface Alias { + aliasname?: string; + colnames?: Node[]; +} +export interface RangeVar { + catalogname?: string; + schemaname?: string; + relname?: string; + inh?: boolean; + relpersistence?: string; + alias?: Alias; + location?: number; +} +export interface TableFunc { + ns_uris?: Node[]; + ns_names?: Node[]; + docexpr?: Node; + rowexpr?: Node; + colnames?: Node[]; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + colexprs?: Node[]; + coldefexprs?: Node[]; + notnulls?: bigint[]; + ordinalitycol?: number; + location?: number; +} +export interface IntoClause { + rel?: RangeVar; + colNames?: Node[]; + accessMethod?: string; + options?: Node[]; + onCommit?: OnCommitAction; + tableSpaceName?: string; + viewQuery?: Node; + skipData?: boolean; +} +export interface Var { + xpr?: Node; + varno?: number; + varattno?: number; + vartype?: number; + vartypmod?: number; + varcollid?: number; + varnullingrels?: bigint[]; + varlevelsup?: number; + location?: number; +} +export interface Param { + xpr?: Node; + paramkind?: ParamKind; + paramid?: number; + paramtype?: number; + paramtypmod?: number; + paramcollid?: number; + location?: number; +} +export interface Aggref { + xpr?: Node; + aggfnoid?: number; + aggtype?: number; + aggcollid?: number; + inputcollid?: number; + aggargtypes?: Node[]; + aggdirectargs?: Node[]; + args?: Node[]; + aggorder?: Node[]; + aggdistinct?: Node[]; + aggfilter?: Node; + aggstar?: boolean; + aggvariadic?: boolean; + aggkind?: string; + agglevelsup?: number; + aggsplit?: AggSplit; + aggno?: number; + aggtransno?: number; + location?: number; +} +export interface GroupingFunc { + xpr?: Node; + args?: Node[]; + refs?: Node[]; + agglevelsup?: number; + location?: number; +} +export interface WindowFunc { + xpr?: Node; + winfnoid?: number; + wintype?: number; + wincollid?: number; + inputcollid?: number; + args?: Node[]; + aggfilter?: Node; + winref?: number; + winstar?: boolean; + winagg?: boolean; + location?: number; +} +export interface SubscriptingRef { + xpr?: Node; + refcontainertype?: number; + refelemtype?: number; + refrestype?: number; + reftypmod?: number; + refcollid?: number; + refupperindexpr?: Node[]; + reflowerindexpr?: Node[]; + refexpr?: Node; + refassgnexpr?: Node; +} +export interface FuncExpr { + xpr?: Node; + funcid?: number; + funcresulttype?: number; + funcretset?: boolean; + funcvariadic?: boolean; + funcformat?: CoercionForm; + funccollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NamedArgExpr { + xpr?: Node; + arg?: Node; + name?: string; + argnumber?: number; + location?: number; +} +export interface OpExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface DistinctExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NullIfExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface ScalarArrayOpExpr { + xpr?: Node; + opno?: number; + useOr?: boolean; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface BoolExpr { + xpr?: Node; + boolop?: BoolExprType; + args?: Node[]; + location?: number; +} +export interface SubLink { + xpr?: Node; + subLinkType?: SubLinkType; + subLinkId?: number; + testexpr?: Node; + operName?: Node[]; + subselect?: Node; + location?: number; +} +export interface SubPlan { + xpr?: Node; + subLinkType?: SubLinkType; + testexpr?: Node; + paramIds?: Node[]; + plan_id?: number; + plan_name?: string; + firstColType?: number; + firstColTypmod?: number; + firstColCollation?: number; + useHashTable?: boolean; + unknownEqFalse?: boolean; + parallel_safe?: boolean; + setParam?: Node[]; + parParam?: Node[]; + args?: Node[]; + startup_cost?: number; + per_call_cost?: number; +} +export interface AlternativeSubPlan { + xpr?: Node; + subplans?: Node[]; +} +export interface FieldSelect { + xpr?: Node; + arg?: Node; + fieldnum?: number; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; +} +export interface FieldStore { + xpr?: Node; + arg?: Node; + newvals?: Node[]; + fieldnums?: Node[]; + resulttype?: number; +} +export interface RelabelType { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + relabelformat?: CoercionForm; + location?: number; +} +export interface CoerceViaIO { + xpr?: Node; + arg?: Node; + resulttype?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ArrayCoerceExpr { + xpr?: Node; + arg?: Node; + elemexpr?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ConvertRowtypeExpr { + xpr?: Node; + arg?: Node; + resulttype?: number; + convertformat?: CoercionForm; + location?: number; +} +export interface CollateExpr { + xpr?: Node; + arg?: Node; + collOid?: number; + location?: number; +} +export interface CaseExpr { + xpr?: Node; + casetype?: number; + casecollid?: number; + arg?: Node; + args?: Node[]; + defresult?: Node; + location?: number; +} +export interface CaseWhen { + xpr?: Node; + expr?: Node; + result?: Node; + location?: number; +} +export interface CaseTestExpr { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; +} +export interface ArrayExpr { + xpr?: Node; + array_typeid?: number; + array_collid?: number; + element_typeid?: number; + elements?: Node[]; + multidims?: boolean; + location?: number; +} +export interface RowExpr { + xpr?: Node; + args?: Node[]; + row_typeid?: number; + row_format?: CoercionForm; + colnames?: Node[]; + location?: number; +} +export interface RowCompareExpr { + xpr?: Node; + rctype?: RowCompareType; + opnos?: Node[]; + opfamilies?: Node[]; + inputcollids?: Node[]; + largs?: Node[]; + rargs?: Node[]; +} +export interface CoalesceExpr { + xpr?: Node; + coalescetype?: number; + coalescecollid?: number; + args?: Node[]; + location?: number; +} +export interface MinMaxExpr { + xpr?: Node; + minmaxtype?: number; + minmaxcollid?: number; + inputcollid?: number; + op?: MinMaxOp; + args?: Node[]; + location?: number; +} +export interface SQLValueFunction { + xpr?: Node; + op?: SQLValueFunctionOp; + type?: number; + typmod?: number; + location?: number; +} +export interface XmlExpr { + xpr?: Node; + op?: XmlExprOp; + name?: string; + named_args?: Node[]; + arg_names?: Node[]; + args?: Node[]; + xmloption?: XmlOptionType; + indent?: boolean; + type?: number; + typmod?: number; + location?: number; +} +export interface JsonFormat { + format_type?: JsonFormatType; + encoding?: JsonEncoding; + location?: number; +} +export interface JsonReturning { + format?: JsonFormat; + typid?: number; + typmod?: number; +} +export interface JsonValueExpr { + raw_expr?: Node; + formatted_expr?: Node; + format?: JsonFormat; +} +export interface JsonConstructorExpr { + xpr?: Node; + type?: JsonConstructorType; + args?: Node[]; + func?: Node; + coercion?: Node; + returning?: JsonReturning; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonIsPredicate { + expr?: Node; + format?: JsonFormat; + item_type?: JsonValueType; + unique_keys?: boolean; + location?: number; +} +export interface NullTest { + xpr?: Node; + arg?: Node; + nulltesttype?: NullTestType; + argisrow?: boolean; + location?: number; +} +export interface BooleanTest { + xpr?: Node; + arg?: Node; + booltesttype?: BoolTestType; + location?: number; +} +export interface CoerceToDomain { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coercionformat?: CoercionForm; + location?: number; +} +export interface CoerceToDomainValue { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface SetToDefault { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface CurrentOfExpr { + xpr?: Node; + cvarno?: number; + cursor_name?: string; + cursor_param?: number; +} +export interface NextValueExpr { + xpr?: Node; + seqid?: number; + typeId?: number; +} +export interface InferenceElem { + xpr?: Node; + expr?: Node; + infercollid?: number; + inferopclass?: number; +} +export interface TargetEntry { + xpr?: Node; + expr?: Node; + resno?: number; + resname?: string; + ressortgroupref?: number; + resorigtbl?: number; + resorigcol?: number; + resjunk?: boolean; +} +export interface RangeTblRef { + rtindex?: number; +} +export interface JoinExpr { + jointype?: JoinType; + isNatural?: boolean; + larg?: Node; + rarg?: Node; + usingClause?: Node[]; + join_using_alias?: Alias; + quals?: Node; + alias?: Alias; + rtindex?: number; +} +export interface FromExpr { + fromlist?: Node[]; + quals?: Node; +} +export interface OnConflictExpr { + action?: OnConflictAction; + arbiterElems?: Node[]; + arbiterWhere?: Node; + constraint?: number; + onConflictSet?: Node[]; + onConflictWhere?: Node; + exclRelIndex?: number; + exclRelTlist?: Node[]; +} +export interface Query { + commandType?: CmdType; + querySource?: QuerySource; + canSetTag?: boolean; + utilityStmt?: Node; + resultRelation?: number; + hasAggs?: boolean; + hasWindowFuncs?: boolean; + hasTargetSRFs?: boolean; + hasSubLinks?: boolean; + hasDistinctOn?: boolean; + hasRecursive?: boolean; + hasModifyingCTE?: boolean; + hasForUpdate?: boolean; + hasRowSecurity?: boolean; + isReturn?: boolean; + cteList?: Node[]; + rtable?: Node[]; + rteperminfos?: Node[]; + jointree?: FromExpr; + mergeActionList?: Node[]; + mergeUseOuterJoin?: boolean; + targetList?: Node[]; + override?: OverridingKind; + onConflict?: OnConflictExpr; + returningList?: Node[]; + groupClause?: Node[]; + groupDistinct?: boolean; + groupingSets?: Node[]; + havingQual?: Node; + windowClause?: Node[]; + distinctClause?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + rowMarks?: Node[]; + setOperations?: Node; + constraintDeps?: Node[]; + withCheckOptions?: Node[]; + stmt_location?: number; + stmt_len?: number; +} +export interface TypeName { + names?: Node[]; + typeOid?: number; + setof?: boolean; + pct_type?: boolean; + typmods?: Node[]; + typemod?: number; + arrayBounds?: Node[]; + location?: number; +} +export interface ColumnRef { + fields?: Node[]; + location?: number; +} +export interface ParamRef { + number?: number; + location?: number; +} +export interface A_Expr { + kind?: A_Expr_Kind; + name?: Node[]; + lexpr?: Node; + rexpr?: Node; + location?: number; +} +export interface TypeCast { + arg?: Node; + typeName?: TypeName; + location?: number; +} +export interface CollateClause { + arg?: Node; + collname?: Node[]; + location?: number; +} +export interface RoleSpec { + roletype?: RoleSpecType; + rolename?: string; + location?: number; +} +export interface FuncCall { + funcname?: Node[]; + args?: Node[]; + agg_order?: Node[]; + agg_filter?: Node; + over?: WindowDef; + agg_within_group?: boolean; + agg_star?: boolean; + agg_distinct?: boolean; + func_variadic?: boolean; + funcformat?: CoercionForm; + location?: number; +} +export interface A_Star {} +export interface A_Indices { + is_slice?: boolean; + lidx?: Node; + uidx?: Node; +} +export interface A_Indirection { + arg?: Node; + indirection?: Node[]; +} +export interface A_ArrayExpr { + elements?: Node[]; + location?: number; +} +export interface ResTarget { + name?: string; + indirection?: Node[]; + val?: Node; + location?: number; +} +export interface MultiAssignRef { + source?: Node; + colno?: number; + ncolumns?: number; +} +export interface SortBy { + node?: Node; + sortby_dir?: SortByDir; + sortby_nulls?: SortByNulls; + useOp?: Node[]; + location?: number; +} +export interface WindowDef { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + location?: number; +} +export interface RangeSubselect { + lateral?: boolean; + subquery?: Node; + alias?: Alias; +} +export interface RangeFunction { + lateral?: boolean; + ordinality?: boolean; + is_rowsfrom?: boolean; + functions?: Node[]; + alias?: Alias; + coldeflist?: Node[]; +} +export interface RangeTableFunc { + lateral?: boolean; + docexpr?: Node; + rowexpr?: Node; + namespaces?: Node[]; + columns?: Node[]; + alias?: Alias; + location?: number; +} +export interface RangeTableFuncCol { + colname?: string; + typeName?: TypeName; + for_ordinality?: boolean; + is_not_null?: boolean; + colexpr?: Node; + coldefexpr?: Node; + location?: number; +} +export interface RangeTableSample { + relation?: Node; + method?: Node[]; + args?: Node[]; + repeatable?: Node; + location?: number; +} +export interface ColumnDef { + colname?: string; + typeName?: TypeName; + compression?: string; + inhcount?: number; + is_local?: boolean; + is_not_null?: boolean; + is_from_type?: boolean; + storage?: string; + storage_name?: string; + raw_default?: Node; + cooked_default?: Node; + identity?: string; + identitySequence?: RangeVar; + generated?: string; + collClause?: CollateClause; + collOid?: number; + constraints?: Node[]; + fdwoptions?: Node[]; + location?: number; +} +export interface TableLikeClause { + relation?: RangeVar; + options?: number; + relationOid?: number; +} +export interface IndexElem { + name?: string; + expr?: Node; + indexcolname?: string; + collation?: Node[]; + opclass?: Node[]; + opclassopts?: Node[]; + ordering?: SortByDir; + nulls_ordering?: SortByNulls; +} +export interface DefElem { + defnamespace?: string; + defname?: string; + arg?: Node; + defaction?: DefElemAction; + location?: number; +} +export interface LockingClause { + lockedRels?: Node[]; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; +} +export interface XmlSerialize { + xmloption?: XmlOptionType; + expr?: Node; + typeName?: TypeName; + indent?: boolean; + location?: number; +} +export interface PartitionElem { + name?: string; + expr?: Node; + collation?: Node[]; + opclass?: Node[]; + location?: number; +} +export interface PartitionSpec { + strategy?: PartitionStrategy; + partParams?: Node[]; + location?: number; +} +export interface PartitionBoundSpec { + strategy?: string; + is_default?: boolean; + modulus?: number; + remainder?: number; + listdatums?: Node[]; + lowerdatums?: Node[]; + upperdatums?: Node[]; + location?: number; +} +export interface PartitionRangeDatum { + kind?: PartitionRangeDatumKind; + value?: Node; + location?: number; +} +export interface PartitionCmd { + name?: RangeVar; + bound?: PartitionBoundSpec; + concurrent?: boolean; +} +export interface RangeTblEntry { + rtekind?: RTEKind; + relid?: number; + relkind?: string; + rellockmode?: number; + tablesample?: TableSampleClause; + perminfoindex?: number; + subquery?: Query; + security_barrier?: boolean; + jointype?: JoinType; + joinmergedcols?: number; + joinaliasvars?: Node[]; + joinleftcols?: Node[]; + joinrightcols?: Node[]; + join_using_alias?: Alias; + functions?: Node[]; + funcordinality?: boolean; + tablefunc?: TableFunc; + values_lists?: Node[]; + ctename?: string; + ctelevelsup?: number; + self_reference?: boolean; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + enrname?: string; + enrtuples?: number; + alias?: Alias; + eref?: Alias; + lateral?: boolean; + inh?: boolean; + inFromCl?: boolean; + securityQuals?: Node[]; +} +export interface RTEPermissionInfo { + relid?: number; + inh?: boolean; + requiredPerms?: bigint; + checkAsUser?: number; + selectedCols?: bigint[]; + insertedCols?: bigint[]; + updatedCols?: bigint[]; +} +export interface RangeTblFunction { + funcexpr?: Node; + funccolcount?: number; + funccolnames?: Node[]; + funccoltypes?: Node[]; + funccoltypmods?: Node[]; + funccolcollations?: Node[]; + funcparams?: bigint[]; +} +export interface TableSampleClause { + tsmhandler?: number; + args?: Node[]; + repeatable?: Node; +} +export interface WithCheckOption { + kind?: WCOKind; + relname?: string; + polname?: string; + qual?: Node; + cascaded?: boolean; +} +export interface SortGroupClause { + tleSortGroupRef?: number; + eqop?: number; + sortop?: number; + nulls_first?: boolean; + hashable?: boolean; +} +export interface GroupingSet { + kind?: GroupingSetKind; + content?: Node[]; + location?: number; +} +export interface WindowClause { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + runCondition?: Node[]; + startInRangeFunc?: number; + endInRangeFunc?: number; + inRangeColl?: number; + inRangeAsc?: boolean; + inRangeNullsFirst?: boolean; + winref?: number; + copiedOrder?: boolean; +} +export interface RowMarkClause { + rti?: number; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; + pushedDown?: boolean; +} +export interface WithClause { + ctes?: Node[]; + recursive?: boolean; + location?: number; +} +export interface InferClause { + indexElems?: Node[]; + whereClause?: Node; + conname?: string; + location?: number; +} +export interface OnConflictClause { + action?: OnConflictAction; + infer?: InferClause; + targetList?: Node[]; + whereClause?: Node; + location?: number; +} +export interface CTESearchClause { + search_col_list?: Node[]; + search_breadth_first?: boolean; + search_seq_column?: string; + location?: number; +} +export interface CTECycleClause { + cycle_col_list?: Node[]; + cycle_mark_column?: string; + cycle_mark_value?: Node; + cycle_mark_default?: Node; + cycle_path_column?: string; + location?: number; + cycle_mark_type?: number; + cycle_mark_typmod?: number; + cycle_mark_collation?: number; + cycle_mark_neop?: number; +} +export interface CommonTableExpr { + ctename?: string; + aliascolnames?: Node[]; + ctematerialized?: CTEMaterialize; + ctequery?: Node; + search_clause?: CTESearchClause; + cycle_clause?: CTECycleClause; + location?: number; + cterecursive?: boolean; + cterefcount?: number; + ctecolnames?: Node[]; + ctecoltypes?: Node[]; + ctecoltypmods?: Node[]; + ctecolcollations?: Node[]; +} +export interface MergeWhenClause { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + condition?: Node; + targetList?: Node[]; + values?: Node[]; +} +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} +export interface TriggerTransition { + name?: string; + isNew?: boolean; + isTable?: boolean; +} +export interface JsonOutput { + typeName?: TypeName; + returning?: JsonReturning; +} +export interface JsonKeyValue { + key?: Node; + value?: JsonValueExpr; +} +export interface JsonObjectConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonArrayConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + location?: number; +} +export interface JsonArrayQueryConstructor { + query?: Node; + output?: JsonOutput; + format?: JsonFormat; + absent_on_null?: boolean; + location?: number; +} +export interface JsonAggConstructor { + output?: JsonOutput; + agg_filter?: Node; + agg_order?: Node[]; + over?: WindowDef; + location?: number; +} +export interface JsonObjectAgg { + constructor?: JsonAggConstructor; + arg?: JsonKeyValue; + absent_on_null?: boolean; + unique?: boolean; +} +export interface JsonArrayAgg { + constructor?: JsonAggConstructor; + arg?: JsonValueExpr; + absent_on_null?: boolean; +} +export interface RawStmt { + stmt?: Node; + stmt_location?: number; + stmt_len?: number; +} +export interface InsertStmt { + relation?: RangeVar; + cols?: Node[]; + selectStmt?: Node; + onConflictClause?: OnConflictClause; + returningList?: Node[]; + withClause?: WithClause; + override?: OverridingKind; +} +export interface DeleteStmt { + relation?: RangeVar; + usingClause?: Node[]; + whereClause?: Node; + returningList?: Node[]; + withClause?: WithClause; +} +export interface UpdateStmt { + relation?: RangeVar; + targetList?: Node[]; + whereClause?: Node; + fromClause?: Node[]; + returningList?: Node[]; + withClause?: WithClause; +} +export interface MergeStmt { + relation?: RangeVar; + sourceRelation?: Node; + joinCondition?: Node; + mergeWhenClauses?: Node[]; + withClause?: WithClause; +} +export interface SelectStmt { + distinctClause?: Node[]; + intoClause?: IntoClause; + targetList?: Node[]; + fromClause?: Node[]; + whereClause?: Node; + groupClause?: Node[]; + groupDistinct?: boolean; + havingClause?: Node; + windowClause?: Node[]; + valuesLists?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + lockingClause?: Node[]; + withClause?: WithClause; + op?: SetOperation; + all?: boolean; + larg?: SelectStmt; + rarg?: SelectStmt; +} +export interface SetOperationStmt { + op?: SetOperation; + all?: boolean; + larg?: Node; + rarg?: Node; + colTypes?: Node[]; + colTypmods?: Node[]; + colCollations?: Node[]; + groupClauses?: Node[]; +} +export interface ReturnStmt { + returnval?: Node; +} +export interface PLAssignStmt { + name?: string; + indirection?: Node[]; + nnames?: number; + val?: SelectStmt; + location?: number; +} +export interface CreateSchemaStmt { + schemaname?: string; + authrole?: RoleSpec; + schemaElts?: Node[]; + if_not_exists?: boolean; +} +export interface AlterTableStmt { + relation?: RangeVar; + cmds?: Node[]; + objtype?: ObjectType; + missing_ok?: boolean; +} +export interface ReplicaIdentityStmt { + identity_type?: string; + name?: string; +} +export interface AlterTableCmd { + subtype?: AlterTableType; + name?: string; + num?: number; + newowner?: RoleSpec; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; + recurse?: boolean; +} +export interface AlterCollationStmt { + collname?: Node[]; +} +export interface AlterDomainStmt { + subtype?: string; + typeName?: Node[]; + name?: string; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface GrantStmt { + is_grant?: boolean; + targtype?: GrantTargetType; + objtype?: ObjectType; + objects?: Node[]; + privileges?: Node[]; + grantees?: Node[]; + grant_option?: boolean; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface ObjectWithArgs { + objname?: Node[]; + objargs?: Node[]; + objfuncargs?: Node[]; + args_unspecified?: boolean; +} +export interface AccessPriv { + priv_name?: string; + cols?: Node[]; +} +export interface GrantRoleStmt { + granted_roles?: Node[]; + grantee_roles?: Node[]; + is_grant?: boolean; + opt?: Node[]; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface AlterDefaultPrivilegesStmt { + options?: Node[]; + action?: GrantStmt; +} +export interface CopyStmt { + relation?: RangeVar; + query?: Node; + attlist?: Node[]; + is_from?: boolean; + is_program?: boolean; + filename?: string; + options?: Node[]; + whereClause?: Node; +} +export interface VariableSetStmt { + kind?: VariableSetKind; + name?: string; + args?: Node[]; + is_local?: boolean; +} +export interface VariableShowStmt { + name?: string; +} +export interface CreateStmt { + relation?: RangeVar; + tableElts?: Node[]; + inhRelations?: Node[]; + partbound?: PartitionBoundSpec; + partspec?: PartitionSpec; + ofTypename?: TypeName; + constraints?: Node[]; + options?: Node[]; + oncommit?: OnCommitAction; + tablespacename?: string; + accessMethod?: string; + if_not_exists?: boolean; +} +export interface Constraint { + contype?: ConstrType; + conname?: string; + deferrable?: boolean; + initdeferred?: boolean; + location?: number; + is_no_inherit?: boolean; + raw_expr?: Node; + cooked_expr?: string; + generated_when?: string; + nulls_not_distinct?: boolean; + keys?: Node[]; + including?: Node[]; + exclusions?: Node[]; + options?: Node[]; + indexname?: string; + indexspace?: string; + reset_default_tblspc?: boolean; + access_method?: string; + where_clause?: Node; + pktable?: RangeVar; + fk_attrs?: Node[]; + pk_attrs?: Node[]; + fk_matchtype?: string; + fk_upd_action?: string; + fk_del_action?: string; + fk_del_set_cols?: Node[]; + old_conpfeqop?: Node[]; + old_pktable_oid?: number; + skip_validation?: boolean; + initially_valid?: boolean; +} +export interface CreateTableSpaceStmt { + tablespacename?: string; + owner?: RoleSpec; + location?: string; + options?: Node[]; +} +export interface DropTableSpaceStmt { + tablespacename?: string; + missing_ok?: boolean; +} +export interface AlterTableSpaceOptionsStmt { + tablespacename?: string; + options?: Node[]; + isReset?: boolean; +} +export interface AlterTableMoveAllStmt { + orig_tablespacename?: string; + objtype?: ObjectType; + roles?: Node[]; + new_tablespacename?: string; + nowait?: boolean; +} +export interface CreateExtensionStmt { + extname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterExtensionStmt { + extname?: string; + options?: Node[]; +} +export interface AlterExtensionContentsStmt { + extname?: string; + action?: number; + objtype?: ObjectType; + object?: Node; +} +export interface CreateFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface AlterFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface CreateForeignServerStmt { + servername?: string; + servertype?: string; + version?: string; + fdwname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterForeignServerStmt { + servername?: string; + version?: string; + options?: Node[]; + has_version?: boolean; +} +export interface CreateForeignTableStmt { + base?: CreateStmt; + servername?: string; + options?: Node[]; +} +export interface CreateUserMappingStmt { + user?: RoleSpec; + servername?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterUserMappingStmt { + user?: RoleSpec; + servername?: string; + options?: Node[]; +} +export interface DropUserMappingStmt { + user?: RoleSpec; + servername?: string; + missing_ok?: boolean; +} +export interface ImportForeignSchemaStmt { + server_name?: string; + remote_schema?: string; + local_schema?: string; + list_type?: ImportForeignSchemaType; + table_list?: Node[]; + options?: Node[]; +} +export interface CreatePolicyStmt { + policy_name?: string; + table?: RangeVar; + cmd_name?: string; + permissive?: boolean; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface AlterPolicyStmt { + policy_name?: string; + table?: RangeVar; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface CreateAmStmt { + amname?: string; + handler_name?: Node[]; + amtype?: string; +} +export interface CreateTrigStmt { + replace?: boolean; + isconstraint?: boolean; + trigname?: string; + relation?: RangeVar; + funcname?: Node[]; + args?: Node[]; + row?: boolean; + timing?: number; + events?: number; + columns?: Node[]; + whenClause?: Node; + transitionRels?: Node[]; + deferrable?: boolean; + initdeferred?: boolean; + constrrel?: RangeVar; +} +export interface CreateEventTrigStmt { + trigname?: string; + eventname?: string; + whenclause?: Node[]; + funcname?: Node[]; +} +export interface AlterEventTrigStmt { + trigname?: string; + tgenabled?: string; +} +export interface CreatePLangStmt { + replace?: boolean; + plname?: string; + plhandler?: Node[]; + plinline?: Node[]; + plvalidator?: Node[]; + pltrusted?: boolean; +} +export interface CreateRoleStmt { + stmt_type?: RoleStmtType; + role?: string; + options?: Node[]; +} +export interface AlterRoleStmt { + role?: RoleSpec; + options?: Node[]; + action?: number; +} +export interface AlterRoleSetStmt { + role?: RoleSpec; + database?: string; + setstmt?: VariableSetStmt; +} +export interface DropRoleStmt { + roles?: Node[]; + missing_ok?: boolean; +} +export interface CreateSeqStmt { + sequence?: RangeVar; + options?: Node[]; + ownerId?: number; + for_identity?: boolean; + if_not_exists?: boolean; +} +export interface AlterSeqStmt { + sequence?: RangeVar; + options?: Node[]; + for_identity?: boolean; + missing_ok?: boolean; +} +export interface DefineStmt { + kind?: ObjectType; + oldstyle?: boolean; + defnames?: Node[]; + args?: Node[]; + definition?: Node[]; + if_not_exists?: boolean; + replace?: boolean; +} +export interface CreateDomainStmt { + domainname?: Node[]; + typeName?: TypeName; + collClause?: CollateClause; + constraints?: Node[]; +} +export interface CreateOpClassStmt { + opclassname?: Node[]; + opfamilyname?: Node[]; + amname?: string; + datatype?: TypeName; + items?: Node[]; + isDefault?: boolean; +} +export interface CreateOpClassItem { + itemtype?: number; + name?: ObjectWithArgs; + number?: number; + order_family?: Node[]; + class_args?: Node[]; + storedtype?: TypeName; +} +export interface CreateOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; +} +export interface AlterOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; + isDrop?: boolean; + items?: Node[]; +} +export interface DropStmt { + objects?: Node[]; + removeType?: ObjectType; + behavior?: DropBehavior; + missing_ok?: boolean; + concurrent?: boolean; +} +export interface TruncateStmt { + relations?: Node[]; + restart_seqs?: boolean; + behavior?: DropBehavior; +} +export interface CommentStmt { + objtype?: ObjectType; + object?: Node; + comment?: string; +} +export interface SecLabelStmt { + objtype?: ObjectType; + object?: Node; + provider?: string; + label?: string; +} +export interface DeclareCursorStmt { + portalname?: string; + options?: number; + query?: Node; +} +export interface ClosePortalStmt { + portalname?: string; +} +export interface FetchStmt { + direction?: FetchDirection; + howMany?: bigint; + portalname?: string; + ismove?: boolean; +} +export interface IndexStmt { + idxname?: string; + relation?: RangeVar; + accessMethod?: string; + tableSpace?: string; + indexParams?: Node[]; + indexIncludingParams?: Node[]; + options?: Node[]; + whereClause?: Node; + excludeOpNames?: Node[]; + idxcomment?: string; + indexOid?: number; + oldNumber?: number; + oldCreateSubid?: number; + oldFirstRelfilelocatorSubid?: number; + unique?: boolean; + nulls_not_distinct?: boolean; + primary?: boolean; + isconstraint?: boolean; + deferrable?: boolean; + initdeferred?: boolean; + transformed?: boolean; + concurrent?: boolean; + if_not_exists?: boolean; + reset_default_tblspc?: boolean; +} +export interface CreateStatsStmt { + defnames?: Node[]; + stat_types?: Node[]; + exprs?: Node[]; + relations?: Node[]; + stxcomment?: string; + transformed?: boolean; + if_not_exists?: boolean; +} +export interface StatsElem { + name?: string; + expr?: Node; +} +export interface AlterStatsStmt { + defnames?: Node[]; + stxstattarget?: number; + missing_ok?: boolean; +} +export interface CreateFunctionStmt { + is_procedure?: boolean; + replace?: boolean; + funcname?: Node[]; + parameters?: Node[]; + returnType?: TypeName; + options?: Node[]; + sql_body?: Node; +} +export interface FunctionParameter { + name?: string; + argType?: TypeName; + mode?: FunctionParameterMode; + defexpr?: Node; +} +export interface AlterFunctionStmt { + objtype?: ObjectType; + func?: ObjectWithArgs; + actions?: Node[]; +} +export interface DoStmt { + args?: Node[]; +} +export interface InlineCodeBlock { + source_text?: string; + langOid?: number; + langIsTrusted?: boolean; + atomic?: boolean; +} +export interface CallStmt { + funccall?: FuncCall; + funcexpr?: FuncExpr; + outargs?: Node[]; +} +export interface CallContext { + atomic?: boolean; +} +export interface RenameStmt { + renameType?: ObjectType; + relationType?: ObjectType; + relation?: RangeVar; + object?: Node; + subname?: string; + newname?: string; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface AlterObjectDependsStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + extname?: String; + remove?: boolean; +} +export interface AlterObjectSchemaStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newschema?: string; + missing_ok?: boolean; +} +export interface AlterOwnerStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newowner?: RoleSpec; +} +export interface AlterOperatorStmt { + opername?: ObjectWithArgs; + options?: Node[]; +} +export interface AlterTypeStmt { + typeName?: Node[]; + options?: Node[]; +} +export interface RuleStmt { + relation?: RangeVar; + rulename?: string; + whereClause?: Node; + event?: CmdType; + instead?: boolean; + actions?: Node[]; + replace?: boolean; +} +export interface NotifyStmt { + conditionname?: string; + payload?: string; +} +export interface ListenStmt { + conditionname?: string; +} +export interface UnlistenStmt { + conditionname?: string; +} +export interface TransactionStmt { + kind?: TransactionStmtKind; + options?: Node[]; + savepoint_name?: string; + gid?: string; + chain?: boolean; +} +export interface CompositeTypeStmt { + typevar?: RangeVar; + coldeflist?: Node[]; +} +export interface CreateEnumStmt { + typeName?: Node[]; + vals?: Node[]; +} +export interface CreateRangeStmt { + typeName?: Node[]; + params?: Node[]; +} +export interface AlterEnumStmt { + typeName?: Node[]; + oldVal?: string; + newVal?: string; + newValNeighbor?: string; + newValIsAfter?: boolean; + skipIfNewValExists?: boolean; +} +export interface ViewStmt { + view?: RangeVar; + aliases?: Node[]; + query?: Node; + replace?: boolean; + options?: Node[]; + withCheckOption?: ViewCheckOption; +} +export interface LoadStmt { + filename?: string; +} +export interface CreatedbStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseRefreshCollStmt { + dbname?: string; +} +export interface AlterDatabaseSetStmt { + dbname?: string; + setstmt?: VariableSetStmt; +} +export interface DropdbStmt { + dbname?: string; + missing_ok?: boolean; + options?: Node[]; +} +export interface AlterSystemStmt { + setstmt?: VariableSetStmt; +} +export interface ClusterStmt { + relation?: RangeVar; + indexname?: string; + params?: Node[]; +} +export interface VacuumStmt { + options?: Node[]; + rels?: Node[]; + is_vacuumcmd?: boolean; +} +export interface VacuumRelation { + relation?: RangeVar; + oid?: number; + va_cols?: Node[]; +} +export interface ExplainStmt { + query?: Node; + options?: Node[]; +} +export interface CreateTableAsStmt { + query?: Node; + into?: IntoClause; + objtype?: ObjectType; + is_select_into?: boolean; + if_not_exists?: boolean; +} +export interface RefreshMatViewStmt { + concurrent?: boolean; + skipData?: boolean; + relation?: RangeVar; +} +export interface CheckPointStmt {} +export interface DiscardStmt { + target?: DiscardMode; +} +export interface LockStmt { + relations?: Node[]; + mode?: number; + nowait?: boolean; +} +export interface ConstraintsSetStmt { + constraints?: Node[]; + deferred?: boolean; +} +export interface ReindexStmt { + kind?: ReindexObjectType; + relation?: RangeVar; + name?: string; + params?: Node[]; +} +export interface CreateConversionStmt { + conversion_name?: Node[]; + for_encoding_name?: string; + to_encoding_name?: string; + func_name?: Node[]; + def?: boolean; +} +export interface CreateCastStmt { + sourcetype?: TypeName; + targettype?: TypeName; + func?: ObjectWithArgs; + context?: CoercionContext; + inout?: boolean; +} +export interface CreateTransformStmt { + replace?: boolean; + type_name?: TypeName; + lang?: string; + fromsql?: ObjectWithArgs; + tosql?: ObjectWithArgs; +} +export interface PrepareStmt { + name?: string; + argtypes?: Node[]; + query?: Node; +} +export interface ExecuteStmt { + name?: string; + params?: Node[]; +} +export interface DeallocateStmt { + name?: string; +} +export interface DropOwnedStmt { + roles?: Node[]; + behavior?: DropBehavior; +} +export interface ReassignOwnedStmt { + roles?: Node[]; + newrole?: RoleSpec; +} +export interface AlterTSDictionaryStmt { + dictname?: Node[]; + options?: Node[]; +} +export interface AlterTSConfigurationStmt { + kind?: AlterTSConfigType; + cfgname?: Node[]; + tokentype?: Node[]; + dicts?: Node[]; + override?: boolean; + replace?: boolean; + missing_ok?: boolean; +} +export interface PublicationTable { + relation?: RangeVar; + whereClause?: Node; + columns?: Node[]; +} +export interface PublicationObjSpec { + pubobjtype?: PublicationObjSpecType; + name?: string; + pubtable?: PublicationTable; + location?: number; +} +export interface CreatePublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; +} +export interface AlterPublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; + action?: AlterPublicationAction; +} +export interface CreateSubscriptionStmt { + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface AlterSubscriptionStmt { + kind?: AlterSubscriptionType; + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface DropSubscriptionStmt { + subname?: string; + missing_ok?: boolean; + behavior?: DropBehavior; +} +export interface ScanToken { + start?: number; + end?: number; + token?: Token; + keywordKind?: KeywordKind; +} \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/wrappedHelpers/asts.ts b/__fixtures__/output/utils/astHelpers/wrappedHelpers/asts.ts new file mode 100644 index 00000000..313b2223 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/wrappedHelpers/asts.ts @@ -0,0 +1,3350 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +}; \ No newline at end of file diff --git a/__fixtures__/output/utils/astHelpers/wrappedHelpers/types.ts b/__fixtures__/output/utils/astHelpers/wrappedHelpers/types.ts new file mode 100644 index 00000000..cf5f2c36 --- /dev/null +++ b/__fixtures__/output/utils/astHelpers/wrappedHelpers/types.ts @@ -0,0 +1,2326 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +export type Node = { + ParseResult: ParseResult; +} | { + ScanResult: ScanResult; +} | { + Integer: Integer; +} | { + Float: Float; +} | { + Boolean: Boolean; +} | { + String: String; +} | { + BitString: BitString; +} | { + List: List; +} | { + OidList: OidList; +} | { + IntList: IntList; +} | { + A_Const: A_Const; +} | { + Alias: Alias; +} | { + RangeVar: RangeVar; +} | { + TableFunc: TableFunc; +} | { + IntoClause: IntoClause; +} | { + Var: Var; +} | { + Param: Param; +} | { + Aggref: Aggref; +} | { + GroupingFunc: GroupingFunc; +} | { + WindowFunc: WindowFunc; +} | { + SubscriptingRef: SubscriptingRef; +} | { + FuncExpr: FuncExpr; +} | { + NamedArgExpr: NamedArgExpr; +} | { + OpExpr: OpExpr; +} | { + DistinctExpr: DistinctExpr; +} | { + NullIfExpr: NullIfExpr; +} | { + ScalarArrayOpExpr: ScalarArrayOpExpr; +} | { + BoolExpr: BoolExpr; +} | { + SubLink: SubLink; +} | { + SubPlan: SubPlan; +} | { + AlternativeSubPlan: AlternativeSubPlan; +} | { + FieldSelect: FieldSelect; +} | { + FieldStore: FieldStore; +} | { + RelabelType: RelabelType; +} | { + CoerceViaIO: CoerceViaIO; +} | { + ArrayCoerceExpr: ArrayCoerceExpr; +} | { + ConvertRowtypeExpr: ConvertRowtypeExpr; +} | { + CollateExpr: CollateExpr; +} | { + CaseExpr: CaseExpr; +} | { + CaseWhen: CaseWhen; +} | { + CaseTestExpr: CaseTestExpr; +} | { + ArrayExpr: ArrayExpr; +} | { + RowExpr: RowExpr; +} | { + RowCompareExpr: RowCompareExpr; +} | { + CoalesceExpr: CoalesceExpr; +} | { + MinMaxExpr: MinMaxExpr; +} | { + SQLValueFunction: SQLValueFunction; +} | { + XmlExpr: XmlExpr; +} | { + JsonFormat: JsonFormat; +} | { + JsonReturning: JsonReturning; +} | { + JsonValueExpr: JsonValueExpr; +} | { + JsonConstructorExpr: JsonConstructorExpr; +} | { + JsonIsPredicate: JsonIsPredicate; +} | { + NullTest: NullTest; +} | { + BooleanTest: BooleanTest; +} | { + CoerceToDomain: CoerceToDomain; +} | { + CoerceToDomainValue: CoerceToDomainValue; +} | { + SetToDefault: SetToDefault; +} | { + CurrentOfExpr: CurrentOfExpr; +} | { + NextValueExpr: NextValueExpr; +} | { + InferenceElem: InferenceElem; +} | { + TargetEntry: TargetEntry; +} | { + RangeTblRef: RangeTblRef; +} | { + JoinExpr: JoinExpr; +} | { + FromExpr: FromExpr; +} | { + OnConflictExpr: OnConflictExpr; +} | { + Query: Query; +} | { + TypeName: TypeName; +} | { + ColumnRef: ColumnRef; +} | { + ParamRef: ParamRef; +} | { + A_Expr: A_Expr; +} | { + TypeCast: TypeCast; +} | { + CollateClause: CollateClause; +} | { + RoleSpec: RoleSpec; +} | { + FuncCall: FuncCall; +} | { + A_Star: A_Star; +} | { + A_Indices: A_Indices; +} | { + A_Indirection: A_Indirection; +} | { + A_ArrayExpr: A_ArrayExpr; +} | { + ResTarget: ResTarget; +} | { + MultiAssignRef: MultiAssignRef; +} | { + SortBy: SortBy; +} | { + WindowDef: WindowDef; +} | { + RangeSubselect: RangeSubselect; +} | { + RangeFunction: RangeFunction; +} | { + RangeTableFunc: RangeTableFunc; +} | { + RangeTableFuncCol: RangeTableFuncCol; +} | { + RangeTableSample: RangeTableSample; +} | { + ColumnDef: ColumnDef; +} | { + TableLikeClause: TableLikeClause; +} | { + IndexElem: IndexElem; +} | { + DefElem: DefElem; +} | { + LockingClause: LockingClause; +} | { + XmlSerialize: XmlSerialize; +} | { + PartitionElem: PartitionElem; +} | { + PartitionSpec: PartitionSpec; +} | { + PartitionBoundSpec: PartitionBoundSpec; +} | { + PartitionRangeDatum: PartitionRangeDatum; +} | { + PartitionCmd: PartitionCmd; +} | { + RangeTblEntry: RangeTblEntry; +} | { + RTEPermissionInfo: RTEPermissionInfo; +} | { + RangeTblFunction: RangeTblFunction; +} | { + TableSampleClause: TableSampleClause; +} | { + WithCheckOption: WithCheckOption; +} | { + SortGroupClause: SortGroupClause; +} | { + GroupingSet: GroupingSet; +} | { + WindowClause: WindowClause; +} | { + RowMarkClause: RowMarkClause; +} | { + WithClause: WithClause; +} | { + InferClause: InferClause; +} | { + OnConflictClause: OnConflictClause; +} | { + CTESearchClause: CTESearchClause; +} | { + CTECycleClause: CTECycleClause; +} | { + CommonTableExpr: CommonTableExpr; +} | { + MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; +} | { + TriggerTransition: TriggerTransition; +} | { + JsonOutput: JsonOutput; +} | { + JsonKeyValue: JsonKeyValue; +} | { + JsonObjectConstructor: JsonObjectConstructor; +} | { + JsonArrayConstructor: JsonArrayConstructor; +} | { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; +} | { + JsonAggConstructor: JsonAggConstructor; +} | { + JsonObjectAgg: JsonObjectAgg; +} | { + JsonArrayAgg: JsonArrayAgg; +} | { + RawStmt: RawStmt; +} | { + InsertStmt: InsertStmt; +} | { + DeleteStmt: DeleteStmt; +} | { + UpdateStmt: UpdateStmt; +} | { + MergeStmt: MergeStmt; +} | { + SelectStmt: SelectStmt; +} | { + SetOperationStmt: SetOperationStmt; +} | { + ReturnStmt: ReturnStmt; +} | { + PLAssignStmt: PLAssignStmt; +} | { + CreateSchemaStmt: CreateSchemaStmt; +} | { + AlterTableStmt: AlterTableStmt; +} | { + ReplicaIdentityStmt: ReplicaIdentityStmt; +} | { + AlterTableCmd: AlterTableCmd; +} | { + AlterCollationStmt: AlterCollationStmt; +} | { + AlterDomainStmt: AlterDomainStmt; +} | { + GrantStmt: GrantStmt; +} | { + ObjectWithArgs: ObjectWithArgs; +} | { + AccessPriv: AccessPriv; +} | { + GrantRoleStmt: GrantRoleStmt; +} | { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; +} | { + CopyStmt: CopyStmt; +} | { + VariableSetStmt: VariableSetStmt; +} | { + VariableShowStmt: VariableShowStmt; +} | { + CreateStmt: CreateStmt; +} | { + Constraint: Constraint; +} | { + CreateTableSpaceStmt: CreateTableSpaceStmt; +} | { + DropTableSpaceStmt: DropTableSpaceStmt; +} | { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; +} | { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; +} | { + CreateExtensionStmt: CreateExtensionStmt; +} | { + AlterExtensionStmt: AlterExtensionStmt; +} | { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; +} | { + CreateFdwStmt: CreateFdwStmt; +} | { + AlterFdwStmt: AlterFdwStmt; +} | { + CreateForeignServerStmt: CreateForeignServerStmt; +} | { + AlterForeignServerStmt: AlterForeignServerStmt; +} | { + CreateForeignTableStmt: CreateForeignTableStmt; +} | { + CreateUserMappingStmt: CreateUserMappingStmt; +} | { + AlterUserMappingStmt: AlterUserMappingStmt; +} | { + DropUserMappingStmt: DropUserMappingStmt; +} | { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; +} | { + CreatePolicyStmt: CreatePolicyStmt; +} | { + AlterPolicyStmt: AlterPolicyStmt; +} | { + CreateAmStmt: CreateAmStmt; +} | { + CreateTrigStmt: CreateTrigStmt; +} | { + CreateEventTrigStmt: CreateEventTrigStmt; +} | { + AlterEventTrigStmt: AlterEventTrigStmt; +} | { + CreatePLangStmt: CreatePLangStmt; +} | { + CreateRoleStmt: CreateRoleStmt; +} | { + AlterRoleStmt: AlterRoleStmt; +} | { + AlterRoleSetStmt: AlterRoleSetStmt; +} | { + DropRoleStmt: DropRoleStmt; +} | { + CreateSeqStmt: CreateSeqStmt; +} | { + AlterSeqStmt: AlterSeqStmt; +} | { + DefineStmt: DefineStmt; +} | { + CreateDomainStmt: CreateDomainStmt; +} | { + CreateOpClassStmt: CreateOpClassStmt; +} | { + CreateOpClassItem: CreateOpClassItem; +} | { + CreateOpFamilyStmt: CreateOpFamilyStmt; +} | { + AlterOpFamilyStmt: AlterOpFamilyStmt; +} | { + DropStmt: DropStmt; +} | { + TruncateStmt: TruncateStmt; +} | { + CommentStmt: CommentStmt; +} | { + SecLabelStmt: SecLabelStmt; +} | { + DeclareCursorStmt: DeclareCursorStmt; +} | { + ClosePortalStmt: ClosePortalStmt; +} | { + FetchStmt: FetchStmt; +} | { + IndexStmt: IndexStmt; +} | { + CreateStatsStmt: CreateStatsStmt; +} | { + StatsElem: StatsElem; +} | { + AlterStatsStmt: AlterStatsStmt; +} | { + CreateFunctionStmt: CreateFunctionStmt; +} | { + FunctionParameter: FunctionParameter; +} | { + AlterFunctionStmt: AlterFunctionStmt; +} | { + DoStmt: DoStmt; +} | { + InlineCodeBlock: InlineCodeBlock; +} | { + CallStmt: CallStmt; +} | { + CallContext: CallContext; +} | { + RenameStmt: RenameStmt; +} | { + AlterObjectDependsStmt: AlterObjectDependsStmt; +} | { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; +} | { + AlterOwnerStmt: AlterOwnerStmt; +} | { + AlterOperatorStmt: AlterOperatorStmt; +} | { + AlterTypeStmt: AlterTypeStmt; +} | { + RuleStmt: RuleStmt; +} | { + NotifyStmt: NotifyStmt; +} | { + ListenStmt: ListenStmt; +} | { + UnlistenStmt: UnlistenStmt; +} | { + TransactionStmt: TransactionStmt; +} | { + CompositeTypeStmt: CompositeTypeStmt; +} | { + CreateEnumStmt: CreateEnumStmt; +} | { + CreateRangeStmt: CreateRangeStmt; +} | { + AlterEnumStmt: AlterEnumStmt; +} | { + ViewStmt: ViewStmt; +} | { + LoadStmt: LoadStmt; +} | { + CreatedbStmt: CreatedbStmt; +} | { + AlterDatabaseStmt: AlterDatabaseStmt; +} | { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; +} | { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; +} | { + DropdbStmt: DropdbStmt; +} | { + AlterSystemStmt: AlterSystemStmt; +} | { + ClusterStmt: ClusterStmt; +} | { + VacuumStmt: VacuumStmt; +} | { + VacuumRelation: VacuumRelation; +} | { + ExplainStmt: ExplainStmt; +} | { + CreateTableAsStmt: CreateTableAsStmt; +} | { + RefreshMatViewStmt: RefreshMatViewStmt; +} | { + CheckPointStmt: CheckPointStmt; +} | { + DiscardStmt: DiscardStmt; +} | { + LockStmt: LockStmt; +} | { + ConstraintsSetStmt: ConstraintsSetStmt; +} | { + ReindexStmt: ReindexStmt; +} | { + CreateConversionStmt: CreateConversionStmt; +} | { + CreateCastStmt: CreateCastStmt; +} | { + CreateTransformStmt: CreateTransformStmt; +} | { + PrepareStmt: PrepareStmt; +} | { + ExecuteStmt: ExecuteStmt; +} | { + DeallocateStmt: DeallocateStmt; +} | { + DropOwnedStmt: DropOwnedStmt; +} | { + ReassignOwnedStmt: ReassignOwnedStmt; +} | { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; +} | { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; +} | { + PublicationTable: PublicationTable; +} | { + PublicationObjSpec: PublicationObjSpec; +} | { + CreatePublicationStmt: CreatePublicationStmt; +} | { + AlterPublicationStmt: AlterPublicationStmt; +} | { + CreateSubscriptionStmt: CreateSubscriptionStmt; +} | { + AlterSubscriptionStmt: AlterSubscriptionStmt; +} | { + DropSubscriptionStmt: DropSubscriptionStmt; +} | { + ScanToken: ScanToken; +}; +export interface ParseResult { + version?: number; + stmts?: RawStmt[]; +} +export interface ScanResult { + version?: number; + tokens?: ScanToken[]; +} +export interface Integer { + ival?: number; +} +export interface Float { + fval?: string; +} +export interface Boolean { + boolval?: boolean; +} +export interface String { + sval?: string; +} +export interface BitString { + bsval?: string; +} +export interface List { + items?: Node[]; +} +export interface OidList { + items?: Node[]; +} +export interface IntList { + items?: Node[]; +} +export interface A_Const { + ival?: Integer; + fval?: Float; + boolval?: Boolean; + sval?: String; + bsval?: BitString; + isnull?: boolean; + location?: number; +} +export interface Alias { + aliasname?: string; + colnames?: Node[]; +} +export interface RangeVar { + catalogname?: string; + schemaname?: string; + relname?: string; + inh?: boolean; + relpersistence?: string; + alias?: Alias; + location?: number; +} +export interface TableFunc { + ns_uris?: Node[]; + ns_names?: Node[]; + docexpr?: Node; + rowexpr?: Node; + colnames?: Node[]; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + colexprs?: Node[]; + coldefexprs?: Node[]; + notnulls?: bigint[]; + ordinalitycol?: number; + location?: number; +} +export interface IntoClause { + rel?: RangeVar; + colNames?: Node[]; + accessMethod?: string; + options?: Node[]; + onCommit?: OnCommitAction; + tableSpaceName?: string; + viewQuery?: Node; + skipData?: boolean; +} +export interface Var { + xpr?: Node; + varno?: number; + varattno?: number; + vartype?: number; + vartypmod?: number; + varcollid?: number; + varnullingrels?: bigint[]; + varlevelsup?: number; + location?: number; +} +export interface Param { + xpr?: Node; + paramkind?: ParamKind; + paramid?: number; + paramtype?: number; + paramtypmod?: number; + paramcollid?: number; + location?: number; +} +export interface Aggref { + xpr?: Node; + aggfnoid?: number; + aggtype?: number; + aggcollid?: number; + inputcollid?: number; + aggargtypes?: Node[]; + aggdirectargs?: Node[]; + args?: Node[]; + aggorder?: Node[]; + aggdistinct?: Node[]; + aggfilter?: Node; + aggstar?: boolean; + aggvariadic?: boolean; + aggkind?: string; + agglevelsup?: number; + aggsplit?: AggSplit; + aggno?: number; + aggtransno?: number; + location?: number; +} +export interface GroupingFunc { + xpr?: Node; + args?: Node[]; + refs?: Node[]; + agglevelsup?: number; + location?: number; +} +export interface WindowFunc { + xpr?: Node; + winfnoid?: number; + wintype?: number; + wincollid?: number; + inputcollid?: number; + args?: Node[]; + aggfilter?: Node; + winref?: number; + winstar?: boolean; + winagg?: boolean; + location?: number; +} +export interface SubscriptingRef { + xpr?: Node; + refcontainertype?: number; + refelemtype?: number; + refrestype?: number; + reftypmod?: number; + refcollid?: number; + refupperindexpr?: Node[]; + reflowerindexpr?: Node[]; + refexpr?: Node; + refassgnexpr?: Node; +} +export interface FuncExpr { + xpr?: Node; + funcid?: number; + funcresulttype?: number; + funcretset?: boolean; + funcvariadic?: boolean; + funcformat?: CoercionForm; + funccollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NamedArgExpr { + xpr?: Node; + arg?: Node; + name?: string; + argnumber?: number; + location?: number; +} +export interface OpExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface DistinctExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NullIfExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface ScalarArrayOpExpr { + xpr?: Node; + opno?: number; + useOr?: boolean; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface BoolExpr { + xpr?: Node; + boolop?: BoolExprType; + args?: Node[]; + location?: number; +} +export interface SubLink { + xpr?: Node; + subLinkType?: SubLinkType; + subLinkId?: number; + testexpr?: Node; + operName?: Node[]; + subselect?: Node; + location?: number; +} +export interface SubPlan { + xpr?: Node; + subLinkType?: SubLinkType; + testexpr?: Node; + paramIds?: Node[]; + plan_id?: number; + plan_name?: string; + firstColType?: number; + firstColTypmod?: number; + firstColCollation?: number; + useHashTable?: boolean; + unknownEqFalse?: boolean; + parallel_safe?: boolean; + setParam?: Node[]; + parParam?: Node[]; + args?: Node[]; + startup_cost?: number; + per_call_cost?: number; +} +export interface AlternativeSubPlan { + xpr?: Node; + subplans?: Node[]; +} +export interface FieldSelect { + xpr?: Node; + arg?: Node; + fieldnum?: number; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; +} +export interface FieldStore { + xpr?: Node; + arg?: Node; + newvals?: Node[]; + fieldnums?: Node[]; + resulttype?: number; +} +export interface RelabelType { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + relabelformat?: CoercionForm; + location?: number; +} +export interface CoerceViaIO { + xpr?: Node; + arg?: Node; + resulttype?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ArrayCoerceExpr { + xpr?: Node; + arg?: Node; + elemexpr?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ConvertRowtypeExpr { + xpr?: Node; + arg?: Node; + resulttype?: number; + convertformat?: CoercionForm; + location?: number; +} +export interface CollateExpr { + xpr?: Node; + arg?: Node; + collOid?: number; + location?: number; +} +export interface CaseExpr { + xpr?: Node; + casetype?: number; + casecollid?: number; + arg?: Node; + args?: Node[]; + defresult?: Node; + location?: number; +} +export interface CaseWhen { + xpr?: Node; + expr?: Node; + result?: Node; + location?: number; +} +export interface CaseTestExpr { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; +} +export interface ArrayExpr { + xpr?: Node; + array_typeid?: number; + array_collid?: number; + element_typeid?: number; + elements?: Node[]; + multidims?: boolean; + location?: number; +} +export interface RowExpr { + xpr?: Node; + args?: Node[]; + row_typeid?: number; + row_format?: CoercionForm; + colnames?: Node[]; + location?: number; +} +export interface RowCompareExpr { + xpr?: Node; + rctype?: RowCompareType; + opnos?: Node[]; + opfamilies?: Node[]; + inputcollids?: Node[]; + largs?: Node[]; + rargs?: Node[]; +} +export interface CoalesceExpr { + xpr?: Node; + coalescetype?: number; + coalescecollid?: number; + args?: Node[]; + location?: number; +} +export interface MinMaxExpr { + xpr?: Node; + minmaxtype?: number; + minmaxcollid?: number; + inputcollid?: number; + op?: MinMaxOp; + args?: Node[]; + location?: number; +} +export interface SQLValueFunction { + xpr?: Node; + op?: SQLValueFunctionOp; + type?: number; + typmod?: number; + location?: number; +} +export interface XmlExpr { + xpr?: Node; + op?: XmlExprOp; + name?: string; + named_args?: Node[]; + arg_names?: Node[]; + args?: Node[]; + xmloption?: XmlOptionType; + indent?: boolean; + type?: number; + typmod?: number; + location?: number; +} +export interface JsonFormat { + format_type?: JsonFormatType; + encoding?: JsonEncoding; + location?: number; +} +export interface JsonReturning { + format?: JsonFormat; + typid?: number; + typmod?: number; +} +export interface JsonValueExpr { + raw_expr?: Node; + formatted_expr?: Node; + format?: JsonFormat; +} +export interface JsonConstructorExpr { + xpr?: Node; + type?: JsonConstructorType; + args?: Node[]; + func?: Node; + coercion?: Node; + returning?: JsonReturning; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonIsPredicate { + expr?: Node; + format?: JsonFormat; + item_type?: JsonValueType; + unique_keys?: boolean; + location?: number; +} +export interface NullTest { + xpr?: Node; + arg?: Node; + nulltesttype?: NullTestType; + argisrow?: boolean; + location?: number; +} +export interface BooleanTest { + xpr?: Node; + arg?: Node; + booltesttype?: BoolTestType; + location?: number; +} +export interface CoerceToDomain { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coercionformat?: CoercionForm; + location?: number; +} +export interface CoerceToDomainValue { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface SetToDefault { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface CurrentOfExpr { + xpr?: Node; + cvarno?: number; + cursor_name?: string; + cursor_param?: number; +} +export interface NextValueExpr { + xpr?: Node; + seqid?: number; + typeId?: number; +} +export interface InferenceElem { + xpr?: Node; + expr?: Node; + infercollid?: number; + inferopclass?: number; +} +export interface TargetEntry { + xpr?: Node; + expr?: Node; + resno?: number; + resname?: string; + ressortgroupref?: number; + resorigtbl?: number; + resorigcol?: number; + resjunk?: boolean; +} +export interface RangeTblRef { + rtindex?: number; +} +export interface JoinExpr { + jointype?: JoinType; + isNatural?: boolean; + larg?: Node; + rarg?: Node; + usingClause?: Node[]; + join_using_alias?: Alias; + quals?: Node; + alias?: Alias; + rtindex?: number; +} +export interface FromExpr { + fromlist?: Node[]; + quals?: Node; +} +export interface OnConflictExpr { + action?: OnConflictAction; + arbiterElems?: Node[]; + arbiterWhere?: Node; + constraint?: number; + onConflictSet?: Node[]; + onConflictWhere?: Node; + exclRelIndex?: number; + exclRelTlist?: Node[]; +} +export interface Query { + commandType?: CmdType; + querySource?: QuerySource; + canSetTag?: boolean; + utilityStmt?: Node; + resultRelation?: number; + hasAggs?: boolean; + hasWindowFuncs?: boolean; + hasTargetSRFs?: boolean; + hasSubLinks?: boolean; + hasDistinctOn?: boolean; + hasRecursive?: boolean; + hasModifyingCTE?: boolean; + hasForUpdate?: boolean; + hasRowSecurity?: boolean; + isReturn?: boolean; + cteList?: Node[]; + rtable?: Node[]; + rteperminfos?: Node[]; + jointree?: FromExpr; + mergeActionList?: Node[]; + mergeUseOuterJoin?: boolean; + targetList?: Node[]; + override?: OverridingKind; + onConflict?: OnConflictExpr; + returningList?: Node[]; + groupClause?: Node[]; + groupDistinct?: boolean; + groupingSets?: Node[]; + havingQual?: Node; + windowClause?: Node[]; + distinctClause?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + rowMarks?: Node[]; + setOperations?: Node; + constraintDeps?: Node[]; + withCheckOptions?: Node[]; + stmt_location?: number; + stmt_len?: number; +} +export interface TypeName { + names?: Node[]; + typeOid?: number; + setof?: boolean; + pct_type?: boolean; + typmods?: Node[]; + typemod?: number; + arrayBounds?: Node[]; + location?: number; +} +export interface ColumnRef { + fields?: Node[]; + location?: number; +} +export interface ParamRef { + number?: number; + location?: number; +} +export interface A_Expr { + kind?: A_Expr_Kind; + name?: Node[]; + lexpr?: Node; + rexpr?: Node; + location?: number; +} +export interface TypeCast { + arg?: Node; + typeName?: TypeName; + location?: number; +} +export interface CollateClause { + arg?: Node; + collname?: Node[]; + location?: number; +} +export interface RoleSpec { + roletype?: RoleSpecType; + rolename?: string; + location?: number; +} +export interface FuncCall { + funcname?: Node[]; + args?: Node[]; + agg_order?: Node[]; + agg_filter?: Node; + over?: WindowDef; + agg_within_group?: boolean; + agg_star?: boolean; + agg_distinct?: boolean; + func_variadic?: boolean; + funcformat?: CoercionForm; + location?: number; +} +export interface A_Star {} +export interface A_Indices { + is_slice?: boolean; + lidx?: Node; + uidx?: Node; +} +export interface A_Indirection { + arg?: Node; + indirection?: Node[]; +} +export interface A_ArrayExpr { + elements?: Node[]; + location?: number; +} +export interface ResTarget { + name?: string; + indirection?: Node[]; + val?: Node; + location?: number; +} +export interface MultiAssignRef { + source?: Node; + colno?: number; + ncolumns?: number; +} +export interface SortBy { + node?: Node; + sortby_dir?: SortByDir; + sortby_nulls?: SortByNulls; + useOp?: Node[]; + location?: number; +} +export interface WindowDef { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + location?: number; +} +export interface RangeSubselect { + lateral?: boolean; + subquery?: Node; + alias?: Alias; +} +export interface RangeFunction { + lateral?: boolean; + ordinality?: boolean; + is_rowsfrom?: boolean; + functions?: Node[]; + alias?: Alias; + coldeflist?: Node[]; +} +export interface RangeTableFunc { + lateral?: boolean; + docexpr?: Node; + rowexpr?: Node; + namespaces?: Node[]; + columns?: Node[]; + alias?: Alias; + location?: number; +} +export interface RangeTableFuncCol { + colname?: string; + typeName?: TypeName; + for_ordinality?: boolean; + is_not_null?: boolean; + colexpr?: Node; + coldefexpr?: Node; + location?: number; +} +export interface RangeTableSample { + relation?: Node; + method?: Node[]; + args?: Node[]; + repeatable?: Node; + location?: number; +} +export interface ColumnDef { + colname?: string; + typeName?: TypeName; + compression?: string; + inhcount?: number; + is_local?: boolean; + is_not_null?: boolean; + is_from_type?: boolean; + storage?: string; + storage_name?: string; + raw_default?: Node; + cooked_default?: Node; + identity?: string; + identitySequence?: RangeVar; + generated?: string; + collClause?: CollateClause; + collOid?: number; + constraints?: Node[]; + fdwoptions?: Node[]; + location?: number; +} +export interface TableLikeClause { + relation?: RangeVar; + options?: number; + relationOid?: number; +} +export interface IndexElem { + name?: string; + expr?: Node; + indexcolname?: string; + collation?: Node[]; + opclass?: Node[]; + opclassopts?: Node[]; + ordering?: SortByDir; + nulls_ordering?: SortByNulls; +} +export interface DefElem { + defnamespace?: string; + defname?: string; + arg?: Node; + defaction?: DefElemAction; + location?: number; +} +export interface LockingClause { + lockedRels?: Node[]; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; +} +export interface XmlSerialize { + xmloption?: XmlOptionType; + expr?: Node; + typeName?: TypeName; + indent?: boolean; + location?: number; +} +export interface PartitionElem { + name?: string; + expr?: Node; + collation?: Node[]; + opclass?: Node[]; + location?: number; +} +export interface PartitionSpec { + strategy?: PartitionStrategy; + partParams?: Node[]; + location?: number; +} +export interface PartitionBoundSpec { + strategy?: string; + is_default?: boolean; + modulus?: number; + remainder?: number; + listdatums?: Node[]; + lowerdatums?: Node[]; + upperdatums?: Node[]; + location?: number; +} +export interface PartitionRangeDatum { + kind?: PartitionRangeDatumKind; + value?: Node; + location?: number; +} +export interface PartitionCmd { + name?: RangeVar; + bound?: PartitionBoundSpec; + concurrent?: boolean; +} +export interface RangeTblEntry { + rtekind?: RTEKind; + relid?: number; + relkind?: string; + rellockmode?: number; + tablesample?: TableSampleClause; + perminfoindex?: number; + subquery?: Query; + security_barrier?: boolean; + jointype?: JoinType; + joinmergedcols?: number; + joinaliasvars?: Node[]; + joinleftcols?: Node[]; + joinrightcols?: Node[]; + join_using_alias?: Alias; + functions?: Node[]; + funcordinality?: boolean; + tablefunc?: TableFunc; + values_lists?: Node[]; + ctename?: string; + ctelevelsup?: number; + self_reference?: boolean; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + enrname?: string; + enrtuples?: number; + alias?: Alias; + eref?: Alias; + lateral?: boolean; + inh?: boolean; + inFromCl?: boolean; + securityQuals?: Node[]; +} +export interface RTEPermissionInfo { + relid?: number; + inh?: boolean; + requiredPerms?: bigint; + checkAsUser?: number; + selectedCols?: bigint[]; + insertedCols?: bigint[]; + updatedCols?: bigint[]; +} +export interface RangeTblFunction { + funcexpr?: Node; + funccolcount?: number; + funccolnames?: Node[]; + funccoltypes?: Node[]; + funccoltypmods?: Node[]; + funccolcollations?: Node[]; + funcparams?: bigint[]; +} +export interface TableSampleClause { + tsmhandler?: number; + args?: Node[]; + repeatable?: Node; +} +export interface WithCheckOption { + kind?: WCOKind; + relname?: string; + polname?: string; + qual?: Node; + cascaded?: boolean; +} +export interface SortGroupClause { + tleSortGroupRef?: number; + eqop?: number; + sortop?: number; + nulls_first?: boolean; + hashable?: boolean; +} +export interface GroupingSet { + kind?: GroupingSetKind; + content?: Node[]; + location?: number; +} +export interface WindowClause { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + runCondition?: Node[]; + startInRangeFunc?: number; + endInRangeFunc?: number; + inRangeColl?: number; + inRangeAsc?: boolean; + inRangeNullsFirst?: boolean; + winref?: number; + copiedOrder?: boolean; +} +export interface RowMarkClause { + rti?: number; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; + pushedDown?: boolean; +} +export interface WithClause { + ctes?: Node[]; + recursive?: boolean; + location?: number; +} +export interface InferClause { + indexElems?: Node[]; + whereClause?: Node; + conname?: string; + location?: number; +} +export interface OnConflictClause { + action?: OnConflictAction; + infer?: InferClause; + targetList?: Node[]; + whereClause?: Node; + location?: number; +} +export interface CTESearchClause { + search_col_list?: Node[]; + search_breadth_first?: boolean; + search_seq_column?: string; + location?: number; +} +export interface CTECycleClause { + cycle_col_list?: Node[]; + cycle_mark_column?: string; + cycle_mark_value?: Node; + cycle_mark_default?: Node; + cycle_path_column?: string; + location?: number; + cycle_mark_type?: number; + cycle_mark_typmod?: number; + cycle_mark_collation?: number; + cycle_mark_neop?: number; +} +export interface CommonTableExpr { + ctename?: string; + aliascolnames?: Node[]; + ctematerialized?: CTEMaterialize; + ctequery?: Node; + search_clause?: CTESearchClause; + cycle_clause?: CTECycleClause; + location?: number; + cterecursive?: boolean; + cterefcount?: number; + ctecolnames?: Node[]; + ctecoltypes?: Node[]; + ctecoltypmods?: Node[]; + ctecolcollations?: Node[]; +} +export interface MergeWhenClause { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + condition?: Node; + targetList?: Node[]; + values?: Node[]; +} +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} +export interface TriggerTransition { + name?: string; + isNew?: boolean; + isTable?: boolean; +} +export interface JsonOutput { + typeName?: TypeName; + returning?: JsonReturning; +} +export interface JsonKeyValue { + key?: Node; + value?: JsonValueExpr; +} +export interface JsonObjectConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonArrayConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + location?: number; +} +export interface JsonArrayQueryConstructor { + query?: Node; + output?: JsonOutput; + format?: JsonFormat; + absent_on_null?: boolean; + location?: number; +} +export interface JsonAggConstructor { + output?: JsonOutput; + agg_filter?: Node; + agg_order?: Node[]; + over?: WindowDef; + location?: number; +} +export interface JsonObjectAgg { + constructor?: JsonAggConstructor; + arg?: JsonKeyValue; + absent_on_null?: boolean; + unique?: boolean; +} +export interface JsonArrayAgg { + constructor?: JsonAggConstructor; + arg?: JsonValueExpr; + absent_on_null?: boolean; +} +export interface RawStmt { + stmt?: Node; + stmt_location?: number; + stmt_len?: number; +} +export interface InsertStmt { + relation?: RangeVar; + cols?: Node[]; + selectStmt?: Node; + onConflictClause?: OnConflictClause; + returningList?: Node[]; + withClause?: WithClause; + override?: OverridingKind; +} +export interface DeleteStmt { + relation?: RangeVar; + usingClause?: Node[]; + whereClause?: Node; + returningList?: Node[]; + withClause?: WithClause; +} +export interface UpdateStmt { + relation?: RangeVar; + targetList?: Node[]; + whereClause?: Node; + fromClause?: Node[]; + returningList?: Node[]; + withClause?: WithClause; +} +export interface MergeStmt { + relation?: RangeVar; + sourceRelation?: Node; + joinCondition?: Node; + mergeWhenClauses?: Node[]; + withClause?: WithClause; +} +export interface SelectStmt { + distinctClause?: Node[]; + intoClause?: IntoClause; + targetList?: Node[]; + fromClause?: Node[]; + whereClause?: Node; + groupClause?: Node[]; + groupDistinct?: boolean; + havingClause?: Node; + windowClause?: Node[]; + valuesLists?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + lockingClause?: Node[]; + withClause?: WithClause; + op?: SetOperation; + all?: boolean; + larg?: SelectStmt; + rarg?: SelectStmt; +} +export interface SetOperationStmt { + op?: SetOperation; + all?: boolean; + larg?: Node; + rarg?: Node; + colTypes?: Node[]; + colTypmods?: Node[]; + colCollations?: Node[]; + groupClauses?: Node[]; +} +export interface ReturnStmt { + returnval?: Node; +} +export interface PLAssignStmt { + name?: string; + indirection?: Node[]; + nnames?: number; + val?: SelectStmt; + location?: number; +} +export interface CreateSchemaStmt { + schemaname?: string; + authrole?: RoleSpec; + schemaElts?: Node[]; + if_not_exists?: boolean; +} +export interface AlterTableStmt { + relation?: RangeVar; + cmds?: Node[]; + objtype?: ObjectType; + missing_ok?: boolean; +} +export interface ReplicaIdentityStmt { + identity_type?: string; + name?: string; +} +export interface AlterTableCmd { + subtype?: AlterTableType; + name?: string; + num?: number; + newowner?: RoleSpec; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; + recurse?: boolean; +} +export interface AlterCollationStmt { + collname?: Node[]; +} +export interface AlterDomainStmt { + subtype?: string; + typeName?: Node[]; + name?: string; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface GrantStmt { + is_grant?: boolean; + targtype?: GrantTargetType; + objtype?: ObjectType; + objects?: Node[]; + privileges?: Node[]; + grantees?: Node[]; + grant_option?: boolean; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface ObjectWithArgs { + objname?: Node[]; + objargs?: Node[]; + objfuncargs?: Node[]; + args_unspecified?: boolean; +} +export interface AccessPriv { + priv_name?: string; + cols?: Node[]; +} +export interface GrantRoleStmt { + granted_roles?: Node[]; + grantee_roles?: Node[]; + is_grant?: boolean; + opt?: Node[]; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface AlterDefaultPrivilegesStmt { + options?: Node[]; + action?: GrantStmt; +} +export interface CopyStmt { + relation?: RangeVar; + query?: Node; + attlist?: Node[]; + is_from?: boolean; + is_program?: boolean; + filename?: string; + options?: Node[]; + whereClause?: Node; +} +export interface VariableSetStmt { + kind?: VariableSetKind; + name?: string; + args?: Node[]; + is_local?: boolean; +} +export interface VariableShowStmt { + name?: string; +} +export interface CreateStmt { + relation?: RangeVar; + tableElts?: Node[]; + inhRelations?: Node[]; + partbound?: PartitionBoundSpec; + partspec?: PartitionSpec; + ofTypename?: TypeName; + constraints?: Node[]; + options?: Node[]; + oncommit?: OnCommitAction; + tablespacename?: string; + accessMethod?: string; + if_not_exists?: boolean; +} +export interface Constraint { + contype?: ConstrType; + conname?: string; + deferrable?: boolean; + initdeferred?: boolean; + location?: number; + is_no_inherit?: boolean; + raw_expr?: Node; + cooked_expr?: string; + generated_when?: string; + nulls_not_distinct?: boolean; + keys?: Node[]; + including?: Node[]; + exclusions?: Node[]; + options?: Node[]; + indexname?: string; + indexspace?: string; + reset_default_tblspc?: boolean; + access_method?: string; + where_clause?: Node; + pktable?: RangeVar; + fk_attrs?: Node[]; + pk_attrs?: Node[]; + fk_matchtype?: string; + fk_upd_action?: string; + fk_del_action?: string; + fk_del_set_cols?: Node[]; + old_conpfeqop?: Node[]; + old_pktable_oid?: number; + skip_validation?: boolean; + initially_valid?: boolean; +} +export interface CreateTableSpaceStmt { + tablespacename?: string; + owner?: RoleSpec; + location?: string; + options?: Node[]; +} +export interface DropTableSpaceStmt { + tablespacename?: string; + missing_ok?: boolean; +} +export interface AlterTableSpaceOptionsStmt { + tablespacename?: string; + options?: Node[]; + isReset?: boolean; +} +export interface AlterTableMoveAllStmt { + orig_tablespacename?: string; + objtype?: ObjectType; + roles?: Node[]; + new_tablespacename?: string; + nowait?: boolean; +} +export interface CreateExtensionStmt { + extname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterExtensionStmt { + extname?: string; + options?: Node[]; +} +export interface AlterExtensionContentsStmt { + extname?: string; + action?: number; + objtype?: ObjectType; + object?: Node; +} +export interface CreateFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface AlterFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface CreateForeignServerStmt { + servername?: string; + servertype?: string; + version?: string; + fdwname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterForeignServerStmt { + servername?: string; + version?: string; + options?: Node[]; + has_version?: boolean; +} +export interface CreateForeignTableStmt { + base?: CreateStmt; + servername?: string; + options?: Node[]; +} +export interface CreateUserMappingStmt { + user?: RoleSpec; + servername?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterUserMappingStmt { + user?: RoleSpec; + servername?: string; + options?: Node[]; +} +export interface DropUserMappingStmt { + user?: RoleSpec; + servername?: string; + missing_ok?: boolean; +} +export interface ImportForeignSchemaStmt { + server_name?: string; + remote_schema?: string; + local_schema?: string; + list_type?: ImportForeignSchemaType; + table_list?: Node[]; + options?: Node[]; +} +export interface CreatePolicyStmt { + policy_name?: string; + table?: RangeVar; + cmd_name?: string; + permissive?: boolean; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface AlterPolicyStmt { + policy_name?: string; + table?: RangeVar; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface CreateAmStmt { + amname?: string; + handler_name?: Node[]; + amtype?: string; +} +export interface CreateTrigStmt { + replace?: boolean; + isconstraint?: boolean; + trigname?: string; + relation?: RangeVar; + funcname?: Node[]; + args?: Node[]; + row?: boolean; + timing?: number; + events?: number; + columns?: Node[]; + whenClause?: Node; + transitionRels?: Node[]; + deferrable?: boolean; + initdeferred?: boolean; + constrrel?: RangeVar; +} +export interface CreateEventTrigStmt { + trigname?: string; + eventname?: string; + whenclause?: Node[]; + funcname?: Node[]; +} +export interface AlterEventTrigStmt { + trigname?: string; + tgenabled?: string; +} +export interface CreatePLangStmt { + replace?: boolean; + plname?: string; + plhandler?: Node[]; + plinline?: Node[]; + plvalidator?: Node[]; + pltrusted?: boolean; +} +export interface CreateRoleStmt { + stmt_type?: RoleStmtType; + role?: string; + options?: Node[]; +} +export interface AlterRoleStmt { + role?: RoleSpec; + options?: Node[]; + action?: number; +} +export interface AlterRoleSetStmt { + role?: RoleSpec; + database?: string; + setstmt?: VariableSetStmt; +} +export interface DropRoleStmt { + roles?: Node[]; + missing_ok?: boolean; +} +export interface CreateSeqStmt { + sequence?: RangeVar; + options?: Node[]; + ownerId?: number; + for_identity?: boolean; + if_not_exists?: boolean; +} +export interface AlterSeqStmt { + sequence?: RangeVar; + options?: Node[]; + for_identity?: boolean; + missing_ok?: boolean; +} +export interface DefineStmt { + kind?: ObjectType; + oldstyle?: boolean; + defnames?: Node[]; + args?: Node[]; + definition?: Node[]; + if_not_exists?: boolean; + replace?: boolean; +} +export interface CreateDomainStmt { + domainname?: Node[]; + typeName?: TypeName; + collClause?: CollateClause; + constraints?: Node[]; +} +export interface CreateOpClassStmt { + opclassname?: Node[]; + opfamilyname?: Node[]; + amname?: string; + datatype?: TypeName; + items?: Node[]; + isDefault?: boolean; +} +export interface CreateOpClassItem { + itemtype?: number; + name?: ObjectWithArgs; + number?: number; + order_family?: Node[]; + class_args?: Node[]; + storedtype?: TypeName; +} +export interface CreateOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; +} +export interface AlterOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; + isDrop?: boolean; + items?: Node[]; +} +export interface DropStmt { + objects?: Node[]; + removeType?: ObjectType; + behavior?: DropBehavior; + missing_ok?: boolean; + concurrent?: boolean; +} +export interface TruncateStmt { + relations?: Node[]; + restart_seqs?: boolean; + behavior?: DropBehavior; +} +export interface CommentStmt { + objtype?: ObjectType; + object?: Node; + comment?: string; +} +export interface SecLabelStmt { + objtype?: ObjectType; + object?: Node; + provider?: string; + label?: string; +} +export interface DeclareCursorStmt { + portalname?: string; + options?: number; + query?: Node; +} +export interface ClosePortalStmt { + portalname?: string; +} +export interface FetchStmt { + direction?: FetchDirection; + howMany?: bigint; + portalname?: string; + ismove?: boolean; +} +export interface IndexStmt { + idxname?: string; + relation?: RangeVar; + accessMethod?: string; + tableSpace?: string; + indexParams?: Node[]; + indexIncludingParams?: Node[]; + options?: Node[]; + whereClause?: Node; + excludeOpNames?: Node[]; + idxcomment?: string; + indexOid?: number; + oldNumber?: number; + oldCreateSubid?: number; + oldFirstRelfilelocatorSubid?: number; + unique?: boolean; + nulls_not_distinct?: boolean; + primary?: boolean; + isconstraint?: boolean; + deferrable?: boolean; + initdeferred?: boolean; + transformed?: boolean; + concurrent?: boolean; + if_not_exists?: boolean; + reset_default_tblspc?: boolean; +} +export interface CreateStatsStmt { + defnames?: Node[]; + stat_types?: Node[]; + exprs?: Node[]; + relations?: Node[]; + stxcomment?: string; + transformed?: boolean; + if_not_exists?: boolean; +} +export interface StatsElem { + name?: string; + expr?: Node; +} +export interface AlterStatsStmt { + defnames?: Node[]; + stxstattarget?: number; + missing_ok?: boolean; +} +export interface CreateFunctionStmt { + is_procedure?: boolean; + replace?: boolean; + funcname?: Node[]; + parameters?: Node[]; + returnType?: TypeName; + options?: Node[]; + sql_body?: Node; +} +export interface FunctionParameter { + name?: string; + argType?: TypeName; + mode?: FunctionParameterMode; + defexpr?: Node; +} +export interface AlterFunctionStmt { + objtype?: ObjectType; + func?: ObjectWithArgs; + actions?: Node[]; +} +export interface DoStmt { + args?: Node[]; +} +export interface InlineCodeBlock { + source_text?: string; + langOid?: number; + langIsTrusted?: boolean; + atomic?: boolean; +} +export interface CallStmt { + funccall?: FuncCall; + funcexpr?: FuncExpr; + outargs?: Node[]; +} +export interface CallContext { + atomic?: boolean; +} +export interface RenameStmt { + renameType?: ObjectType; + relationType?: ObjectType; + relation?: RangeVar; + object?: Node; + subname?: string; + newname?: string; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface AlterObjectDependsStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + extname?: String; + remove?: boolean; +} +export interface AlterObjectSchemaStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newschema?: string; + missing_ok?: boolean; +} +export interface AlterOwnerStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newowner?: RoleSpec; +} +export interface AlterOperatorStmt { + opername?: ObjectWithArgs; + options?: Node[]; +} +export interface AlterTypeStmt { + typeName?: Node[]; + options?: Node[]; +} +export interface RuleStmt { + relation?: RangeVar; + rulename?: string; + whereClause?: Node; + event?: CmdType; + instead?: boolean; + actions?: Node[]; + replace?: boolean; +} +export interface NotifyStmt { + conditionname?: string; + payload?: string; +} +export interface ListenStmt { + conditionname?: string; +} +export interface UnlistenStmt { + conditionname?: string; +} +export interface TransactionStmt { + kind?: TransactionStmtKind; + options?: Node[]; + savepoint_name?: string; + gid?: string; + chain?: boolean; +} +export interface CompositeTypeStmt { + typevar?: RangeVar; + coldeflist?: Node[]; +} +export interface CreateEnumStmt { + typeName?: Node[]; + vals?: Node[]; +} +export interface CreateRangeStmt { + typeName?: Node[]; + params?: Node[]; +} +export interface AlterEnumStmt { + typeName?: Node[]; + oldVal?: string; + newVal?: string; + newValNeighbor?: string; + newValIsAfter?: boolean; + skipIfNewValExists?: boolean; +} +export interface ViewStmt { + view?: RangeVar; + aliases?: Node[]; + query?: Node; + replace?: boolean; + options?: Node[]; + withCheckOption?: ViewCheckOption; +} +export interface LoadStmt { + filename?: string; +} +export interface CreatedbStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseRefreshCollStmt { + dbname?: string; +} +export interface AlterDatabaseSetStmt { + dbname?: string; + setstmt?: VariableSetStmt; +} +export interface DropdbStmt { + dbname?: string; + missing_ok?: boolean; + options?: Node[]; +} +export interface AlterSystemStmt { + setstmt?: VariableSetStmt; +} +export interface ClusterStmt { + relation?: RangeVar; + indexname?: string; + params?: Node[]; +} +export interface VacuumStmt { + options?: Node[]; + rels?: Node[]; + is_vacuumcmd?: boolean; +} +export interface VacuumRelation { + relation?: RangeVar; + oid?: number; + va_cols?: Node[]; +} +export interface ExplainStmt { + query?: Node; + options?: Node[]; +} +export interface CreateTableAsStmt { + query?: Node; + into?: IntoClause; + objtype?: ObjectType; + is_select_into?: boolean; + if_not_exists?: boolean; +} +export interface RefreshMatViewStmt { + concurrent?: boolean; + skipData?: boolean; + relation?: RangeVar; +} +export interface CheckPointStmt {} +export interface DiscardStmt { + target?: DiscardMode; +} +export interface LockStmt { + relations?: Node[]; + mode?: number; + nowait?: boolean; +} +export interface ConstraintsSetStmt { + constraints?: Node[]; + deferred?: boolean; +} +export interface ReindexStmt { + kind?: ReindexObjectType; + relation?: RangeVar; + name?: string; + params?: Node[]; +} +export interface CreateConversionStmt { + conversion_name?: Node[]; + for_encoding_name?: string; + to_encoding_name?: string; + func_name?: Node[]; + def?: boolean; +} +export interface CreateCastStmt { + sourcetype?: TypeName; + targettype?: TypeName; + func?: ObjectWithArgs; + context?: CoercionContext; + inout?: boolean; +} +export interface CreateTransformStmt { + replace?: boolean; + type_name?: TypeName; + lang?: string; + fromsql?: ObjectWithArgs; + tosql?: ObjectWithArgs; +} +export interface PrepareStmt { + name?: string; + argtypes?: Node[]; + query?: Node; +} +export interface ExecuteStmt { + name?: string; + params?: Node[]; +} +export interface DeallocateStmt { + name?: string; +} +export interface DropOwnedStmt { + roles?: Node[]; + behavior?: DropBehavior; +} +export interface ReassignOwnedStmt { + roles?: Node[]; + newrole?: RoleSpec; +} +export interface AlterTSDictionaryStmt { + dictname?: Node[]; + options?: Node[]; +} +export interface AlterTSConfigurationStmt { + kind?: AlterTSConfigType; + cfgname?: Node[]; + tokentype?: Node[]; + dicts?: Node[]; + override?: boolean; + replace?: boolean; + missing_ok?: boolean; +} +export interface PublicationTable { + relation?: RangeVar; + whereClause?: Node; + columns?: Node[]; +} +export interface PublicationObjSpec { + pubobjtype?: PublicationObjSpecType; + name?: string; + pubtable?: PublicationTable; + location?: number; +} +export interface CreatePublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; +} +export interface AlterPublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; + action?: AlterPublicationAction; +} +export interface CreateSubscriptionStmt { + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface AlterSubscriptionStmt { + kind?: AlterSubscriptionType; + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface DropSubscriptionStmt { + subname?: string; + missing_ok?: boolean; + behavior?: DropBehavior; +} +export interface ScanToken { + start?: number; + end?: number; + token?: Token; + keywordKind?: KeywordKind; +} \ No newline at end of file diff --git a/__fixtures__/output/utils/wrappedAstHelpers/enabled/types.ts b/__fixtures__/output/utils/wrappedAstHelpers/enabled/types.ts new file mode 100644 index 00000000..cf5f2c36 --- /dev/null +++ b/__fixtures__/output/utils/wrappedAstHelpers/enabled/types.ts @@ -0,0 +1,2326 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +export type Node = { + ParseResult: ParseResult; +} | { + ScanResult: ScanResult; +} | { + Integer: Integer; +} | { + Float: Float; +} | { + Boolean: Boolean; +} | { + String: String; +} | { + BitString: BitString; +} | { + List: List; +} | { + OidList: OidList; +} | { + IntList: IntList; +} | { + A_Const: A_Const; +} | { + Alias: Alias; +} | { + RangeVar: RangeVar; +} | { + TableFunc: TableFunc; +} | { + IntoClause: IntoClause; +} | { + Var: Var; +} | { + Param: Param; +} | { + Aggref: Aggref; +} | { + GroupingFunc: GroupingFunc; +} | { + WindowFunc: WindowFunc; +} | { + SubscriptingRef: SubscriptingRef; +} | { + FuncExpr: FuncExpr; +} | { + NamedArgExpr: NamedArgExpr; +} | { + OpExpr: OpExpr; +} | { + DistinctExpr: DistinctExpr; +} | { + NullIfExpr: NullIfExpr; +} | { + ScalarArrayOpExpr: ScalarArrayOpExpr; +} | { + BoolExpr: BoolExpr; +} | { + SubLink: SubLink; +} | { + SubPlan: SubPlan; +} | { + AlternativeSubPlan: AlternativeSubPlan; +} | { + FieldSelect: FieldSelect; +} | { + FieldStore: FieldStore; +} | { + RelabelType: RelabelType; +} | { + CoerceViaIO: CoerceViaIO; +} | { + ArrayCoerceExpr: ArrayCoerceExpr; +} | { + ConvertRowtypeExpr: ConvertRowtypeExpr; +} | { + CollateExpr: CollateExpr; +} | { + CaseExpr: CaseExpr; +} | { + CaseWhen: CaseWhen; +} | { + CaseTestExpr: CaseTestExpr; +} | { + ArrayExpr: ArrayExpr; +} | { + RowExpr: RowExpr; +} | { + RowCompareExpr: RowCompareExpr; +} | { + CoalesceExpr: CoalesceExpr; +} | { + MinMaxExpr: MinMaxExpr; +} | { + SQLValueFunction: SQLValueFunction; +} | { + XmlExpr: XmlExpr; +} | { + JsonFormat: JsonFormat; +} | { + JsonReturning: JsonReturning; +} | { + JsonValueExpr: JsonValueExpr; +} | { + JsonConstructorExpr: JsonConstructorExpr; +} | { + JsonIsPredicate: JsonIsPredicate; +} | { + NullTest: NullTest; +} | { + BooleanTest: BooleanTest; +} | { + CoerceToDomain: CoerceToDomain; +} | { + CoerceToDomainValue: CoerceToDomainValue; +} | { + SetToDefault: SetToDefault; +} | { + CurrentOfExpr: CurrentOfExpr; +} | { + NextValueExpr: NextValueExpr; +} | { + InferenceElem: InferenceElem; +} | { + TargetEntry: TargetEntry; +} | { + RangeTblRef: RangeTblRef; +} | { + JoinExpr: JoinExpr; +} | { + FromExpr: FromExpr; +} | { + OnConflictExpr: OnConflictExpr; +} | { + Query: Query; +} | { + TypeName: TypeName; +} | { + ColumnRef: ColumnRef; +} | { + ParamRef: ParamRef; +} | { + A_Expr: A_Expr; +} | { + TypeCast: TypeCast; +} | { + CollateClause: CollateClause; +} | { + RoleSpec: RoleSpec; +} | { + FuncCall: FuncCall; +} | { + A_Star: A_Star; +} | { + A_Indices: A_Indices; +} | { + A_Indirection: A_Indirection; +} | { + A_ArrayExpr: A_ArrayExpr; +} | { + ResTarget: ResTarget; +} | { + MultiAssignRef: MultiAssignRef; +} | { + SortBy: SortBy; +} | { + WindowDef: WindowDef; +} | { + RangeSubselect: RangeSubselect; +} | { + RangeFunction: RangeFunction; +} | { + RangeTableFunc: RangeTableFunc; +} | { + RangeTableFuncCol: RangeTableFuncCol; +} | { + RangeTableSample: RangeTableSample; +} | { + ColumnDef: ColumnDef; +} | { + TableLikeClause: TableLikeClause; +} | { + IndexElem: IndexElem; +} | { + DefElem: DefElem; +} | { + LockingClause: LockingClause; +} | { + XmlSerialize: XmlSerialize; +} | { + PartitionElem: PartitionElem; +} | { + PartitionSpec: PartitionSpec; +} | { + PartitionBoundSpec: PartitionBoundSpec; +} | { + PartitionRangeDatum: PartitionRangeDatum; +} | { + PartitionCmd: PartitionCmd; +} | { + RangeTblEntry: RangeTblEntry; +} | { + RTEPermissionInfo: RTEPermissionInfo; +} | { + RangeTblFunction: RangeTblFunction; +} | { + TableSampleClause: TableSampleClause; +} | { + WithCheckOption: WithCheckOption; +} | { + SortGroupClause: SortGroupClause; +} | { + GroupingSet: GroupingSet; +} | { + WindowClause: WindowClause; +} | { + RowMarkClause: RowMarkClause; +} | { + WithClause: WithClause; +} | { + InferClause: InferClause; +} | { + OnConflictClause: OnConflictClause; +} | { + CTESearchClause: CTESearchClause; +} | { + CTECycleClause: CTECycleClause; +} | { + CommonTableExpr: CommonTableExpr; +} | { + MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; +} | { + TriggerTransition: TriggerTransition; +} | { + JsonOutput: JsonOutput; +} | { + JsonKeyValue: JsonKeyValue; +} | { + JsonObjectConstructor: JsonObjectConstructor; +} | { + JsonArrayConstructor: JsonArrayConstructor; +} | { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; +} | { + JsonAggConstructor: JsonAggConstructor; +} | { + JsonObjectAgg: JsonObjectAgg; +} | { + JsonArrayAgg: JsonArrayAgg; +} | { + RawStmt: RawStmt; +} | { + InsertStmt: InsertStmt; +} | { + DeleteStmt: DeleteStmt; +} | { + UpdateStmt: UpdateStmt; +} | { + MergeStmt: MergeStmt; +} | { + SelectStmt: SelectStmt; +} | { + SetOperationStmt: SetOperationStmt; +} | { + ReturnStmt: ReturnStmt; +} | { + PLAssignStmt: PLAssignStmt; +} | { + CreateSchemaStmt: CreateSchemaStmt; +} | { + AlterTableStmt: AlterTableStmt; +} | { + ReplicaIdentityStmt: ReplicaIdentityStmt; +} | { + AlterTableCmd: AlterTableCmd; +} | { + AlterCollationStmt: AlterCollationStmt; +} | { + AlterDomainStmt: AlterDomainStmt; +} | { + GrantStmt: GrantStmt; +} | { + ObjectWithArgs: ObjectWithArgs; +} | { + AccessPriv: AccessPriv; +} | { + GrantRoleStmt: GrantRoleStmt; +} | { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; +} | { + CopyStmt: CopyStmt; +} | { + VariableSetStmt: VariableSetStmt; +} | { + VariableShowStmt: VariableShowStmt; +} | { + CreateStmt: CreateStmt; +} | { + Constraint: Constraint; +} | { + CreateTableSpaceStmt: CreateTableSpaceStmt; +} | { + DropTableSpaceStmt: DropTableSpaceStmt; +} | { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; +} | { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; +} | { + CreateExtensionStmt: CreateExtensionStmt; +} | { + AlterExtensionStmt: AlterExtensionStmt; +} | { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; +} | { + CreateFdwStmt: CreateFdwStmt; +} | { + AlterFdwStmt: AlterFdwStmt; +} | { + CreateForeignServerStmt: CreateForeignServerStmt; +} | { + AlterForeignServerStmt: AlterForeignServerStmt; +} | { + CreateForeignTableStmt: CreateForeignTableStmt; +} | { + CreateUserMappingStmt: CreateUserMappingStmt; +} | { + AlterUserMappingStmt: AlterUserMappingStmt; +} | { + DropUserMappingStmt: DropUserMappingStmt; +} | { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; +} | { + CreatePolicyStmt: CreatePolicyStmt; +} | { + AlterPolicyStmt: AlterPolicyStmt; +} | { + CreateAmStmt: CreateAmStmt; +} | { + CreateTrigStmt: CreateTrigStmt; +} | { + CreateEventTrigStmt: CreateEventTrigStmt; +} | { + AlterEventTrigStmt: AlterEventTrigStmt; +} | { + CreatePLangStmt: CreatePLangStmt; +} | { + CreateRoleStmt: CreateRoleStmt; +} | { + AlterRoleStmt: AlterRoleStmt; +} | { + AlterRoleSetStmt: AlterRoleSetStmt; +} | { + DropRoleStmt: DropRoleStmt; +} | { + CreateSeqStmt: CreateSeqStmt; +} | { + AlterSeqStmt: AlterSeqStmt; +} | { + DefineStmt: DefineStmt; +} | { + CreateDomainStmt: CreateDomainStmt; +} | { + CreateOpClassStmt: CreateOpClassStmt; +} | { + CreateOpClassItem: CreateOpClassItem; +} | { + CreateOpFamilyStmt: CreateOpFamilyStmt; +} | { + AlterOpFamilyStmt: AlterOpFamilyStmt; +} | { + DropStmt: DropStmt; +} | { + TruncateStmt: TruncateStmt; +} | { + CommentStmt: CommentStmt; +} | { + SecLabelStmt: SecLabelStmt; +} | { + DeclareCursorStmt: DeclareCursorStmt; +} | { + ClosePortalStmt: ClosePortalStmt; +} | { + FetchStmt: FetchStmt; +} | { + IndexStmt: IndexStmt; +} | { + CreateStatsStmt: CreateStatsStmt; +} | { + StatsElem: StatsElem; +} | { + AlterStatsStmt: AlterStatsStmt; +} | { + CreateFunctionStmt: CreateFunctionStmt; +} | { + FunctionParameter: FunctionParameter; +} | { + AlterFunctionStmt: AlterFunctionStmt; +} | { + DoStmt: DoStmt; +} | { + InlineCodeBlock: InlineCodeBlock; +} | { + CallStmt: CallStmt; +} | { + CallContext: CallContext; +} | { + RenameStmt: RenameStmt; +} | { + AlterObjectDependsStmt: AlterObjectDependsStmt; +} | { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; +} | { + AlterOwnerStmt: AlterOwnerStmt; +} | { + AlterOperatorStmt: AlterOperatorStmt; +} | { + AlterTypeStmt: AlterTypeStmt; +} | { + RuleStmt: RuleStmt; +} | { + NotifyStmt: NotifyStmt; +} | { + ListenStmt: ListenStmt; +} | { + UnlistenStmt: UnlistenStmt; +} | { + TransactionStmt: TransactionStmt; +} | { + CompositeTypeStmt: CompositeTypeStmt; +} | { + CreateEnumStmt: CreateEnumStmt; +} | { + CreateRangeStmt: CreateRangeStmt; +} | { + AlterEnumStmt: AlterEnumStmt; +} | { + ViewStmt: ViewStmt; +} | { + LoadStmt: LoadStmt; +} | { + CreatedbStmt: CreatedbStmt; +} | { + AlterDatabaseStmt: AlterDatabaseStmt; +} | { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; +} | { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; +} | { + DropdbStmt: DropdbStmt; +} | { + AlterSystemStmt: AlterSystemStmt; +} | { + ClusterStmt: ClusterStmt; +} | { + VacuumStmt: VacuumStmt; +} | { + VacuumRelation: VacuumRelation; +} | { + ExplainStmt: ExplainStmt; +} | { + CreateTableAsStmt: CreateTableAsStmt; +} | { + RefreshMatViewStmt: RefreshMatViewStmt; +} | { + CheckPointStmt: CheckPointStmt; +} | { + DiscardStmt: DiscardStmt; +} | { + LockStmt: LockStmt; +} | { + ConstraintsSetStmt: ConstraintsSetStmt; +} | { + ReindexStmt: ReindexStmt; +} | { + CreateConversionStmt: CreateConversionStmt; +} | { + CreateCastStmt: CreateCastStmt; +} | { + CreateTransformStmt: CreateTransformStmt; +} | { + PrepareStmt: PrepareStmt; +} | { + ExecuteStmt: ExecuteStmt; +} | { + DeallocateStmt: DeallocateStmt; +} | { + DropOwnedStmt: DropOwnedStmt; +} | { + ReassignOwnedStmt: ReassignOwnedStmt; +} | { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; +} | { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; +} | { + PublicationTable: PublicationTable; +} | { + PublicationObjSpec: PublicationObjSpec; +} | { + CreatePublicationStmt: CreatePublicationStmt; +} | { + AlterPublicationStmt: AlterPublicationStmt; +} | { + CreateSubscriptionStmt: CreateSubscriptionStmt; +} | { + AlterSubscriptionStmt: AlterSubscriptionStmt; +} | { + DropSubscriptionStmt: DropSubscriptionStmt; +} | { + ScanToken: ScanToken; +}; +export interface ParseResult { + version?: number; + stmts?: RawStmt[]; +} +export interface ScanResult { + version?: number; + tokens?: ScanToken[]; +} +export interface Integer { + ival?: number; +} +export interface Float { + fval?: string; +} +export interface Boolean { + boolval?: boolean; +} +export interface String { + sval?: string; +} +export interface BitString { + bsval?: string; +} +export interface List { + items?: Node[]; +} +export interface OidList { + items?: Node[]; +} +export interface IntList { + items?: Node[]; +} +export interface A_Const { + ival?: Integer; + fval?: Float; + boolval?: Boolean; + sval?: String; + bsval?: BitString; + isnull?: boolean; + location?: number; +} +export interface Alias { + aliasname?: string; + colnames?: Node[]; +} +export interface RangeVar { + catalogname?: string; + schemaname?: string; + relname?: string; + inh?: boolean; + relpersistence?: string; + alias?: Alias; + location?: number; +} +export interface TableFunc { + ns_uris?: Node[]; + ns_names?: Node[]; + docexpr?: Node; + rowexpr?: Node; + colnames?: Node[]; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + colexprs?: Node[]; + coldefexprs?: Node[]; + notnulls?: bigint[]; + ordinalitycol?: number; + location?: number; +} +export interface IntoClause { + rel?: RangeVar; + colNames?: Node[]; + accessMethod?: string; + options?: Node[]; + onCommit?: OnCommitAction; + tableSpaceName?: string; + viewQuery?: Node; + skipData?: boolean; +} +export interface Var { + xpr?: Node; + varno?: number; + varattno?: number; + vartype?: number; + vartypmod?: number; + varcollid?: number; + varnullingrels?: bigint[]; + varlevelsup?: number; + location?: number; +} +export interface Param { + xpr?: Node; + paramkind?: ParamKind; + paramid?: number; + paramtype?: number; + paramtypmod?: number; + paramcollid?: number; + location?: number; +} +export interface Aggref { + xpr?: Node; + aggfnoid?: number; + aggtype?: number; + aggcollid?: number; + inputcollid?: number; + aggargtypes?: Node[]; + aggdirectargs?: Node[]; + args?: Node[]; + aggorder?: Node[]; + aggdistinct?: Node[]; + aggfilter?: Node; + aggstar?: boolean; + aggvariadic?: boolean; + aggkind?: string; + agglevelsup?: number; + aggsplit?: AggSplit; + aggno?: number; + aggtransno?: number; + location?: number; +} +export interface GroupingFunc { + xpr?: Node; + args?: Node[]; + refs?: Node[]; + agglevelsup?: number; + location?: number; +} +export interface WindowFunc { + xpr?: Node; + winfnoid?: number; + wintype?: number; + wincollid?: number; + inputcollid?: number; + args?: Node[]; + aggfilter?: Node; + winref?: number; + winstar?: boolean; + winagg?: boolean; + location?: number; +} +export interface SubscriptingRef { + xpr?: Node; + refcontainertype?: number; + refelemtype?: number; + refrestype?: number; + reftypmod?: number; + refcollid?: number; + refupperindexpr?: Node[]; + reflowerindexpr?: Node[]; + refexpr?: Node; + refassgnexpr?: Node; +} +export interface FuncExpr { + xpr?: Node; + funcid?: number; + funcresulttype?: number; + funcretset?: boolean; + funcvariadic?: boolean; + funcformat?: CoercionForm; + funccollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NamedArgExpr { + xpr?: Node; + arg?: Node; + name?: string; + argnumber?: number; + location?: number; +} +export interface OpExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface DistinctExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NullIfExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface ScalarArrayOpExpr { + xpr?: Node; + opno?: number; + useOr?: boolean; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface BoolExpr { + xpr?: Node; + boolop?: BoolExprType; + args?: Node[]; + location?: number; +} +export interface SubLink { + xpr?: Node; + subLinkType?: SubLinkType; + subLinkId?: number; + testexpr?: Node; + operName?: Node[]; + subselect?: Node; + location?: number; +} +export interface SubPlan { + xpr?: Node; + subLinkType?: SubLinkType; + testexpr?: Node; + paramIds?: Node[]; + plan_id?: number; + plan_name?: string; + firstColType?: number; + firstColTypmod?: number; + firstColCollation?: number; + useHashTable?: boolean; + unknownEqFalse?: boolean; + parallel_safe?: boolean; + setParam?: Node[]; + parParam?: Node[]; + args?: Node[]; + startup_cost?: number; + per_call_cost?: number; +} +export interface AlternativeSubPlan { + xpr?: Node; + subplans?: Node[]; +} +export interface FieldSelect { + xpr?: Node; + arg?: Node; + fieldnum?: number; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; +} +export interface FieldStore { + xpr?: Node; + arg?: Node; + newvals?: Node[]; + fieldnums?: Node[]; + resulttype?: number; +} +export interface RelabelType { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + relabelformat?: CoercionForm; + location?: number; +} +export interface CoerceViaIO { + xpr?: Node; + arg?: Node; + resulttype?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ArrayCoerceExpr { + xpr?: Node; + arg?: Node; + elemexpr?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ConvertRowtypeExpr { + xpr?: Node; + arg?: Node; + resulttype?: number; + convertformat?: CoercionForm; + location?: number; +} +export interface CollateExpr { + xpr?: Node; + arg?: Node; + collOid?: number; + location?: number; +} +export interface CaseExpr { + xpr?: Node; + casetype?: number; + casecollid?: number; + arg?: Node; + args?: Node[]; + defresult?: Node; + location?: number; +} +export interface CaseWhen { + xpr?: Node; + expr?: Node; + result?: Node; + location?: number; +} +export interface CaseTestExpr { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; +} +export interface ArrayExpr { + xpr?: Node; + array_typeid?: number; + array_collid?: number; + element_typeid?: number; + elements?: Node[]; + multidims?: boolean; + location?: number; +} +export interface RowExpr { + xpr?: Node; + args?: Node[]; + row_typeid?: number; + row_format?: CoercionForm; + colnames?: Node[]; + location?: number; +} +export interface RowCompareExpr { + xpr?: Node; + rctype?: RowCompareType; + opnos?: Node[]; + opfamilies?: Node[]; + inputcollids?: Node[]; + largs?: Node[]; + rargs?: Node[]; +} +export interface CoalesceExpr { + xpr?: Node; + coalescetype?: number; + coalescecollid?: number; + args?: Node[]; + location?: number; +} +export interface MinMaxExpr { + xpr?: Node; + minmaxtype?: number; + minmaxcollid?: number; + inputcollid?: number; + op?: MinMaxOp; + args?: Node[]; + location?: number; +} +export interface SQLValueFunction { + xpr?: Node; + op?: SQLValueFunctionOp; + type?: number; + typmod?: number; + location?: number; +} +export interface XmlExpr { + xpr?: Node; + op?: XmlExprOp; + name?: string; + named_args?: Node[]; + arg_names?: Node[]; + args?: Node[]; + xmloption?: XmlOptionType; + indent?: boolean; + type?: number; + typmod?: number; + location?: number; +} +export interface JsonFormat { + format_type?: JsonFormatType; + encoding?: JsonEncoding; + location?: number; +} +export interface JsonReturning { + format?: JsonFormat; + typid?: number; + typmod?: number; +} +export interface JsonValueExpr { + raw_expr?: Node; + formatted_expr?: Node; + format?: JsonFormat; +} +export interface JsonConstructorExpr { + xpr?: Node; + type?: JsonConstructorType; + args?: Node[]; + func?: Node; + coercion?: Node; + returning?: JsonReturning; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonIsPredicate { + expr?: Node; + format?: JsonFormat; + item_type?: JsonValueType; + unique_keys?: boolean; + location?: number; +} +export interface NullTest { + xpr?: Node; + arg?: Node; + nulltesttype?: NullTestType; + argisrow?: boolean; + location?: number; +} +export interface BooleanTest { + xpr?: Node; + arg?: Node; + booltesttype?: BoolTestType; + location?: number; +} +export interface CoerceToDomain { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coercionformat?: CoercionForm; + location?: number; +} +export interface CoerceToDomainValue { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface SetToDefault { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface CurrentOfExpr { + xpr?: Node; + cvarno?: number; + cursor_name?: string; + cursor_param?: number; +} +export interface NextValueExpr { + xpr?: Node; + seqid?: number; + typeId?: number; +} +export interface InferenceElem { + xpr?: Node; + expr?: Node; + infercollid?: number; + inferopclass?: number; +} +export interface TargetEntry { + xpr?: Node; + expr?: Node; + resno?: number; + resname?: string; + ressortgroupref?: number; + resorigtbl?: number; + resorigcol?: number; + resjunk?: boolean; +} +export interface RangeTblRef { + rtindex?: number; +} +export interface JoinExpr { + jointype?: JoinType; + isNatural?: boolean; + larg?: Node; + rarg?: Node; + usingClause?: Node[]; + join_using_alias?: Alias; + quals?: Node; + alias?: Alias; + rtindex?: number; +} +export interface FromExpr { + fromlist?: Node[]; + quals?: Node; +} +export interface OnConflictExpr { + action?: OnConflictAction; + arbiterElems?: Node[]; + arbiterWhere?: Node; + constraint?: number; + onConflictSet?: Node[]; + onConflictWhere?: Node; + exclRelIndex?: number; + exclRelTlist?: Node[]; +} +export interface Query { + commandType?: CmdType; + querySource?: QuerySource; + canSetTag?: boolean; + utilityStmt?: Node; + resultRelation?: number; + hasAggs?: boolean; + hasWindowFuncs?: boolean; + hasTargetSRFs?: boolean; + hasSubLinks?: boolean; + hasDistinctOn?: boolean; + hasRecursive?: boolean; + hasModifyingCTE?: boolean; + hasForUpdate?: boolean; + hasRowSecurity?: boolean; + isReturn?: boolean; + cteList?: Node[]; + rtable?: Node[]; + rteperminfos?: Node[]; + jointree?: FromExpr; + mergeActionList?: Node[]; + mergeUseOuterJoin?: boolean; + targetList?: Node[]; + override?: OverridingKind; + onConflict?: OnConflictExpr; + returningList?: Node[]; + groupClause?: Node[]; + groupDistinct?: boolean; + groupingSets?: Node[]; + havingQual?: Node; + windowClause?: Node[]; + distinctClause?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + rowMarks?: Node[]; + setOperations?: Node; + constraintDeps?: Node[]; + withCheckOptions?: Node[]; + stmt_location?: number; + stmt_len?: number; +} +export interface TypeName { + names?: Node[]; + typeOid?: number; + setof?: boolean; + pct_type?: boolean; + typmods?: Node[]; + typemod?: number; + arrayBounds?: Node[]; + location?: number; +} +export interface ColumnRef { + fields?: Node[]; + location?: number; +} +export interface ParamRef { + number?: number; + location?: number; +} +export interface A_Expr { + kind?: A_Expr_Kind; + name?: Node[]; + lexpr?: Node; + rexpr?: Node; + location?: number; +} +export interface TypeCast { + arg?: Node; + typeName?: TypeName; + location?: number; +} +export interface CollateClause { + arg?: Node; + collname?: Node[]; + location?: number; +} +export interface RoleSpec { + roletype?: RoleSpecType; + rolename?: string; + location?: number; +} +export interface FuncCall { + funcname?: Node[]; + args?: Node[]; + agg_order?: Node[]; + agg_filter?: Node; + over?: WindowDef; + agg_within_group?: boolean; + agg_star?: boolean; + agg_distinct?: boolean; + func_variadic?: boolean; + funcformat?: CoercionForm; + location?: number; +} +export interface A_Star {} +export interface A_Indices { + is_slice?: boolean; + lidx?: Node; + uidx?: Node; +} +export interface A_Indirection { + arg?: Node; + indirection?: Node[]; +} +export interface A_ArrayExpr { + elements?: Node[]; + location?: number; +} +export interface ResTarget { + name?: string; + indirection?: Node[]; + val?: Node; + location?: number; +} +export interface MultiAssignRef { + source?: Node; + colno?: number; + ncolumns?: number; +} +export interface SortBy { + node?: Node; + sortby_dir?: SortByDir; + sortby_nulls?: SortByNulls; + useOp?: Node[]; + location?: number; +} +export interface WindowDef { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + location?: number; +} +export interface RangeSubselect { + lateral?: boolean; + subquery?: Node; + alias?: Alias; +} +export interface RangeFunction { + lateral?: boolean; + ordinality?: boolean; + is_rowsfrom?: boolean; + functions?: Node[]; + alias?: Alias; + coldeflist?: Node[]; +} +export interface RangeTableFunc { + lateral?: boolean; + docexpr?: Node; + rowexpr?: Node; + namespaces?: Node[]; + columns?: Node[]; + alias?: Alias; + location?: number; +} +export interface RangeTableFuncCol { + colname?: string; + typeName?: TypeName; + for_ordinality?: boolean; + is_not_null?: boolean; + colexpr?: Node; + coldefexpr?: Node; + location?: number; +} +export interface RangeTableSample { + relation?: Node; + method?: Node[]; + args?: Node[]; + repeatable?: Node; + location?: number; +} +export interface ColumnDef { + colname?: string; + typeName?: TypeName; + compression?: string; + inhcount?: number; + is_local?: boolean; + is_not_null?: boolean; + is_from_type?: boolean; + storage?: string; + storage_name?: string; + raw_default?: Node; + cooked_default?: Node; + identity?: string; + identitySequence?: RangeVar; + generated?: string; + collClause?: CollateClause; + collOid?: number; + constraints?: Node[]; + fdwoptions?: Node[]; + location?: number; +} +export interface TableLikeClause { + relation?: RangeVar; + options?: number; + relationOid?: number; +} +export interface IndexElem { + name?: string; + expr?: Node; + indexcolname?: string; + collation?: Node[]; + opclass?: Node[]; + opclassopts?: Node[]; + ordering?: SortByDir; + nulls_ordering?: SortByNulls; +} +export interface DefElem { + defnamespace?: string; + defname?: string; + arg?: Node; + defaction?: DefElemAction; + location?: number; +} +export interface LockingClause { + lockedRels?: Node[]; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; +} +export interface XmlSerialize { + xmloption?: XmlOptionType; + expr?: Node; + typeName?: TypeName; + indent?: boolean; + location?: number; +} +export interface PartitionElem { + name?: string; + expr?: Node; + collation?: Node[]; + opclass?: Node[]; + location?: number; +} +export interface PartitionSpec { + strategy?: PartitionStrategy; + partParams?: Node[]; + location?: number; +} +export interface PartitionBoundSpec { + strategy?: string; + is_default?: boolean; + modulus?: number; + remainder?: number; + listdatums?: Node[]; + lowerdatums?: Node[]; + upperdatums?: Node[]; + location?: number; +} +export interface PartitionRangeDatum { + kind?: PartitionRangeDatumKind; + value?: Node; + location?: number; +} +export interface PartitionCmd { + name?: RangeVar; + bound?: PartitionBoundSpec; + concurrent?: boolean; +} +export interface RangeTblEntry { + rtekind?: RTEKind; + relid?: number; + relkind?: string; + rellockmode?: number; + tablesample?: TableSampleClause; + perminfoindex?: number; + subquery?: Query; + security_barrier?: boolean; + jointype?: JoinType; + joinmergedcols?: number; + joinaliasvars?: Node[]; + joinleftcols?: Node[]; + joinrightcols?: Node[]; + join_using_alias?: Alias; + functions?: Node[]; + funcordinality?: boolean; + tablefunc?: TableFunc; + values_lists?: Node[]; + ctename?: string; + ctelevelsup?: number; + self_reference?: boolean; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + enrname?: string; + enrtuples?: number; + alias?: Alias; + eref?: Alias; + lateral?: boolean; + inh?: boolean; + inFromCl?: boolean; + securityQuals?: Node[]; +} +export interface RTEPermissionInfo { + relid?: number; + inh?: boolean; + requiredPerms?: bigint; + checkAsUser?: number; + selectedCols?: bigint[]; + insertedCols?: bigint[]; + updatedCols?: bigint[]; +} +export interface RangeTblFunction { + funcexpr?: Node; + funccolcount?: number; + funccolnames?: Node[]; + funccoltypes?: Node[]; + funccoltypmods?: Node[]; + funccolcollations?: Node[]; + funcparams?: bigint[]; +} +export interface TableSampleClause { + tsmhandler?: number; + args?: Node[]; + repeatable?: Node; +} +export interface WithCheckOption { + kind?: WCOKind; + relname?: string; + polname?: string; + qual?: Node; + cascaded?: boolean; +} +export interface SortGroupClause { + tleSortGroupRef?: number; + eqop?: number; + sortop?: number; + nulls_first?: boolean; + hashable?: boolean; +} +export interface GroupingSet { + kind?: GroupingSetKind; + content?: Node[]; + location?: number; +} +export interface WindowClause { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + runCondition?: Node[]; + startInRangeFunc?: number; + endInRangeFunc?: number; + inRangeColl?: number; + inRangeAsc?: boolean; + inRangeNullsFirst?: boolean; + winref?: number; + copiedOrder?: boolean; +} +export interface RowMarkClause { + rti?: number; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; + pushedDown?: boolean; +} +export interface WithClause { + ctes?: Node[]; + recursive?: boolean; + location?: number; +} +export interface InferClause { + indexElems?: Node[]; + whereClause?: Node; + conname?: string; + location?: number; +} +export interface OnConflictClause { + action?: OnConflictAction; + infer?: InferClause; + targetList?: Node[]; + whereClause?: Node; + location?: number; +} +export interface CTESearchClause { + search_col_list?: Node[]; + search_breadth_first?: boolean; + search_seq_column?: string; + location?: number; +} +export interface CTECycleClause { + cycle_col_list?: Node[]; + cycle_mark_column?: string; + cycle_mark_value?: Node; + cycle_mark_default?: Node; + cycle_path_column?: string; + location?: number; + cycle_mark_type?: number; + cycle_mark_typmod?: number; + cycle_mark_collation?: number; + cycle_mark_neop?: number; +} +export interface CommonTableExpr { + ctename?: string; + aliascolnames?: Node[]; + ctematerialized?: CTEMaterialize; + ctequery?: Node; + search_clause?: CTESearchClause; + cycle_clause?: CTECycleClause; + location?: number; + cterecursive?: boolean; + cterefcount?: number; + ctecolnames?: Node[]; + ctecoltypes?: Node[]; + ctecoltypmods?: Node[]; + ctecolcollations?: Node[]; +} +export interface MergeWhenClause { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + condition?: Node; + targetList?: Node[]; + values?: Node[]; +} +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} +export interface TriggerTransition { + name?: string; + isNew?: boolean; + isTable?: boolean; +} +export interface JsonOutput { + typeName?: TypeName; + returning?: JsonReturning; +} +export interface JsonKeyValue { + key?: Node; + value?: JsonValueExpr; +} +export interface JsonObjectConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonArrayConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + location?: number; +} +export interface JsonArrayQueryConstructor { + query?: Node; + output?: JsonOutput; + format?: JsonFormat; + absent_on_null?: boolean; + location?: number; +} +export interface JsonAggConstructor { + output?: JsonOutput; + agg_filter?: Node; + agg_order?: Node[]; + over?: WindowDef; + location?: number; +} +export interface JsonObjectAgg { + constructor?: JsonAggConstructor; + arg?: JsonKeyValue; + absent_on_null?: boolean; + unique?: boolean; +} +export interface JsonArrayAgg { + constructor?: JsonAggConstructor; + arg?: JsonValueExpr; + absent_on_null?: boolean; +} +export interface RawStmt { + stmt?: Node; + stmt_location?: number; + stmt_len?: number; +} +export interface InsertStmt { + relation?: RangeVar; + cols?: Node[]; + selectStmt?: Node; + onConflictClause?: OnConflictClause; + returningList?: Node[]; + withClause?: WithClause; + override?: OverridingKind; +} +export interface DeleteStmt { + relation?: RangeVar; + usingClause?: Node[]; + whereClause?: Node; + returningList?: Node[]; + withClause?: WithClause; +} +export interface UpdateStmt { + relation?: RangeVar; + targetList?: Node[]; + whereClause?: Node; + fromClause?: Node[]; + returningList?: Node[]; + withClause?: WithClause; +} +export interface MergeStmt { + relation?: RangeVar; + sourceRelation?: Node; + joinCondition?: Node; + mergeWhenClauses?: Node[]; + withClause?: WithClause; +} +export interface SelectStmt { + distinctClause?: Node[]; + intoClause?: IntoClause; + targetList?: Node[]; + fromClause?: Node[]; + whereClause?: Node; + groupClause?: Node[]; + groupDistinct?: boolean; + havingClause?: Node; + windowClause?: Node[]; + valuesLists?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + lockingClause?: Node[]; + withClause?: WithClause; + op?: SetOperation; + all?: boolean; + larg?: SelectStmt; + rarg?: SelectStmt; +} +export interface SetOperationStmt { + op?: SetOperation; + all?: boolean; + larg?: Node; + rarg?: Node; + colTypes?: Node[]; + colTypmods?: Node[]; + colCollations?: Node[]; + groupClauses?: Node[]; +} +export interface ReturnStmt { + returnval?: Node; +} +export interface PLAssignStmt { + name?: string; + indirection?: Node[]; + nnames?: number; + val?: SelectStmt; + location?: number; +} +export interface CreateSchemaStmt { + schemaname?: string; + authrole?: RoleSpec; + schemaElts?: Node[]; + if_not_exists?: boolean; +} +export interface AlterTableStmt { + relation?: RangeVar; + cmds?: Node[]; + objtype?: ObjectType; + missing_ok?: boolean; +} +export interface ReplicaIdentityStmt { + identity_type?: string; + name?: string; +} +export interface AlterTableCmd { + subtype?: AlterTableType; + name?: string; + num?: number; + newowner?: RoleSpec; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; + recurse?: boolean; +} +export interface AlterCollationStmt { + collname?: Node[]; +} +export interface AlterDomainStmt { + subtype?: string; + typeName?: Node[]; + name?: string; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface GrantStmt { + is_grant?: boolean; + targtype?: GrantTargetType; + objtype?: ObjectType; + objects?: Node[]; + privileges?: Node[]; + grantees?: Node[]; + grant_option?: boolean; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface ObjectWithArgs { + objname?: Node[]; + objargs?: Node[]; + objfuncargs?: Node[]; + args_unspecified?: boolean; +} +export interface AccessPriv { + priv_name?: string; + cols?: Node[]; +} +export interface GrantRoleStmt { + granted_roles?: Node[]; + grantee_roles?: Node[]; + is_grant?: boolean; + opt?: Node[]; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface AlterDefaultPrivilegesStmt { + options?: Node[]; + action?: GrantStmt; +} +export interface CopyStmt { + relation?: RangeVar; + query?: Node; + attlist?: Node[]; + is_from?: boolean; + is_program?: boolean; + filename?: string; + options?: Node[]; + whereClause?: Node; +} +export interface VariableSetStmt { + kind?: VariableSetKind; + name?: string; + args?: Node[]; + is_local?: boolean; +} +export interface VariableShowStmt { + name?: string; +} +export interface CreateStmt { + relation?: RangeVar; + tableElts?: Node[]; + inhRelations?: Node[]; + partbound?: PartitionBoundSpec; + partspec?: PartitionSpec; + ofTypename?: TypeName; + constraints?: Node[]; + options?: Node[]; + oncommit?: OnCommitAction; + tablespacename?: string; + accessMethod?: string; + if_not_exists?: boolean; +} +export interface Constraint { + contype?: ConstrType; + conname?: string; + deferrable?: boolean; + initdeferred?: boolean; + location?: number; + is_no_inherit?: boolean; + raw_expr?: Node; + cooked_expr?: string; + generated_when?: string; + nulls_not_distinct?: boolean; + keys?: Node[]; + including?: Node[]; + exclusions?: Node[]; + options?: Node[]; + indexname?: string; + indexspace?: string; + reset_default_tblspc?: boolean; + access_method?: string; + where_clause?: Node; + pktable?: RangeVar; + fk_attrs?: Node[]; + pk_attrs?: Node[]; + fk_matchtype?: string; + fk_upd_action?: string; + fk_del_action?: string; + fk_del_set_cols?: Node[]; + old_conpfeqop?: Node[]; + old_pktable_oid?: number; + skip_validation?: boolean; + initially_valid?: boolean; +} +export interface CreateTableSpaceStmt { + tablespacename?: string; + owner?: RoleSpec; + location?: string; + options?: Node[]; +} +export interface DropTableSpaceStmt { + tablespacename?: string; + missing_ok?: boolean; +} +export interface AlterTableSpaceOptionsStmt { + tablespacename?: string; + options?: Node[]; + isReset?: boolean; +} +export interface AlterTableMoveAllStmt { + orig_tablespacename?: string; + objtype?: ObjectType; + roles?: Node[]; + new_tablespacename?: string; + nowait?: boolean; +} +export interface CreateExtensionStmt { + extname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterExtensionStmt { + extname?: string; + options?: Node[]; +} +export interface AlterExtensionContentsStmt { + extname?: string; + action?: number; + objtype?: ObjectType; + object?: Node; +} +export interface CreateFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface AlterFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface CreateForeignServerStmt { + servername?: string; + servertype?: string; + version?: string; + fdwname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterForeignServerStmt { + servername?: string; + version?: string; + options?: Node[]; + has_version?: boolean; +} +export interface CreateForeignTableStmt { + base?: CreateStmt; + servername?: string; + options?: Node[]; +} +export interface CreateUserMappingStmt { + user?: RoleSpec; + servername?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterUserMappingStmt { + user?: RoleSpec; + servername?: string; + options?: Node[]; +} +export interface DropUserMappingStmt { + user?: RoleSpec; + servername?: string; + missing_ok?: boolean; +} +export interface ImportForeignSchemaStmt { + server_name?: string; + remote_schema?: string; + local_schema?: string; + list_type?: ImportForeignSchemaType; + table_list?: Node[]; + options?: Node[]; +} +export interface CreatePolicyStmt { + policy_name?: string; + table?: RangeVar; + cmd_name?: string; + permissive?: boolean; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface AlterPolicyStmt { + policy_name?: string; + table?: RangeVar; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface CreateAmStmt { + amname?: string; + handler_name?: Node[]; + amtype?: string; +} +export interface CreateTrigStmt { + replace?: boolean; + isconstraint?: boolean; + trigname?: string; + relation?: RangeVar; + funcname?: Node[]; + args?: Node[]; + row?: boolean; + timing?: number; + events?: number; + columns?: Node[]; + whenClause?: Node; + transitionRels?: Node[]; + deferrable?: boolean; + initdeferred?: boolean; + constrrel?: RangeVar; +} +export interface CreateEventTrigStmt { + trigname?: string; + eventname?: string; + whenclause?: Node[]; + funcname?: Node[]; +} +export interface AlterEventTrigStmt { + trigname?: string; + tgenabled?: string; +} +export interface CreatePLangStmt { + replace?: boolean; + plname?: string; + plhandler?: Node[]; + plinline?: Node[]; + plvalidator?: Node[]; + pltrusted?: boolean; +} +export interface CreateRoleStmt { + stmt_type?: RoleStmtType; + role?: string; + options?: Node[]; +} +export interface AlterRoleStmt { + role?: RoleSpec; + options?: Node[]; + action?: number; +} +export interface AlterRoleSetStmt { + role?: RoleSpec; + database?: string; + setstmt?: VariableSetStmt; +} +export interface DropRoleStmt { + roles?: Node[]; + missing_ok?: boolean; +} +export interface CreateSeqStmt { + sequence?: RangeVar; + options?: Node[]; + ownerId?: number; + for_identity?: boolean; + if_not_exists?: boolean; +} +export interface AlterSeqStmt { + sequence?: RangeVar; + options?: Node[]; + for_identity?: boolean; + missing_ok?: boolean; +} +export interface DefineStmt { + kind?: ObjectType; + oldstyle?: boolean; + defnames?: Node[]; + args?: Node[]; + definition?: Node[]; + if_not_exists?: boolean; + replace?: boolean; +} +export interface CreateDomainStmt { + domainname?: Node[]; + typeName?: TypeName; + collClause?: CollateClause; + constraints?: Node[]; +} +export interface CreateOpClassStmt { + opclassname?: Node[]; + opfamilyname?: Node[]; + amname?: string; + datatype?: TypeName; + items?: Node[]; + isDefault?: boolean; +} +export interface CreateOpClassItem { + itemtype?: number; + name?: ObjectWithArgs; + number?: number; + order_family?: Node[]; + class_args?: Node[]; + storedtype?: TypeName; +} +export interface CreateOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; +} +export interface AlterOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; + isDrop?: boolean; + items?: Node[]; +} +export interface DropStmt { + objects?: Node[]; + removeType?: ObjectType; + behavior?: DropBehavior; + missing_ok?: boolean; + concurrent?: boolean; +} +export interface TruncateStmt { + relations?: Node[]; + restart_seqs?: boolean; + behavior?: DropBehavior; +} +export interface CommentStmt { + objtype?: ObjectType; + object?: Node; + comment?: string; +} +export interface SecLabelStmt { + objtype?: ObjectType; + object?: Node; + provider?: string; + label?: string; +} +export interface DeclareCursorStmt { + portalname?: string; + options?: number; + query?: Node; +} +export interface ClosePortalStmt { + portalname?: string; +} +export interface FetchStmt { + direction?: FetchDirection; + howMany?: bigint; + portalname?: string; + ismove?: boolean; +} +export interface IndexStmt { + idxname?: string; + relation?: RangeVar; + accessMethod?: string; + tableSpace?: string; + indexParams?: Node[]; + indexIncludingParams?: Node[]; + options?: Node[]; + whereClause?: Node; + excludeOpNames?: Node[]; + idxcomment?: string; + indexOid?: number; + oldNumber?: number; + oldCreateSubid?: number; + oldFirstRelfilelocatorSubid?: number; + unique?: boolean; + nulls_not_distinct?: boolean; + primary?: boolean; + isconstraint?: boolean; + deferrable?: boolean; + initdeferred?: boolean; + transformed?: boolean; + concurrent?: boolean; + if_not_exists?: boolean; + reset_default_tblspc?: boolean; +} +export interface CreateStatsStmt { + defnames?: Node[]; + stat_types?: Node[]; + exprs?: Node[]; + relations?: Node[]; + stxcomment?: string; + transformed?: boolean; + if_not_exists?: boolean; +} +export interface StatsElem { + name?: string; + expr?: Node; +} +export interface AlterStatsStmt { + defnames?: Node[]; + stxstattarget?: number; + missing_ok?: boolean; +} +export interface CreateFunctionStmt { + is_procedure?: boolean; + replace?: boolean; + funcname?: Node[]; + parameters?: Node[]; + returnType?: TypeName; + options?: Node[]; + sql_body?: Node; +} +export interface FunctionParameter { + name?: string; + argType?: TypeName; + mode?: FunctionParameterMode; + defexpr?: Node; +} +export interface AlterFunctionStmt { + objtype?: ObjectType; + func?: ObjectWithArgs; + actions?: Node[]; +} +export interface DoStmt { + args?: Node[]; +} +export interface InlineCodeBlock { + source_text?: string; + langOid?: number; + langIsTrusted?: boolean; + atomic?: boolean; +} +export interface CallStmt { + funccall?: FuncCall; + funcexpr?: FuncExpr; + outargs?: Node[]; +} +export interface CallContext { + atomic?: boolean; +} +export interface RenameStmt { + renameType?: ObjectType; + relationType?: ObjectType; + relation?: RangeVar; + object?: Node; + subname?: string; + newname?: string; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface AlterObjectDependsStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + extname?: String; + remove?: boolean; +} +export interface AlterObjectSchemaStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newschema?: string; + missing_ok?: boolean; +} +export interface AlterOwnerStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newowner?: RoleSpec; +} +export interface AlterOperatorStmt { + opername?: ObjectWithArgs; + options?: Node[]; +} +export interface AlterTypeStmt { + typeName?: Node[]; + options?: Node[]; +} +export interface RuleStmt { + relation?: RangeVar; + rulename?: string; + whereClause?: Node; + event?: CmdType; + instead?: boolean; + actions?: Node[]; + replace?: boolean; +} +export interface NotifyStmt { + conditionname?: string; + payload?: string; +} +export interface ListenStmt { + conditionname?: string; +} +export interface UnlistenStmt { + conditionname?: string; +} +export interface TransactionStmt { + kind?: TransactionStmtKind; + options?: Node[]; + savepoint_name?: string; + gid?: string; + chain?: boolean; +} +export interface CompositeTypeStmt { + typevar?: RangeVar; + coldeflist?: Node[]; +} +export interface CreateEnumStmt { + typeName?: Node[]; + vals?: Node[]; +} +export interface CreateRangeStmt { + typeName?: Node[]; + params?: Node[]; +} +export interface AlterEnumStmt { + typeName?: Node[]; + oldVal?: string; + newVal?: string; + newValNeighbor?: string; + newValIsAfter?: boolean; + skipIfNewValExists?: boolean; +} +export interface ViewStmt { + view?: RangeVar; + aliases?: Node[]; + query?: Node; + replace?: boolean; + options?: Node[]; + withCheckOption?: ViewCheckOption; +} +export interface LoadStmt { + filename?: string; +} +export interface CreatedbStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseRefreshCollStmt { + dbname?: string; +} +export interface AlterDatabaseSetStmt { + dbname?: string; + setstmt?: VariableSetStmt; +} +export interface DropdbStmt { + dbname?: string; + missing_ok?: boolean; + options?: Node[]; +} +export interface AlterSystemStmt { + setstmt?: VariableSetStmt; +} +export interface ClusterStmt { + relation?: RangeVar; + indexname?: string; + params?: Node[]; +} +export interface VacuumStmt { + options?: Node[]; + rels?: Node[]; + is_vacuumcmd?: boolean; +} +export interface VacuumRelation { + relation?: RangeVar; + oid?: number; + va_cols?: Node[]; +} +export interface ExplainStmt { + query?: Node; + options?: Node[]; +} +export interface CreateTableAsStmt { + query?: Node; + into?: IntoClause; + objtype?: ObjectType; + is_select_into?: boolean; + if_not_exists?: boolean; +} +export interface RefreshMatViewStmt { + concurrent?: boolean; + skipData?: boolean; + relation?: RangeVar; +} +export interface CheckPointStmt {} +export interface DiscardStmt { + target?: DiscardMode; +} +export interface LockStmt { + relations?: Node[]; + mode?: number; + nowait?: boolean; +} +export interface ConstraintsSetStmt { + constraints?: Node[]; + deferred?: boolean; +} +export interface ReindexStmt { + kind?: ReindexObjectType; + relation?: RangeVar; + name?: string; + params?: Node[]; +} +export interface CreateConversionStmt { + conversion_name?: Node[]; + for_encoding_name?: string; + to_encoding_name?: string; + func_name?: Node[]; + def?: boolean; +} +export interface CreateCastStmt { + sourcetype?: TypeName; + targettype?: TypeName; + func?: ObjectWithArgs; + context?: CoercionContext; + inout?: boolean; +} +export interface CreateTransformStmt { + replace?: boolean; + type_name?: TypeName; + lang?: string; + fromsql?: ObjectWithArgs; + tosql?: ObjectWithArgs; +} +export interface PrepareStmt { + name?: string; + argtypes?: Node[]; + query?: Node; +} +export interface ExecuteStmt { + name?: string; + params?: Node[]; +} +export interface DeallocateStmt { + name?: string; +} +export interface DropOwnedStmt { + roles?: Node[]; + behavior?: DropBehavior; +} +export interface ReassignOwnedStmt { + roles?: Node[]; + newrole?: RoleSpec; +} +export interface AlterTSDictionaryStmt { + dictname?: Node[]; + options?: Node[]; +} +export interface AlterTSConfigurationStmt { + kind?: AlterTSConfigType; + cfgname?: Node[]; + tokentype?: Node[]; + dicts?: Node[]; + override?: boolean; + replace?: boolean; + missing_ok?: boolean; +} +export interface PublicationTable { + relation?: RangeVar; + whereClause?: Node; + columns?: Node[]; +} +export interface PublicationObjSpec { + pubobjtype?: PublicationObjSpecType; + name?: string; + pubtable?: PublicationTable; + location?: number; +} +export interface CreatePublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; +} +export interface AlterPublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; + action?: AlterPublicationAction; +} +export interface CreateSubscriptionStmt { + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface AlterSubscriptionStmt { + kind?: AlterSubscriptionType; + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface DropSubscriptionStmt { + subname?: string; + missing_ok?: boolean; + behavior?: DropBehavior; +} +export interface ScanToken { + start?: number; + end?: number; + token?: Token; + keywordKind?: KeywordKind; +} \ No newline at end of file diff --git a/__fixtures__/output/utils/wrappedAstHelpers/enabled/wrapped-asts.ts b/__fixtures__/output/utils/wrappedAstHelpers/enabled/wrapped-asts.ts new file mode 100644 index 00000000..313b2223 --- /dev/null +++ b/__fixtures__/output/utils/wrappedAstHelpers/enabled/wrapped-asts.ts @@ -0,0 +1,3350 @@ +/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +}; \ No newline at end of file diff --git a/packages/deparser/__tests__/kitchen-sink/misc-booleans-cast.test.ts b/packages/deparser/__tests__/kitchen-sink/misc-booleans-cast.test.ts new file mode 100644 index 00000000..f9f96697 --- /dev/null +++ b/packages/deparser/__tests__/kitchen-sink/misc-booleans-cast.test.ts @@ -0,0 +1,10 @@ + +import { FixtureTestUtils } from '../../test-utils'; +const fixtures = new FixtureTestUtils(); + +it('misc-booleans-cast', async () => { + await fixtures.runFixtureTests([ + "misc/booleans-cast-1.sql", + "misc/booleans-cast-2.sql" +]); +}); diff --git a/packages/deparser/package.json b/packages/deparser/package.json index 1e887486..6d302d5a 100644 --- a/packages/deparser/package.json +++ b/packages/deparser/package.json @@ -49,6 +49,6 @@ "libpg-query": "17.3.3" }, "dependencies": { - "@pgsql/types": "^17.5.2" + "@pgsql/types": "^17.5.3" } } diff --git a/packages/enums/src/index.ts b/packages/enums/src/index.ts index d069ce85..9a9e632f 100644 --- a/packages/enums/src/index.ts +++ b/packages/enums/src/index.ts @@ -1,5 +1,5 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ diff --git a/packages/parser/package.json b/packages/parser/package.json index 90b932f7..32ab9845 100644 --- a/packages/parser/package.json +++ b/packages/parser/package.json @@ -42,7 +42,7 @@ "database" ], "dependencies": { - "@pgsql/types": "^17.5.2", + "@pgsql/types": "^17.5.3", "libpg-query": "17.3.3", "minimist": "^1.2.6" } diff --git a/packages/proto-parser/AST_METHODS.md b/packages/proto-parser/AST_METHODS.md new file mode 100644 index 00000000..b4357f0e --- /dev/null +++ b/packages/proto-parser/AST_METHODS.md @@ -0,0 +1,216 @@ +# AST Code Generation Methods Documentation + +This document describes the various code generation methods in the proto-parser package, explaining what each method generates and how they're used in the parsing pipeline. + +## Overview + +The proto-parser package processes protobuf definitions and generates TypeScript code for working with PostgreSQL AST nodes. The main entry point is the `ProtoStore` class in `src/store.ts`, which orchestrates the code generation process. + +## Type Generation Methods (`src/ast/types/types.ts`) + +### `generateTypeImports(types, source, suffix?)` +- **Purpose**: Generates import statements for types from a specified source module +- **Output**: `import { Type1, Type2 } from './source'` or with suffix: `import { Type1 as Type1Suffix } from './source'` +- **Used in**: Importing types into other generated files + +### `generateAstHelperMethods(types)` +- **Purpose**: Creates factory functions for instantiating AST nodes that return the type directly +- **Output**: An object with camelCase methods for each type +- **Example**: + ```typescript + export default { + selectStmt: (_p?: SelectStmt) => SelectStmt, + insertStmt: (_p?: InsertStmt) => InsertStmt + } + ``` +- **Used in**: `asts.ts` file generation (when `utils.astHelpers.enabled` is true) + +### `generateWrappedAstHelperMethods(types)` +- **Purpose**: Creates factory functions that return AST nodes wrapped in type-specific objects +- **Output**: An object with camelCase methods that return wrapped types +- **Example**: + ```typescript + export default { + selectStmt: (_p?: SelectStmt) => { SelectStmt: SelectStmt }, + insertStmt: (_p?: InsertStmt) => { InsertStmt: InsertStmt } + } + ``` +- **Used in**: `wrapped-asts.ts` file generation (when `utils.wrappedAstHelpers.enabled` is true) + +### `generateNodeUnionType(options, types)` +- **Purpose**: Creates a union type of all AST node types +- **Output**: + - Simple: `export type Node = SelectStmt | InsertStmt | ...` + - Wrapped: `export type Node = { SelectStmt: SelectStmt } | { InsertStmt: InsertStmt } | ...` +- **Used in**: `types.ts` file generation + +### `convertTypeToTsInterface(type, options)` +- **Purpose**: Converts protobuf Type definitions to TypeScript interfaces +- **Output**: + ```typescript + export interface SelectStmt { + targetList?: Node[]; + fromClause?: Node[]; + // ... other fields + } + ``` +- **Used in**: `types.ts` file generation + +### `generateTypeImportSpecifiers(types, options)` +- **Purpose**: Creates import specifiers for types from configured source +- **Output**: `import { SelectStmt, InsertStmt, ... } from './types'` +- **Used in**: `ast-helpers.ts` to import type definitions + +## Enum Generation Methods + +### Core Enum Methods (`src/ast/enums/enums.ts`) + +### `convertEnumToTsEnumDeclaration(enumData)` +- **Purpose**: Converts protobuf enums to TypeScript enum declarations +- **Output**: + ```typescript + export enum MyEnum { + VALUE1 = 0, + VALUE2 = 1 + } + ``` +- **Used in**: `enums.ts` file generation (when not using union types) + +### `convertEnumToTsUnionType(enumData)` +- **Purpose**: Converts protobuf enums to TypeScript union types +- **Output**: `export type MyEnum = 'VALUE1' | 'VALUE2' | ...` +- **Used in**: `enums.ts` file generation (when `enumsAsTypeUnion` is true) + +### `generateEnumImports(enums, source)` +- **Purpose**: Generates import statements for enums +- **Output**: `import { Enum1, Enum2 } from './enums'` +- **Used in**: Importing enums into `types.ts` + +### `generateEnumValueFunctions(enumData)` +- **Purpose**: Creates bidirectional enum converter function +- **Output**: + ```typescript + export const getEnumValue = (enumType: EnumType, key: string | number) => { + // Returns number for string input, string for number input + } + ``` +- **Used in**: `utils/enums.ts` (bidirectional mode) + +### `generateEnumToIntFunctions(enumData)` +- **Purpose**: Creates function to convert enum strings to numbers +- **Output**: `export const getEnumInt = (enumType: EnumType, key: string): number => { ... }` +- **Used in**: `utils/enums-to-int.ts` (unidirectional mode) + +### `generateEnumToStringFunctions(enumData)` +- **Purpose**: Creates function to convert enum numbers to strings +- **Output**: `export const getEnumString = (enumType: EnumType, key: number): string => { ... }` +- **Used in**: `utils/enums-to-str.ts` (unidirectional mode) + +### `generateEnumToIntFunctionsNested(enumData)` +- **Purpose**: Creates nested object with individual enum converters +- **Output**: + ```typescript + export const enumToIntMap = { + MyEnum: (key: string) => number, + OtherEnum: (key: string) => number + } + ``` +- **Used in**: `utils/enums-to-int.ts` (nested object format) + +### `generateEnumToStringFunctionsNested(enumData)` +- **Purpose**: Creates nested object for number-to-string conversion +- **Output**: + ```typescript + export const enumToStringMap = { + MyEnum: (value: number) => string, + OtherEnum: (value: number) => string + } + ``` +- **Used in**: `utils/enums-to-str.ts` (nested object format) + +### JSON Generation Methods (`src/ast/enums/enums-json.ts`) + +### `generateEnum2StrJSON(enums)` +- **Purpose**: Creates JSON mapping from enum values to names +- **Output**: + ```json + { + "MyEnum": { + "0": "VALUE1", + "1": "VALUE2" + } + } + ``` +- **Used in**: `writeEnumMaps()` for generating enum mapping files + +### `generateEnum2IntJSON(enums)` +- **Purpose**: Creates JSON mapping from enum names to values +- **Output**: + ```json + { + "MyEnum": { + "VALUE1": 0, + "VALUE2": 1 + } + } + ``` +- **Used in**: `writeEnumMaps()` for generating enum mapping files + +## Type Resolution Utilities (`src/ast/types/utils.ts`) + +### `getTSType(type)` +- **Purpose**: Maps protobuf primitive types to TypeScript types +- **Mappings**: + - `string` → `string` + - `double`, `float`, `int32`, etc. → `number` + - `int64`, `uint64`, etc. → `bigint` + - `bytes` → `Uint8Array` + - `bool` → `boolean` + - Custom types → Type reference + +### `resolveTypeName(type)` +- **Purpose**: Main entry point for type resolution +- **Logic**: Uses `getTSType` for primitives, creates type references for custom types + +## Code Generation Flow + +1. **Parse Phase** (`ProtoStore._parse`) + - Processes protobuf definitions + - Collects types, enums, and services + - Handles enum value transformations (e.g., removing UNDEFINED at 0) + +2. **Write Phase** (`ProtoStore.write`) + - `writeEnumMaps()`: Generates JSON or TypeScript enum mapping files + - `writeTypes()`: Generates TypeScript interfaces for all types + - `writeEnums()`: Generates enum declarations or union types + - `writeUtilsEnums()`: Generates enum utility functions + - `writeAstHelpers()`: Generates AST node factory functions + - `writeRuntimeSchema()`: Generates runtime schema information + +## Configuration Options + +The generation behavior is controlled by options in `PgProtoStoreOptions`: + +- `types.enabled`: Enable type generation +- `types.optionalFields`: Make all fields optional +- `types.wrappedNodeTypeExport`: Use wrapped object format for Node union +- `enums.enabled`: Enable enum generation +- `enums.enumsAsTypeUnion`: Generate union types instead of enums +- `enums.removeUndefinedAt0`: Remove UNDEFINED enum value at position 0 +- `utils.enums.unidirectional`: Generate separate to-int and to-string functions +- `utils.enums.outputFormat`: Use 'nestedObjects' for better type safety +- `utils.astHelpers.enabled`: Generate AST helper methods in `asts.ts` +- `utils.wrappedAstHelpers.enabled`: Generate wrapped AST helper methods in `wrapped-asts.ts` + +## Output Files + +Based on configuration, the following files are typically generated: + +- `types.ts`: TypeScript interfaces for all AST node types +- `enums.ts`: Enum declarations or union types +- `utils/enums.ts`: Bidirectional enum converter (or separate files for unidirectional) +- `asts.ts`: AST helper methods that return type instances directly +- `wrapped-asts.ts`: AST helper methods that return `{ TypeName: instance }` +- `utils/ast-helpers.ts`: Factory functions for creating AST nodes +- `enums-map-to-int.json/ts`: Enum to integer mappings +- `enums-map-to-str.json/ts`: Integer to enum string mappings \ No newline at end of file diff --git a/packages/proto-parser/__tests__/__snapshots__/enum-utils.test.ts.snap b/packages/proto-parser/__tests__/__snapshots__/enum-utils.test.ts.snap index 8bef3978..2096e71e 100644 --- a/packages/proto-parser/__tests__/__snapshots__/enum-utils.test.ts.snap +++ b/packages/proto-parser/__tests__/__snapshots__/enum-utils.test.ts.snap @@ -7046,7 +7046,7 @@ export const enumToStringMap: EnumToStringMap = { } } };", - "file": "custom-string-nested.ts", + "file": "enum-to-string-nested.ts", }, { "code": "/** @@ -9393,8942 +9393,13 @@ export const enumToIntMap: EnumToIntMap = { } } };", - "file": "custom-int-nested.ts", - }, - { - "code": "/** -* This file was automatically generated by pg-proto-parser@latest. -* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, -* and run the pg-proto-parser generate command to regenerate this file. -*/ -export type EnumType = "OverridingKind" | "QuerySource" | "SortByDir" | "SortByNulls" | "SetQuantifier" | "A_Expr_Kind" | "RoleSpecType" | "TableLikeOption" | "DefElemAction" | "PartitionStrategy" | "PartitionRangeDatumKind" | "RTEKind" | "WCOKind" | "GroupingSetKind" | "CTEMaterialize" | "SetOperation" | "ObjectType" | "DropBehavior" | "AlterTableType" | "GrantTargetType" | "VariableSetKind" | "ConstrType" | "ImportForeignSchemaType" | "RoleStmtType" | "FetchDirection" | "FunctionParameterMode" | "TransactionStmtKind" | "ViewCheckOption" | "DiscardMode" | "ReindexObjectType" | "AlterTSConfigType" | "PublicationObjSpecType" | "AlterPublicationAction" | "AlterSubscriptionType" | "OnCommitAction" | "ParamKind" | "CoercionContext" | "CoercionForm" | "BoolExprType" | "SubLinkType" | "RowCompareType" | "MinMaxOp" | "SQLValueFunctionOp" | "XmlExprOp" | "XmlOptionType" | "JsonEncoding" | "JsonFormatType" | "JsonConstructorType" | "JsonValueType" | "NullTestType" | "BoolTestType" | "CmdType" | "JoinType" | "AggStrategy" | "AggSplit" | "SetOpCmd" | "SetOpStrategy" | "OnConflictAction" | "LimitOption" | "LockClauseStrength" | "LockWaitPolicy" | "LockTupleMode" | "KeywordKind" | "Token"; -export type EnumToStringMap = { - "OverridingKind": (value: number) => string; - "QuerySource": (value: number) => string; - "SortByDir": (value: number) => string; - "SortByNulls": (value: number) => string; - "SetQuantifier": (value: number) => string; - "A_Expr_Kind": (value: number) => string; - "RoleSpecType": (value: number) => string; - "TableLikeOption": (value: number) => string; - "DefElemAction": (value: number) => string; - "PartitionStrategy": (value: number) => string; - "PartitionRangeDatumKind": (value: number) => string; - "RTEKind": (value: number) => string; - "WCOKind": (value: number) => string; - "GroupingSetKind": (value: number) => string; - "CTEMaterialize": (value: number) => string; - "SetOperation": (value: number) => string; - "ObjectType": (value: number) => string; - "DropBehavior": (value: number) => string; - "AlterTableType": (value: number) => string; - "GrantTargetType": (value: number) => string; - "VariableSetKind": (value: number) => string; - "ConstrType": (value: number) => string; - "ImportForeignSchemaType": (value: number) => string; - "RoleStmtType": (value: number) => string; - "FetchDirection": (value: number) => string; - "FunctionParameterMode": (value: number) => string; - "TransactionStmtKind": (value: number) => string; - "ViewCheckOption": (value: number) => string; - "DiscardMode": (value: number) => string; - "ReindexObjectType": (value: number) => string; - "AlterTSConfigType": (value: number) => string; - "PublicationObjSpecType": (value: number) => string; - "AlterPublicationAction": (value: number) => string; - "AlterSubscriptionType": (value: number) => string; - "OnCommitAction": (value: number) => string; - "ParamKind": (value: number) => string; - "CoercionContext": (value: number) => string; - "CoercionForm": (value: number) => string; - "BoolExprType": (value: number) => string; - "SubLinkType": (value: number) => string; - "RowCompareType": (value: number) => string; - "MinMaxOp": (value: number) => string; - "SQLValueFunctionOp": (value: number) => string; - "XmlExprOp": (value: number) => string; - "XmlOptionType": (value: number) => string; - "JsonEncoding": (value: number) => string; - "JsonFormatType": (value: number) => string; - "JsonConstructorType": (value: number) => string; - "JsonValueType": (value: number) => string; - "NullTestType": (value: number) => string; - "BoolTestType": (value: number) => string; - "CmdType": (value: number) => string; - "JoinType": (value: number) => string; - "AggStrategy": (value: number) => string; - "AggSplit": (value: number) => string; - "SetOpCmd": (value: number) => string; - "SetOpStrategy": (value: number) => string; - "OnConflictAction": (value: number) => string; - "LimitOption": (value: number) => string; - "LockClauseStrength": (value: number) => string; - "LockWaitPolicy": (value: number) => string; - "LockTupleMode": (value: number) => string; - "KeywordKind": (value: number) => string; - "Token": (value: number) => string; -}; -export const enumToStringMap: EnumToStringMap = { - "OverridingKind": (value: number): string => { - switch (value) { - case 0: - return "OVERRIDING_NOT_SET"; - case 1: - return "OVERRIDING_USER_VALUE"; - case 2: - return "OVERRIDING_SYSTEM_VALUE"; - default: - throw new Error("Value not recognized in enum OverridingKind"); - } - }, - "QuerySource": (value: number): string => { - switch (value) { - case 0: - return "QSRC_ORIGINAL"; - case 1: - return "QSRC_PARSER"; - case 2: - return "QSRC_INSTEAD_RULE"; - case 3: - return "QSRC_QUAL_INSTEAD_RULE"; - case 4: - return "QSRC_NON_INSTEAD_RULE"; - default: - throw new Error("Value not recognized in enum QuerySource"); - } - }, - "SortByDir": (value: number): string => { - switch (value) { - case 0: - return "SORTBY_DEFAULT"; - case 1: - return "SORTBY_ASC"; - case 2: - return "SORTBY_DESC"; - case 3: - return "SORTBY_USING"; - default: - throw new Error("Value not recognized in enum SortByDir"); - } - }, - "SortByNulls": (value: number): string => { - switch (value) { - case 0: - return "SORTBY_NULLS_DEFAULT"; - case 1: - return "SORTBY_NULLS_FIRST"; - case 2: - return "SORTBY_NULLS_LAST"; - default: - throw new Error("Value not recognized in enum SortByNulls"); - } - }, - "SetQuantifier": (value: number): string => { - switch (value) { - case 0: - return "SET_QUANTIFIER_DEFAULT"; - case 1: - return "SET_QUANTIFIER_ALL"; - case 2: - return "SET_QUANTIFIER_DISTINCT"; - default: - throw new Error("Value not recognized in enum SetQuantifier"); - } - }, - "A_Expr_Kind": (value: number): string => { - switch (value) { - case 0: - return "AEXPR_OP"; - case 1: - return "AEXPR_OP_ANY"; - case 2: - return "AEXPR_OP_ALL"; - case 3: - return "AEXPR_DISTINCT"; - case 4: - return "AEXPR_NOT_DISTINCT"; - case 5: - return "AEXPR_NULLIF"; - case 6: - return "AEXPR_IN"; - case 7: - return "AEXPR_LIKE"; - case 8: - return "AEXPR_ILIKE"; - case 9: - return "AEXPR_SIMILAR"; - case 10: - return "AEXPR_BETWEEN"; - case 11: - return "AEXPR_NOT_BETWEEN"; - case 12: - return "AEXPR_BETWEEN_SYM"; - case 13: - return "AEXPR_NOT_BETWEEN_SYM"; - default: - throw new Error("Value not recognized in enum A_Expr_Kind"); - } - }, - "RoleSpecType": (value: number): string => { - switch (value) { - case 0: - return "ROLESPEC_CSTRING"; - case 1: - return "ROLESPEC_CURRENT_ROLE"; - case 2: - return "ROLESPEC_CURRENT_USER"; - case 3: - return "ROLESPEC_SESSION_USER"; - case 4: - return "ROLESPEC_PUBLIC"; - default: - throw new Error("Value not recognized in enum RoleSpecType"); - } - }, - "TableLikeOption": (value: number): string => { - switch (value) { - case 0: - return "CREATE_TABLE_LIKE_COMMENTS"; - case 1: - return "CREATE_TABLE_LIKE_COMPRESSION"; - case 2: - return "CREATE_TABLE_LIKE_CONSTRAINTS"; - case 3: - return "CREATE_TABLE_LIKE_DEFAULTS"; - case 4: - return "CREATE_TABLE_LIKE_GENERATED"; - case 5: - return "CREATE_TABLE_LIKE_IDENTITY"; - case 6: - return "CREATE_TABLE_LIKE_INDEXES"; - case 7: - return "CREATE_TABLE_LIKE_STATISTICS"; - case 8: - return "CREATE_TABLE_LIKE_STORAGE"; - case 9: - return "CREATE_TABLE_LIKE_ALL"; - default: - throw new Error("Value not recognized in enum TableLikeOption"); - } - }, - "DefElemAction": (value: number): string => { - switch (value) { - case 0: - return "DEFELEM_UNSPEC"; - case 1: - return "DEFELEM_SET"; - case 2: - return "DEFELEM_ADD"; - case 3: - return "DEFELEM_DROP"; - default: - throw new Error("Value not recognized in enum DefElemAction"); - } - }, - "PartitionStrategy": (value: number): string => { - switch (value) { - case 0: - return "PARTITION_STRATEGY_LIST"; - case 1: - return "PARTITION_STRATEGY_RANGE"; - case 2: - return "PARTITION_STRATEGY_HASH"; - default: - throw new Error("Value not recognized in enum PartitionStrategy"); - } - }, - "PartitionRangeDatumKind": (value: number): string => { - switch (value) { - case 0: - return "PARTITION_RANGE_DATUM_MINVALUE"; - case 1: - return "PARTITION_RANGE_DATUM_VALUE"; - case 2: - return "PARTITION_RANGE_DATUM_MAXVALUE"; - default: - throw new Error("Value not recognized in enum PartitionRangeDatumKind"); - } - }, - "RTEKind": (value: number): string => { - switch (value) { - case 0: - return "RTE_RELATION"; - case 1: - return "RTE_SUBQUERY"; - case 2: - return "RTE_JOIN"; - case 3: - return "RTE_FUNCTION"; - case 4: - return "RTE_TABLEFUNC"; - case 5: - return "RTE_VALUES"; - case 6: - return "RTE_CTE"; - case 7: - return "RTE_NAMEDTUPLESTORE"; - case 8: - return "RTE_RESULT"; - default: - throw new Error("Value not recognized in enum RTEKind"); - } - }, - "WCOKind": (value: number): string => { - switch (value) { - case 0: - return "WCO_VIEW_CHECK"; - case 1: - return "WCO_RLS_INSERT_CHECK"; - case 2: - return "WCO_RLS_UPDATE_CHECK"; - case 3: - return "WCO_RLS_CONFLICT_CHECK"; - case 4: - return "WCO_RLS_MERGE_UPDATE_CHECK"; - case 5: - return "WCO_RLS_MERGE_DELETE_CHECK"; - default: - throw new Error("Value not recognized in enum WCOKind"); - } - }, - "GroupingSetKind": (value: number): string => { - switch (value) { - case 0: - return "GROUPING_SET_EMPTY"; - case 1: - return "GROUPING_SET_SIMPLE"; - case 2: - return "GROUPING_SET_ROLLUP"; - case 3: - return "GROUPING_SET_CUBE"; - case 4: - return "GROUPING_SET_SETS"; - default: - throw new Error("Value not recognized in enum GroupingSetKind"); - } - }, - "CTEMaterialize": (value: number): string => { - switch (value) { - case 0: - return "CTEMaterializeDefault"; - case 1: - return "CTEMaterializeAlways"; - case 2: - return "CTEMaterializeNever"; - default: - throw new Error("Value not recognized in enum CTEMaterialize"); - } - }, - "SetOperation": (value: number): string => { - switch (value) { - case 0: - return "SETOP_NONE"; - case 1: - return "SETOP_UNION"; - case 2: - return "SETOP_INTERSECT"; - case 3: - return "SETOP_EXCEPT"; - default: - throw new Error("Value not recognized in enum SetOperation"); - } - }, - "ObjectType": (value: number): string => { - switch (value) { - case 0: - return "OBJECT_ACCESS_METHOD"; - case 1: - return "OBJECT_AGGREGATE"; - case 2: - return "OBJECT_AMOP"; - case 3: - return "OBJECT_AMPROC"; - case 4: - return "OBJECT_ATTRIBUTE"; - case 5: - return "OBJECT_CAST"; - case 6: - return "OBJECT_COLUMN"; - case 7: - return "OBJECT_COLLATION"; - case 8: - return "OBJECT_CONVERSION"; - case 9: - return "OBJECT_DATABASE"; - case 10: - return "OBJECT_DEFAULT"; - case 11: - return "OBJECT_DEFACL"; - case 12: - return "OBJECT_DOMAIN"; - case 13: - return "OBJECT_DOMCONSTRAINT"; - case 14: - return "OBJECT_EVENT_TRIGGER"; - case 15: - return "OBJECT_EXTENSION"; - case 16: - return "OBJECT_FDW"; - case 17: - return "OBJECT_FOREIGN_SERVER"; - case 18: - return "OBJECT_FOREIGN_TABLE"; - case 19: - return "OBJECT_FUNCTION"; - case 20: - return "OBJECT_INDEX"; - case 21: - return "OBJECT_LANGUAGE"; - case 22: - return "OBJECT_LARGEOBJECT"; - case 23: - return "OBJECT_MATVIEW"; - case 24: - return "OBJECT_OPCLASS"; - case 25: - return "OBJECT_OPERATOR"; - case 26: - return "OBJECT_OPFAMILY"; - case 27: - return "OBJECT_PARAMETER_ACL"; - case 28: - return "OBJECT_POLICY"; - case 29: - return "OBJECT_PROCEDURE"; - case 30: - return "OBJECT_PUBLICATION"; - case 31: - return "OBJECT_PUBLICATION_NAMESPACE"; - case 32: - return "OBJECT_PUBLICATION_REL"; - case 33: - return "OBJECT_ROLE"; - case 34: - return "OBJECT_ROUTINE"; - case 35: - return "OBJECT_RULE"; - case 36: - return "OBJECT_SCHEMA"; - case 37: - return "OBJECT_SEQUENCE"; - case 38: - return "OBJECT_SUBSCRIPTION"; - case 39: - return "OBJECT_STATISTIC_EXT"; - case 40: - return "OBJECT_TABCONSTRAINT"; - case 41: - return "OBJECT_TABLE"; - case 42: - return "OBJECT_TABLESPACE"; - case 43: - return "OBJECT_TRANSFORM"; - case 44: - return "OBJECT_TRIGGER"; - case 45: - return "OBJECT_TSCONFIGURATION"; - case 46: - return "OBJECT_TSDICTIONARY"; - case 47: - return "OBJECT_TSPARSER"; - case 48: - return "OBJECT_TSTEMPLATE"; - case 49: - return "OBJECT_TYPE"; - case 50: - return "OBJECT_USER_MAPPING"; - case 51: - return "OBJECT_VIEW"; - default: - throw new Error("Value not recognized in enum ObjectType"); - } - }, - "DropBehavior": (value: number): string => { - switch (value) { - case 0: - return "DROP_RESTRICT"; - case 1: - return "DROP_CASCADE"; - default: - throw new Error("Value not recognized in enum DropBehavior"); - } - }, - "AlterTableType": (value: number): string => { - switch (value) { - case 0: - return "AT_AddColumn"; - case 1: - return "AT_AddColumnToView"; - case 2: - return "AT_ColumnDefault"; - case 3: - return "AT_CookedColumnDefault"; - case 4: - return "AT_DropNotNull"; - case 5: - return "AT_SetNotNull"; - case 6: - return "AT_DropExpression"; - case 7: - return "AT_CheckNotNull"; - case 8: - return "AT_SetStatistics"; - case 9: - return "AT_SetOptions"; - case 10: - return "AT_ResetOptions"; - case 11: - return "AT_SetStorage"; - case 12: - return "AT_SetCompression"; - case 13: - return "AT_DropColumn"; - case 14: - return "AT_AddIndex"; - case 15: - return "AT_ReAddIndex"; - case 16: - return "AT_AddConstraint"; - case 17: - return "AT_ReAddConstraint"; - case 18: - return "AT_ReAddDomainConstraint"; - case 19: - return "AT_AlterConstraint"; - case 20: - return "AT_ValidateConstraint"; - case 21: - return "AT_AddIndexConstraint"; - case 22: - return "AT_DropConstraint"; - case 23: - return "AT_ReAddComment"; - case 24: - return "AT_AlterColumnType"; - case 25: - return "AT_AlterColumnGenericOptions"; - case 26: - return "AT_ChangeOwner"; - case 27: - return "AT_ClusterOn"; - case 28: - return "AT_DropCluster"; - case 29: - return "AT_SetLogged"; - case 30: - return "AT_SetUnLogged"; - case 31: - return "AT_DropOids"; - case 32: - return "AT_SetAccessMethod"; - case 33: - return "AT_SetTableSpace"; - case 34: - return "AT_SetRelOptions"; - case 35: - return "AT_ResetRelOptions"; - case 36: - return "AT_ReplaceRelOptions"; - case 37: - return "AT_EnableTrig"; - case 38: - return "AT_EnableAlwaysTrig"; - case 39: - return "AT_EnableReplicaTrig"; - case 40: - return "AT_DisableTrig"; - case 41: - return "AT_EnableTrigAll"; - case 42: - return "AT_DisableTrigAll"; - case 43: - return "AT_EnableTrigUser"; - case 44: - return "AT_DisableTrigUser"; - case 45: - return "AT_EnableRule"; - case 46: - return "AT_EnableAlwaysRule"; - case 47: - return "AT_EnableReplicaRule"; - case 48: - return "AT_DisableRule"; - case 49: - return "AT_AddInherit"; - case 50: - return "AT_DropInherit"; - case 51: - return "AT_AddOf"; - case 52: - return "AT_DropOf"; - case 53: - return "AT_ReplicaIdentity"; - case 54: - return "AT_EnableRowSecurity"; - case 55: - return "AT_DisableRowSecurity"; - case 56: - return "AT_ForceRowSecurity"; - case 57: - return "AT_NoForceRowSecurity"; - case 58: - return "AT_GenericOptions"; - case 59: - return "AT_AttachPartition"; - case 60: - return "AT_DetachPartition"; - case 61: - return "AT_DetachPartitionFinalize"; - case 62: - return "AT_AddIdentity"; - case 63: - return "AT_SetIdentity"; - case 64: - return "AT_DropIdentity"; - case 65: - return "AT_ReAddStatistics"; - default: - throw new Error("Value not recognized in enum AlterTableType"); - } - }, - "GrantTargetType": (value: number): string => { - switch (value) { - case 0: - return "ACL_TARGET_OBJECT"; - case 1: - return "ACL_TARGET_ALL_IN_SCHEMA"; - case 2: - return "ACL_TARGET_DEFAULTS"; - default: - throw new Error("Value not recognized in enum GrantTargetType"); - } - }, - "VariableSetKind": (value: number): string => { - switch (value) { - case 0: - return "VAR_SET_VALUE"; - case 1: - return "VAR_SET_DEFAULT"; - case 2: - return "VAR_SET_CURRENT"; - case 3: - return "VAR_SET_MULTI"; - case 4: - return "VAR_RESET"; - case 5: - return "VAR_RESET_ALL"; - default: - throw new Error("Value not recognized in enum VariableSetKind"); - } - }, - "ConstrType": (value: number): string => { - switch (value) { - case 0: - return "CONSTR_NULL"; - case 1: - return "CONSTR_NOTNULL"; - case 2: - return "CONSTR_DEFAULT"; - case 3: - return "CONSTR_IDENTITY"; - case 4: - return "CONSTR_GENERATED"; - case 5: - return "CONSTR_CHECK"; - case 6: - return "CONSTR_PRIMARY"; - case 7: - return "CONSTR_UNIQUE"; - case 8: - return "CONSTR_EXCLUSION"; - case 9: - return "CONSTR_FOREIGN"; - case 10: - return "CONSTR_ATTR_DEFERRABLE"; - case 11: - return "CONSTR_ATTR_NOT_DEFERRABLE"; - case 12: - return "CONSTR_ATTR_DEFERRED"; - case 13: - return "CONSTR_ATTR_IMMEDIATE"; - default: - throw new Error("Value not recognized in enum ConstrType"); - } - }, - "ImportForeignSchemaType": (value: number): string => { - switch (value) { - case 0: - return "FDW_IMPORT_SCHEMA_ALL"; - case 1: - return "FDW_IMPORT_SCHEMA_LIMIT_TO"; - case 2: - return "FDW_IMPORT_SCHEMA_EXCEPT"; - default: - throw new Error("Value not recognized in enum ImportForeignSchemaType"); - } - }, - "RoleStmtType": (value: number): string => { - switch (value) { - case 0: - return "ROLESTMT_ROLE"; - case 1: - return "ROLESTMT_USER"; - case 2: - return "ROLESTMT_GROUP"; - default: - throw new Error("Value not recognized in enum RoleStmtType"); - } - }, - "FetchDirection": (value: number): string => { - switch (value) { - case 0: - return "FETCH_FORWARD"; - case 1: - return "FETCH_BACKWARD"; - case 2: - return "FETCH_ABSOLUTE"; - case 3: - return "FETCH_RELATIVE"; - default: - throw new Error("Value not recognized in enum FetchDirection"); - } - }, - "FunctionParameterMode": (value: number): string => { - switch (value) { - case 0: - return "FUNC_PARAM_IN"; - case 1: - return "FUNC_PARAM_OUT"; - case 2: - return "FUNC_PARAM_INOUT"; - case 3: - return "FUNC_PARAM_VARIADIC"; - case 4: - return "FUNC_PARAM_TABLE"; - case 5: - return "FUNC_PARAM_DEFAULT"; - default: - throw new Error("Value not recognized in enum FunctionParameterMode"); - } - }, - "TransactionStmtKind": (value: number): string => { - switch (value) { - case 0: - return "TRANS_STMT_BEGIN"; - case 1: - return "TRANS_STMT_START"; - case 2: - return "TRANS_STMT_COMMIT"; - case 3: - return "TRANS_STMT_ROLLBACK"; - case 4: - return "TRANS_STMT_SAVEPOINT"; - case 5: - return "TRANS_STMT_RELEASE"; - case 6: - return "TRANS_STMT_ROLLBACK_TO"; - case 7: - return "TRANS_STMT_PREPARE"; - case 8: - return "TRANS_STMT_COMMIT_PREPARED"; - case 9: - return "TRANS_STMT_ROLLBACK_PREPARED"; - default: - throw new Error("Value not recognized in enum TransactionStmtKind"); - } - }, - "ViewCheckOption": (value: number): string => { - switch (value) { - case 0: - return "NO_CHECK_OPTION"; - case 1: - return "LOCAL_CHECK_OPTION"; - case 2: - return "CASCADED_CHECK_OPTION"; - default: - throw new Error("Value not recognized in enum ViewCheckOption"); - } - }, - "DiscardMode": (value: number): string => { - switch (value) { - case 0: - return "DISCARD_ALL"; - case 1: - return "DISCARD_PLANS"; - case 2: - return "DISCARD_SEQUENCES"; - case 3: - return "DISCARD_TEMP"; - default: - throw new Error("Value not recognized in enum DiscardMode"); - } - }, - "ReindexObjectType": (value: number): string => { - switch (value) { - case 0: - return "REINDEX_OBJECT_INDEX"; - case 1: - return "REINDEX_OBJECT_TABLE"; - case 2: - return "REINDEX_OBJECT_SCHEMA"; - case 3: - return "REINDEX_OBJECT_SYSTEM"; - case 4: - return "REINDEX_OBJECT_DATABASE"; - default: - throw new Error("Value not recognized in enum ReindexObjectType"); - } - }, - "AlterTSConfigType": (value: number): string => { - switch (value) { - case 0: - return "ALTER_TSCONFIG_ADD_MAPPING"; - case 1: - return "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN"; - case 2: - return "ALTER_TSCONFIG_REPLACE_DICT"; - case 3: - return "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN"; - case 4: - return "ALTER_TSCONFIG_DROP_MAPPING"; - default: - throw new Error("Value not recognized in enum AlterTSConfigType"); - } - }, - "PublicationObjSpecType": (value: number): string => { - switch (value) { - case 0: - return "PUBLICATIONOBJ_TABLE"; - case 1: - return "PUBLICATIONOBJ_TABLES_IN_SCHEMA"; - case 2: - return "PUBLICATIONOBJ_TABLES_IN_CUR_SCHEMA"; - case 3: - return "PUBLICATIONOBJ_CONTINUATION"; - default: - throw new Error("Value not recognized in enum PublicationObjSpecType"); - } - }, - "AlterPublicationAction": (value: number): string => { - switch (value) { - case 0: - return "AP_AddObjects"; - case 1: - return "AP_DropObjects"; - case 2: - return "AP_SetObjects"; - default: - throw new Error("Value not recognized in enum AlterPublicationAction"); - } - }, - "AlterSubscriptionType": (value: number): string => { - switch (value) { - case 0: - return "ALTER_SUBSCRIPTION_OPTIONS"; - case 1: - return "ALTER_SUBSCRIPTION_CONNECTION"; - case 2: - return "ALTER_SUBSCRIPTION_SET_PUBLICATION"; - case 3: - return "ALTER_SUBSCRIPTION_ADD_PUBLICATION"; - case 4: - return "ALTER_SUBSCRIPTION_DROP_PUBLICATION"; - case 5: - return "ALTER_SUBSCRIPTION_REFRESH"; - case 6: - return "ALTER_SUBSCRIPTION_ENABLED"; - case 7: - return "ALTER_SUBSCRIPTION_SKIP"; - default: - throw new Error("Value not recognized in enum AlterSubscriptionType"); - } - }, - "OnCommitAction": (value: number): string => { - switch (value) { - case 0: - return "ONCOMMIT_NOOP"; - case 1: - return "ONCOMMIT_PRESERVE_ROWS"; - case 2: - return "ONCOMMIT_DELETE_ROWS"; - case 3: - return "ONCOMMIT_DROP"; - default: - throw new Error("Value not recognized in enum OnCommitAction"); - } - }, - "ParamKind": (value: number): string => { - switch (value) { - case 0: - return "PARAM_EXTERN"; - case 1: - return "PARAM_EXEC"; - case 2: - return "PARAM_SUBLINK"; - case 3: - return "PARAM_MULTIEXPR"; - default: - throw new Error("Value not recognized in enum ParamKind"); - } - }, - "CoercionContext": (value: number): string => { - switch (value) { - case 0: - return "COERCION_IMPLICIT"; - case 1: - return "COERCION_ASSIGNMENT"; - case 2: - return "COERCION_PLPGSQL"; - case 3: - return "COERCION_EXPLICIT"; - default: - throw new Error("Value not recognized in enum CoercionContext"); - } - }, - "CoercionForm": (value: number): string => { - switch (value) { - case 0: - return "COERCE_EXPLICIT_CALL"; - case 1: - return "COERCE_EXPLICIT_CAST"; - case 2: - return "COERCE_IMPLICIT_CAST"; - case 3: - return "COERCE_SQL_SYNTAX"; - default: - throw new Error("Value not recognized in enum CoercionForm"); - } - }, - "BoolExprType": (value: number): string => { - switch (value) { - case 0: - return "AND_EXPR"; - case 1: - return "OR_EXPR"; - case 2: - return "NOT_EXPR"; - default: - throw new Error("Value not recognized in enum BoolExprType"); - } - }, - "SubLinkType": (value: number): string => { - switch (value) { - case 0: - return "EXISTS_SUBLINK"; - case 1: - return "ALL_SUBLINK"; - case 2: - return "ANY_SUBLINK"; - case 3: - return "ROWCOMPARE_SUBLINK"; - case 4: - return "EXPR_SUBLINK"; - case 5: - return "MULTIEXPR_SUBLINK"; - case 6: - return "ARRAY_SUBLINK"; - case 7: - return "CTE_SUBLINK"; - default: - throw new Error("Value not recognized in enum SubLinkType"); - } - }, - "RowCompareType": (value: number): string => { - switch (value) { - case 0: - return "ROWCOMPARE_LT"; - case 1: - return "ROWCOMPARE_LE"; - case 2: - return "ROWCOMPARE_EQ"; - case 3: - return "ROWCOMPARE_GE"; - case 4: - return "ROWCOMPARE_GT"; - case 5: - return "ROWCOMPARE_NE"; - default: - throw new Error("Value not recognized in enum RowCompareType"); - } - }, - "MinMaxOp": (value: number): string => { - switch (value) { - case 0: - return "IS_GREATEST"; - case 1: - return "IS_LEAST"; - default: - throw new Error("Value not recognized in enum MinMaxOp"); - } - }, - "SQLValueFunctionOp": (value: number): string => { - switch (value) { - case 0: - return "SVFOP_CURRENT_DATE"; - case 1: - return "SVFOP_CURRENT_TIME"; - case 2: - return "SVFOP_CURRENT_TIME_N"; - case 3: - return "SVFOP_CURRENT_TIMESTAMP"; - case 4: - return "SVFOP_CURRENT_TIMESTAMP_N"; - case 5: - return "SVFOP_LOCALTIME"; - case 6: - return "SVFOP_LOCALTIME_N"; - case 7: - return "SVFOP_LOCALTIMESTAMP"; - case 8: - return "SVFOP_LOCALTIMESTAMP_N"; - case 9: - return "SVFOP_CURRENT_ROLE"; - case 10: - return "SVFOP_CURRENT_USER"; - case 11: - return "SVFOP_USER"; - case 12: - return "SVFOP_SESSION_USER"; - case 13: - return "SVFOP_CURRENT_CATALOG"; - case 14: - return "SVFOP_CURRENT_SCHEMA"; - default: - throw new Error("Value not recognized in enum SQLValueFunctionOp"); - } - }, - "XmlExprOp": (value: number): string => { - switch (value) { - case 0: - return "IS_XMLCONCAT"; - case 1: - return "IS_XMLELEMENT"; - case 2: - return "IS_XMLFOREST"; - case 3: - return "IS_XMLPARSE"; - case 4: - return "IS_XMLPI"; - case 5: - return "IS_XMLROOT"; - case 6: - return "IS_XMLSERIALIZE"; - case 7: - return "IS_DOCUMENT"; - default: - throw new Error("Value not recognized in enum XmlExprOp"); - } - }, - "XmlOptionType": (value: number): string => { - switch (value) { - case 0: - return "XMLOPTION_DOCUMENT"; - case 1: - return "XMLOPTION_CONTENT"; - default: - throw new Error("Value not recognized in enum XmlOptionType"); - } - }, - "JsonEncoding": (value: number): string => { - switch (value) { - case 0: - return "JS_ENC_DEFAULT"; - case 1: - return "JS_ENC_UTF8"; - case 2: - return "JS_ENC_UTF16"; - case 3: - return "JS_ENC_UTF32"; - default: - throw new Error("Value not recognized in enum JsonEncoding"); - } - }, - "JsonFormatType": (value: number): string => { - switch (value) { - case 0: - return "JS_FORMAT_DEFAULT"; - case 1: - return "JS_FORMAT_JSON"; - case 2: - return "JS_FORMAT_JSONB"; - default: - throw new Error("Value not recognized in enum JsonFormatType"); - } - }, - "JsonConstructorType": (value: number): string => { - switch (value) { - case 0: - return "JSCTOR_JSON_OBJECT"; - case 1: - return "JSCTOR_JSON_ARRAY"; - case 2: - return "JSCTOR_JSON_OBJECTAGG"; - case 3: - return "JSCTOR_JSON_ARRAYAGG"; - default: - throw new Error("Value not recognized in enum JsonConstructorType"); - } - }, - "JsonValueType": (value: number): string => { - switch (value) { - case 0: - return "JS_TYPE_ANY"; - case 1: - return "JS_TYPE_OBJECT"; - case 2: - return "JS_TYPE_ARRAY"; - case 3: - return "JS_TYPE_SCALAR"; - default: - throw new Error("Value not recognized in enum JsonValueType"); - } - }, - "NullTestType": (value: number): string => { - switch (value) { - case 0: - return "IS_NULL"; - case 1: - return "IS_NOT_NULL"; - default: - throw new Error("Value not recognized in enum NullTestType"); - } - }, - "BoolTestType": (value: number): string => { - switch (value) { - case 0: - return "IS_TRUE"; - case 1: - return "IS_NOT_TRUE"; - case 2: - return "IS_FALSE"; - case 3: - return "IS_NOT_FALSE"; - case 4: - return "IS_UNKNOWN"; - case 5: - return "IS_NOT_UNKNOWN"; - default: - throw new Error("Value not recognized in enum BoolTestType"); - } - }, - "CmdType": (value: number): string => { - switch (value) { - case 0: - return "CMD_UNKNOWN"; - case 1: - return "CMD_SELECT"; - case 2: - return "CMD_UPDATE"; - case 3: - return "CMD_INSERT"; - case 4: - return "CMD_DELETE"; - case 5: - return "CMD_MERGE"; - case 6: - return "CMD_UTILITY"; - case 7: - return "CMD_NOTHING"; - default: - throw new Error("Value not recognized in enum CmdType"); - } - }, - "JoinType": (value: number): string => { - switch (value) { - case 0: - return "JOIN_INNER"; - case 1: - return "JOIN_LEFT"; - case 2: - return "JOIN_FULL"; - case 3: - return "JOIN_RIGHT"; - case 4: - return "JOIN_SEMI"; - case 5: - return "JOIN_ANTI"; - case 6: - return "JOIN_RIGHT_ANTI"; - case 7: - return "JOIN_UNIQUE_OUTER"; - case 8: - return "JOIN_UNIQUE_INNER"; - default: - throw new Error("Value not recognized in enum JoinType"); - } - }, - "AggStrategy": (value: number): string => { - switch (value) { - case 0: - return "AGG_PLAIN"; - case 1: - return "AGG_SORTED"; - case 2: - return "AGG_HASHED"; - case 3: - return "AGG_MIXED"; - default: - throw new Error("Value not recognized in enum AggStrategy"); - } - }, - "AggSplit": (value: number): string => { - switch (value) { - case 0: - return "AGGSPLIT_SIMPLE"; - case 1: - return "AGGSPLIT_INITIAL_SERIAL"; - case 2: - return "AGGSPLIT_FINAL_DESERIAL"; - default: - throw new Error("Value not recognized in enum AggSplit"); - } - }, - "SetOpCmd": (value: number): string => { - switch (value) { - case 0: - return "SETOPCMD_INTERSECT"; - case 1: - return "SETOPCMD_INTERSECT_ALL"; - case 2: - return "SETOPCMD_EXCEPT"; - case 3: - return "SETOPCMD_EXCEPT_ALL"; - default: - throw new Error("Value not recognized in enum SetOpCmd"); - } - }, - "SetOpStrategy": (value: number): string => { - switch (value) { - case 0: - return "SETOP_SORTED"; - case 1: - return "SETOP_HASHED"; - default: - throw new Error("Value not recognized in enum SetOpStrategy"); - } - }, - "OnConflictAction": (value: number): string => { - switch (value) { - case 0: - return "ONCONFLICT_NONE"; - case 1: - return "ONCONFLICT_NOTHING"; - case 2: - return "ONCONFLICT_UPDATE"; - default: - throw new Error("Value not recognized in enum OnConflictAction"); - } - }, - "LimitOption": (value: number): string => { - switch (value) { - case 0: - return "LIMIT_OPTION_DEFAULT"; - case 1: - return "LIMIT_OPTION_COUNT"; - case 2: - return "LIMIT_OPTION_WITH_TIES"; - default: - throw new Error("Value not recognized in enum LimitOption"); - } - }, - "LockClauseStrength": (value: number): string => { - switch (value) { - case 0: - return "LCS_NONE"; - case 1: - return "LCS_FORKEYSHARE"; - case 2: - return "LCS_FORSHARE"; - case 3: - return "LCS_FORNOKEYUPDATE"; - case 4: - return "LCS_FORUPDATE"; - default: - throw new Error("Value not recognized in enum LockClauseStrength"); - } - }, - "LockWaitPolicy": (value: number): string => { - switch (value) { - case 0: - return "LockWaitBlock"; - case 1: - return "LockWaitSkip"; - case 2: - return "LockWaitError"; - default: - throw new Error("Value not recognized in enum LockWaitPolicy"); - } - }, - "LockTupleMode": (value: number): string => { - switch (value) { - case 0: - return "LockTupleKeyShare"; - case 1: - return "LockTupleShare"; - case 2: - return "LockTupleNoKeyExclusive"; - case 3: - return "LockTupleExclusive"; - default: - throw new Error("Value not recognized in enum LockTupleMode"); - } - }, - "KeywordKind": (value: number): string => { - switch (value) { - case 0: - return "NO_KEYWORD"; - case 1: - return "UNRESERVED_KEYWORD"; - case 2: - return "COL_NAME_KEYWORD"; - case 3: - return "TYPE_FUNC_NAME_KEYWORD"; - case 4: - return "RESERVED_KEYWORD"; - default: - throw new Error("Value not recognized in enum KeywordKind"); - } - }, - "Token": (value: number): string => { - switch (value) { - case 0: - return "NUL"; - case 36: - return "ASCII_36"; - case 37: - return "ASCII_37"; - case 40: - return "ASCII_40"; - case 41: - return "ASCII_41"; - case 42: - return "ASCII_42"; - case 43: - return "ASCII_43"; - case 44: - return "ASCII_44"; - case 45: - return "ASCII_45"; - case 46: - return "ASCII_46"; - case 47: - return "ASCII_47"; - case 58: - return "ASCII_58"; - case 59: - return "ASCII_59"; - case 60: - return "ASCII_60"; - case 61: - return "ASCII_61"; - case 62: - return "ASCII_62"; - case 63: - return "ASCII_63"; - case 91: - return "ASCII_91"; - case 92: - return "ASCII_92"; - case 93: - return "ASCII_93"; - case 94: - return "ASCII_94"; - case 258: - return "IDENT"; - case 259: - return "UIDENT"; - case 260: - return "FCONST"; - case 261: - return "SCONST"; - case 262: - return "USCONST"; - case 263: - return "BCONST"; - case 264: - return "XCONST"; - case 265: - return "Op"; - case 266: - return "ICONST"; - case 267: - return "PARAM"; - case 268: - return "TYPECAST"; - case 269: - return "DOT_DOT"; - case 270: - return "COLON_EQUALS"; - case 271: - return "EQUALS_GREATER"; - case 272: - return "LESS_EQUALS"; - case 273: - return "GREATER_EQUALS"; - case 274: - return "NOT_EQUALS"; - case 275: - return "SQL_COMMENT"; - case 276: - return "C_COMMENT"; - case 277: - return "ABORT_P"; - case 278: - return "ABSENT"; - case 279: - return "ABSOLUTE_P"; - case 280: - return "ACCESS"; - case 281: - return "ACTION"; - case 282: - return "ADD_P"; - case 283: - return "ADMIN"; - case 284: - return "AFTER"; - case 285: - return "AGGREGATE"; - case 286: - return "ALL"; - case 287: - return "ALSO"; - case 288: - return "ALTER"; - case 289: - return "ALWAYS"; - case 290: - return "ANALYSE"; - case 291: - return "ANALYZE"; - case 292: - return "AND"; - case 293: - return "ANY"; - case 294: - return "ARRAY"; - case 295: - return "AS"; - case 296: - return "ASC"; - case 297: - return "ASENSITIVE"; - case 298: - return "ASSERTION"; - case 299: - return "ASSIGNMENT"; - case 300: - return "ASYMMETRIC"; - case 301: - return "ATOMIC"; - case 302: - return "AT"; - case 303: - return "ATTACH"; - case 304: - return "ATTRIBUTE"; - case 305: - return "AUTHORIZATION"; - case 306: - return "BACKWARD"; - case 307: - return "BEFORE"; - case 308: - return "BEGIN_P"; - case 309: - return "BETWEEN"; - case 310: - return "BIGINT"; - case 311: - return "BINARY"; - case 312: - return "BIT"; - case 313: - return "BOOLEAN_P"; - case 314: - return "BOTH"; - case 315: - return "BREADTH"; - case 316: - return "BY"; - case 317: - return "CACHE"; - case 318: - return "CALL"; - case 319: - return "CALLED"; - case 320: - return "CASCADE"; - case 321: - return "CASCADED"; - case 322: - return "CASE"; - case 323: - return "CAST"; - case 324: - return "CATALOG_P"; - case 325: - return "CHAIN"; - case 326: - return "CHAR_P"; - case 327: - return "CHARACTER"; - case 328: - return "CHARACTERISTICS"; - case 329: - return "CHECK"; - case 330: - return "CHECKPOINT"; - case 331: - return "CLASS"; - case 332: - return "CLOSE"; - case 333: - return "CLUSTER"; - case 334: - return "COALESCE"; - case 335: - return "COLLATE"; - case 336: - return "COLLATION"; - case 337: - return "COLUMN"; - case 338: - return "COLUMNS"; - case 339: - return "COMMENT"; - case 340: - return "COMMENTS"; - case 341: - return "COMMIT"; - case 342: - return "COMMITTED"; - case 343: - return "COMPRESSION"; - case 344: - return "CONCURRENTLY"; - case 345: - return "CONFIGURATION"; - case 346: - return "CONFLICT"; - case 347: - return "CONNECTION"; - case 348: - return "CONSTRAINT"; - case 349: - return "CONSTRAINTS"; - case 350: - return "CONTENT_P"; - case 351: - return "CONTINUE_P"; - case 352: - return "CONVERSION_P"; - case 353: - return "COPY"; - case 354: - return "COST"; - case 355: - return "CREATE"; - case 356: - return "CROSS"; - case 357: - return "CSV"; - case 358: - return "CUBE"; - case 359: - return "CURRENT_P"; - case 360: - return "CURRENT_CATALOG"; - case 361: - return "CURRENT_DATE"; - case 362: - return "CURRENT_ROLE"; - case 363: - return "CURRENT_SCHEMA"; - case 364: - return "CURRENT_TIME"; - case 365: - return "CURRENT_TIMESTAMP"; - case 366: - return "CURRENT_USER"; - case 367: - return "CURSOR"; - case 368: - return "CYCLE"; - case 369: - return "DATA_P"; - case 370: - return "DATABASE"; - case 371: - return "DAY_P"; - case 372: - return "DEALLOCATE"; - case 373: - return "DEC"; - case 374: - return "DECIMAL_P"; - case 375: - return "DECLARE"; - case 376: - return "DEFAULT"; - case 377: - return "DEFAULTS"; - case 378: - return "DEFERRABLE"; - case 379: - return "DEFERRED"; - case 380: - return "DEFINER"; - case 381: - return "DELETE_P"; - case 382: - return "DELIMITER"; - case 383: - return "DELIMITERS"; - case 384: - return "DEPENDS"; - case 385: - return "DEPTH"; - case 386: - return "DESC"; - case 387: - return "DETACH"; - case 388: - return "DICTIONARY"; - case 389: - return "DISABLE_P"; - case 390: - return "DISCARD"; - case 391: - return "DISTINCT"; - case 392: - return "DO"; - case 393: - return "DOCUMENT_P"; - case 394: - return "DOMAIN_P"; - case 395: - return "DOUBLE_P"; - case 396: - return "DROP"; - case 397: - return "EACH"; - case 398: - return "ELSE"; - case 399: - return "ENABLE_P"; - case 400: - return "ENCODING"; - case 401: - return "ENCRYPTED"; - case 402: - return "END_P"; - case 403: - return "ENUM_P"; - case 404: - return "ESCAPE"; - case 405: - return "EVENT"; - case 406: - return "EXCEPT"; - case 407: - return "EXCLUDE"; - case 408: - return "EXCLUDING"; - case 409: - return "EXCLUSIVE"; - case 410: - return "EXECUTE"; - case 411: - return "EXISTS"; - case 412: - return "EXPLAIN"; - case 413: - return "EXPRESSION"; - case 414: - return "EXTENSION"; - case 415: - return "EXTERNAL"; - case 416: - return "EXTRACT"; - case 417: - return "FALSE_P"; - case 418: - return "FAMILY"; - case 419: - return "FETCH"; - case 420: - return "FILTER"; - case 421: - return "FINALIZE"; - case 422: - return "FIRST_P"; - case 423: - return "FLOAT_P"; - case 424: - return "FOLLOWING"; - case 425: - return "FOR"; - case 426: - return "FORCE"; - case 427: - return "FOREIGN"; - case 428: - return "FORMAT"; - case 429: - return "FORWARD"; - case 430: - return "FREEZE"; - case 431: - return "FROM"; - case 432: - return "FULL"; - case 433: - return "FUNCTION"; - case 434: - return "FUNCTIONS"; - case 435: - return "GENERATED"; - case 436: - return "GLOBAL"; - case 437: - return "GRANT"; - case 438: - return "GRANTED"; - case 439: - return "GREATEST"; - case 440: - return "GROUP_P"; - case 441: - return "GROUPING"; - case 442: - return "GROUPS"; - case 443: - return "HANDLER"; - case 444: - return "HAVING"; - case 445: - return "HEADER_P"; - case 446: - return "HOLD"; - case 447: - return "HOUR_P"; - case 448: - return "IDENTITY_P"; - case 449: - return "IF_P"; - case 450: - return "ILIKE"; - case 451: - return "IMMEDIATE"; - case 452: - return "IMMUTABLE"; - case 453: - return "IMPLICIT_P"; - case 454: - return "IMPORT_P"; - case 455: - return "IN_P"; - case 456: - return "INCLUDE"; - case 457: - return "INCLUDING"; - case 458: - return "INCREMENT"; - case 459: - return "INDENT"; - case 460: - return "INDEX"; - case 461: - return "INDEXES"; - case 462: - return "INHERIT"; - case 463: - return "INHERITS"; - case 464: - return "INITIALLY"; - case 465: - return "INLINE_P"; - case 466: - return "INNER_P"; - case 467: - return "INOUT"; - case 468: - return "INPUT_P"; - case 469: - return "INSENSITIVE"; - case 470: - return "INSERT"; - case 471: - return "INSTEAD"; - case 472: - return "INT_P"; - case 473: - return "INTEGER"; - case 474: - return "INTERSECT"; - case 475: - return "INTERVAL"; - case 476: - return "INTO"; - case 477: - return "INVOKER"; - case 478: - return "IS"; - case 479: - return "ISNULL"; - case 480: - return "ISOLATION"; - case 481: - return "JOIN"; - case 482: - return "JSON"; - case 483: - return "JSON_ARRAY"; - case 484: - return "JSON_ARRAYAGG"; - case 485: - return "JSON_OBJECT"; - case 486: - return "JSON_OBJECTAGG"; - case 487: - return "KEY"; - case 488: - return "KEYS"; - case 489: - return "LABEL"; - case 490: - return "LANGUAGE"; - case 491: - return "LARGE_P"; - case 492: - return "LAST_P"; - case 493: - return "LATERAL_P"; - case 494: - return "LEADING"; - case 495: - return "LEAKPROOF"; - case 496: - return "LEAST"; - case 497: - return "LEFT"; - case 498: - return "LEVEL"; - case 499: - return "LIKE"; - case 500: - return "LIMIT"; - case 501: - return "LISTEN"; - case 502: - return "LOAD"; - case 503: - return "LOCAL"; - case 504: - return "LOCALTIME"; - case 505: - return "LOCALTIMESTAMP"; - case 506: - return "LOCATION"; - case 507: - return "LOCK_P"; - case 508: - return "LOCKED"; - case 509: - return "LOGGED"; - case 510: - return "MAPPING"; - case 511: - return "MATCH"; - case 512: - return "MATCHED"; - case 513: - return "MATERIALIZED"; - case 514: - return "MAXVALUE"; - case 515: - return "MERGE"; - case 516: - return "METHOD"; - case 517: - return "MINUTE_P"; - case 518: - return "MINVALUE"; - case 519: - return "MODE"; - case 520: - return "MONTH_P"; - case 521: - return "MOVE"; - case 522: - return "NAME_P"; - case 523: - return "NAMES"; - case 524: - return "NATIONAL"; - case 525: - return "NATURAL"; - case 526: - return "NCHAR"; - case 527: - return "NEW"; - case 528: - return "NEXT"; - case 529: - return "NFC"; - case 530: - return "NFD"; - case 531: - return "NFKC"; - case 532: - return "NFKD"; - case 533: - return "NO"; - case 534: - return "NONE"; - case 535: - return "NORMALIZE"; - case 536: - return "NORMALIZED"; - case 537: - return "NOT"; - case 538: - return "NOTHING"; - case 539: - return "NOTIFY"; - case 540: - return "NOTNULL"; - case 541: - return "NOWAIT"; - case 542: - return "NULL_P"; - case 543: - return "NULLIF"; - case 544: - return "NULLS_P"; - case 545: - return "NUMERIC"; - case 546: - return "OBJECT_P"; - case 547: - return "OF"; - case 548: - return "OFF"; - case 549: - return "OFFSET"; - case 550: - return "OIDS"; - case 551: - return "OLD"; - case 552: - return "ON"; - case 553: - return "ONLY"; - case 554: - return "OPERATOR"; - case 555: - return "OPTION"; - case 556: - return "OPTIONS"; - case 557: - return "OR"; - case 558: - return "ORDER"; - case 559: - return "ORDINALITY"; - case 560: - return "OTHERS"; - case 561: - return "OUT_P"; - case 562: - return "OUTER_P"; - case 563: - return "OVER"; - case 564: - return "OVERLAPS"; - case 565: - return "OVERLAY"; - case 566: - return "OVERRIDING"; - case 567: - return "OWNED"; - case 568: - return "OWNER"; - case 569: - return "PARALLEL"; - case 570: - return "PARAMETER"; - case 571: - return "PARSER"; - case 572: - return "PARTIAL"; - case 573: - return "PARTITION"; - case 574: - return "PASSING"; - case 575: - return "PASSWORD"; - case 576: - return "PLACING"; - case 577: - return "PLANS"; - case 578: - return "POLICY"; - case 579: - return "POSITION"; - case 580: - return "PRECEDING"; - case 581: - return "PRECISION"; - case 582: - return "PRESERVE"; - case 583: - return "PREPARE"; - case 584: - return "PREPARED"; - case 585: - return "PRIMARY"; - case 586: - return "PRIOR"; - case 587: - return "PRIVILEGES"; - case 588: - return "PROCEDURAL"; - case 589: - return "PROCEDURE"; - case 590: - return "PROCEDURES"; - case 591: - return "PROGRAM"; - case 592: - return "PUBLICATION"; - case 593: - return "QUOTE"; - case 594: - return "RANGE"; - case 595: - return "READ"; - case 596: - return "REAL"; - case 597: - return "REASSIGN"; - case 598: - return "RECHECK"; - case 599: - return "RECURSIVE"; - case 600: - return "REF_P"; - case 601: - return "REFERENCES"; - case 602: - return "REFERENCING"; - case 603: - return "REFRESH"; - case 604: - return "REINDEX"; - case 605: - return "RELATIVE_P"; - case 606: - return "RELEASE"; - case 607: - return "RENAME"; - case 608: - return "REPEATABLE"; - case 609: - return "REPLACE"; - case 610: - return "REPLICA"; - case 611: - return "RESET"; - case 612: - return "RESTART"; - case 613: - return "RESTRICT"; - case 614: - return "RETURN"; - case 615: - return "RETURNING"; - case 616: - return "RETURNS"; - case 617: - return "REVOKE"; - case 618: - return "RIGHT"; - case 619: - return "ROLE"; - case 620: - return "ROLLBACK"; - case 621: - return "ROLLUP"; - case 622: - return "ROUTINE"; - case 623: - return "ROUTINES"; - case 624: - return "ROW"; - case 625: - return "ROWS"; - case 626: - return "RULE"; - case 627: - return "SAVEPOINT"; - case 628: - return "SCALAR"; - case 629: - return "SCHEMA"; - case 630: - return "SCHEMAS"; - case 631: - return "SCROLL"; - case 632: - return "SEARCH"; - case 633: - return "SECOND_P"; - case 634: - return "SECURITY"; - case 635: - return "SELECT"; - case 636: - return "SEQUENCE"; - case 637: - return "SEQUENCES"; - case 638: - return "SERIALIZABLE"; - case 639: - return "SERVER"; - case 640: - return "SESSION"; - case 641: - return "SESSION_USER"; - case 642: - return "SET"; - case 643: - return "SETS"; - case 644: - return "SETOF"; - case 645: - return "SHARE"; - case 646: - return "SHOW"; - case 647: - return "SIMILAR"; - case 648: - return "SIMPLE"; - case 649: - return "SKIP"; - case 650: - return "SMALLINT"; - case 651: - return "SNAPSHOT"; - case 652: - return "SOME"; - case 653: - return "SQL_P"; - case 654: - return "STABLE"; - case 655: - return "STANDALONE_P"; - case 656: - return "START"; - case 657: - return "STATEMENT"; - case 658: - return "STATISTICS"; - case 659: - return "STDIN"; - case 660: - return "STDOUT"; - case 661: - return "STORAGE"; - case 662: - return "STORED"; - case 663: - return "STRICT_P"; - case 664: - return "STRIP_P"; - case 665: - return "SUBSCRIPTION"; - case 666: - return "SUBSTRING"; - case 667: - return "SUPPORT"; - case 668: - return "SYMMETRIC"; - case 669: - return "SYSID"; - case 670: - return "SYSTEM_P"; - case 671: - return "SYSTEM_USER"; - case 672: - return "TABLE"; - case 673: - return "TABLES"; - case 674: - return "TABLESAMPLE"; - case 675: - return "TABLESPACE"; - case 676: - return "TEMP"; - case 677: - return "TEMPLATE"; - case 678: - return "TEMPORARY"; - case 679: - return "TEXT_P"; - case 680: - return "THEN"; - case 681: - return "TIES"; - case 682: - return "TIME"; - case 683: - return "TIMESTAMP"; - case 684: - return "TO"; - case 685: - return "TRAILING"; - case 686: - return "TRANSACTION"; - case 687: - return "TRANSFORM"; - case 688: - return "TREAT"; - case 689: - return "TRIGGER"; - case 690: - return "TRIM"; - case 691: - return "TRUE_P"; - case 692: - return "TRUNCATE"; - case 693: - return "TRUSTED"; - case 694: - return "TYPE_P"; - case 695: - return "TYPES_P"; - case 696: - return "UESCAPE"; - case 697: - return "UNBOUNDED"; - case 698: - return "UNCOMMITTED"; - case 699: - return "UNENCRYPTED"; - case 700: - return "UNION"; - case 701: - return "UNIQUE"; - case 702: - return "UNKNOWN"; - case 703: - return "UNLISTEN"; - case 704: - return "UNLOGGED"; - case 705: - return "UNTIL"; - case 706: - return "UPDATE"; - case 707: - return "USER"; - case 708: - return "USING"; - case 709: - return "VACUUM"; - case 710: - return "VALID"; - case 711: - return "VALIDATE"; - case 712: - return "VALIDATOR"; - case 713: - return "VALUE_P"; - case 714: - return "VALUES"; - case 715: - return "VARCHAR"; - case 716: - return "VARIADIC"; - case 717: - return "VARYING"; - case 718: - return "VERBOSE"; - case 719: - return "VERSION_P"; - case 720: - return "VIEW"; - case 721: - return "VIEWS"; - case 722: - return "VOLATILE"; - case 723: - return "WHEN"; - case 724: - return "WHERE"; - case 725: - return "WHITESPACE_P"; - case 726: - return "WINDOW"; - case 727: - return "WITH"; - case 728: - return "WITHIN"; - case 729: - return "WITHOUT"; - case 730: - return "WORK"; - case 731: - return "WRAPPER"; - case 732: - return "WRITE"; - case 733: - return "XML_P"; - case 734: - return "XMLATTRIBUTES"; - case 735: - return "XMLCONCAT"; - case 736: - return "XMLELEMENT"; - case 737: - return "XMLEXISTS"; - case 738: - return "XMLFOREST"; - case 739: - return "XMLNAMESPACES"; - case 740: - return "XMLPARSE"; - case 741: - return "XMLPI"; - case 742: - return "XMLROOT"; - case 743: - return "XMLSERIALIZE"; - case 744: - return "XMLTABLE"; - case 745: - return "YEAR_P"; - case 746: - return "YES_P"; - case 747: - return "ZONE"; - case 748: - return "FORMAT_LA"; - case 749: - return "NOT_LA"; - case 750: - return "NULLS_LA"; - case 751: - return "WITH_LA"; - case 752: - return "WITHOUT_LA"; - case 753: - return "MODE_TYPE_NAME"; - case 754: - return "MODE_PLPGSQL_EXPR"; - case 755: - return "MODE_PLPGSQL_ASSIGN1"; - case 756: - return "MODE_PLPGSQL_ASSIGN2"; - case 757: - return "MODE_PLPGSQL_ASSIGN3"; - case 758: - return "UMINUS"; - default: - throw new Error("Value not recognized in enum Token"); - } - } -};", - "file": "enum-to-string-nested.ts", - }, - { - "code": "/** -* This file was automatically generated by pg-proto-parser@latest. -* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, -* and run the pg-proto-parser generate command to regenerate this file. -*/ -export type EnumType = "OverridingKind" | "QuerySource" | "SortByDir" | "SortByNulls" | "SetQuantifier" | "A_Expr_Kind" | "RoleSpecType" | "TableLikeOption" | "DefElemAction" | "PartitionStrategy" | "PartitionRangeDatumKind" | "RTEKind" | "WCOKind" | "GroupingSetKind" | "CTEMaterialize" | "SetOperation" | "ObjectType" | "DropBehavior" | "AlterTableType" | "GrantTargetType" | "VariableSetKind" | "ConstrType" | "ImportForeignSchemaType" | "RoleStmtType" | "FetchDirection" | "FunctionParameterMode" | "TransactionStmtKind" | "ViewCheckOption" | "DiscardMode" | "ReindexObjectType" | "AlterTSConfigType" | "PublicationObjSpecType" | "AlterPublicationAction" | "AlterSubscriptionType" | "OnCommitAction" | "ParamKind" | "CoercionContext" | "CoercionForm" | "BoolExprType" | "SubLinkType" | "RowCompareType" | "MinMaxOp" | "SQLValueFunctionOp" | "XmlExprOp" | "XmlOptionType" | "JsonEncoding" | "JsonFormatType" | "JsonConstructorType" | "JsonValueType" | "NullTestType" | "BoolTestType" | "CmdType" | "JoinType" | "AggStrategy" | "AggSplit" | "SetOpCmd" | "SetOpStrategy" | "OnConflictAction" | "LimitOption" | "LockClauseStrength" | "LockWaitPolicy" | "LockTupleMode" | "KeywordKind" | "Token"; -export type EnumToIntMap = { - "OverridingKind": (key: string) => number; - "QuerySource": (key: string) => number; - "SortByDir": (key: string) => number; - "SortByNulls": (key: string) => number; - "SetQuantifier": (key: string) => number; - "A_Expr_Kind": (key: string) => number; - "RoleSpecType": (key: string) => number; - "TableLikeOption": (key: string) => number; - "DefElemAction": (key: string) => number; - "PartitionStrategy": (key: string) => number; - "PartitionRangeDatumKind": (key: string) => number; - "RTEKind": (key: string) => number; - "WCOKind": (key: string) => number; - "GroupingSetKind": (key: string) => number; - "CTEMaterialize": (key: string) => number; - "SetOperation": (key: string) => number; - "ObjectType": (key: string) => number; - "DropBehavior": (key: string) => number; - "AlterTableType": (key: string) => number; - "GrantTargetType": (key: string) => number; - "VariableSetKind": (key: string) => number; - "ConstrType": (key: string) => number; - "ImportForeignSchemaType": (key: string) => number; - "RoleStmtType": (key: string) => number; - "FetchDirection": (key: string) => number; - "FunctionParameterMode": (key: string) => number; - "TransactionStmtKind": (key: string) => number; - "ViewCheckOption": (key: string) => number; - "DiscardMode": (key: string) => number; - "ReindexObjectType": (key: string) => number; - "AlterTSConfigType": (key: string) => number; - "PublicationObjSpecType": (key: string) => number; - "AlterPublicationAction": (key: string) => number; - "AlterSubscriptionType": (key: string) => number; - "OnCommitAction": (key: string) => number; - "ParamKind": (key: string) => number; - "CoercionContext": (key: string) => number; - "CoercionForm": (key: string) => number; - "BoolExprType": (key: string) => number; - "SubLinkType": (key: string) => number; - "RowCompareType": (key: string) => number; - "MinMaxOp": (key: string) => number; - "SQLValueFunctionOp": (key: string) => number; - "XmlExprOp": (key: string) => number; - "XmlOptionType": (key: string) => number; - "JsonEncoding": (key: string) => number; - "JsonFormatType": (key: string) => number; - "JsonConstructorType": (key: string) => number; - "JsonValueType": (key: string) => number; - "NullTestType": (key: string) => number; - "BoolTestType": (key: string) => number; - "CmdType": (key: string) => number; - "JoinType": (key: string) => number; - "AggStrategy": (key: string) => number; - "AggSplit": (key: string) => number; - "SetOpCmd": (key: string) => number; - "SetOpStrategy": (key: string) => number; - "OnConflictAction": (key: string) => number; - "LimitOption": (key: string) => number; - "LockClauseStrength": (key: string) => number; - "LockWaitPolicy": (key: string) => number; - "LockTupleMode": (key: string) => number; - "KeywordKind": (key: string) => number; - "Token": (key: string) => number; -}; -export const enumToIntMap: EnumToIntMap = { - "OverridingKind": (key: string): number => { - switch (key) { - case "OVERRIDING_NOT_SET": - return 0; - case "OVERRIDING_USER_VALUE": - return 1; - case "OVERRIDING_SYSTEM_VALUE": - return 2; - default: - throw new Error("Key not recognized in enum OverridingKind"); - } - }, - "QuerySource": (key: string): number => { - switch (key) { - case "QSRC_ORIGINAL": - return 0; - case "QSRC_PARSER": - return 1; - case "QSRC_INSTEAD_RULE": - return 2; - case "QSRC_QUAL_INSTEAD_RULE": - return 3; - case "QSRC_NON_INSTEAD_RULE": - return 4; - default: - throw new Error("Key not recognized in enum QuerySource"); - } - }, - "SortByDir": (key: string): number => { - switch (key) { - case "SORTBY_DEFAULT": - return 0; - case "SORTBY_ASC": - return 1; - case "SORTBY_DESC": - return 2; - case "SORTBY_USING": - return 3; - default: - throw new Error("Key not recognized in enum SortByDir"); - } - }, - "SortByNulls": (key: string): number => { - switch (key) { - case "SORTBY_NULLS_DEFAULT": - return 0; - case "SORTBY_NULLS_FIRST": - return 1; - case "SORTBY_NULLS_LAST": - return 2; - default: - throw new Error("Key not recognized in enum SortByNulls"); - } - }, - "SetQuantifier": (key: string): number => { - switch (key) { - case "SET_QUANTIFIER_DEFAULT": - return 0; - case "SET_QUANTIFIER_ALL": - return 1; - case "SET_QUANTIFIER_DISTINCT": - return 2; - default: - throw new Error("Key not recognized in enum SetQuantifier"); - } - }, - "A_Expr_Kind": (key: string): number => { - switch (key) { - case "AEXPR_OP": - return 0; - case "AEXPR_OP_ANY": - return 1; - case "AEXPR_OP_ALL": - return 2; - case "AEXPR_DISTINCT": - return 3; - case "AEXPR_NOT_DISTINCT": - return 4; - case "AEXPR_NULLIF": - return 5; - case "AEXPR_IN": - return 6; - case "AEXPR_LIKE": - return 7; - case "AEXPR_ILIKE": - return 8; - case "AEXPR_SIMILAR": - return 9; - case "AEXPR_BETWEEN": - return 10; - case "AEXPR_NOT_BETWEEN": - return 11; - case "AEXPR_BETWEEN_SYM": - return 12; - case "AEXPR_NOT_BETWEEN_SYM": - return 13; - default: - throw new Error("Key not recognized in enum A_Expr_Kind"); - } - }, - "RoleSpecType": (key: string): number => { - switch (key) { - case "ROLESPEC_CSTRING": - return 0; - case "ROLESPEC_CURRENT_ROLE": - return 1; - case "ROLESPEC_CURRENT_USER": - return 2; - case "ROLESPEC_SESSION_USER": - return 3; - case "ROLESPEC_PUBLIC": - return 4; - default: - throw new Error("Key not recognized in enum RoleSpecType"); - } - }, - "TableLikeOption": (key: string): number => { - switch (key) { - case "CREATE_TABLE_LIKE_COMMENTS": - return 0; - case "CREATE_TABLE_LIKE_COMPRESSION": - return 1; - case "CREATE_TABLE_LIKE_CONSTRAINTS": - return 2; - case "CREATE_TABLE_LIKE_DEFAULTS": - return 3; - case "CREATE_TABLE_LIKE_GENERATED": - return 4; - case "CREATE_TABLE_LIKE_IDENTITY": - return 5; - case "CREATE_TABLE_LIKE_INDEXES": - return 6; - case "CREATE_TABLE_LIKE_STATISTICS": - return 7; - case "CREATE_TABLE_LIKE_STORAGE": - return 8; - case "CREATE_TABLE_LIKE_ALL": - return 9; - default: - throw new Error("Key not recognized in enum TableLikeOption"); - } - }, - "DefElemAction": (key: string): number => { - switch (key) { - case "DEFELEM_UNSPEC": - return 0; - case "DEFELEM_SET": - return 1; - case "DEFELEM_ADD": - return 2; - case "DEFELEM_DROP": - return 3; - default: - throw new Error("Key not recognized in enum DefElemAction"); - } - }, - "PartitionStrategy": (key: string): number => { - switch (key) { - case "PARTITION_STRATEGY_LIST": - return 0; - case "PARTITION_STRATEGY_RANGE": - return 1; - case "PARTITION_STRATEGY_HASH": - return 2; - default: - throw new Error("Key not recognized in enum PartitionStrategy"); - } - }, - "PartitionRangeDatumKind": (key: string): number => { - switch (key) { - case "PARTITION_RANGE_DATUM_MINVALUE": - return 0; - case "PARTITION_RANGE_DATUM_VALUE": - return 1; - case "PARTITION_RANGE_DATUM_MAXVALUE": - return 2; - default: - throw new Error("Key not recognized in enum PartitionRangeDatumKind"); - } - }, - "RTEKind": (key: string): number => { - switch (key) { - case "RTE_RELATION": - return 0; - case "RTE_SUBQUERY": - return 1; - case "RTE_JOIN": - return 2; - case "RTE_FUNCTION": - return 3; - case "RTE_TABLEFUNC": - return 4; - case "RTE_VALUES": - return 5; - case "RTE_CTE": - return 6; - case "RTE_NAMEDTUPLESTORE": - return 7; - case "RTE_RESULT": - return 8; - default: - throw new Error("Key not recognized in enum RTEKind"); - } - }, - "WCOKind": (key: string): number => { - switch (key) { - case "WCO_VIEW_CHECK": - return 0; - case "WCO_RLS_INSERT_CHECK": - return 1; - case "WCO_RLS_UPDATE_CHECK": - return 2; - case "WCO_RLS_CONFLICT_CHECK": - return 3; - case "WCO_RLS_MERGE_UPDATE_CHECK": - return 4; - case "WCO_RLS_MERGE_DELETE_CHECK": - return 5; - default: - throw new Error("Key not recognized in enum WCOKind"); - } - }, - "GroupingSetKind": (key: string): number => { - switch (key) { - case "GROUPING_SET_EMPTY": - return 0; - case "GROUPING_SET_SIMPLE": - return 1; - case "GROUPING_SET_ROLLUP": - return 2; - case "GROUPING_SET_CUBE": - return 3; - case "GROUPING_SET_SETS": - return 4; - default: - throw new Error("Key not recognized in enum GroupingSetKind"); - } - }, - "CTEMaterialize": (key: string): number => { - switch (key) { - case "CTEMaterializeDefault": - return 0; - case "CTEMaterializeAlways": - return 1; - case "CTEMaterializeNever": - return 2; - default: - throw new Error("Key not recognized in enum CTEMaterialize"); - } - }, - "SetOperation": (key: string): number => { - switch (key) { - case "SETOP_NONE": - return 0; - case "SETOP_UNION": - return 1; - case "SETOP_INTERSECT": - return 2; - case "SETOP_EXCEPT": - return 3; - default: - throw new Error("Key not recognized in enum SetOperation"); - } - }, - "ObjectType": (key: string): number => { - switch (key) { - case "OBJECT_ACCESS_METHOD": - return 0; - case "OBJECT_AGGREGATE": - return 1; - case "OBJECT_AMOP": - return 2; - case "OBJECT_AMPROC": - return 3; - case "OBJECT_ATTRIBUTE": - return 4; - case "OBJECT_CAST": - return 5; - case "OBJECT_COLUMN": - return 6; - case "OBJECT_COLLATION": - return 7; - case "OBJECT_CONVERSION": - return 8; - case "OBJECT_DATABASE": - return 9; - case "OBJECT_DEFAULT": - return 10; - case "OBJECT_DEFACL": - return 11; - case "OBJECT_DOMAIN": - return 12; - case "OBJECT_DOMCONSTRAINT": - return 13; - case "OBJECT_EVENT_TRIGGER": - return 14; - case "OBJECT_EXTENSION": - return 15; - case "OBJECT_FDW": - return 16; - case "OBJECT_FOREIGN_SERVER": - return 17; - case "OBJECT_FOREIGN_TABLE": - return 18; - case "OBJECT_FUNCTION": - return 19; - case "OBJECT_INDEX": - return 20; - case "OBJECT_LANGUAGE": - return 21; - case "OBJECT_LARGEOBJECT": - return 22; - case "OBJECT_MATVIEW": - return 23; - case "OBJECT_OPCLASS": - return 24; - case "OBJECT_OPERATOR": - return 25; - case "OBJECT_OPFAMILY": - return 26; - case "OBJECT_PARAMETER_ACL": - return 27; - case "OBJECT_POLICY": - return 28; - case "OBJECT_PROCEDURE": - return 29; - case "OBJECT_PUBLICATION": - return 30; - case "OBJECT_PUBLICATION_NAMESPACE": - return 31; - case "OBJECT_PUBLICATION_REL": - return 32; - case "OBJECT_ROLE": - return 33; - case "OBJECT_ROUTINE": - return 34; - case "OBJECT_RULE": - return 35; - case "OBJECT_SCHEMA": - return 36; - case "OBJECT_SEQUENCE": - return 37; - case "OBJECT_SUBSCRIPTION": - return 38; - case "OBJECT_STATISTIC_EXT": - return 39; - case "OBJECT_TABCONSTRAINT": - return 40; - case "OBJECT_TABLE": - return 41; - case "OBJECT_TABLESPACE": - return 42; - case "OBJECT_TRANSFORM": - return 43; - case "OBJECT_TRIGGER": - return 44; - case "OBJECT_TSCONFIGURATION": - return 45; - case "OBJECT_TSDICTIONARY": - return 46; - case "OBJECT_TSPARSER": - return 47; - case "OBJECT_TSTEMPLATE": - return 48; - case "OBJECT_TYPE": - return 49; - case "OBJECT_USER_MAPPING": - return 50; - case "OBJECT_VIEW": - return 51; - default: - throw new Error("Key not recognized in enum ObjectType"); - } - }, - "DropBehavior": (key: string): number => { - switch (key) { - case "DROP_RESTRICT": - return 0; - case "DROP_CASCADE": - return 1; - default: - throw new Error("Key not recognized in enum DropBehavior"); - } - }, - "AlterTableType": (key: string): number => { - switch (key) { - case "AT_AddColumn": - return 0; - case "AT_AddColumnToView": - return 1; - case "AT_ColumnDefault": - return 2; - case "AT_CookedColumnDefault": - return 3; - case "AT_DropNotNull": - return 4; - case "AT_SetNotNull": - return 5; - case "AT_DropExpression": - return 6; - case "AT_CheckNotNull": - return 7; - case "AT_SetStatistics": - return 8; - case "AT_SetOptions": - return 9; - case "AT_ResetOptions": - return 10; - case "AT_SetStorage": - return 11; - case "AT_SetCompression": - return 12; - case "AT_DropColumn": - return 13; - case "AT_AddIndex": - return 14; - case "AT_ReAddIndex": - return 15; - case "AT_AddConstraint": - return 16; - case "AT_ReAddConstraint": - return 17; - case "AT_ReAddDomainConstraint": - return 18; - case "AT_AlterConstraint": - return 19; - case "AT_ValidateConstraint": - return 20; - case "AT_AddIndexConstraint": - return 21; - case "AT_DropConstraint": - return 22; - case "AT_ReAddComment": - return 23; - case "AT_AlterColumnType": - return 24; - case "AT_AlterColumnGenericOptions": - return 25; - case "AT_ChangeOwner": - return 26; - case "AT_ClusterOn": - return 27; - case "AT_DropCluster": - return 28; - case "AT_SetLogged": - return 29; - case "AT_SetUnLogged": - return 30; - case "AT_DropOids": - return 31; - case "AT_SetAccessMethod": - return 32; - case "AT_SetTableSpace": - return 33; - case "AT_SetRelOptions": - return 34; - case "AT_ResetRelOptions": - return 35; - case "AT_ReplaceRelOptions": - return 36; - case "AT_EnableTrig": - return 37; - case "AT_EnableAlwaysTrig": - return 38; - case "AT_EnableReplicaTrig": - return 39; - case "AT_DisableTrig": - return 40; - case "AT_EnableTrigAll": - return 41; - case "AT_DisableTrigAll": - return 42; - case "AT_EnableTrigUser": - return 43; - case "AT_DisableTrigUser": - return 44; - case "AT_EnableRule": - return 45; - case "AT_EnableAlwaysRule": - return 46; - case "AT_EnableReplicaRule": - return 47; - case "AT_DisableRule": - return 48; - case "AT_AddInherit": - return 49; - case "AT_DropInherit": - return 50; - case "AT_AddOf": - return 51; - case "AT_DropOf": - return 52; - case "AT_ReplicaIdentity": - return 53; - case "AT_EnableRowSecurity": - return 54; - case "AT_DisableRowSecurity": - return 55; - case "AT_ForceRowSecurity": - return 56; - case "AT_NoForceRowSecurity": - return 57; - case "AT_GenericOptions": - return 58; - case "AT_AttachPartition": - return 59; - case "AT_DetachPartition": - return 60; - case "AT_DetachPartitionFinalize": - return 61; - case "AT_AddIdentity": - return 62; - case "AT_SetIdentity": - return 63; - case "AT_DropIdentity": - return 64; - case "AT_ReAddStatistics": - return 65; - default: - throw new Error("Key not recognized in enum AlterTableType"); - } - }, - "GrantTargetType": (key: string): number => { - switch (key) { - case "ACL_TARGET_OBJECT": - return 0; - case "ACL_TARGET_ALL_IN_SCHEMA": - return 1; - case "ACL_TARGET_DEFAULTS": - return 2; - default: - throw new Error("Key not recognized in enum GrantTargetType"); - } - }, - "VariableSetKind": (key: string): number => { - switch (key) { - case "VAR_SET_VALUE": - return 0; - case "VAR_SET_DEFAULT": - return 1; - case "VAR_SET_CURRENT": - return 2; - case "VAR_SET_MULTI": - return 3; - case "VAR_RESET": - return 4; - case "VAR_RESET_ALL": - return 5; - default: - throw new Error("Key not recognized in enum VariableSetKind"); - } - }, - "ConstrType": (key: string): number => { - switch (key) { - case "CONSTR_NULL": - return 0; - case "CONSTR_NOTNULL": - return 1; - case "CONSTR_DEFAULT": - return 2; - case "CONSTR_IDENTITY": - return 3; - case "CONSTR_GENERATED": - return 4; - case "CONSTR_CHECK": - return 5; - case "CONSTR_PRIMARY": - return 6; - case "CONSTR_UNIQUE": - return 7; - case "CONSTR_EXCLUSION": - return 8; - case "CONSTR_FOREIGN": - return 9; - case "CONSTR_ATTR_DEFERRABLE": - return 10; - case "CONSTR_ATTR_NOT_DEFERRABLE": - return 11; - case "CONSTR_ATTR_DEFERRED": - return 12; - case "CONSTR_ATTR_IMMEDIATE": - return 13; - default: - throw new Error("Key not recognized in enum ConstrType"); - } - }, - "ImportForeignSchemaType": (key: string): number => { - switch (key) { - case "FDW_IMPORT_SCHEMA_ALL": - return 0; - case "FDW_IMPORT_SCHEMA_LIMIT_TO": - return 1; - case "FDW_IMPORT_SCHEMA_EXCEPT": - return 2; - default: - throw new Error("Key not recognized in enum ImportForeignSchemaType"); - } - }, - "RoleStmtType": (key: string): number => { - switch (key) { - case "ROLESTMT_ROLE": - return 0; - case "ROLESTMT_USER": - return 1; - case "ROLESTMT_GROUP": - return 2; - default: - throw new Error("Key not recognized in enum RoleStmtType"); - } - }, - "FetchDirection": (key: string): number => { - switch (key) { - case "FETCH_FORWARD": - return 0; - case "FETCH_BACKWARD": - return 1; - case "FETCH_ABSOLUTE": - return 2; - case "FETCH_RELATIVE": - return 3; - default: - throw new Error("Key not recognized in enum FetchDirection"); - } - }, - "FunctionParameterMode": (key: string): number => { - switch (key) { - case "FUNC_PARAM_IN": - return 0; - case "FUNC_PARAM_OUT": - return 1; - case "FUNC_PARAM_INOUT": - return 2; - case "FUNC_PARAM_VARIADIC": - return 3; - case "FUNC_PARAM_TABLE": - return 4; - case "FUNC_PARAM_DEFAULT": - return 5; - default: - throw new Error("Key not recognized in enum FunctionParameterMode"); - } - }, - "TransactionStmtKind": (key: string): number => { - switch (key) { - case "TRANS_STMT_BEGIN": - return 0; - case "TRANS_STMT_START": - return 1; - case "TRANS_STMT_COMMIT": - return 2; - case "TRANS_STMT_ROLLBACK": - return 3; - case "TRANS_STMT_SAVEPOINT": - return 4; - case "TRANS_STMT_RELEASE": - return 5; - case "TRANS_STMT_ROLLBACK_TO": - return 6; - case "TRANS_STMT_PREPARE": - return 7; - case "TRANS_STMT_COMMIT_PREPARED": - return 8; - case "TRANS_STMT_ROLLBACK_PREPARED": - return 9; - default: - throw new Error("Key not recognized in enum TransactionStmtKind"); - } - }, - "ViewCheckOption": (key: string): number => { - switch (key) { - case "NO_CHECK_OPTION": - return 0; - case "LOCAL_CHECK_OPTION": - return 1; - case "CASCADED_CHECK_OPTION": - return 2; - default: - throw new Error("Key not recognized in enum ViewCheckOption"); - } - }, - "DiscardMode": (key: string): number => { - switch (key) { - case "DISCARD_ALL": - return 0; - case "DISCARD_PLANS": - return 1; - case "DISCARD_SEQUENCES": - return 2; - case "DISCARD_TEMP": - return 3; - default: - throw new Error("Key not recognized in enum DiscardMode"); - } - }, - "ReindexObjectType": (key: string): number => { - switch (key) { - case "REINDEX_OBJECT_INDEX": - return 0; - case "REINDEX_OBJECT_TABLE": - return 1; - case "REINDEX_OBJECT_SCHEMA": - return 2; - case "REINDEX_OBJECT_SYSTEM": - return 3; - case "REINDEX_OBJECT_DATABASE": - return 4; - default: - throw new Error("Key not recognized in enum ReindexObjectType"); - } - }, - "AlterTSConfigType": (key: string): number => { - switch (key) { - case "ALTER_TSCONFIG_ADD_MAPPING": - return 0; - case "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN": - return 1; - case "ALTER_TSCONFIG_REPLACE_DICT": - return 2; - case "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN": - return 3; - case "ALTER_TSCONFIG_DROP_MAPPING": - return 4; - default: - throw new Error("Key not recognized in enum AlterTSConfigType"); - } - }, - "PublicationObjSpecType": (key: string): number => { - switch (key) { - case "PUBLICATIONOBJ_TABLE": - return 0; - case "PUBLICATIONOBJ_TABLES_IN_SCHEMA": - return 1; - case "PUBLICATIONOBJ_TABLES_IN_CUR_SCHEMA": - return 2; - case "PUBLICATIONOBJ_CONTINUATION": - return 3; - default: - throw new Error("Key not recognized in enum PublicationObjSpecType"); - } - }, - "AlterPublicationAction": (key: string): number => { - switch (key) { - case "AP_AddObjects": - return 0; - case "AP_DropObjects": - return 1; - case "AP_SetObjects": - return 2; - default: - throw new Error("Key not recognized in enum AlterPublicationAction"); - } - }, - "AlterSubscriptionType": (key: string): number => { - switch (key) { - case "ALTER_SUBSCRIPTION_OPTIONS": - return 0; - case "ALTER_SUBSCRIPTION_CONNECTION": - return 1; - case "ALTER_SUBSCRIPTION_SET_PUBLICATION": - return 2; - case "ALTER_SUBSCRIPTION_ADD_PUBLICATION": - return 3; - case "ALTER_SUBSCRIPTION_DROP_PUBLICATION": - return 4; - case "ALTER_SUBSCRIPTION_REFRESH": - return 5; - case "ALTER_SUBSCRIPTION_ENABLED": - return 6; - case "ALTER_SUBSCRIPTION_SKIP": - return 7; - default: - throw new Error("Key not recognized in enum AlterSubscriptionType"); - } - }, - "OnCommitAction": (key: string): number => { - switch (key) { - case "ONCOMMIT_NOOP": - return 0; - case "ONCOMMIT_PRESERVE_ROWS": - return 1; - case "ONCOMMIT_DELETE_ROWS": - return 2; - case "ONCOMMIT_DROP": - return 3; - default: - throw new Error("Key not recognized in enum OnCommitAction"); - } - }, - "ParamKind": (key: string): number => { - switch (key) { - case "PARAM_EXTERN": - return 0; - case "PARAM_EXEC": - return 1; - case "PARAM_SUBLINK": - return 2; - case "PARAM_MULTIEXPR": - return 3; - default: - throw new Error("Key not recognized in enum ParamKind"); - } - }, - "CoercionContext": (key: string): number => { - switch (key) { - case "COERCION_IMPLICIT": - return 0; - case "COERCION_ASSIGNMENT": - return 1; - case "COERCION_PLPGSQL": - return 2; - case "COERCION_EXPLICIT": - return 3; - default: - throw new Error("Key not recognized in enum CoercionContext"); - } - }, - "CoercionForm": (key: string): number => { - switch (key) { - case "COERCE_EXPLICIT_CALL": - return 0; - case "COERCE_EXPLICIT_CAST": - return 1; - case "COERCE_IMPLICIT_CAST": - return 2; - case "COERCE_SQL_SYNTAX": - return 3; - default: - throw new Error("Key not recognized in enum CoercionForm"); - } - }, - "BoolExprType": (key: string): number => { - switch (key) { - case "AND_EXPR": - return 0; - case "OR_EXPR": - return 1; - case "NOT_EXPR": - return 2; - default: - throw new Error("Key not recognized in enum BoolExprType"); - } - }, - "SubLinkType": (key: string): number => { - switch (key) { - case "EXISTS_SUBLINK": - return 0; - case "ALL_SUBLINK": - return 1; - case "ANY_SUBLINK": - return 2; - case "ROWCOMPARE_SUBLINK": - return 3; - case "EXPR_SUBLINK": - return 4; - case "MULTIEXPR_SUBLINK": - return 5; - case "ARRAY_SUBLINK": - return 6; - case "CTE_SUBLINK": - return 7; - default: - throw new Error("Key not recognized in enum SubLinkType"); - } - }, - "RowCompareType": (key: string): number => { - switch (key) { - case "ROWCOMPARE_LT": - return 0; - case "ROWCOMPARE_LE": - return 1; - case "ROWCOMPARE_EQ": - return 2; - case "ROWCOMPARE_GE": - return 3; - case "ROWCOMPARE_GT": - return 4; - case "ROWCOMPARE_NE": - return 5; - default: - throw new Error("Key not recognized in enum RowCompareType"); - } - }, - "MinMaxOp": (key: string): number => { - switch (key) { - case "IS_GREATEST": - return 0; - case "IS_LEAST": - return 1; - default: - throw new Error("Key not recognized in enum MinMaxOp"); - } - }, - "SQLValueFunctionOp": (key: string): number => { - switch (key) { - case "SVFOP_CURRENT_DATE": - return 0; - case "SVFOP_CURRENT_TIME": - return 1; - case "SVFOP_CURRENT_TIME_N": - return 2; - case "SVFOP_CURRENT_TIMESTAMP": - return 3; - case "SVFOP_CURRENT_TIMESTAMP_N": - return 4; - case "SVFOP_LOCALTIME": - return 5; - case "SVFOP_LOCALTIME_N": - return 6; - case "SVFOP_LOCALTIMESTAMP": - return 7; - case "SVFOP_LOCALTIMESTAMP_N": - return 8; - case "SVFOP_CURRENT_ROLE": - return 9; - case "SVFOP_CURRENT_USER": - return 10; - case "SVFOP_USER": - return 11; - case "SVFOP_SESSION_USER": - return 12; - case "SVFOP_CURRENT_CATALOG": - return 13; - case "SVFOP_CURRENT_SCHEMA": - return 14; - default: - throw new Error("Key not recognized in enum SQLValueFunctionOp"); - } - }, - "XmlExprOp": (key: string): number => { - switch (key) { - case "IS_XMLCONCAT": - return 0; - case "IS_XMLELEMENT": - return 1; - case "IS_XMLFOREST": - return 2; - case "IS_XMLPARSE": - return 3; - case "IS_XMLPI": - return 4; - case "IS_XMLROOT": - return 5; - case "IS_XMLSERIALIZE": - return 6; - case "IS_DOCUMENT": - return 7; - default: - throw new Error("Key not recognized in enum XmlExprOp"); - } - }, - "XmlOptionType": (key: string): number => { - switch (key) { - case "XMLOPTION_DOCUMENT": - return 0; - case "XMLOPTION_CONTENT": - return 1; - default: - throw new Error("Key not recognized in enum XmlOptionType"); - } - }, - "JsonEncoding": (key: string): number => { - switch (key) { - case "JS_ENC_DEFAULT": - return 0; - case "JS_ENC_UTF8": - return 1; - case "JS_ENC_UTF16": - return 2; - case "JS_ENC_UTF32": - return 3; - default: - throw new Error("Key not recognized in enum JsonEncoding"); - } - }, - "JsonFormatType": (key: string): number => { - switch (key) { - case "JS_FORMAT_DEFAULT": - return 0; - case "JS_FORMAT_JSON": - return 1; - case "JS_FORMAT_JSONB": - return 2; - default: - throw new Error("Key not recognized in enum JsonFormatType"); - } - }, - "JsonConstructorType": (key: string): number => { - switch (key) { - case "JSCTOR_JSON_OBJECT": - return 0; - case "JSCTOR_JSON_ARRAY": - return 1; - case "JSCTOR_JSON_OBJECTAGG": - return 2; - case "JSCTOR_JSON_ARRAYAGG": - return 3; - default: - throw new Error("Key not recognized in enum JsonConstructorType"); - } - }, - "JsonValueType": (key: string): number => { - switch (key) { - case "JS_TYPE_ANY": - return 0; - case "JS_TYPE_OBJECT": - return 1; - case "JS_TYPE_ARRAY": - return 2; - case "JS_TYPE_SCALAR": - return 3; - default: - throw new Error("Key not recognized in enum JsonValueType"); - } - }, - "NullTestType": (key: string): number => { - switch (key) { - case "IS_NULL": - return 0; - case "IS_NOT_NULL": - return 1; - default: - throw new Error("Key not recognized in enum NullTestType"); - } - }, - "BoolTestType": (key: string): number => { - switch (key) { - case "IS_TRUE": - return 0; - case "IS_NOT_TRUE": - return 1; - case "IS_FALSE": - return 2; - case "IS_NOT_FALSE": - return 3; - case "IS_UNKNOWN": - return 4; - case "IS_NOT_UNKNOWN": - return 5; - default: - throw new Error("Key not recognized in enum BoolTestType"); - } - }, - "CmdType": (key: string): number => { - switch (key) { - case "CMD_UNKNOWN": - return 0; - case "CMD_SELECT": - return 1; - case "CMD_UPDATE": - return 2; - case "CMD_INSERT": - return 3; - case "CMD_DELETE": - return 4; - case "CMD_MERGE": - return 5; - case "CMD_UTILITY": - return 6; - case "CMD_NOTHING": - return 7; - default: - throw new Error("Key not recognized in enum CmdType"); - } - }, - "JoinType": (key: string): number => { - switch (key) { - case "JOIN_INNER": - return 0; - case "JOIN_LEFT": - return 1; - case "JOIN_FULL": - return 2; - case "JOIN_RIGHT": - return 3; - case "JOIN_SEMI": - return 4; - case "JOIN_ANTI": - return 5; - case "JOIN_RIGHT_ANTI": - return 6; - case "JOIN_UNIQUE_OUTER": - return 7; - case "JOIN_UNIQUE_INNER": - return 8; - default: - throw new Error("Key not recognized in enum JoinType"); - } - }, - "AggStrategy": (key: string): number => { - switch (key) { - case "AGG_PLAIN": - return 0; - case "AGG_SORTED": - return 1; - case "AGG_HASHED": - return 2; - case "AGG_MIXED": - return 3; - default: - throw new Error("Key not recognized in enum AggStrategy"); - } - }, - "AggSplit": (key: string): number => { - switch (key) { - case "AGGSPLIT_SIMPLE": - return 0; - case "AGGSPLIT_INITIAL_SERIAL": - return 1; - case "AGGSPLIT_FINAL_DESERIAL": - return 2; - default: - throw new Error("Key not recognized in enum AggSplit"); - } - }, - "SetOpCmd": (key: string): number => { - switch (key) { - case "SETOPCMD_INTERSECT": - return 0; - case "SETOPCMD_INTERSECT_ALL": - return 1; - case "SETOPCMD_EXCEPT": - return 2; - case "SETOPCMD_EXCEPT_ALL": - return 3; - default: - throw new Error("Key not recognized in enum SetOpCmd"); - } - }, - "SetOpStrategy": (key: string): number => { - switch (key) { - case "SETOP_SORTED": - return 0; - case "SETOP_HASHED": - return 1; - default: - throw new Error("Key not recognized in enum SetOpStrategy"); - } - }, - "OnConflictAction": (key: string): number => { - switch (key) { - case "ONCONFLICT_NONE": - return 0; - case "ONCONFLICT_NOTHING": - return 1; - case "ONCONFLICT_UPDATE": - return 2; - default: - throw new Error("Key not recognized in enum OnConflictAction"); - } - }, - "LimitOption": (key: string): number => { - switch (key) { - case "LIMIT_OPTION_DEFAULT": - return 0; - case "LIMIT_OPTION_COUNT": - return 1; - case "LIMIT_OPTION_WITH_TIES": - return 2; - default: - throw new Error("Key not recognized in enum LimitOption"); - } - }, - "LockClauseStrength": (key: string): number => { - switch (key) { - case "LCS_NONE": - return 0; - case "LCS_FORKEYSHARE": - return 1; - case "LCS_FORSHARE": - return 2; - case "LCS_FORNOKEYUPDATE": - return 3; - case "LCS_FORUPDATE": - return 4; - default: - throw new Error("Key not recognized in enum LockClauseStrength"); - } - }, - "LockWaitPolicy": (key: string): number => { - switch (key) { - case "LockWaitBlock": - return 0; - case "LockWaitSkip": - return 1; - case "LockWaitError": - return 2; - default: - throw new Error("Key not recognized in enum LockWaitPolicy"); - } - }, - "LockTupleMode": (key: string): number => { - switch (key) { - case "LockTupleKeyShare": - return 0; - case "LockTupleShare": - return 1; - case "LockTupleNoKeyExclusive": - return 2; - case "LockTupleExclusive": - return 3; - default: - throw new Error("Key not recognized in enum LockTupleMode"); - } - }, - "KeywordKind": (key: string): number => { - switch (key) { - case "NO_KEYWORD": - return 0; - case "UNRESERVED_KEYWORD": - return 1; - case "COL_NAME_KEYWORD": - return 2; - case "TYPE_FUNC_NAME_KEYWORD": - return 3; - case "RESERVED_KEYWORD": - return 4; - default: - throw new Error("Key not recognized in enum KeywordKind"); - } - }, - "Token": (key: string): number => { - switch (key) { - case "NUL": - return 0; - case "ASCII_36": - return 36; - case "ASCII_37": - return 37; - case "ASCII_40": - return 40; - case "ASCII_41": - return 41; - case "ASCII_42": - return 42; - case "ASCII_43": - return 43; - case "ASCII_44": - return 44; - case "ASCII_45": - return 45; - case "ASCII_46": - return 46; - case "ASCII_47": - return 47; - case "ASCII_58": - return 58; - case "ASCII_59": - return 59; - case "ASCII_60": - return 60; - case "ASCII_61": - return 61; - case "ASCII_62": - return 62; - case "ASCII_63": - return 63; - case "ASCII_91": - return 91; - case "ASCII_92": - return 92; - case "ASCII_93": - return 93; - case "ASCII_94": - return 94; - case "IDENT": - return 258; - case "UIDENT": - return 259; - case "FCONST": - return 260; - case "SCONST": - return 261; - case "USCONST": - return 262; - case "BCONST": - return 263; - case "XCONST": - return 264; - case "Op": - return 265; - case "ICONST": - return 266; - case "PARAM": - return 267; - case "TYPECAST": - return 268; - case "DOT_DOT": - return 269; - case "COLON_EQUALS": - return 270; - case "EQUALS_GREATER": - return 271; - case "LESS_EQUALS": - return 272; - case "GREATER_EQUALS": - return 273; - case "NOT_EQUALS": - return 274; - case "SQL_COMMENT": - return 275; - case "C_COMMENT": - return 276; - case "ABORT_P": - return 277; - case "ABSENT": - return 278; - case "ABSOLUTE_P": - return 279; - case "ACCESS": - return 280; - case "ACTION": - return 281; - case "ADD_P": - return 282; - case "ADMIN": - return 283; - case "AFTER": - return 284; - case "AGGREGATE": - return 285; - case "ALL": - return 286; - case "ALSO": - return 287; - case "ALTER": - return 288; - case "ALWAYS": - return 289; - case "ANALYSE": - return 290; - case "ANALYZE": - return 291; - case "AND": - return 292; - case "ANY": - return 293; - case "ARRAY": - return 294; - case "AS": - return 295; - case "ASC": - return 296; - case "ASENSITIVE": - return 297; - case "ASSERTION": - return 298; - case "ASSIGNMENT": - return 299; - case "ASYMMETRIC": - return 300; - case "ATOMIC": - return 301; - case "AT": - return 302; - case "ATTACH": - return 303; - case "ATTRIBUTE": - return 304; - case "AUTHORIZATION": - return 305; - case "BACKWARD": - return 306; - case "BEFORE": - return 307; - case "BEGIN_P": - return 308; - case "BETWEEN": - return 309; - case "BIGINT": - return 310; - case "BINARY": - return 311; - case "BIT": - return 312; - case "BOOLEAN_P": - return 313; - case "BOTH": - return 314; - case "BREADTH": - return 315; - case "BY": - return 316; - case "CACHE": - return 317; - case "CALL": - return 318; - case "CALLED": - return 319; - case "CASCADE": - return 320; - case "CASCADED": - return 321; - case "CASE": - return 322; - case "CAST": - return 323; - case "CATALOG_P": - return 324; - case "CHAIN": - return 325; - case "CHAR_P": - return 326; - case "CHARACTER": - return 327; - case "CHARACTERISTICS": - return 328; - case "CHECK": - return 329; - case "CHECKPOINT": - return 330; - case "CLASS": - return 331; - case "CLOSE": - return 332; - case "CLUSTER": - return 333; - case "COALESCE": - return 334; - case "COLLATE": - return 335; - case "COLLATION": - return 336; - case "COLUMN": - return 337; - case "COLUMNS": - return 338; - case "COMMENT": - return 339; - case "COMMENTS": - return 340; - case "COMMIT": - return 341; - case "COMMITTED": - return 342; - case "COMPRESSION": - return 343; - case "CONCURRENTLY": - return 344; - case "CONFIGURATION": - return 345; - case "CONFLICT": - return 346; - case "CONNECTION": - return 347; - case "CONSTRAINT": - return 348; - case "CONSTRAINTS": - return 349; - case "CONTENT_P": - return 350; - case "CONTINUE_P": - return 351; - case "CONVERSION_P": - return 352; - case "COPY": - return 353; - case "COST": - return 354; - case "CREATE": - return 355; - case "CROSS": - return 356; - case "CSV": - return 357; - case "CUBE": - return 358; - case "CURRENT_P": - return 359; - case "CURRENT_CATALOG": - return 360; - case "CURRENT_DATE": - return 361; - case "CURRENT_ROLE": - return 362; - case "CURRENT_SCHEMA": - return 363; - case "CURRENT_TIME": - return 364; - case "CURRENT_TIMESTAMP": - return 365; - case "CURRENT_USER": - return 366; - case "CURSOR": - return 367; - case "CYCLE": - return 368; - case "DATA_P": - return 369; - case "DATABASE": - return 370; - case "DAY_P": - return 371; - case "DEALLOCATE": - return 372; - case "DEC": - return 373; - case "DECIMAL_P": - return 374; - case "DECLARE": - return 375; - case "DEFAULT": - return 376; - case "DEFAULTS": - return 377; - case "DEFERRABLE": - return 378; - case "DEFERRED": - return 379; - case "DEFINER": - return 380; - case "DELETE_P": - return 381; - case "DELIMITER": - return 382; - case "DELIMITERS": - return 383; - case "DEPENDS": - return 384; - case "DEPTH": - return 385; - case "DESC": - return 386; - case "DETACH": - return 387; - case "DICTIONARY": - return 388; - case "DISABLE_P": - return 389; - case "DISCARD": - return 390; - case "DISTINCT": - return 391; - case "DO": - return 392; - case "DOCUMENT_P": - return 393; - case "DOMAIN_P": - return 394; - case "DOUBLE_P": - return 395; - case "DROP": - return 396; - case "EACH": - return 397; - case "ELSE": - return 398; - case "ENABLE_P": - return 399; - case "ENCODING": - return 400; - case "ENCRYPTED": - return 401; - case "END_P": - return 402; - case "ENUM_P": - return 403; - case "ESCAPE": - return 404; - case "EVENT": - return 405; - case "EXCEPT": - return 406; - case "EXCLUDE": - return 407; - case "EXCLUDING": - return 408; - case "EXCLUSIVE": - return 409; - case "EXECUTE": - return 410; - case "EXISTS": - return 411; - case "EXPLAIN": - return 412; - case "EXPRESSION": - return 413; - case "EXTENSION": - return 414; - case "EXTERNAL": - return 415; - case "EXTRACT": - return 416; - case "FALSE_P": - return 417; - case "FAMILY": - return 418; - case "FETCH": - return 419; - case "FILTER": - return 420; - case "FINALIZE": - return 421; - case "FIRST_P": - return 422; - case "FLOAT_P": - return 423; - case "FOLLOWING": - return 424; - case "FOR": - return 425; - case "FORCE": - return 426; - case "FOREIGN": - return 427; - case "FORMAT": - return 428; - case "FORWARD": - return 429; - case "FREEZE": - return 430; - case "FROM": - return 431; - case "FULL": - return 432; - case "FUNCTION": - return 433; - case "FUNCTIONS": - return 434; - case "GENERATED": - return 435; - case "GLOBAL": - return 436; - case "GRANT": - return 437; - case "GRANTED": - return 438; - case "GREATEST": - return 439; - case "GROUP_P": - return 440; - case "GROUPING": - return 441; - case "GROUPS": - return 442; - case "HANDLER": - return 443; - case "HAVING": - return 444; - case "HEADER_P": - return 445; - case "HOLD": - return 446; - case "HOUR_P": - return 447; - case "IDENTITY_P": - return 448; - case "IF_P": - return 449; - case "ILIKE": - return 450; - case "IMMEDIATE": - return 451; - case "IMMUTABLE": - return 452; - case "IMPLICIT_P": - return 453; - case "IMPORT_P": - return 454; - case "IN_P": - return 455; - case "INCLUDE": - return 456; - case "INCLUDING": - return 457; - case "INCREMENT": - return 458; - case "INDENT": - return 459; - case "INDEX": - return 460; - case "INDEXES": - return 461; - case "INHERIT": - return 462; - case "INHERITS": - return 463; - case "INITIALLY": - return 464; - case "INLINE_P": - return 465; - case "INNER_P": - return 466; - case "INOUT": - return 467; - case "INPUT_P": - return 468; - case "INSENSITIVE": - return 469; - case "INSERT": - return 470; - case "INSTEAD": - return 471; - case "INT_P": - return 472; - case "INTEGER": - return 473; - case "INTERSECT": - return 474; - case "INTERVAL": - return 475; - case "INTO": - return 476; - case "INVOKER": - return 477; - case "IS": - return 478; - case "ISNULL": - return 479; - case "ISOLATION": - return 480; - case "JOIN": - return 481; - case "JSON": - return 482; - case "JSON_ARRAY": - return 483; - case "JSON_ARRAYAGG": - return 484; - case "JSON_OBJECT": - return 485; - case "JSON_OBJECTAGG": - return 486; - case "KEY": - return 487; - case "KEYS": - return 488; - case "LABEL": - return 489; - case "LANGUAGE": - return 490; - case "LARGE_P": - return 491; - case "LAST_P": - return 492; - case "LATERAL_P": - return 493; - case "LEADING": - return 494; - case "LEAKPROOF": - return 495; - case "LEAST": - return 496; - case "LEFT": - return 497; - case "LEVEL": - return 498; - case "LIKE": - return 499; - case "LIMIT": - return 500; - case "LISTEN": - return 501; - case "LOAD": - return 502; - case "LOCAL": - return 503; - case "LOCALTIME": - return 504; - case "LOCALTIMESTAMP": - return 505; - case "LOCATION": - return 506; - case "LOCK_P": - return 507; - case "LOCKED": - return 508; - case "LOGGED": - return 509; - case "MAPPING": - return 510; - case "MATCH": - return 511; - case "MATCHED": - return 512; - case "MATERIALIZED": - return 513; - case "MAXVALUE": - return 514; - case "MERGE": - return 515; - case "METHOD": - return 516; - case "MINUTE_P": - return 517; - case "MINVALUE": - return 518; - case "MODE": - return 519; - case "MONTH_P": - return 520; - case "MOVE": - return 521; - case "NAME_P": - return 522; - case "NAMES": - return 523; - case "NATIONAL": - return 524; - case "NATURAL": - return 525; - case "NCHAR": - return 526; - case "NEW": - return 527; - case "NEXT": - return 528; - case "NFC": - return 529; - case "NFD": - return 530; - case "NFKC": - return 531; - case "NFKD": - return 532; - case "NO": - return 533; - case "NONE": - return 534; - case "NORMALIZE": - return 535; - case "NORMALIZED": - return 536; - case "NOT": - return 537; - case "NOTHING": - return 538; - case "NOTIFY": - return 539; - case "NOTNULL": - return 540; - case "NOWAIT": - return 541; - case "NULL_P": - return 542; - case "NULLIF": - return 543; - case "NULLS_P": - return 544; - case "NUMERIC": - return 545; - case "OBJECT_P": - return 546; - case "OF": - return 547; - case "OFF": - return 548; - case "OFFSET": - return 549; - case "OIDS": - return 550; - case "OLD": - return 551; - case "ON": - return 552; - case "ONLY": - return 553; - case "OPERATOR": - return 554; - case "OPTION": - return 555; - case "OPTIONS": - return 556; - case "OR": - return 557; - case "ORDER": - return 558; - case "ORDINALITY": - return 559; - case "OTHERS": - return 560; - case "OUT_P": - return 561; - case "OUTER_P": - return 562; - case "OVER": - return 563; - case "OVERLAPS": - return 564; - case "OVERLAY": - return 565; - case "OVERRIDING": - return 566; - case "OWNED": - return 567; - case "OWNER": - return 568; - case "PARALLEL": - return 569; - case "PARAMETER": - return 570; - case "PARSER": - return 571; - case "PARTIAL": - return 572; - case "PARTITION": - return 573; - case "PASSING": - return 574; - case "PASSWORD": - return 575; - case "PLACING": - return 576; - case "PLANS": - return 577; - case "POLICY": - return 578; - case "POSITION": - return 579; - case "PRECEDING": - return 580; - case "PRECISION": - return 581; - case "PRESERVE": - return 582; - case "PREPARE": - return 583; - case "PREPARED": - return 584; - case "PRIMARY": - return 585; - case "PRIOR": - return 586; - case "PRIVILEGES": - return 587; - case "PROCEDURAL": - return 588; - case "PROCEDURE": - return 589; - case "PROCEDURES": - return 590; - case "PROGRAM": - return 591; - case "PUBLICATION": - return 592; - case "QUOTE": - return 593; - case "RANGE": - return 594; - case "READ": - return 595; - case "REAL": - return 596; - case "REASSIGN": - return 597; - case "RECHECK": - return 598; - case "RECURSIVE": - return 599; - case "REF_P": - return 600; - case "REFERENCES": - return 601; - case "REFERENCING": - return 602; - case "REFRESH": - return 603; - case "REINDEX": - return 604; - case "RELATIVE_P": - return 605; - case "RELEASE": - return 606; - case "RENAME": - return 607; - case "REPEATABLE": - return 608; - case "REPLACE": - return 609; - case "REPLICA": - return 610; - case "RESET": - return 611; - case "RESTART": - return 612; - case "RESTRICT": - return 613; - case "RETURN": - return 614; - case "RETURNING": - return 615; - case "RETURNS": - return 616; - case "REVOKE": - return 617; - case "RIGHT": - return 618; - case "ROLE": - return 619; - case "ROLLBACK": - return 620; - case "ROLLUP": - return 621; - case "ROUTINE": - return 622; - case "ROUTINES": - return 623; - case "ROW": - return 624; - case "ROWS": - return 625; - case "RULE": - return 626; - case "SAVEPOINT": - return 627; - case "SCALAR": - return 628; - case "SCHEMA": - return 629; - case "SCHEMAS": - return 630; - case "SCROLL": - return 631; - case "SEARCH": - return 632; - case "SECOND_P": - return 633; - case "SECURITY": - return 634; - case "SELECT": - return 635; - case "SEQUENCE": - return 636; - case "SEQUENCES": - return 637; - case "SERIALIZABLE": - return 638; - case "SERVER": - return 639; - case "SESSION": - return 640; - case "SESSION_USER": - return 641; - case "SET": - return 642; - case "SETS": - return 643; - case "SETOF": - return 644; - case "SHARE": - return 645; - case "SHOW": - return 646; - case "SIMILAR": - return 647; - case "SIMPLE": - return 648; - case "SKIP": - return 649; - case "SMALLINT": - return 650; - case "SNAPSHOT": - return 651; - case "SOME": - return 652; - case "SQL_P": - return 653; - case "STABLE": - return 654; - case "STANDALONE_P": - return 655; - case "START": - return 656; - case "STATEMENT": - return 657; - case "STATISTICS": - return 658; - case "STDIN": - return 659; - case "STDOUT": - return 660; - case "STORAGE": - return 661; - case "STORED": - return 662; - case "STRICT_P": - return 663; - case "STRIP_P": - return 664; - case "SUBSCRIPTION": - return 665; - case "SUBSTRING": - return 666; - case "SUPPORT": - return 667; - case "SYMMETRIC": - return 668; - case "SYSID": - return 669; - case "SYSTEM_P": - return 670; - case "SYSTEM_USER": - return 671; - case "TABLE": - return 672; - case "TABLES": - return 673; - case "TABLESAMPLE": - return 674; - case "TABLESPACE": - return 675; - case "TEMP": - return 676; - case "TEMPLATE": - return 677; - case "TEMPORARY": - return 678; - case "TEXT_P": - return 679; - case "THEN": - return 680; - case "TIES": - return 681; - case "TIME": - return 682; - case "TIMESTAMP": - return 683; - case "TO": - return 684; - case "TRAILING": - return 685; - case "TRANSACTION": - return 686; - case "TRANSFORM": - return 687; - case "TREAT": - return 688; - case "TRIGGER": - return 689; - case "TRIM": - return 690; - case "TRUE_P": - return 691; - case "TRUNCATE": - return 692; - case "TRUSTED": - return 693; - case "TYPE_P": - return 694; - case "TYPES_P": - return 695; - case "UESCAPE": - return 696; - case "UNBOUNDED": - return 697; - case "UNCOMMITTED": - return 698; - case "UNENCRYPTED": - return 699; - case "UNION": - return 700; - case "UNIQUE": - return 701; - case "UNKNOWN": - return 702; - case "UNLISTEN": - return 703; - case "UNLOGGED": - return 704; - case "UNTIL": - return 705; - case "UPDATE": - return 706; - case "USER": - return 707; - case "USING": - return 708; - case "VACUUM": - return 709; - case "VALID": - return 710; - case "VALIDATE": - return 711; - case "VALIDATOR": - return 712; - case "VALUE_P": - return 713; - case "VALUES": - return 714; - case "VARCHAR": - return 715; - case "VARIADIC": - return 716; - case "VARYING": - return 717; - case "VERBOSE": - return 718; - case "VERSION_P": - return 719; - case "VIEW": - return 720; - case "VIEWS": - return 721; - case "VOLATILE": - return 722; - case "WHEN": - return 723; - case "WHERE": - return 724; - case "WHITESPACE_P": - return 725; - case "WINDOW": - return 726; - case "WITH": - return 727; - case "WITHIN": - return 728; - case "WITHOUT": - return 729; - case "WORK": - return 730; - case "WRAPPER": - return 731; - case "WRITE": - return 732; - case "XML_P": - return 733; - case "XMLATTRIBUTES": - return 734; - case "XMLCONCAT": - return 735; - case "XMLELEMENT": - return 736; - case "XMLEXISTS": - return 737; - case "XMLFOREST": - return 738; - case "XMLNAMESPACES": - return 739; - case "XMLPARSE": - return 740; - case "XMLPI": - return 741; - case "XMLROOT": - return 742; - case "XMLSERIALIZE": - return 743; - case "XMLTABLE": - return 744; - case "YEAR_P": - return 745; - case "YES_P": - return 746; - case "ZONE": - return 747; - case "FORMAT_LA": - return 748; - case "NOT_LA": - return 749; - case "NULLS_LA": - return 750; - case "WITH_LA": - return 751; - case "WITHOUT_LA": - return 752; - case "MODE_TYPE_NAME": - return 753; - case "MODE_PLPGSQL_EXPR": - return 754; - case "MODE_PLPGSQL_ASSIGN1": - return 755; - case "MODE_PLPGSQL_ASSIGN2": - return 756; - case "MODE_PLPGSQL_ASSIGN3": - return 757; - case "UMINUS": - return 758; - default: - throw new Error("Key not recognized in enum Token"); - } - } -};", - "file": "enum-to-int-nested.ts", - }, -] -`; - -exports[`enum utils switch statements format generates bidirectional enum value functions 1`] = ` -[ - { - "code": "/** -* This file was automatically generated by pg-proto-parser@latest. -* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, -* and run the pg-proto-parser generate command to regenerate this file. -*/ -export type EnumType = "OverridingKind" | "QuerySource" | "SortByDir" | "SortByNulls" | "SetQuantifier" | "A_Expr_Kind" | "RoleSpecType" | "TableLikeOption" | "DefElemAction" | "PartitionStrategy" | "PartitionRangeDatumKind" | "RTEKind" | "WCOKind" | "GroupingSetKind" | "CTEMaterialize" | "SetOperation" | "ObjectType" | "DropBehavior" | "AlterTableType" | "GrantTargetType" | "VariableSetKind" | "ConstrType" | "ImportForeignSchemaType" | "RoleStmtType" | "FetchDirection" | "FunctionParameterMode" | "TransactionStmtKind" | "ViewCheckOption" | "DiscardMode" | "ReindexObjectType" | "AlterTSConfigType" | "PublicationObjSpecType" | "AlterPublicationAction" | "AlterSubscriptionType" | "OnCommitAction" | "ParamKind" | "CoercionContext" | "CoercionForm" | "BoolExprType" | "SubLinkType" | "RowCompareType" | "MinMaxOp" | "SQLValueFunctionOp" | "XmlExprOp" | "XmlOptionType" | "JsonEncoding" | "JsonFormatType" | "JsonConstructorType" | "JsonValueType" | "NullTestType" | "BoolTestType" | "CmdType" | "JoinType" | "AggStrategy" | "AggSplit" | "SetOpCmd" | "SetOpStrategy" | "OnConflictAction" | "LimitOption" | "LockClauseStrength" | "LockWaitPolicy" | "LockTupleMode" | "KeywordKind" | "Token"; -export const getEnumValue = (enumType: EnumType, key: string | number) => { - switch (enumType) { - case "OverridingKind": - { - switch (key) { - case "OVERRIDING_NOT_SET": - return 0; - case "OVERRIDING_USER_VALUE": - return 1; - case "OVERRIDING_SYSTEM_VALUE": - return 2; - case 0: - return "OVERRIDING_NOT_SET"; - case 1: - return "OVERRIDING_USER_VALUE"; - case 2: - return "OVERRIDING_SYSTEM_VALUE"; - default: - throw new Error("Key not recognized in enum OverridingKind"); - } - } - case "QuerySource": - { - switch (key) { - case "QSRC_ORIGINAL": - return 0; - case "QSRC_PARSER": - return 1; - case "QSRC_INSTEAD_RULE": - return 2; - case "QSRC_QUAL_INSTEAD_RULE": - return 3; - case "QSRC_NON_INSTEAD_RULE": - return 4; - case 0: - return "QSRC_ORIGINAL"; - case 1: - return "QSRC_PARSER"; - case 2: - return "QSRC_INSTEAD_RULE"; - case 3: - return "QSRC_QUAL_INSTEAD_RULE"; - case 4: - return "QSRC_NON_INSTEAD_RULE"; - default: - throw new Error("Key not recognized in enum QuerySource"); - } - } - case "SortByDir": - { - switch (key) { - case "SORTBY_DEFAULT": - return 0; - case "SORTBY_ASC": - return 1; - case "SORTBY_DESC": - return 2; - case "SORTBY_USING": - return 3; - case 0: - return "SORTBY_DEFAULT"; - case 1: - return "SORTBY_ASC"; - case 2: - return "SORTBY_DESC"; - case 3: - return "SORTBY_USING"; - default: - throw new Error("Key not recognized in enum SortByDir"); - } - } - case "SortByNulls": - { - switch (key) { - case "SORTBY_NULLS_DEFAULT": - return 0; - case "SORTBY_NULLS_FIRST": - return 1; - case "SORTBY_NULLS_LAST": - return 2; - case 0: - return "SORTBY_NULLS_DEFAULT"; - case 1: - return "SORTBY_NULLS_FIRST"; - case 2: - return "SORTBY_NULLS_LAST"; - default: - throw new Error("Key not recognized in enum SortByNulls"); - } - } - case "SetQuantifier": - { - switch (key) { - case "SET_QUANTIFIER_DEFAULT": - return 0; - case "SET_QUANTIFIER_ALL": - return 1; - case "SET_QUANTIFIER_DISTINCT": - return 2; - case 0: - return "SET_QUANTIFIER_DEFAULT"; - case 1: - return "SET_QUANTIFIER_ALL"; - case 2: - return "SET_QUANTIFIER_DISTINCT"; - default: - throw new Error("Key not recognized in enum SetQuantifier"); - } - } - case "A_Expr_Kind": - { - switch (key) { - case "AEXPR_OP": - return 0; - case "AEXPR_OP_ANY": - return 1; - case "AEXPR_OP_ALL": - return 2; - case "AEXPR_DISTINCT": - return 3; - case "AEXPR_NOT_DISTINCT": - return 4; - case "AEXPR_NULLIF": - return 5; - case "AEXPR_IN": - return 6; - case "AEXPR_LIKE": - return 7; - case "AEXPR_ILIKE": - return 8; - case "AEXPR_SIMILAR": - return 9; - case "AEXPR_BETWEEN": - return 10; - case "AEXPR_NOT_BETWEEN": - return 11; - case "AEXPR_BETWEEN_SYM": - return 12; - case "AEXPR_NOT_BETWEEN_SYM": - return 13; - case 0: - return "AEXPR_OP"; - case 1: - return "AEXPR_OP_ANY"; - case 2: - return "AEXPR_OP_ALL"; - case 3: - return "AEXPR_DISTINCT"; - case 4: - return "AEXPR_NOT_DISTINCT"; - case 5: - return "AEXPR_NULLIF"; - case 6: - return "AEXPR_IN"; - case 7: - return "AEXPR_LIKE"; - case 8: - return "AEXPR_ILIKE"; - case 9: - return "AEXPR_SIMILAR"; - case 10: - return "AEXPR_BETWEEN"; - case 11: - return "AEXPR_NOT_BETWEEN"; - case 12: - return "AEXPR_BETWEEN_SYM"; - case 13: - return "AEXPR_NOT_BETWEEN_SYM"; - default: - throw new Error("Key not recognized in enum A_Expr_Kind"); - } - } - case "RoleSpecType": - { - switch (key) { - case "ROLESPEC_CSTRING": - return 0; - case "ROLESPEC_CURRENT_ROLE": - return 1; - case "ROLESPEC_CURRENT_USER": - return 2; - case "ROLESPEC_SESSION_USER": - return 3; - case "ROLESPEC_PUBLIC": - return 4; - case 0: - return "ROLESPEC_CSTRING"; - case 1: - return "ROLESPEC_CURRENT_ROLE"; - case 2: - return "ROLESPEC_CURRENT_USER"; - case 3: - return "ROLESPEC_SESSION_USER"; - case 4: - return "ROLESPEC_PUBLIC"; - default: - throw new Error("Key not recognized in enum RoleSpecType"); - } - } - case "TableLikeOption": - { - switch (key) { - case "CREATE_TABLE_LIKE_COMMENTS": - return 0; - case "CREATE_TABLE_LIKE_COMPRESSION": - return 1; - case "CREATE_TABLE_LIKE_CONSTRAINTS": - return 2; - case "CREATE_TABLE_LIKE_DEFAULTS": - return 3; - case "CREATE_TABLE_LIKE_GENERATED": - return 4; - case "CREATE_TABLE_LIKE_IDENTITY": - return 5; - case "CREATE_TABLE_LIKE_INDEXES": - return 6; - case "CREATE_TABLE_LIKE_STATISTICS": - return 7; - case "CREATE_TABLE_LIKE_STORAGE": - return 8; - case "CREATE_TABLE_LIKE_ALL": - return 9; - case 0: - return "CREATE_TABLE_LIKE_COMMENTS"; - case 1: - return "CREATE_TABLE_LIKE_COMPRESSION"; - case 2: - return "CREATE_TABLE_LIKE_CONSTRAINTS"; - case 3: - return "CREATE_TABLE_LIKE_DEFAULTS"; - case 4: - return "CREATE_TABLE_LIKE_GENERATED"; - case 5: - return "CREATE_TABLE_LIKE_IDENTITY"; - case 6: - return "CREATE_TABLE_LIKE_INDEXES"; - case 7: - return "CREATE_TABLE_LIKE_STATISTICS"; - case 8: - return "CREATE_TABLE_LIKE_STORAGE"; - case 9: - return "CREATE_TABLE_LIKE_ALL"; - default: - throw new Error("Key not recognized in enum TableLikeOption"); - } - } - case "DefElemAction": - { - switch (key) { - case "DEFELEM_UNSPEC": - return 0; - case "DEFELEM_SET": - return 1; - case "DEFELEM_ADD": - return 2; - case "DEFELEM_DROP": - return 3; - case 0: - return "DEFELEM_UNSPEC"; - case 1: - return "DEFELEM_SET"; - case 2: - return "DEFELEM_ADD"; - case 3: - return "DEFELEM_DROP"; - default: - throw new Error("Key not recognized in enum DefElemAction"); - } - } - case "PartitionStrategy": - { - switch (key) { - case "PARTITION_STRATEGY_LIST": - return 0; - case "PARTITION_STRATEGY_RANGE": - return 1; - case "PARTITION_STRATEGY_HASH": - return 2; - case 0: - return "PARTITION_STRATEGY_LIST"; - case 1: - return "PARTITION_STRATEGY_RANGE"; - case 2: - return "PARTITION_STRATEGY_HASH"; - default: - throw new Error("Key not recognized in enum PartitionStrategy"); - } - } - case "PartitionRangeDatumKind": - { - switch (key) { - case "PARTITION_RANGE_DATUM_MINVALUE": - return 0; - case "PARTITION_RANGE_DATUM_VALUE": - return 1; - case "PARTITION_RANGE_DATUM_MAXVALUE": - return 2; - case 0: - return "PARTITION_RANGE_DATUM_MINVALUE"; - case 1: - return "PARTITION_RANGE_DATUM_VALUE"; - case 2: - return "PARTITION_RANGE_DATUM_MAXVALUE"; - default: - throw new Error("Key not recognized in enum PartitionRangeDatumKind"); - } - } - case "RTEKind": - { - switch (key) { - case "RTE_RELATION": - return 0; - case "RTE_SUBQUERY": - return 1; - case "RTE_JOIN": - return 2; - case "RTE_FUNCTION": - return 3; - case "RTE_TABLEFUNC": - return 4; - case "RTE_VALUES": - return 5; - case "RTE_CTE": - return 6; - case "RTE_NAMEDTUPLESTORE": - return 7; - case "RTE_RESULT": - return 8; - case 0: - return "RTE_RELATION"; - case 1: - return "RTE_SUBQUERY"; - case 2: - return "RTE_JOIN"; - case 3: - return "RTE_FUNCTION"; - case 4: - return "RTE_TABLEFUNC"; - case 5: - return "RTE_VALUES"; - case 6: - return "RTE_CTE"; - case 7: - return "RTE_NAMEDTUPLESTORE"; - case 8: - return "RTE_RESULT"; - default: - throw new Error("Key not recognized in enum RTEKind"); - } - } - case "WCOKind": - { - switch (key) { - case "WCO_VIEW_CHECK": - return 0; - case "WCO_RLS_INSERT_CHECK": - return 1; - case "WCO_RLS_UPDATE_CHECK": - return 2; - case "WCO_RLS_CONFLICT_CHECK": - return 3; - case "WCO_RLS_MERGE_UPDATE_CHECK": - return 4; - case "WCO_RLS_MERGE_DELETE_CHECK": - return 5; - case 0: - return "WCO_VIEW_CHECK"; - case 1: - return "WCO_RLS_INSERT_CHECK"; - case 2: - return "WCO_RLS_UPDATE_CHECK"; - case 3: - return "WCO_RLS_CONFLICT_CHECK"; - case 4: - return "WCO_RLS_MERGE_UPDATE_CHECK"; - case 5: - return "WCO_RLS_MERGE_DELETE_CHECK"; - default: - throw new Error("Key not recognized in enum WCOKind"); - } - } - case "GroupingSetKind": - { - switch (key) { - case "GROUPING_SET_EMPTY": - return 0; - case "GROUPING_SET_SIMPLE": - return 1; - case "GROUPING_SET_ROLLUP": - return 2; - case "GROUPING_SET_CUBE": - return 3; - case "GROUPING_SET_SETS": - return 4; - case 0: - return "GROUPING_SET_EMPTY"; - case 1: - return "GROUPING_SET_SIMPLE"; - case 2: - return "GROUPING_SET_ROLLUP"; - case 3: - return "GROUPING_SET_CUBE"; - case 4: - return "GROUPING_SET_SETS"; - default: - throw new Error("Key not recognized in enum GroupingSetKind"); - } - } - case "CTEMaterialize": - { - switch (key) { - case "CTEMaterializeDefault": - return 0; - case "CTEMaterializeAlways": - return 1; - case "CTEMaterializeNever": - return 2; - case 0: - return "CTEMaterializeDefault"; - case 1: - return "CTEMaterializeAlways"; - case 2: - return "CTEMaterializeNever"; - default: - throw new Error("Key not recognized in enum CTEMaterialize"); - } - } - case "SetOperation": - { - switch (key) { - case "SETOP_NONE": - return 0; - case "SETOP_UNION": - return 1; - case "SETOP_INTERSECT": - return 2; - case "SETOP_EXCEPT": - return 3; - case 0: - return "SETOP_NONE"; - case 1: - return "SETOP_UNION"; - case 2: - return "SETOP_INTERSECT"; - case 3: - return "SETOP_EXCEPT"; - default: - throw new Error("Key not recognized in enum SetOperation"); - } - } - case "ObjectType": - { - switch (key) { - case "OBJECT_ACCESS_METHOD": - return 0; - case "OBJECT_AGGREGATE": - return 1; - case "OBJECT_AMOP": - return 2; - case "OBJECT_AMPROC": - return 3; - case "OBJECT_ATTRIBUTE": - return 4; - case "OBJECT_CAST": - return 5; - case "OBJECT_COLUMN": - return 6; - case "OBJECT_COLLATION": - return 7; - case "OBJECT_CONVERSION": - return 8; - case "OBJECT_DATABASE": - return 9; - case "OBJECT_DEFAULT": - return 10; - case "OBJECT_DEFACL": - return 11; - case "OBJECT_DOMAIN": - return 12; - case "OBJECT_DOMCONSTRAINT": - return 13; - case "OBJECT_EVENT_TRIGGER": - return 14; - case "OBJECT_EXTENSION": - return 15; - case "OBJECT_FDW": - return 16; - case "OBJECT_FOREIGN_SERVER": - return 17; - case "OBJECT_FOREIGN_TABLE": - return 18; - case "OBJECT_FUNCTION": - return 19; - case "OBJECT_INDEX": - return 20; - case "OBJECT_LANGUAGE": - return 21; - case "OBJECT_LARGEOBJECT": - return 22; - case "OBJECT_MATVIEW": - return 23; - case "OBJECT_OPCLASS": - return 24; - case "OBJECT_OPERATOR": - return 25; - case "OBJECT_OPFAMILY": - return 26; - case "OBJECT_PARAMETER_ACL": - return 27; - case "OBJECT_POLICY": - return 28; - case "OBJECT_PROCEDURE": - return 29; - case "OBJECT_PUBLICATION": - return 30; - case "OBJECT_PUBLICATION_NAMESPACE": - return 31; - case "OBJECT_PUBLICATION_REL": - return 32; - case "OBJECT_ROLE": - return 33; - case "OBJECT_ROUTINE": - return 34; - case "OBJECT_RULE": - return 35; - case "OBJECT_SCHEMA": - return 36; - case "OBJECT_SEQUENCE": - return 37; - case "OBJECT_SUBSCRIPTION": - return 38; - case "OBJECT_STATISTIC_EXT": - return 39; - case "OBJECT_TABCONSTRAINT": - return 40; - case "OBJECT_TABLE": - return 41; - case "OBJECT_TABLESPACE": - return 42; - case "OBJECT_TRANSFORM": - return 43; - case "OBJECT_TRIGGER": - return 44; - case "OBJECT_TSCONFIGURATION": - return 45; - case "OBJECT_TSDICTIONARY": - return 46; - case "OBJECT_TSPARSER": - return 47; - case "OBJECT_TSTEMPLATE": - return 48; - case "OBJECT_TYPE": - return 49; - case "OBJECT_USER_MAPPING": - return 50; - case "OBJECT_VIEW": - return 51; - case 0: - return "OBJECT_ACCESS_METHOD"; - case 1: - return "OBJECT_AGGREGATE"; - case 2: - return "OBJECT_AMOP"; - case 3: - return "OBJECT_AMPROC"; - case 4: - return "OBJECT_ATTRIBUTE"; - case 5: - return "OBJECT_CAST"; - case 6: - return "OBJECT_COLUMN"; - case 7: - return "OBJECT_COLLATION"; - case 8: - return "OBJECT_CONVERSION"; - case 9: - return "OBJECT_DATABASE"; - case 10: - return "OBJECT_DEFAULT"; - case 11: - return "OBJECT_DEFACL"; - case 12: - return "OBJECT_DOMAIN"; - case 13: - return "OBJECT_DOMCONSTRAINT"; - case 14: - return "OBJECT_EVENT_TRIGGER"; - case 15: - return "OBJECT_EXTENSION"; - case 16: - return "OBJECT_FDW"; - case 17: - return "OBJECT_FOREIGN_SERVER"; - case 18: - return "OBJECT_FOREIGN_TABLE"; - case 19: - return "OBJECT_FUNCTION"; - case 20: - return "OBJECT_INDEX"; - case 21: - return "OBJECT_LANGUAGE"; - case 22: - return "OBJECT_LARGEOBJECT"; - case 23: - return "OBJECT_MATVIEW"; - case 24: - return "OBJECT_OPCLASS"; - case 25: - return "OBJECT_OPERATOR"; - case 26: - return "OBJECT_OPFAMILY"; - case 27: - return "OBJECT_PARAMETER_ACL"; - case 28: - return "OBJECT_POLICY"; - case 29: - return "OBJECT_PROCEDURE"; - case 30: - return "OBJECT_PUBLICATION"; - case 31: - return "OBJECT_PUBLICATION_NAMESPACE"; - case 32: - return "OBJECT_PUBLICATION_REL"; - case 33: - return "OBJECT_ROLE"; - case 34: - return "OBJECT_ROUTINE"; - case 35: - return "OBJECT_RULE"; - case 36: - return "OBJECT_SCHEMA"; - case 37: - return "OBJECT_SEQUENCE"; - case 38: - return "OBJECT_SUBSCRIPTION"; - case 39: - return "OBJECT_STATISTIC_EXT"; - case 40: - return "OBJECT_TABCONSTRAINT"; - case 41: - return "OBJECT_TABLE"; - case 42: - return "OBJECT_TABLESPACE"; - case 43: - return "OBJECT_TRANSFORM"; - case 44: - return "OBJECT_TRIGGER"; - case 45: - return "OBJECT_TSCONFIGURATION"; - case 46: - return "OBJECT_TSDICTIONARY"; - case 47: - return "OBJECT_TSPARSER"; - case 48: - return "OBJECT_TSTEMPLATE"; - case 49: - return "OBJECT_TYPE"; - case 50: - return "OBJECT_USER_MAPPING"; - case 51: - return "OBJECT_VIEW"; - default: - throw new Error("Key not recognized in enum ObjectType"); - } - } - case "DropBehavior": - { - switch (key) { - case "DROP_RESTRICT": - return 0; - case "DROP_CASCADE": - return 1; - case 0: - return "DROP_RESTRICT"; - case 1: - return "DROP_CASCADE"; - default: - throw new Error("Key not recognized in enum DropBehavior"); - } - } - case "AlterTableType": - { - switch (key) { - case "AT_AddColumn": - return 0; - case "AT_AddColumnToView": - return 1; - case "AT_ColumnDefault": - return 2; - case "AT_CookedColumnDefault": - return 3; - case "AT_DropNotNull": - return 4; - case "AT_SetNotNull": - return 5; - case "AT_DropExpression": - return 6; - case "AT_CheckNotNull": - return 7; - case "AT_SetStatistics": - return 8; - case "AT_SetOptions": - return 9; - case "AT_ResetOptions": - return 10; - case "AT_SetStorage": - return 11; - case "AT_SetCompression": - return 12; - case "AT_DropColumn": - return 13; - case "AT_AddIndex": - return 14; - case "AT_ReAddIndex": - return 15; - case "AT_AddConstraint": - return 16; - case "AT_ReAddConstraint": - return 17; - case "AT_ReAddDomainConstraint": - return 18; - case "AT_AlterConstraint": - return 19; - case "AT_ValidateConstraint": - return 20; - case "AT_AddIndexConstraint": - return 21; - case "AT_DropConstraint": - return 22; - case "AT_ReAddComment": - return 23; - case "AT_AlterColumnType": - return 24; - case "AT_AlterColumnGenericOptions": - return 25; - case "AT_ChangeOwner": - return 26; - case "AT_ClusterOn": - return 27; - case "AT_DropCluster": - return 28; - case "AT_SetLogged": - return 29; - case "AT_SetUnLogged": - return 30; - case "AT_DropOids": - return 31; - case "AT_SetAccessMethod": - return 32; - case "AT_SetTableSpace": - return 33; - case "AT_SetRelOptions": - return 34; - case "AT_ResetRelOptions": - return 35; - case "AT_ReplaceRelOptions": - return 36; - case "AT_EnableTrig": - return 37; - case "AT_EnableAlwaysTrig": - return 38; - case "AT_EnableReplicaTrig": - return 39; - case "AT_DisableTrig": - return 40; - case "AT_EnableTrigAll": - return 41; - case "AT_DisableTrigAll": - return 42; - case "AT_EnableTrigUser": - return 43; - case "AT_DisableTrigUser": - return 44; - case "AT_EnableRule": - return 45; - case "AT_EnableAlwaysRule": - return 46; - case "AT_EnableReplicaRule": - return 47; - case "AT_DisableRule": - return 48; - case "AT_AddInherit": - return 49; - case "AT_DropInherit": - return 50; - case "AT_AddOf": - return 51; - case "AT_DropOf": - return 52; - case "AT_ReplicaIdentity": - return 53; - case "AT_EnableRowSecurity": - return 54; - case "AT_DisableRowSecurity": - return 55; - case "AT_ForceRowSecurity": - return 56; - case "AT_NoForceRowSecurity": - return 57; - case "AT_GenericOptions": - return 58; - case "AT_AttachPartition": - return 59; - case "AT_DetachPartition": - return 60; - case "AT_DetachPartitionFinalize": - return 61; - case "AT_AddIdentity": - return 62; - case "AT_SetIdentity": - return 63; - case "AT_DropIdentity": - return 64; - case "AT_ReAddStatistics": - return 65; - case 0: - return "AT_AddColumn"; - case 1: - return "AT_AddColumnToView"; - case 2: - return "AT_ColumnDefault"; - case 3: - return "AT_CookedColumnDefault"; - case 4: - return "AT_DropNotNull"; - case 5: - return "AT_SetNotNull"; - case 6: - return "AT_DropExpression"; - case 7: - return "AT_CheckNotNull"; - case 8: - return "AT_SetStatistics"; - case 9: - return "AT_SetOptions"; - case 10: - return "AT_ResetOptions"; - case 11: - return "AT_SetStorage"; - case 12: - return "AT_SetCompression"; - case 13: - return "AT_DropColumn"; - case 14: - return "AT_AddIndex"; - case 15: - return "AT_ReAddIndex"; - case 16: - return "AT_AddConstraint"; - case 17: - return "AT_ReAddConstraint"; - case 18: - return "AT_ReAddDomainConstraint"; - case 19: - return "AT_AlterConstraint"; - case 20: - return "AT_ValidateConstraint"; - case 21: - return "AT_AddIndexConstraint"; - case 22: - return "AT_DropConstraint"; - case 23: - return "AT_ReAddComment"; - case 24: - return "AT_AlterColumnType"; - case 25: - return "AT_AlterColumnGenericOptions"; - case 26: - return "AT_ChangeOwner"; - case 27: - return "AT_ClusterOn"; - case 28: - return "AT_DropCluster"; - case 29: - return "AT_SetLogged"; - case 30: - return "AT_SetUnLogged"; - case 31: - return "AT_DropOids"; - case 32: - return "AT_SetAccessMethod"; - case 33: - return "AT_SetTableSpace"; - case 34: - return "AT_SetRelOptions"; - case 35: - return "AT_ResetRelOptions"; - case 36: - return "AT_ReplaceRelOptions"; - case 37: - return "AT_EnableTrig"; - case 38: - return "AT_EnableAlwaysTrig"; - case 39: - return "AT_EnableReplicaTrig"; - case 40: - return "AT_DisableTrig"; - case 41: - return "AT_EnableTrigAll"; - case 42: - return "AT_DisableTrigAll"; - case 43: - return "AT_EnableTrigUser"; - case 44: - return "AT_DisableTrigUser"; - case 45: - return "AT_EnableRule"; - case 46: - return "AT_EnableAlwaysRule"; - case 47: - return "AT_EnableReplicaRule"; - case 48: - return "AT_DisableRule"; - case 49: - return "AT_AddInherit"; - case 50: - return "AT_DropInherit"; - case 51: - return "AT_AddOf"; - case 52: - return "AT_DropOf"; - case 53: - return "AT_ReplicaIdentity"; - case 54: - return "AT_EnableRowSecurity"; - case 55: - return "AT_DisableRowSecurity"; - case 56: - return "AT_ForceRowSecurity"; - case 57: - return "AT_NoForceRowSecurity"; - case 58: - return "AT_GenericOptions"; - case 59: - return "AT_AttachPartition"; - case 60: - return "AT_DetachPartition"; - case 61: - return "AT_DetachPartitionFinalize"; - case 62: - return "AT_AddIdentity"; - case 63: - return "AT_SetIdentity"; - case 64: - return "AT_DropIdentity"; - case 65: - return "AT_ReAddStatistics"; - default: - throw new Error("Key not recognized in enum AlterTableType"); - } - } - case "GrantTargetType": - { - switch (key) { - case "ACL_TARGET_OBJECT": - return 0; - case "ACL_TARGET_ALL_IN_SCHEMA": - return 1; - case "ACL_TARGET_DEFAULTS": - return 2; - case 0: - return "ACL_TARGET_OBJECT"; - case 1: - return "ACL_TARGET_ALL_IN_SCHEMA"; - case 2: - return "ACL_TARGET_DEFAULTS"; - default: - throw new Error("Key not recognized in enum GrantTargetType"); - } - } - case "VariableSetKind": - { - switch (key) { - case "VAR_SET_VALUE": - return 0; - case "VAR_SET_DEFAULT": - return 1; - case "VAR_SET_CURRENT": - return 2; - case "VAR_SET_MULTI": - return 3; - case "VAR_RESET": - return 4; - case "VAR_RESET_ALL": - return 5; - case 0: - return "VAR_SET_VALUE"; - case 1: - return "VAR_SET_DEFAULT"; - case 2: - return "VAR_SET_CURRENT"; - case 3: - return "VAR_SET_MULTI"; - case 4: - return "VAR_RESET"; - case 5: - return "VAR_RESET_ALL"; - default: - throw new Error("Key not recognized in enum VariableSetKind"); - } - } - case "ConstrType": - { - switch (key) { - case "CONSTR_NULL": - return 0; - case "CONSTR_NOTNULL": - return 1; - case "CONSTR_DEFAULT": - return 2; - case "CONSTR_IDENTITY": - return 3; - case "CONSTR_GENERATED": - return 4; - case "CONSTR_CHECK": - return 5; - case "CONSTR_PRIMARY": - return 6; - case "CONSTR_UNIQUE": - return 7; - case "CONSTR_EXCLUSION": - return 8; - case "CONSTR_FOREIGN": - return 9; - case "CONSTR_ATTR_DEFERRABLE": - return 10; - case "CONSTR_ATTR_NOT_DEFERRABLE": - return 11; - case "CONSTR_ATTR_DEFERRED": - return 12; - case "CONSTR_ATTR_IMMEDIATE": - return 13; - case 0: - return "CONSTR_NULL"; - case 1: - return "CONSTR_NOTNULL"; - case 2: - return "CONSTR_DEFAULT"; - case 3: - return "CONSTR_IDENTITY"; - case 4: - return "CONSTR_GENERATED"; - case 5: - return "CONSTR_CHECK"; - case 6: - return "CONSTR_PRIMARY"; - case 7: - return "CONSTR_UNIQUE"; - case 8: - return "CONSTR_EXCLUSION"; - case 9: - return "CONSTR_FOREIGN"; - case 10: - return "CONSTR_ATTR_DEFERRABLE"; - case 11: - return "CONSTR_ATTR_NOT_DEFERRABLE"; - case 12: - return "CONSTR_ATTR_DEFERRED"; - case 13: - return "CONSTR_ATTR_IMMEDIATE"; - default: - throw new Error("Key not recognized in enum ConstrType"); - } - } - case "ImportForeignSchemaType": - { - switch (key) { - case "FDW_IMPORT_SCHEMA_ALL": - return 0; - case "FDW_IMPORT_SCHEMA_LIMIT_TO": - return 1; - case "FDW_IMPORT_SCHEMA_EXCEPT": - return 2; - case 0: - return "FDW_IMPORT_SCHEMA_ALL"; - case 1: - return "FDW_IMPORT_SCHEMA_LIMIT_TO"; - case 2: - return "FDW_IMPORT_SCHEMA_EXCEPT"; - default: - throw new Error("Key not recognized in enum ImportForeignSchemaType"); - } - } - case "RoleStmtType": - { - switch (key) { - case "ROLESTMT_ROLE": - return 0; - case "ROLESTMT_USER": - return 1; - case "ROLESTMT_GROUP": - return 2; - case 0: - return "ROLESTMT_ROLE"; - case 1: - return "ROLESTMT_USER"; - case 2: - return "ROLESTMT_GROUP"; - default: - throw new Error("Key not recognized in enum RoleStmtType"); - } - } - case "FetchDirection": - { - switch (key) { - case "FETCH_FORWARD": - return 0; - case "FETCH_BACKWARD": - return 1; - case "FETCH_ABSOLUTE": - return 2; - case "FETCH_RELATIVE": - return 3; - case 0: - return "FETCH_FORWARD"; - case 1: - return "FETCH_BACKWARD"; - case 2: - return "FETCH_ABSOLUTE"; - case 3: - return "FETCH_RELATIVE"; - default: - throw new Error("Key not recognized in enum FetchDirection"); - } - } - case "FunctionParameterMode": - { - switch (key) { - case "FUNC_PARAM_IN": - return 0; - case "FUNC_PARAM_OUT": - return 1; - case "FUNC_PARAM_INOUT": - return 2; - case "FUNC_PARAM_VARIADIC": - return 3; - case "FUNC_PARAM_TABLE": - return 4; - case "FUNC_PARAM_DEFAULT": - return 5; - case 0: - return "FUNC_PARAM_IN"; - case 1: - return "FUNC_PARAM_OUT"; - case 2: - return "FUNC_PARAM_INOUT"; - case 3: - return "FUNC_PARAM_VARIADIC"; - case 4: - return "FUNC_PARAM_TABLE"; - case 5: - return "FUNC_PARAM_DEFAULT"; - default: - throw new Error("Key not recognized in enum FunctionParameterMode"); - } - } - case "TransactionStmtKind": - { - switch (key) { - case "TRANS_STMT_BEGIN": - return 0; - case "TRANS_STMT_START": - return 1; - case "TRANS_STMT_COMMIT": - return 2; - case "TRANS_STMT_ROLLBACK": - return 3; - case "TRANS_STMT_SAVEPOINT": - return 4; - case "TRANS_STMT_RELEASE": - return 5; - case "TRANS_STMT_ROLLBACK_TO": - return 6; - case "TRANS_STMT_PREPARE": - return 7; - case "TRANS_STMT_COMMIT_PREPARED": - return 8; - case "TRANS_STMT_ROLLBACK_PREPARED": - return 9; - case 0: - return "TRANS_STMT_BEGIN"; - case 1: - return "TRANS_STMT_START"; - case 2: - return "TRANS_STMT_COMMIT"; - case 3: - return "TRANS_STMT_ROLLBACK"; - case 4: - return "TRANS_STMT_SAVEPOINT"; - case 5: - return "TRANS_STMT_RELEASE"; - case 6: - return "TRANS_STMT_ROLLBACK_TO"; - case 7: - return "TRANS_STMT_PREPARE"; - case 8: - return "TRANS_STMT_COMMIT_PREPARED"; - case 9: - return "TRANS_STMT_ROLLBACK_PREPARED"; - default: - throw new Error("Key not recognized in enum TransactionStmtKind"); - } - } - case "ViewCheckOption": - { - switch (key) { - case "NO_CHECK_OPTION": - return 0; - case "LOCAL_CHECK_OPTION": - return 1; - case "CASCADED_CHECK_OPTION": - return 2; - case 0: - return "NO_CHECK_OPTION"; - case 1: - return "LOCAL_CHECK_OPTION"; - case 2: - return "CASCADED_CHECK_OPTION"; - default: - throw new Error("Key not recognized in enum ViewCheckOption"); - } - } - case "DiscardMode": - { - switch (key) { - case "DISCARD_ALL": - return 0; - case "DISCARD_PLANS": - return 1; - case "DISCARD_SEQUENCES": - return 2; - case "DISCARD_TEMP": - return 3; - case 0: - return "DISCARD_ALL"; - case 1: - return "DISCARD_PLANS"; - case 2: - return "DISCARD_SEQUENCES"; - case 3: - return "DISCARD_TEMP"; - default: - throw new Error("Key not recognized in enum DiscardMode"); - } - } - case "ReindexObjectType": - { - switch (key) { - case "REINDEX_OBJECT_INDEX": - return 0; - case "REINDEX_OBJECT_TABLE": - return 1; - case "REINDEX_OBJECT_SCHEMA": - return 2; - case "REINDEX_OBJECT_SYSTEM": - return 3; - case "REINDEX_OBJECT_DATABASE": - return 4; - case 0: - return "REINDEX_OBJECT_INDEX"; - case 1: - return "REINDEX_OBJECT_TABLE"; - case 2: - return "REINDEX_OBJECT_SCHEMA"; - case 3: - return "REINDEX_OBJECT_SYSTEM"; - case 4: - return "REINDEX_OBJECT_DATABASE"; - default: - throw new Error("Key not recognized in enum ReindexObjectType"); - } - } - case "AlterTSConfigType": - { - switch (key) { - case "ALTER_TSCONFIG_ADD_MAPPING": - return 0; - case "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN": - return 1; - case "ALTER_TSCONFIG_REPLACE_DICT": - return 2; - case "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN": - return 3; - case "ALTER_TSCONFIG_DROP_MAPPING": - return 4; - case 0: - return "ALTER_TSCONFIG_ADD_MAPPING"; - case 1: - return "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN"; - case 2: - return "ALTER_TSCONFIG_REPLACE_DICT"; - case 3: - return "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN"; - case 4: - return "ALTER_TSCONFIG_DROP_MAPPING"; - default: - throw new Error("Key not recognized in enum AlterTSConfigType"); - } - } - case "PublicationObjSpecType": - { - switch (key) { - case "PUBLICATIONOBJ_TABLE": - return 0; - case "PUBLICATIONOBJ_TABLES_IN_SCHEMA": - return 1; - case "PUBLICATIONOBJ_TABLES_IN_CUR_SCHEMA": - return 2; - case "PUBLICATIONOBJ_CONTINUATION": - return 3; - case 0: - return "PUBLICATIONOBJ_TABLE"; - case 1: - return "PUBLICATIONOBJ_TABLES_IN_SCHEMA"; - case 2: - return "PUBLICATIONOBJ_TABLES_IN_CUR_SCHEMA"; - case 3: - return "PUBLICATIONOBJ_CONTINUATION"; - default: - throw new Error("Key not recognized in enum PublicationObjSpecType"); - } - } - case "AlterPublicationAction": - { - switch (key) { - case "AP_AddObjects": - return 0; - case "AP_DropObjects": - return 1; - case "AP_SetObjects": - return 2; - case 0: - return "AP_AddObjects"; - case 1: - return "AP_DropObjects"; - case 2: - return "AP_SetObjects"; - default: - throw new Error("Key not recognized in enum AlterPublicationAction"); - } - } - case "AlterSubscriptionType": - { - switch (key) { - case "ALTER_SUBSCRIPTION_OPTIONS": - return 0; - case "ALTER_SUBSCRIPTION_CONNECTION": - return 1; - case "ALTER_SUBSCRIPTION_SET_PUBLICATION": - return 2; - case "ALTER_SUBSCRIPTION_ADD_PUBLICATION": - return 3; - case "ALTER_SUBSCRIPTION_DROP_PUBLICATION": - return 4; - case "ALTER_SUBSCRIPTION_REFRESH": - return 5; - case "ALTER_SUBSCRIPTION_ENABLED": - return 6; - case "ALTER_SUBSCRIPTION_SKIP": - return 7; - case 0: - return "ALTER_SUBSCRIPTION_OPTIONS"; - case 1: - return "ALTER_SUBSCRIPTION_CONNECTION"; - case 2: - return "ALTER_SUBSCRIPTION_SET_PUBLICATION"; - case 3: - return "ALTER_SUBSCRIPTION_ADD_PUBLICATION"; - case 4: - return "ALTER_SUBSCRIPTION_DROP_PUBLICATION"; - case 5: - return "ALTER_SUBSCRIPTION_REFRESH"; - case 6: - return "ALTER_SUBSCRIPTION_ENABLED"; - case 7: - return "ALTER_SUBSCRIPTION_SKIP"; - default: - throw new Error("Key not recognized in enum AlterSubscriptionType"); - } - } - case "OnCommitAction": - { - switch (key) { - case "ONCOMMIT_NOOP": - return 0; - case "ONCOMMIT_PRESERVE_ROWS": - return 1; - case "ONCOMMIT_DELETE_ROWS": - return 2; - case "ONCOMMIT_DROP": - return 3; - case 0: - return "ONCOMMIT_NOOP"; - case 1: - return "ONCOMMIT_PRESERVE_ROWS"; - case 2: - return "ONCOMMIT_DELETE_ROWS"; - case 3: - return "ONCOMMIT_DROP"; - default: - throw new Error("Key not recognized in enum OnCommitAction"); - } - } - case "ParamKind": - { - switch (key) { - case "PARAM_EXTERN": - return 0; - case "PARAM_EXEC": - return 1; - case "PARAM_SUBLINK": - return 2; - case "PARAM_MULTIEXPR": - return 3; - case 0: - return "PARAM_EXTERN"; - case 1: - return "PARAM_EXEC"; - case 2: - return "PARAM_SUBLINK"; - case 3: - return "PARAM_MULTIEXPR"; - default: - throw new Error("Key not recognized in enum ParamKind"); - } - } - case "CoercionContext": - { - switch (key) { - case "COERCION_IMPLICIT": - return 0; - case "COERCION_ASSIGNMENT": - return 1; - case "COERCION_PLPGSQL": - return 2; - case "COERCION_EXPLICIT": - return 3; - case 0: - return "COERCION_IMPLICIT"; - case 1: - return "COERCION_ASSIGNMENT"; - case 2: - return "COERCION_PLPGSQL"; - case 3: - return "COERCION_EXPLICIT"; - default: - throw new Error("Key not recognized in enum CoercionContext"); - } - } - case "CoercionForm": - { - switch (key) { - case "COERCE_EXPLICIT_CALL": - return 0; - case "COERCE_EXPLICIT_CAST": - return 1; - case "COERCE_IMPLICIT_CAST": - return 2; - case "COERCE_SQL_SYNTAX": - return 3; - case 0: - return "COERCE_EXPLICIT_CALL"; - case 1: - return "COERCE_EXPLICIT_CAST"; - case 2: - return "COERCE_IMPLICIT_CAST"; - case 3: - return "COERCE_SQL_SYNTAX"; - default: - throw new Error("Key not recognized in enum CoercionForm"); - } - } - case "BoolExprType": - { - switch (key) { - case "AND_EXPR": - return 0; - case "OR_EXPR": - return 1; - case "NOT_EXPR": - return 2; - case 0: - return "AND_EXPR"; - case 1: - return "OR_EXPR"; - case 2: - return "NOT_EXPR"; - default: - throw new Error("Key not recognized in enum BoolExprType"); - } - } - case "SubLinkType": - { - switch (key) { - case "EXISTS_SUBLINK": - return 0; - case "ALL_SUBLINK": - return 1; - case "ANY_SUBLINK": - return 2; - case "ROWCOMPARE_SUBLINK": - return 3; - case "EXPR_SUBLINK": - return 4; - case "MULTIEXPR_SUBLINK": - return 5; - case "ARRAY_SUBLINK": - return 6; - case "CTE_SUBLINK": - return 7; - case 0: - return "EXISTS_SUBLINK"; - case 1: - return "ALL_SUBLINK"; - case 2: - return "ANY_SUBLINK"; - case 3: - return "ROWCOMPARE_SUBLINK"; - case 4: - return "EXPR_SUBLINK"; - case 5: - return "MULTIEXPR_SUBLINK"; - case 6: - return "ARRAY_SUBLINK"; - case 7: - return "CTE_SUBLINK"; - default: - throw new Error("Key not recognized in enum SubLinkType"); - } - } - case "RowCompareType": - { - switch (key) { - case "ROWCOMPARE_LT": - return 0; - case "ROWCOMPARE_LE": - return 1; - case "ROWCOMPARE_EQ": - return 2; - case "ROWCOMPARE_GE": - return 3; - case "ROWCOMPARE_GT": - return 4; - case "ROWCOMPARE_NE": - return 5; - case 0: - return "ROWCOMPARE_LT"; - case 1: - return "ROWCOMPARE_LE"; - case 2: - return "ROWCOMPARE_EQ"; - case 3: - return "ROWCOMPARE_GE"; - case 4: - return "ROWCOMPARE_GT"; - case 5: - return "ROWCOMPARE_NE"; - default: - throw new Error("Key not recognized in enum RowCompareType"); - } - } - case "MinMaxOp": - { - switch (key) { - case "IS_GREATEST": - return 0; - case "IS_LEAST": - return 1; - case 0: - return "IS_GREATEST"; - case 1: - return "IS_LEAST"; - default: - throw new Error("Key not recognized in enum MinMaxOp"); - } - } - case "SQLValueFunctionOp": - { - switch (key) { - case "SVFOP_CURRENT_DATE": - return 0; - case "SVFOP_CURRENT_TIME": - return 1; - case "SVFOP_CURRENT_TIME_N": - return 2; - case "SVFOP_CURRENT_TIMESTAMP": - return 3; - case "SVFOP_CURRENT_TIMESTAMP_N": - return 4; - case "SVFOP_LOCALTIME": - return 5; - case "SVFOP_LOCALTIME_N": - return 6; - case "SVFOP_LOCALTIMESTAMP": - return 7; - case "SVFOP_LOCALTIMESTAMP_N": - return 8; - case "SVFOP_CURRENT_ROLE": - return 9; - case "SVFOP_CURRENT_USER": - return 10; - case "SVFOP_USER": - return 11; - case "SVFOP_SESSION_USER": - return 12; - case "SVFOP_CURRENT_CATALOG": - return 13; - case "SVFOP_CURRENT_SCHEMA": - return 14; - case 0: - return "SVFOP_CURRENT_DATE"; - case 1: - return "SVFOP_CURRENT_TIME"; - case 2: - return "SVFOP_CURRENT_TIME_N"; - case 3: - return "SVFOP_CURRENT_TIMESTAMP"; - case 4: - return "SVFOP_CURRENT_TIMESTAMP_N"; - case 5: - return "SVFOP_LOCALTIME"; - case 6: - return "SVFOP_LOCALTIME_N"; - case 7: - return "SVFOP_LOCALTIMESTAMP"; - case 8: - return "SVFOP_LOCALTIMESTAMP_N"; - case 9: - return "SVFOP_CURRENT_ROLE"; - case 10: - return "SVFOP_CURRENT_USER"; - case 11: - return "SVFOP_USER"; - case 12: - return "SVFOP_SESSION_USER"; - case 13: - return "SVFOP_CURRENT_CATALOG"; - case 14: - return "SVFOP_CURRENT_SCHEMA"; - default: - throw new Error("Key not recognized in enum SQLValueFunctionOp"); - } - } - case "XmlExprOp": - { - switch (key) { - case "IS_XMLCONCAT": - return 0; - case "IS_XMLELEMENT": - return 1; - case "IS_XMLFOREST": - return 2; - case "IS_XMLPARSE": - return 3; - case "IS_XMLPI": - return 4; - case "IS_XMLROOT": - return 5; - case "IS_XMLSERIALIZE": - return 6; - case "IS_DOCUMENT": - return 7; - case 0: - return "IS_XMLCONCAT"; - case 1: - return "IS_XMLELEMENT"; - case 2: - return "IS_XMLFOREST"; - case 3: - return "IS_XMLPARSE"; - case 4: - return "IS_XMLPI"; - case 5: - return "IS_XMLROOT"; - case 6: - return "IS_XMLSERIALIZE"; - case 7: - return "IS_DOCUMENT"; - default: - throw new Error("Key not recognized in enum XmlExprOp"); - } - } - case "XmlOptionType": - { - switch (key) { - case "XMLOPTION_DOCUMENT": - return 0; - case "XMLOPTION_CONTENT": - return 1; - case 0: - return "XMLOPTION_DOCUMENT"; - case 1: - return "XMLOPTION_CONTENT"; - default: - throw new Error("Key not recognized in enum XmlOptionType"); - } - } - case "JsonEncoding": - { - switch (key) { - case "JS_ENC_DEFAULT": - return 0; - case "JS_ENC_UTF8": - return 1; - case "JS_ENC_UTF16": - return 2; - case "JS_ENC_UTF32": - return 3; - case 0: - return "JS_ENC_DEFAULT"; - case 1: - return "JS_ENC_UTF8"; - case 2: - return "JS_ENC_UTF16"; - case 3: - return "JS_ENC_UTF32"; - default: - throw new Error("Key not recognized in enum JsonEncoding"); - } - } - case "JsonFormatType": - { - switch (key) { - case "JS_FORMAT_DEFAULT": - return 0; - case "JS_FORMAT_JSON": - return 1; - case "JS_FORMAT_JSONB": - return 2; - case 0: - return "JS_FORMAT_DEFAULT"; - case 1: - return "JS_FORMAT_JSON"; - case 2: - return "JS_FORMAT_JSONB"; - default: - throw new Error("Key not recognized in enum JsonFormatType"); - } - } - case "JsonConstructorType": - { - switch (key) { - case "JSCTOR_JSON_OBJECT": - return 0; - case "JSCTOR_JSON_ARRAY": - return 1; - case "JSCTOR_JSON_OBJECTAGG": - return 2; - case "JSCTOR_JSON_ARRAYAGG": - return 3; - case 0: - return "JSCTOR_JSON_OBJECT"; - case 1: - return "JSCTOR_JSON_ARRAY"; - case 2: - return "JSCTOR_JSON_OBJECTAGG"; - case 3: - return "JSCTOR_JSON_ARRAYAGG"; - default: - throw new Error("Key not recognized in enum JsonConstructorType"); - } - } - case "JsonValueType": - { - switch (key) { - case "JS_TYPE_ANY": - return 0; - case "JS_TYPE_OBJECT": - return 1; - case "JS_TYPE_ARRAY": - return 2; - case "JS_TYPE_SCALAR": - return 3; - case 0: - return "JS_TYPE_ANY"; - case 1: - return "JS_TYPE_OBJECT"; - case 2: - return "JS_TYPE_ARRAY"; - case 3: - return "JS_TYPE_SCALAR"; - default: - throw new Error("Key not recognized in enum JsonValueType"); - } - } - case "NullTestType": - { - switch (key) { - case "IS_NULL": - return 0; - case "IS_NOT_NULL": - return 1; - case 0: - return "IS_NULL"; - case 1: - return "IS_NOT_NULL"; - default: - throw new Error("Key not recognized in enum NullTestType"); - } - } - case "BoolTestType": - { - switch (key) { - case "IS_TRUE": - return 0; - case "IS_NOT_TRUE": - return 1; - case "IS_FALSE": - return 2; - case "IS_NOT_FALSE": - return 3; - case "IS_UNKNOWN": - return 4; - case "IS_NOT_UNKNOWN": - return 5; - case 0: - return "IS_TRUE"; - case 1: - return "IS_NOT_TRUE"; - case 2: - return "IS_FALSE"; - case 3: - return "IS_NOT_FALSE"; - case 4: - return "IS_UNKNOWN"; - case 5: - return "IS_NOT_UNKNOWN"; - default: - throw new Error("Key not recognized in enum BoolTestType"); - } - } - case "CmdType": - { - switch (key) { - case "CMD_UNKNOWN": - return 0; - case "CMD_SELECT": - return 1; - case "CMD_UPDATE": - return 2; - case "CMD_INSERT": - return 3; - case "CMD_DELETE": - return 4; - case "CMD_MERGE": - return 5; - case "CMD_UTILITY": - return 6; - case "CMD_NOTHING": - return 7; - case 0: - return "CMD_UNKNOWN"; - case 1: - return "CMD_SELECT"; - case 2: - return "CMD_UPDATE"; - case 3: - return "CMD_INSERT"; - case 4: - return "CMD_DELETE"; - case 5: - return "CMD_MERGE"; - case 6: - return "CMD_UTILITY"; - case 7: - return "CMD_NOTHING"; - default: - throw new Error("Key not recognized in enum CmdType"); - } - } - case "JoinType": - { - switch (key) { - case "JOIN_INNER": - return 0; - case "JOIN_LEFT": - return 1; - case "JOIN_FULL": - return 2; - case "JOIN_RIGHT": - return 3; - case "JOIN_SEMI": - return 4; - case "JOIN_ANTI": - return 5; - case "JOIN_RIGHT_ANTI": - return 6; - case "JOIN_UNIQUE_OUTER": - return 7; - case "JOIN_UNIQUE_INNER": - return 8; - case 0: - return "JOIN_INNER"; - case 1: - return "JOIN_LEFT"; - case 2: - return "JOIN_FULL"; - case 3: - return "JOIN_RIGHT"; - case 4: - return "JOIN_SEMI"; - case 5: - return "JOIN_ANTI"; - case 6: - return "JOIN_RIGHT_ANTI"; - case 7: - return "JOIN_UNIQUE_OUTER"; - case 8: - return "JOIN_UNIQUE_INNER"; - default: - throw new Error("Key not recognized in enum JoinType"); - } - } - case "AggStrategy": - { - switch (key) { - case "AGG_PLAIN": - return 0; - case "AGG_SORTED": - return 1; - case "AGG_HASHED": - return 2; - case "AGG_MIXED": - return 3; - case 0: - return "AGG_PLAIN"; - case 1: - return "AGG_SORTED"; - case 2: - return "AGG_HASHED"; - case 3: - return "AGG_MIXED"; - default: - throw new Error("Key not recognized in enum AggStrategy"); - } - } - case "AggSplit": - { - switch (key) { - case "AGGSPLIT_SIMPLE": - return 0; - case "AGGSPLIT_INITIAL_SERIAL": - return 1; - case "AGGSPLIT_FINAL_DESERIAL": - return 2; - case 0: - return "AGGSPLIT_SIMPLE"; - case 1: - return "AGGSPLIT_INITIAL_SERIAL"; - case 2: - return "AGGSPLIT_FINAL_DESERIAL"; - default: - throw new Error("Key not recognized in enum AggSplit"); - } - } - case "SetOpCmd": - { - switch (key) { - case "SETOPCMD_INTERSECT": - return 0; - case "SETOPCMD_INTERSECT_ALL": - return 1; - case "SETOPCMD_EXCEPT": - return 2; - case "SETOPCMD_EXCEPT_ALL": - return 3; - case 0: - return "SETOPCMD_INTERSECT"; - case 1: - return "SETOPCMD_INTERSECT_ALL"; - case 2: - return "SETOPCMD_EXCEPT"; - case 3: - return "SETOPCMD_EXCEPT_ALL"; - default: - throw new Error("Key not recognized in enum SetOpCmd"); - } - } - case "SetOpStrategy": - { - switch (key) { - case "SETOP_SORTED": - return 0; - case "SETOP_HASHED": - return 1; - case 0: - return "SETOP_SORTED"; - case 1: - return "SETOP_HASHED"; - default: - throw new Error("Key not recognized in enum SetOpStrategy"); - } - } - case "OnConflictAction": - { - switch (key) { - case "ONCONFLICT_NONE": - return 0; - case "ONCONFLICT_NOTHING": - return 1; - case "ONCONFLICT_UPDATE": - return 2; - case 0: - return "ONCONFLICT_NONE"; - case 1: - return "ONCONFLICT_NOTHING"; - case 2: - return "ONCONFLICT_UPDATE"; - default: - throw new Error("Key not recognized in enum OnConflictAction"); - } - } - case "LimitOption": - { - switch (key) { - case "LIMIT_OPTION_DEFAULT": - return 0; - case "LIMIT_OPTION_COUNT": - return 1; - case "LIMIT_OPTION_WITH_TIES": - return 2; - case 0: - return "LIMIT_OPTION_DEFAULT"; - case 1: - return "LIMIT_OPTION_COUNT"; - case 2: - return "LIMIT_OPTION_WITH_TIES"; - default: - throw new Error("Key not recognized in enum LimitOption"); - } - } - case "LockClauseStrength": - { - switch (key) { - case "LCS_NONE": - return 0; - case "LCS_FORKEYSHARE": - return 1; - case "LCS_FORSHARE": - return 2; - case "LCS_FORNOKEYUPDATE": - return 3; - case "LCS_FORUPDATE": - return 4; - case 0: - return "LCS_NONE"; - case 1: - return "LCS_FORKEYSHARE"; - case 2: - return "LCS_FORSHARE"; - case 3: - return "LCS_FORNOKEYUPDATE"; - case 4: - return "LCS_FORUPDATE"; - default: - throw new Error("Key not recognized in enum LockClauseStrength"); - } - } - case "LockWaitPolicy": - { - switch (key) { - case "LockWaitBlock": - return 0; - case "LockWaitSkip": - return 1; - case "LockWaitError": - return 2; - case 0: - return "LockWaitBlock"; - case 1: - return "LockWaitSkip"; - case 2: - return "LockWaitError"; - default: - throw new Error("Key not recognized in enum LockWaitPolicy"); - } - } - case "LockTupleMode": - { - switch (key) { - case "LockTupleKeyShare": - return 0; - case "LockTupleShare": - return 1; - case "LockTupleNoKeyExclusive": - return 2; - case "LockTupleExclusive": - return 3; - case 0: - return "LockTupleKeyShare"; - case 1: - return "LockTupleShare"; - case 2: - return "LockTupleNoKeyExclusive"; - case 3: - return "LockTupleExclusive"; - default: - throw new Error("Key not recognized in enum LockTupleMode"); - } - } - case "KeywordKind": - { - switch (key) { - case "NO_KEYWORD": - return 0; - case "UNRESERVED_KEYWORD": - return 1; - case "COL_NAME_KEYWORD": - return 2; - case "TYPE_FUNC_NAME_KEYWORD": - return 3; - case "RESERVED_KEYWORD": - return 4; - case 0: - return "NO_KEYWORD"; - case 1: - return "UNRESERVED_KEYWORD"; - case 2: - return "COL_NAME_KEYWORD"; - case 3: - return "TYPE_FUNC_NAME_KEYWORD"; - case 4: - return "RESERVED_KEYWORD"; - default: - throw new Error("Key not recognized in enum KeywordKind"); - } - } - case "Token": - { - switch (key) { - case "NUL": - return 0; - case "ASCII_36": - return 36; - case "ASCII_37": - return 37; - case "ASCII_40": - return 40; - case "ASCII_41": - return 41; - case "ASCII_42": - return 42; - case "ASCII_43": - return 43; - case "ASCII_44": - return 44; - case "ASCII_45": - return 45; - case "ASCII_46": - return 46; - case "ASCII_47": - return 47; - case "ASCII_58": - return 58; - case "ASCII_59": - return 59; - case "ASCII_60": - return 60; - case "ASCII_61": - return 61; - case "ASCII_62": - return 62; - case "ASCII_63": - return 63; - case "ASCII_91": - return 91; - case "ASCII_92": - return 92; - case "ASCII_93": - return 93; - case "ASCII_94": - return 94; - case "IDENT": - return 258; - case "UIDENT": - return 259; - case "FCONST": - return 260; - case "SCONST": - return 261; - case "USCONST": - return 262; - case "BCONST": - return 263; - case "XCONST": - return 264; - case "Op": - return 265; - case "ICONST": - return 266; - case "PARAM": - return 267; - case "TYPECAST": - return 268; - case "DOT_DOT": - return 269; - case "COLON_EQUALS": - return 270; - case "EQUALS_GREATER": - return 271; - case "LESS_EQUALS": - return 272; - case "GREATER_EQUALS": - return 273; - case "NOT_EQUALS": - return 274; - case "SQL_COMMENT": - return 275; - case "C_COMMENT": - return 276; - case "ABORT_P": - return 277; - case "ABSENT": - return 278; - case "ABSOLUTE_P": - return 279; - case "ACCESS": - return 280; - case "ACTION": - return 281; - case "ADD_P": - return 282; - case "ADMIN": - return 283; - case "AFTER": - return 284; - case "AGGREGATE": - return 285; - case "ALL": - return 286; - case "ALSO": - return 287; - case "ALTER": - return 288; - case "ALWAYS": - return 289; - case "ANALYSE": - return 290; - case "ANALYZE": - return 291; - case "AND": - return 292; - case "ANY": - return 293; - case "ARRAY": - return 294; - case "AS": - return 295; - case "ASC": - return 296; - case "ASENSITIVE": - return 297; - case "ASSERTION": - return 298; - case "ASSIGNMENT": - return 299; - case "ASYMMETRIC": - return 300; - case "ATOMIC": - return 301; - case "AT": - return 302; - case "ATTACH": - return 303; - case "ATTRIBUTE": - return 304; - case "AUTHORIZATION": - return 305; - case "BACKWARD": - return 306; - case "BEFORE": - return 307; - case "BEGIN_P": - return 308; - case "BETWEEN": - return 309; - case "BIGINT": - return 310; - case "BINARY": - return 311; - case "BIT": - return 312; - case "BOOLEAN_P": - return 313; - case "BOTH": - return 314; - case "BREADTH": - return 315; - case "BY": - return 316; - case "CACHE": - return 317; - case "CALL": - return 318; - case "CALLED": - return 319; - case "CASCADE": - return 320; - case "CASCADED": - return 321; - case "CASE": - return 322; - case "CAST": - return 323; - case "CATALOG_P": - return 324; - case "CHAIN": - return 325; - case "CHAR_P": - return 326; - case "CHARACTER": - return 327; - case "CHARACTERISTICS": - return 328; - case "CHECK": - return 329; - case "CHECKPOINT": - return 330; - case "CLASS": - return 331; - case "CLOSE": - return 332; - case "CLUSTER": - return 333; - case "COALESCE": - return 334; - case "COLLATE": - return 335; - case "COLLATION": - return 336; - case "COLUMN": - return 337; - case "COLUMNS": - return 338; - case "COMMENT": - return 339; - case "COMMENTS": - return 340; - case "COMMIT": - return 341; - case "COMMITTED": - return 342; - case "COMPRESSION": - return 343; - case "CONCURRENTLY": - return 344; - case "CONFIGURATION": - return 345; - case "CONFLICT": - return 346; - case "CONNECTION": - return 347; - case "CONSTRAINT": - return 348; - case "CONSTRAINTS": - return 349; - case "CONTENT_P": - return 350; - case "CONTINUE_P": - return 351; - case "CONVERSION_P": - return 352; - case "COPY": - return 353; - case "COST": - return 354; - case "CREATE": - return 355; - case "CROSS": - return 356; - case "CSV": - return 357; - case "CUBE": - return 358; - case "CURRENT_P": - return 359; - case "CURRENT_CATALOG": - return 360; - case "CURRENT_DATE": - return 361; - case "CURRENT_ROLE": - return 362; - case "CURRENT_SCHEMA": - return 363; - case "CURRENT_TIME": - return 364; - case "CURRENT_TIMESTAMP": - return 365; - case "CURRENT_USER": - return 366; - case "CURSOR": - return 367; - case "CYCLE": - return 368; - case "DATA_P": - return 369; - case "DATABASE": - return 370; - case "DAY_P": - return 371; - case "DEALLOCATE": - return 372; - case "DEC": - return 373; - case "DECIMAL_P": - return 374; - case "DECLARE": - return 375; - case "DEFAULT": - return 376; - case "DEFAULTS": - return 377; - case "DEFERRABLE": - return 378; - case "DEFERRED": - return 379; - case "DEFINER": - return 380; - case "DELETE_P": - return 381; - case "DELIMITER": - return 382; - case "DELIMITERS": - return 383; - case "DEPENDS": - return 384; - case "DEPTH": - return 385; - case "DESC": - return 386; - case "DETACH": - return 387; - case "DICTIONARY": - return 388; - case "DISABLE_P": - return 389; - case "DISCARD": - return 390; - case "DISTINCT": - return 391; - case "DO": - return 392; - case "DOCUMENT_P": - return 393; - case "DOMAIN_P": - return 394; - case "DOUBLE_P": - return 395; - case "DROP": - return 396; - case "EACH": - return 397; - case "ELSE": - return 398; - case "ENABLE_P": - return 399; - case "ENCODING": - return 400; - case "ENCRYPTED": - return 401; - case "END_P": - return 402; - case "ENUM_P": - return 403; - case "ESCAPE": - return 404; - case "EVENT": - return 405; - case "EXCEPT": - return 406; - case "EXCLUDE": - return 407; - case "EXCLUDING": - return 408; - case "EXCLUSIVE": - return 409; - case "EXECUTE": - return 410; - case "EXISTS": - return 411; - case "EXPLAIN": - return 412; - case "EXPRESSION": - return 413; - case "EXTENSION": - return 414; - case "EXTERNAL": - return 415; - case "EXTRACT": - return 416; - case "FALSE_P": - return 417; - case "FAMILY": - return 418; - case "FETCH": - return 419; - case "FILTER": - return 420; - case "FINALIZE": - return 421; - case "FIRST_P": - return 422; - case "FLOAT_P": - return 423; - case "FOLLOWING": - return 424; - case "FOR": - return 425; - case "FORCE": - return 426; - case "FOREIGN": - return 427; - case "FORMAT": - return 428; - case "FORWARD": - return 429; - case "FREEZE": - return 430; - case "FROM": - return 431; - case "FULL": - return 432; - case "FUNCTION": - return 433; - case "FUNCTIONS": - return 434; - case "GENERATED": - return 435; - case "GLOBAL": - return 436; - case "GRANT": - return 437; - case "GRANTED": - return 438; - case "GREATEST": - return 439; - case "GROUP_P": - return 440; - case "GROUPING": - return 441; - case "GROUPS": - return 442; - case "HANDLER": - return 443; - case "HAVING": - return 444; - case "HEADER_P": - return 445; - case "HOLD": - return 446; - case "HOUR_P": - return 447; - case "IDENTITY_P": - return 448; - case "IF_P": - return 449; - case "ILIKE": - return 450; - case "IMMEDIATE": - return 451; - case "IMMUTABLE": - return 452; - case "IMPLICIT_P": - return 453; - case "IMPORT_P": - return 454; - case "IN_P": - return 455; - case "INCLUDE": - return 456; - case "INCLUDING": - return 457; - case "INCREMENT": - return 458; - case "INDENT": - return 459; - case "INDEX": - return 460; - case "INDEXES": - return 461; - case "INHERIT": - return 462; - case "INHERITS": - return 463; - case "INITIALLY": - return 464; - case "INLINE_P": - return 465; - case "INNER_P": - return 466; - case "INOUT": - return 467; - case "INPUT_P": - return 468; - case "INSENSITIVE": - return 469; - case "INSERT": - return 470; - case "INSTEAD": - return 471; - case "INT_P": - return 472; - case "INTEGER": - return 473; - case "INTERSECT": - return 474; - case "INTERVAL": - return 475; - case "INTO": - return 476; - case "INVOKER": - return 477; - case "IS": - return 478; - case "ISNULL": - return 479; - case "ISOLATION": - return 480; - case "JOIN": - return 481; - case "JSON": - return 482; - case "JSON_ARRAY": - return 483; - case "JSON_ARRAYAGG": - return 484; - case "JSON_OBJECT": - return 485; - case "JSON_OBJECTAGG": - return 486; - case "KEY": - return 487; - case "KEYS": - return 488; - case "LABEL": - return 489; - case "LANGUAGE": - return 490; - case "LARGE_P": - return 491; - case "LAST_P": - return 492; - case "LATERAL_P": - return 493; - case "LEADING": - return 494; - case "LEAKPROOF": - return 495; - case "LEAST": - return 496; - case "LEFT": - return 497; - case "LEVEL": - return 498; - case "LIKE": - return 499; - case "LIMIT": - return 500; - case "LISTEN": - return 501; - case "LOAD": - return 502; - case "LOCAL": - return 503; - case "LOCALTIME": - return 504; - case "LOCALTIMESTAMP": - return 505; - case "LOCATION": - return 506; - case "LOCK_P": - return 507; - case "LOCKED": - return 508; - case "LOGGED": - return 509; - case "MAPPING": - return 510; - case "MATCH": - return 511; - case "MATCHED": - return 512; - case "MATERIALIZED": - return 513; - case "MAXVALUE": - return 514; - case "MERGE": - return 515; - case "METHOD": - return 516; - case "MINUTE_P": - return 517; - case "MINVALUE": - return 518; - case "MODE": - return 519; - case "MONTH_P": - return 520; - case "MOVE": - return 521; - case "NAME_P": - return 522; - case "NAMES": - return 523; - case "NATIONAL": - return 524; - case "NATURAL": - return 525; - case "NCHAR": - return 526; - case "NEW": - return 527; - case "NEXT": - return 528; - case "NFC": - return 529; - case "NFD": - return 530; - case "NFKC": - return 531; - case "NFKD": - return 532; - case "NO": - return 533; - case "NONE": - return 534; - case "NORMALIZE": - return 535; - case "NORMALIZED": - return 536; - case "NOT": - return 537; - case "NOTHING": - return 538; - case "NOTIFY": - return 539; - case "NOTNULL": - return 540; - case "NOWAIT": - return 541; - case "NULL_P": - return 542; - case "NULLIF": - return 543; - case "NULLS_P": - return 544; - case "NUMERIC": - return 545; - case "OBJECT_P": - return 546; - case "OF": - return 547; - case "OFF": - return 548; - case "OFFSET": - return 549; - case "OIDS": - return 550; - case "OLD": - return 551; - case "ON": - return 552; - case "ONLY": - return 553; - case "OPERATOR": - return 554; - case "OPTION": - return 555; - case "OPTIONS": - return 556; - case "OR": - return 557; - case "ORDER": - return 558; - case "ORDINALITY": - return 559; - case "OTHERS": - return 560; - case "OUT_P": - return 561; - case "OUTER_P": - return 562; - case "OVER": - return 563; - case "OVERLAPS": - return 564; - case "OVERLAY": - return 565; - case "OVERRIDING": - return 566; - case "OWNED": - return 567; - case "OWNER": - return 568; - case "PARALLEL": - return 569; - case "PARAMETER": - return 570; - case "PARSER": - return 571; - case "PARTIAL": - return 572; - case "PARTITION": - return 573; - case "PASSING": - return 574; - case "PASSWORD": - return 575; - case "PLACING": - return 576; - case "PLANS": - return 577; - case "POLICY": - return 578; - case "POSITION": - return 579; - case "PRECEDING": - return 580; - case "PRECISION": - return 581; - case "PRESERVE": - return 582; - case "PREPARE": - return 583; - case "PREPARED": - return 584; - case "PRIMARY": - return 585; - case "PRIOR": - return 586; - case "PRIVILEGES": - return 587; - case "PROCEDURAL": - return 588; - case "PROCEDURE": - return 589; - case "PROCEDURES": - return 590; - case "PROGRAM": - return 591; - case "PUBLICATION": - return 592; - case "QUOTE": - return 593; - case "RANGE": - return 594; - case "READ": - return 595; - case "REAL": - return 596; - case "REASSIGN": - return 597; - case "RECHECK": - return 598; - case "RECURSIVE": - return 599; - case "REF_P": - return 600; - case "REFERENCES": - return 601; - case "REFERENCING": - return 602; - case "REFRESH": - return 603; - case "REINDEX": - return 604; - case "RELATIVE_P": - return 605; - case "RELEASE": - return 606; - case "RENAME": - return 607; - case "REPEATABLE": - return 608; - case "REPLACE": - return 609; - case "REPLICA": - return 610; - case "RESET": - return 611; - case "RESTART": - return 612; - case "RESTRICT": - return 613; - case "RETURN": - return 614; - case "RETURNING": - return 615; - case "RETURNS": - return 616; - case "REVOKE": - return 617; - case "RIGHT": - return 618; - case "ROLE": - return 619; - case "ROLLBACK": - return 620; - case "ROLLUP": - return 621; - case "ROUTINE": - return 622; - case "ROUTINES": - return 623; - case "ROW": - return 624; - case "ROWS": - return 625; - case "RULE": - return 626; - case "SAVEPOINT": - return 627; - case "SCALAR": - return 628; - case "SCHEMA": - return 629; - case "SCHEMAS": - return 630; - case "SCROLL": - return 631; - case "SEARCH": - return 632; - case "SECOND_P": - return 633; - case "SECURITY": - return 634; - case "SELECT": - return 635; - case "SEQUENCE": - return 636; - case "SEQUENCES": - return 637; - case "SERIALIZABLE": - return 638; - case "SERVER": - return 639; - case "SESSION": - return 640; - case "SESSION_USER": - return 641; - case "SET": - return 642; - case "SETS": - return 643; - case "SETOF": - return 644; - case "SHARE": - return 645; - case "SHOW": - return 646; - case "SIMILAR": - return 647; - case "SIMPLE": - return 648; - case "SKIP": - return 649; - case "SMALLINT": - return 650; - case "SNAPSHOT": - return 651; - case "SOME": - return 652; - case "SQL_P": - return 653; - case "STABLE": - return 654; - case "STANDALONE_P": - return 655; - case "START": - return 656; - case "STATEMENT": - return 657; - case "STATISTICS": - return 658; - case "STDIN": - return 659; - case "STDOUT": - return 660; - case "STORAGE": - return 661; - case "STORED": - return 662; - case "STRICT_P": - return 663; - case "STRIP_P": - return 664; - case "SUBSCRIPTION": - return 665; - case "SUBSTRING": - return 666; - case "SUPPORT": - return 667; - case "SYMMETRIC": - return 668; - case "SYSID": - return 669; - case "SYSTEM_P": - return 670; - case "SYSTEM_USER": - return 671; - case "TABLE": - return 672; - case "TABLES": - return 673; - case "TABLESAMPLE": - return 674; - case "TABLESPACE": - return 675; - case "TEMP": - return 676; - case "TEMPLATE": - return 677; - case "TEMPORARY": - return 678; - case "TEXT_P": - return 679; - case "THEN": - return 680; - case "TIES": - return 681; - case "TIME": - return 682; - case "TIMESTAMP": - return 683; - case "TO": - return 684; - case "TRAILING": - return 685; - case "TRANSACTION": - return 686; - case "TRANSFORM": - return 687; - case "TREAT": - return 688; - case "TRIGGER": - return 689; - case "TRIM": - return 690; - case "TRUE_P": - return 691; - case "TRUNCATE": - return 692; - case "TRUSTED": - return 693; - case "TYPE_P": - return 694; - case "TYPES_P": - return 695; - case "UESCAPE": - return 696; - case "UNBOUNDED": - return 697; - case "UNCOMMITTED": - return 698; - case "UNENCRYPTED": - return 699; - case "UNION": - return 700; - case "UNIQUE": - return 701; - case "UNKNOWN": - return 702; - case "UNLISTEN": - return 703; - case "UNLOGGED": - return 704; - case "UNTIL": - return 705; - case "UPDATE": - return 706; - case "USER": - return 707; - case "USING": - return 708; - case "VACUUM": - return 709; - case "VALID": - return 710; - case "VALIDATE": - return 711; - case "VALIDATOR": - return 712; - case "VALUE_P": - return 713; - case "VALUES": - return 714; - case "VARCHAR": - return 715; - case "VARIADIC": - return 716; - case "VARYING": - return 717; - case "VERBOSE": - return 718; - case "VERSION_P": - return 719; - case "VIEW": - return 720; - case "VIEWS": - return 721; - case "VOLATILE": - return 722; - case "WHEN": - return 723; - case "WHERE": - return 724; - case "WHITESPACE_P": - return 725; - case "WINDOW": - return 726; - case "WITH": - return 727; - case "WITHIN": - return 728; - case "WITHOUT": - return 729; - case "WORK": - return 730; - case "WRAPPER": - return 731; - case "WRITE": - return 732; - case "XML_P": - return 733; - case "XMLATTRIBUTES": - return 734; - case "XMLCONCAT": - return 735; - case "XMLELEMENT": - return 736; - case "XMLEXISTS": - return 737; - case "XMLFOREST": - return 738; - case "XMLNAMESPACES": - return 739; - case "XMLPARSE": - return 740; - case "XMLPI": - return 741; - case "XMLROOT": - return 742; - case "XMLSERIALIZE": - return 743; - case "XMLTABLE": - return 744; - case "YEAR_P": - return 745; - case "YES_P": - return 746; - case "ZONE": - return 747; - case "FORMAT_LA": - return 748; - case "NOT_LA": - return 749; - case "NULLS_LA": - return 750; - case "WITH_LA": - return 751; - case "WITHOUT_LA": - return 752; - case "MODE_TYPE_NAME": - return 753; - case "MODE_PLPGSQL_EXPR": - return 754; - case "MODE_PLPGSQL_ASSIGN1": - return 755; - case "MODE_PLPGSQL_ASSIGN2": - return 756; - case "MODE_PLPGSQL_ASSIGN3": - return 757; - case "UMINUS": - return 758; - case 0: - return "NUL"; - case 36: - return "ASCII_36"; - case 37: - return "ASCII_37"; - case 40: - return "ASCII_40"; - case 41: - return "ASCII_41"; - case 42: - return "ASCII_42"; - case 43: - return "ASCII_43"; - case 44: - return "ASCII_44"; - case 45: - return "ASCII_45"; - case 46: - return "ASCII_46"; - case 47: - return "ASCII_47"; - case 58: - return "ASCII_58"; - case 59: - return "ASCII_59"; - case 60: - return "ASCII_60"; - case 61: - return "ASCII_61"; - case 62: - return "ASCII_62"; - case 63: - return "ASCII_63"; - case 91: - return "ASCII_91"; - case 92: - return "ASCII_92"; - case 93: - return "ASCII_93"; - case 94: - return "ASCII_94"; - case 258: - return "IDENT"; - case 259: - return "UIDENT"; - case 260: - return "FCONST"; - case 261: - return "SCONST"; - case 262: - return "USCONST"; - case 263: - return "BCONST"; - case 264: - return "XCONST"; - case 265: - return "Op"; - case 266: - return "ICONST"; - case 267: - return "PARAM"; - case 268: - return "TYPECAST"; - case 269: - return "DOT_DOT"; - case 270: - return "COLON_EQUALS"; - case 271: - return "EQUALS_GREATER"; - case 272: - return "LESS_EQUALS"; - case 273: - return "GREATER_EQUALS"; - case 274: - return "NOT_EQUALS"; - case 275: - return "SQL_COMMENT"; - case 276: - return "C_COMMENT"; - case 277: - return "ABORT_P"; - case 278: - return "ABSENT"; - case 279: - return "ABSOLUTE_P"; - case 280: - return "ACCESS"; - case 281: - return "ACTION"; - case 282: - return "ADD_P"; - case 283: - return "ADMIN"; - case 284: - return "AFTER"; - case 285: - return "AGGREGATE"; - case 286: - return "ALL"; - case 287: - return "ALSO"; - case 288: - return "ALTER"; - case 289: - return "ALWAYS"; - case 290: - return "ANALYSE"; - case 291: - return "ANALYZE"; - case 292: - return "AND"; - case 293: - return "ANY"; - case 294: - return "ARRAY"; - case 295: - return "AS"; - case 296: - return "ASC"; - case 297: - return "ASENSITIVE"; - case 298: - return "ASSERTION"; - case 299: - return "ASSIGNMENT"; - case 300: - return "ASYMMETRIC"; - case 301: - return "ATOMIC"; - case 302: - return "AT"; - case 303: - return "ATTACH"; - case 304: - return "ATTRIBUTE"; - case 305: - return "AUTHORIZATION"; - case 306: - return "BACKWARD"; - case 307: - return "BEFORE"; - case 308: - return "BEGIN_P"; - case 309: - return "BETWEEN"; - case 310: - return "BIGINT"; - case 311: - return "BINARY"; - case 312: - return "BIT"; - case 313: - return "BOOLEAN_P"; - case 314: - return "BOTH"; - case 315: - return "BREADTH"; - case 316: - return "BY"; - case 317: - return "CACHE"; - case 318: - return "CALL"; - case 319: - return "CALLED"; - case 320: - return "CASCADE"; - case 321: - return "CASCADED"; - case 322: - return "CASE"; - case 323: - return "CAST"; - case 324: - return "CATALOG_P"; - case 325: - return "CHAIN"; - case 326: - return "CHAR_P"; - case 327: - return "CHARACTER"; - case 328: - return "CHARACTERISTICS"; - case 329: - return "CHECK"; - case 330: - return "CHECKPOINT"; - case 331: - return "CLASS"; - case 332: - return "CLOSE"; - case 333: - return "CLUSTER"; - case 334: - return "COALESCE"; - case 335: - return "COLLATE"; - case 336: - return "COLLATION"; - case 337: - return "COLUMN"; - case 338: - return "COLUMNS"; - case 339: - return "COMMENT"; - case 340: - return "COMMENTS"; - case 341: - return "COMMIT"; - case 342: - return "COMMITTED"; - case 343: - return "COMPRESSION"; - case 344: - return "CONCURRENTLY"; - case 345: - return "CONFIGURATION"; - case 346: - return "CONFLICT"; - case 347: - return "CONNECTION"; - case 348: - return "CONSTRAINT"; - case 349: - return "CONSTRAINTS"; - case 350: - return "CONTENT_P"; - case 351: - return "CONTINUE_P"; - case 352: - return "CONVERSION_P"; - case 353: - return "COPY"; - case 354: - return "COST"; - case 355: - return "CREATE"; - case 356: - return "CROSS"; - case 357: - return "CSV"; - case 358: - return "CUBE"; - case 359: - return "CURRENT_P"; - case 360: - return "CURRENT_CATALOG"; - case 361: - return "CURRENT_DATE"; - case 362: - return "CURRENT_ROLE"; - case 363: - return "CURRENT_SCHEMA"; - case 364: - return "CURRENT_TIME"; - case 365: - return "CURRENT_TIMESTAMP"; - case 366: - return "CURRENT_USER"; - case 367: - return "CURSOR"; - case 368: - return "CYCLE"; - case 369: - return "DATA_P"; - case 370: - return "DATABASE"; - case 371: - return "DAY_P"; - case 372: - return "DEALLOCATE"; - case 373: - return "DEC"; - case 374: - return "DECIMAL_P"; - case 375: - return "DECLARE"; - case 376: - return "DEFAULT"; - case 377: - return "DEFAULTS"; - case 378: - return "DEFERRABLE"; - case 379: - return "DEFERRED"; - case 380: - return "DEFINER"; - case 381: - return "DELETE_P"; - case 382: - return "DELIMITER"; - case 383: - return "DELIMITERS"; - case 384: - return "DEPENDS"; - case 385: - return "DEPTH"; - case 386: - return "DESC"; - case 387: - return "DETACH"; - case 388: - return "DICTIONARY"; - case 389: - return "DISABLE_P"; - case 390: - return "DISCARD"; - case 391: - return "DISTINCT"; - case 392: - return "DO"; - case 393: - return "DOCUMENT_P"; - case 394: - return "DOMAIN_P"; - case 395: - return "DOUBLE_P"; - case 396: - return "DROP"; - case 397: - return "EACH"; - case 398: - return "ELSE"; - case 399: - return "ENABLE_P"; - case 400: - return "ENCODING"; - case 401: - return "ENCRYPTED"; - case 402: - return "END_P"; - case 403: - return "ENUM_P"; - case 404: - return "ESCAPE"; - case 405: - return "EVENT"; - case 406: - return "EXCEPT"; - case 407: - return "EXCLUDE"; - case 408: - return "EXCLUDING"; - case 409: - return "EXCLUSIVE"; - case 410: - return "EXECUTE"; - case 411: - return "EXISTS"; - case 412: - return "EXPLAIN"; - case 413: - return "EXPRESSION"; - case 414: - return "EXTENSION"; - case 415: - return "EXTERNAL"; - case 416: - return "EXTRACT"; - case 417: - return "FALSE_P"; - case 418: - return "FAMILY"; - case 419: - return "FETCH"; - case 420: - return "FILTER"; - case 421: - return "FINALIZE"; - case 422: - return "FIRST_P"; - case 423: - return "FLOAT_P"; - case 424: - return "FOLLOWING"; - case 425: - return "FOR"; - case 426: - return "FORCE"; - case 427: - return "FOREIGN"; - case 428: - return "FORMAT"; - case 429: - return "FORWARD"; - case 430: - return "FREEZE"; - case 431: - return "FROM"; - case 432: - return "FULL"; - case 433: - return "FUNCTION"; - case 434: - return "FUNCTIONS"; - case 435: - return "GENERATED"; - case 436: - return "GLOBAL"; - case 437: - return "GRANT"; - case 438: - return "GRANTED"; - case 439: - return "GREATEST"; - case 440: - return "GROUP_P"; - case 441: - return "GROUPING"; - case 442: - return "GROUPS"; - case 443: - return "HANDLER"; - case 444: - return "HAVING"; - case 445: - return "HEADER_P"; - case 446: - return "HOLD"; - case 447: - return "HOUR_P"; - case 448: - return "IDENTITY_P"; - case 449: - return "IF_P"; - case 450: - return "ILIKE"; - case 451: - return "IMMEDIATE"; - case 452: - return "IMMUTABLE"; - case 453: - return "IMPLICIT_P"; - case 454: - return "IMPORT_P"; - case 455: - return "IN_P"; - case 456: - return "INCLUDE"; - case 457: - return "INCLUDING"; - case 458: - return "INCREMENT"; - case 459: - return "INDENT"; - case 460: - return "INDEX"; - case 461: - return "INDEXES"; - case 462: - return "INHERIT"; - case 463: - return "INHERITS"; - case 464: - return "INITIALLY"; - case 465: - return "INLINE_P"; - case 466: - return "INNER_P"; - case 467: - return "INOUT"; - case 468: - return "INPUT_P"; - case 469: - return "INSENSITIVE"; - case 470: - return "INSERT"; - case 471: - return "INSTEAD"; - case 472: - return "INT_P"; - case 473: - return "INTEGER"; - case 474: - return "INTERSECT"; - case 475: - return "INTERVAL"; - case 476: - return "INTO"; - case 477: - return "INVOKER"; - case 478: - return "IS"; - case 479: - return "ISNULL"; - case 480: - return "ISOLATION"; - case 481: - return "JOIN"; - case 482: - return "JSON"; - case 483: - return "JSON_ARRAY"; - case 484: - return "JSON_ARRAYAGG"; - case 485: - return "JSON_OBJECT"; - case 486: - return "JSON_OBJECTAGG"; - case 487: - return "KEY"; - case 488: - return "KEYS"; - case 489: - return "LABEL"; - case 490: - return "LANGUAGE"; - case 491: - return "LARGE_P"; - case 492: - return "LAST_P"; - case 493: - return "LATERAL_P"; - case 494: - return "LEADING"; - case 495: - return "LEAKPROOF"; - case 496: - return "LEAST"; - case 497: - return "LEFT"; - case 498: - return "LEVEL"; - case 499: - return "LIKE"; - case 500: - return "LIMIT"; - case 501: - return "LISTEN"; - case 502: - return "LOAD"; - case 503: - return "LOCAL"; - case 504: - return "LOCALTIME"; - case 505: - return "LOCALTIMESTAMP"; - case 506: - return "LOCATION"; - case 507: - return "LOCK_P"; - case 508: - return "LOCKED"; - case 509: - return "LOGGED"; - case 510: - return "MAPPING"; - case 511: - return "MATCH"; - case 512: - return "MATCHED"; - case 513: - return "MATERIALIZED"; - case 514: - return "MAXVALUE"; - case 515: - return "MERGE"; - case 516: - return "METHOD"; - case 517: - return "MINUTE_P"; - case 518: - return "MINVALUE"; - case 519: - return "MODE"; - case 520: - return "MONTH_P"; - case 521: - return "MOVE"; - case 522: - return "NAME_P"; - case 523: - return "NAMES"; - case 524: - return "NATIONAL"; - case 525: - return "NATURAL"; - case 526: - return "NCHAR"; - case 527: - return "NEW"; - case 528: - return "NEXT"; - case 529: - return "NFC"; - case 530: - return "NFD"; - case 531: - return "NFKC"; - case 532: - return "NFKD"; - case 533: - return "NO"; - case 534: - return "NONE"; - case 535: - return "NORMALIZE"; - case 536: - return "NORMALIZED"; - case 537: - return "NOT"; - case 538: - return "NOTHING"; - case 539: - return "NOTIFY"; - case 540: - return "NOTNULL"; - case 541: - return "NOWAIT"; - case 542: - return "NULL_P"; - case 543: - return "NULLIF"; - case 544: - return "NULLS_P"; - case 545: - return "NUMERIC"; - case 546: - return "OBJECT_P"; - case 547: - return "OF"; - case 548: - return "OFF"; - case 549: - return "OFFSET"; - case 550: - return "OIDS"; - case 551: - return "OLD"; - case 552: - return "ON"; - case 553: - return "ONLY"; - case 554: - return "OPERATOR"; - case 555: - return "OPTION"; - case 556: - return "OPTIONS"; - case 557: - return "OR"; - case 558: - return "ORDER"; - case 559: - return "ORDINALITY"; - case 560: - return "OTHERS"; - case 561: - return "OUT_P"; - case 562: - return "OUTER_P"; - case 563: - return "OVER"; - case 564: - return "OVERLAPS"; - case 565: - return "OVERLAY"; - case 566: - return "OVERRIDING"; - case 567: - return "OWNED"; - case 568: - return "OWNER"; - case 569: - return "PARALLEL"; - case 570: - return "PARAMETER"; - case 571: - return "PARSER"; - case 572: - return "PARTIAL"; - case 573: - return "PARTITION"; - case 574: - return "PASSING"; - case 575: - return "PASSWORD"; - case 576: - return "PLACING"; - case 577: - return "PLANS"; - case 578: - return "POLICY"; - case 579: - return "POSITION"; - case 580: - return "PRECEDING"; - case 581: - return "PRECISION"; - case 582: - return "PRESERVE"; - case 583: - return "PREPARE"; - case 584: - return "PREPARED"; - case 585: - return "PRIMARY"; - case 586: - return "PRIOR"; - case 587: - return "PRIVILEGES"; - case 588: - return "PROCEDURAL"; - case 589: - return "PROCEDURE"; - case 590: - return "PROCEDURES"; - case 591: - return "PROGRAM"; - case 592: - return "PUBLICATION"; - case 593: - return "QUOTE"; - case 594: - return "RANGE"; - case 595: - return "READ"; - case 596: - return "REAL"; - case 597: - return "REASSIGN"; - case 598: - return "RECHECK"; - case 599: - return "RECURSIVE"; - case 600: - return "REF_P"; - case 601: - return "REFERENCES"; - case 602: - return "REFERENCING"; - case 603: - return "REFRESH"; - case 604: - return "REINDEX"; - case 605: - return "RELATIVE_P"; - case 606: - return "RELEASE"; - case 607: - return "RENAME"; - case 608: - return "REPEATABLE"; - case 609: - return "REPLACE"; - case 610: - return "REPLICA"; - case 611: - return "RESET"; - case 612: - return "RESTART"; - case 613: - return "RESTRICT"; - case 614: - return "RETURN"; - case 615: - return "RETURNING"; - case 616: - return "RETURNS"; - case 617: - return "REVOKE"; - case 618: - return "RIGHT"; - case 619: - return "ROLE"; - case 620: - return "ROLLBACK"; - case 621: - return "ROLLUP"; - case 622: - return "ROUTINE"; - case 623: - return "ROUTINES"; - case 624: - return "ROW"; - case 625: - return "ROWS"; - case 626: - return "RULE"; - case 627: - return "SAVEPOINT"; - case 628: - return "SCALAR"; - case 629: - return "SCHEMA"; - case 630: - return "SCHEMAS"; - case 631: - return "SCROLL"; - case 632: - return "SEARCH"; - case 633: - return "SECOND_P"; - case 634: - return "SECURITY"; - case 635: - return "SELECT"; - case 636: - return "SEQUENCE"; - case 637: - return "SEQUENCES"; - case 638: - return "SERIALIZABLE"; - case 639: - return "SERVER"; - case 640: - return "SESSION"; - case 641: - return "SESSION_USER"; - case 642: - return "SET"; - case 643: - return "SETS"; - case 644: - return "SETOF"; - case 645: - return "SHARE"; - case 646: - return "SHOW"; - case 647: - return "SIMILAR"; - case 648: - return "SIMPLE"; - case 649: - return "SKIP"; - case 650: - return "SMALLINT"; - case 651: - return "SNAPSHOT"; - case 652: - return "SOME"; - case 653: - return "SQL_P"; - case 654: - return "STABLE"; - case 655: - return "STANDALONE_P"; - case 656: - return "START"; - case 657: - return "STATEMENT"; - case 658: - return "STATISTICS"; - case 659: - return "STDIN"; - case 660: - return "STDOUT"; - case 661: - return "STORAGE"; - case 662: - return "STORED"; - case 663: - return "STRICT_P"; - case 664: - return "STRIP_P"; - case 665: - return "SUBSCRIPTION"; - case 666: - return "SUBSTRING"; - case 667: - return "SUPPORT"; - case 668: - return "SYMMETRIC"; - case 669: - return "SYSID"; - case 670: - return "SYSTEM_P"; - case 671: - return "SYSTEM_USER"; - case 672: - return "TABLE"; - case 673: - return "TABLES"; - case 674: - return "TABLESAMPLE"; - case 675: - return "TABLESPACE"; - case 676: - return "TEMP"; - case 677: - return "TEMPLATE"; - case 678: - return "TEMPORARY"; - case 679: - return "TEXT_P"; - case 680: - return "THEN"; - case 681: - return "TIES"; - case 682: - return "TIME"; - case 683: - return "TIMESTAMP"; - case 684: - return "TO"; - case 685: - return "TRAILING"; - case 686: - return "TRANSACTION"; - case 687: - return "TRANSFORM"; - case 688: - return "TREAT"; - case 689: - return "TRIGGER"; - case 690: - return "TRIM"; - case 691: - return "TRUE_P"; - case 692: - return "TRUNCATE"; - case 693: - return "TRUSTED"; - case 694: - return "TYPE_P"; - case 695: - return "TYPES_P"; - case 696: - return "UESCAPE"; - case 697: - return "UNBOUNDED"; - case 698: - return "UNCOMMITTED"; - case 699: - return "UNENCRYPTED"; - case 700: - return "UNION"; - case 701: - return "UNIQUE"; - case 702: - return "UNKNOWN"; - case 703: - return "UNLISTEN"; - case 704: - return "UNLOGGED"; - case 705: - return "UNTIL"; - case 706: - return "UPDATE"; - case 707: - return "USER"; - case 708: - return "USING"; - case 709: - return "VACUUM"; - case 710: - return "VALID"; - case 711: - return "VALIDATE"; - case 712: - return "VALIDATOR"; - case 713: - return "VALUE_P"; - case 714: - return "VALUES"; - case 715: - return "VARCHAR"; - case 716: - return "VARIADIC"; - case 717: - return "VARYING"; - case 718: - return "VERBOSE"; - case 719: - return "VERSION_P"; - case 720: - return "VIEW"; - case 721: - return "VIEWS"; - case 722: - return "VOLATILE"; - case 723: - return "WHEN"; - case 724: - return "WHERE"; - case 725: - return "WHITESPACE_P"; - case 726: - return "WINDOW"; - case 727: - return "WITH"; - case 728: - return "WITHIN"; - case 729: - return "WITHOUT"; - case 730: - return "WORK"; - case 731: - return "WRAPPER"; - case 732: - return "WRITE"; - case 733: - return "XML_P"; - case 734: - return "XMLATTRIBUTES"; - case 735: - return "XMLCONCAT"; - case 736: - return "XMLELEMENT"; - case 737: - return "XMLEXISTS"; - case 738: - return "XMLFOREST"; - case 739: - return "XMLNAMESPACES"; - case 740: - return "XMLPARSE"; - case 741: - return "XMLPI"; - case 742: - return "XMLROOT"; - case 743: - return "XMLSERIALIZE"; - case 744: - return "XMLTABLE"; - case 745: - return "YEAR_P"; - case 746: - return "YES_P"; - case 747: - return "ZONE"; - case 748: - return "FORMAT_LA"; - case 749: - return "NOT_LA"; - case 750: - return "NULLS_LA"; - case 751: - return "WITH_LA"; - case 752: - return "WITHOUT_LA"; - case 753: - return "MODE_TYPE_NAME"; - case 754: - return "MODE_PLPGSQL_EXPR"; - case 755: - return "MODE_PLPGSQL_ASSIGN1"; - case 756: - return "MODE_PLPGSQL_ASSIGN2"; - case 757: - return "MODE_PLPGSQL_ASSIGN3"; - case 758: - return "UMINUS"; - default: - throw new Error("Key not recognized in enum Token"); - } - } - default: - throw new Error("Enum type not recognized"); - } -};", - "file": "bidirectional.ts", + "file": "enum-to-int-nested.ts", }, +] +`; + +exports[`enum utils switch statements format generates bidirectional enum value functions 1`] = ` +[ { "code": "/** * This file was automatically generated by pg-proto-parser@latest. diff --git a/packages/proto-parser/__tests__/__snapshots__/utils.test.ts.snap b/packages/proto-parser/__tests__/__snapshots__/utils.test.ts.snap index 8f414b3d..f086d5bf 100644 --- a/packages/proto-parser/__tests__/__snapshots__/utils.test.ts.snap +++ b/packages/proto-parser/__tests__/__snapshots__/utils.test.ts.snap @@ -4246,131 +4246,59 @@ export const getEnumValue = (enumType: EnumType, key: string | number) => { import _o from "nested-obj"; import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; export default { - parseResult(_p?: ParseResult, isNode?: boolean): ParseResult | { - ParseResult: ParseResult; - } { + parseResult(_p?: ParseResult): ParseResult { const _j = {} as ParseResult; _o.set(_j, "version", _p?.version); _o.set(_j, "stmts", _p?.stmts); - if (isNode) { - return { - ParseResult: _j - }; - } return _j; }, - scanResult(_p?: ScanResult, isNode?: boolean): ScanResult | { - ScanResult: ScanResult; - } { + scanResult(_p?: ScanResult): ScanResult { const _j = {} as ScanResult; _o.set(_j, "version", _p?.version); _o.set(_j, "tokens", _p?.tokens); - if (isNode) { - return { - ScanResult: _j - }; - } return _j; }, - integer(_p?: Integer, isNode?: boolean): Integer | { - Integer: Integer; - } { + integer(_p?: Integer): Integer { const _j = {} as Integer; _o.set(_j, "ival", _p?.ival); - if (isNode) { - return { - Integer: _j - }; - } return _j; }, - float(_p?: Float, isNode?: boolean): Float | { - Float: Float; - } { + float(_p?: Float): Float { const _j = {} as Float; _o.set(_j, "fval", _p?.fval); - if (isNode) { - return { - Float: _j - }; - } return _j; }, - boolean(_p?: Boolean, isNode?: boolean): Boolean | { - Boolean: Boolean; - } { + boolean(_p?: Boolean): Boolean { const _j = {} as Boolean; _o.set(_j, "boolval", _p?.boolval); - if (isNode) { - return { - Boolean: _j - }; - } return _j; }, - string(_p?: String, isNode?: boolean): String | { - String: String; - } { + string(_p?: String): String { const _j = {} as String; _o.set(_j, "sval", _p?.sval); - if (isNode) { - return { - String: _j - }; - } return _j; }, - bitString(_p?: BitString, isNode?: boolean): BitString | { - BitString: BitString; - } { + bitString(_p?: BitString): BitString { const _j = {} as BitString; _o.set(_j, "bsval", _p?.bsval); - if (isNode) { - return { - BitString: _j - }; - } return _j; }, - list(_p?: List, isNode?: boolean): List | { - List: List; - } { + list(_p?: List): List { const _j = {} as List; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - List: _j - }; - } return _j; }, - oidList(_p?: OidList, isNode?: boolean): OidList | { - OidList: OidList; - } { + oidList(_p?: OidList): OidList { const _j = {} as OidList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - OidList: _j - }; - } return _j; }, - intList(_p?: IntList, isNode?: boolean): IntList | { - IntList: IntList; - } { + intList(_p?: IntList): IntList { const _j = {} as IntList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - IntList: _j - }; - } return _j; }, - aConst(_p?: A_Const, isNode?: boolean): A_Const | { - A_Const: A_Const; - } { + aConst(_p?: A_Const): A_Const { const _j = {} as A_Const; _o.set(_j, "ival", _p?.ival); _o.set(_j, "fval", _p?.fval); @@ -4379,29 +4307,15 @@ export default { _o.set(_j, "bsval", _p?.bsval); _o.set(_j, "isnull", _p?.isnull); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Const: _j - }; - } return _j; }, - alias(_p?: Alias, isNode?: boolean): Alias | { - Alias: Alias; - } { + alias(_p?: Alias): Alias { const _j = {} as Alias; _o.set(_j, "aliasname", _p?.aliasname); _o.set(_j, "colnames", _p?.colnames); - if (isNode) { - return { - Alias: _j - }; - } return _j; }, - rangeVar(_p?: RangeVar, isNode?: boolean): RangeVar | { - RangeVar: RangeVar; - } { + rangeVar(_p?: RangeVar): RangeVar { const _j = {} as RangeVar; _o.set(_j, "catalogname", _p?.catalogname); _o.set(_j, "schemaname", _p?.schemaname); @@ -4410,16 +4324,9 @@ export default { _o.set(_j, "relpersistence", _p?.relpersistence); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeVar: _j - }; - } return _j; }, - tableFunc(_p?: TableFunc, isNode?: boolean): TableFunc | { - TableFunc: TableFunc; - } { + tableFunc(_p?: TableFunc): TableFunc { const _j = {} as TableFunc; _o.set(_j, "ns_uris", _p?.ns_uris); _o.set(_j, "ns_names", _p?.ns_names); @@ -4434,16 +4341,9 @@ export default { _o.set(_j, "notnulls", _p?.notnulls); _o.set(_j, "ordinalitycol", _p?.ordinalitycol); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TableFunc: _j - }; - } return _j; }, - intoClause(_p?: IntoClause, isNode?: boolean): IntoClause | { - IntoClause: IntoClause; - } { + intoClause(_p?: IntoClause): IntoClause { const _j = {} as IntoClause; _o.set(_j, "rel", _p?.rel); _o.set(_j, "colNames", _p?.colNames); @@ -4453,16 +4353,9 @@ export default { _o.set(_j, "tableSpaceName", _p?.tableSpaceName); _o.set(_j, "viewQuery", _p?.viewQuery); _o.set(_j, "skipData", _p?.skipData); - if (isNode) { - return { - IntoClause: _j - }; - } return _j; }, - var(_p?: Var, isNode?: boolean): Var | { - Var: Var; - } { + var(_p?: Var): Var { const _j = {} as Var; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "varno", _p?.varno); @@ -4473,16 +4366,9 @@ export default { _o.set(_j, "varnullingrels", _p?.varnullingrels); _o.set(_j, "varlevelsup", _p?.varlevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Var: _j - }; - } return _j; }, - param(_p?: Param, isNode?: boolean): Param | { - Param: Param; - } { + param(_p?: Param): Param { const _j = {} as Param; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "paramkind", _p?.paramkind); @@ -4491,16 +4377,9 @@ export default { _o.set(_j, "paramtypmod", _p?.paramtypmod); _o.set(_j, "paramcollid", _p?.paramcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Param: _j - }; - } return _j; }, - aggref(_p?: Aggref, isNode?: boolean): Aggref | { - Aggref: Aggref; - } { + aggref(_p?: Aggref): Aggref { const _j = {} as Aggref; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "aggfnoid", _p?.aggfnoid); @@ -4521,32 +4400,18 @@ export default { _o.set(_j, "aggno", _p?.aggno); _o.set(_j, "aggtransno", _p?.aggtransno); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Aggref: _j - }; - } return _j; }, - groupingFunc(_p?: GroupingFunc, isNode?: boolean): GroupingFunc | { - GroupingFunc: GroupingFunc; - } { + groupingFunc(_p?: GroupingFunc): GroupingFunc { const _j = {} as GroupingFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); _o.set(_j, "refs", _p?.refs); _o.set(_j, "agglevelsup", _p?.agglevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingFunc: _j - }; - } return _j; }, - windowFunc(_p?: WindowFunc, isNode?: boolean): WindowFunc | { - WindowFunc: WindowFunc; - } { + windowFunc(_p?: WindowFunc): WindowFunc { const _j = {} as WindowFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "winfnoid", _p?.winfnoid); @@ -4559,16 +4424,9 @@ export default { _o.set(_j, "winstar", _p?.winstar); _o.set(_j, "winagg", _p?.winagg); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowFunc: _j - }; - } return _j; }, - subscriptingRef(_p?: SubscriptingRef, isNode?: boolean): SubscriptingRef | { - SubscriptingRef: SubscriptingRef; - } { + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { const _j = {} as SubscriptingRef; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "refcontainertype", _p?.refcontainertype); @@ -4580,16 +4438,9 @@ export default { _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); _o.set(_j, "refexpr", _p?.refexpr); _o.set(_j, "refassgnexpr", _p?.refassgnexpr); - if (isNode) { - return { - SubscriptingRef: _j - }; - } return _j; }, - funcExpr(_p?: FuncExpr, isNode?: boolean): FuncExpr | { - FuncExpr: FuncExpr; - } { + funcExpr(_p?: FuncExpr): FuncExpr { const _j = {} as FuncExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "funcid", _p?.funcid); @@ -4601,32 +4452,18 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncExpr: _j - }; - } return _j; }, - namedArgExpr(_p?: NamedArgExpr, isNode?: boolean): NamedArgExpr | { - NamedArgExpr: NamedArgExpr; - } { + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { const _j = {} as NamedArgExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "name", _p?.name); _o.set(_j, "argnumber", _p?.argnumber); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NamedArgExpr: _j - }; - } return _j; }, - opExpr(_p?: OpExpr, isNode?: boolean): OpExpr | { - OpExpr: OpExpr; - } { + opExpr(_p?: OpExpr): OpExpr { const _j = {} as OpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -4636,16 +4473,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OpExpr: _j - }; - } return _j; }, - distinctExpr(_p?: DistinctExpr, isNode?: boolean): DistinctExpr | { - DistinctExpr: DistinctExpr; - } { + distinctExpr(_p?: DistinctExpr): DistinctExpr { const _j = {} as DistinctExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -4655,16 +4485,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DistinctExpr: _j - }; - } return _j; }, - nullIfExpr(_p?: NullIfExpr, isNode?: boolean): NullIfExpr | { - NullIfExpr: NullIfExpr; - } { + nullIfExpr(_p?: NullIfExpr): NullIfExpr { const _j = {} as NullIfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -4674,16 +4497,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullIfExpr: _j - }; - } return _j; }, - scalarArrayOpExpr(_p?: ScalarArrayOpExpr, isNode?: boolean): ScalarArrayOpExpr | { - ScalarArrayOpExpr: ScalarArrayOpExpr; - } { + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { const _j = {} as ScalarArrayOpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -4691,31 +4507,17 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ScalarArrayOpExpr: _j - }; - } return _j; }, - boolExpr(_p?: BoolExpr, isNode?: boolean): BoolExpr | { - BoolExpr: BoolExpr; - } { + boolExpr(_p?: BoolExpr): BoolExpr { const _j = {} as BoolExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "boolop", _p?.boolop); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BoolExpr: _j - }; - } return _j; }, - subLink(_p?: SubLink, isNode?: boolean): SubLink | { - SubLink: SubLink; - } { + subLink(_p?: SubLink): SubLink { const _j = {} as SubLink; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -4724,16 +4526,9 @@ export default { _o.set(_j, "operName", _p?.operName); _o.set(_j, "subselect", _p?.subselect); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SubLink: _j - }; - } return _j; }, - subPlan(_p?: SubPlan, isNode?: boolean): SubPlan | { - SubPlan: SubPlan; - } { + subPlan(_p?: SubPlan): SubPlan { const _j = {} as SubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -4752,29 +4547,15 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "startup_cost", _p?.startup_cost); _o.set(_j, "per_call_cost", _p?.per_call_cost); - if (isNode) { - return { - SubPlan: _j - }; - } return _j; }, - alternativeSubPlan(_p?: AlternativeSubPlan, isNode?: boolean): AlternativeSubPlan | { - AlternativeSubPlan: AlternativeSubPlan; - } { + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { const _j = {} as AlternativeSubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subplans", _p?.subplans); - if (isNode) { - return { - AlternativeSubPlan: _j - }; - } return _j; }, - fieldSelect(_p?: FieldSelect, isNode?: boolean): FieldSelect | { - FieldSelect: FieldSelect; - } { + fieldSelect(_p?: FieldSelect): FieldSelect { const _j = {} as FieldSelect; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -4782,32 +4563,18 @@ export default { _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "resulttypmod", _p?.resulttypmod); _o.set(_j, "resultcollid", _p?.resultcollid); - if (isNode) { - return { - FieldSelect: _j - }; - } return _j; }, - fieldStore(_p?: FieldStore, isNode?: boolean): FieldStore | { - FieldStore: FieldStore; - } { + fieldStore(_p?: FieldStore): FieldStore { const _j = {} as FieldStore; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "newvals", _p?.newvals); _o.set(_j, "fieldnums", _p?.fieldnums); _o.set(_j, "resulttype", _p?.resulttype); - if (isNode) { - return { - FieldStore: _j - }; - } return _j; }, - relabelType(_p?: RelabelType, isNode?: boolean): RelabelType | { - RelabelType: RelabelType; - } { + relabelType(_p?: RelabelType): RelabelType { const _j = {} as RelabelType; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -4816,16 +4583,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "relabelformat", _p?.relabelformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RelabelType: _j - }; - } return _j; }, - coerceViaio(_p?: CoerceViaIO, isNode?: boolean): CoerceViaIO | { - CoerceViaIO: CoerceViaIO; - } { + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { const _j = {} as CoerceViaIO; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -4833,16 +4593,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceViaIO: _j - }; - } return _j; }, - arrayCoerceExpr(_p?: ArrayCoerceExpr, isNode?: boolean): ArrayCoerceExpr | { - ArrayCoerceExpr: ArrayCoerceExpr; - } { + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { const _j = {} as ArrayCoerceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -4852,47 +4605,26 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayCoerceExpr: _j - }; - } return _j; }, - convertRowtypeExpr(_p?: ConvertRowtypeExpr, isNode?: boolean): ConvertRowtypeExpr | { - ConvertRowtypeExpr: ConvertRowtypeExpr; - } { + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { const _j = {} as ConvertRowtypeExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "convertformat", _p?.convertformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ConvertRowtypeExpr: _j - }; - } return _j; }, - collateExpr(_p?: CollateExpr, isNode?: boolean): CollateExpr | { - CollateExpr: CollateExpr; - } { + collateExpr(_p?: CollateExpr): CollateExpr { const _j = {} as CollateExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "collOid", _p?.collOid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateExpr: _j - }; - } return _j; }, - caseExpr(_p?: CaseExpr, isNode?: boolean): CaseExpr | { - CaseExpr: CaseExpr; - } { + caseExpr(_p?: CaseExpr): CaseExpr { const _j = {} as CaseExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "casetype", _p?.casetype); @@ -4901,46 +4633,25 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "defresult", _p?.defresult); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseExpr: _j - }; - } return _j; }, - caseWhen(_p?: CaseWhen, isNode?: boolean): CaseWhen | { - CaseWhen: CaseWhen; - } { + caseWhen(_p?: CaseWhen): CaseWhen { const _j = {} as CaseWhen; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "result", _p?.result); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseWhen: _j - }; - } return _j; }, - caseTestExpr(_p?: CaseTestExpr, isNode?: boolean): CaseTestExpr | { - CaseTestExpr: CaseTestExpr; - } { + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { const _j = {} as CaseTestExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); - if (isNode) { - return { - CaseTestExpr: _j - }; - } return _j; }, - arrayExpr(_p?: ArrayExpr, isNode?: boolean): ArrayExpr | { - ArrayExpr: ArrayExpr; - } { + arrayExpr(_p?: ArrayExpr): ArrayExpr { const _j = {} as ArrayExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "array_typeid", _p?.array_typeid); @@ -4949,16 +4660,9 @@ export default { _o.set(_j, "elements", _p?.elements); _o.set(_j, "multidims", _p?.multidims); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayExpr: _j - }; - } return _j; }, - rowExpr(_p?: RowExpr, isNode?: boolean): RowExpr | { - RowExpr: RowExpr; - } { + rowExpr(_p?: RowExpr): RowExpr { const _j = {} as RowExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); @@ -4966,16 +4670,9 @@ export default { _o.set(_j, "row_format", _p?.row_format); _o.set(_j, "colnames", _p?.colnames); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RowExpr: _j - }; - } return _j; }, - rowCompareExpr(_p?: RowCompareExpr, isNode?: boolean): RowCompareExpr | { - RowCompareExpr: RowCompareExpr; - } { + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { const _j = {} as RowCompareExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "rctype", _p?.rctype); @@ -4984,32 +4681,18 @@ export default { _o.set(_j, "inputcollids", _p?.inputcollids); _o.set(_j, "largs", _p?.largs); _o.set(_j, "rargs", _p?.rargs); - if (isNode) { - return { - RowCompareExpr: _j - }; - } return _j; }, - coalesceExpr(_p?: CoalesceExpr, isNode?: boolean): CoalesceExpr | { - CoalesceExpr: CoalesceExpr; - } { + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { const _j = {} as CoalesceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "coalescetype", _p?.coalescetype); _o.set(_j, "coalescecollid", _p?.coalescecollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoalesceExpr: _j - }; - } return _j; }, - minMaxExpr(_p?: MinMaxExpr, isNode?: boolean): MinMaxExpr | { - MinMaxExpr: MinMaxExpr; - } { + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { const _j = {} as MinMaxExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "minmaxtype", _p?.minmaxtype); @@ -5018,32 +4701,18 @@ export default { _o.set(_j, "op", _p?.op); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MinMaxExpr: _j - }; - } return _j; }, - sqlValueFunction(_p?: SQLValueFunction, isNode?: boolean): SQLValueFunction | { - SQLValueFunction: SQLValueFunction; - } { + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { const _j = {} as SQLValueFunction; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SQLValueFunction: _j - }; - } return _j; }, - xmlExpr(_p?: XmlExpr, isNode?: boolean): XmlExpr | { - XmlExpr: XmlExpr; - } { + xmlExpr(_p?: XmlExpr): XmlExpr { const _j = {} as XmlExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -5056,58 +4725,30 @@ export default { _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlExpr: _j - }; - } return _j; }, - jsonFormat(_p?: JsonFormat, isNode?: boolean): JsonFormat | { - JsonFormat: JsonFormat; - } { + jsonFormat(_p?: JsonFormat): JsonFormat { const _j = {} as JsonFormat; _o.set(_j, "format_type", _p?.format_type); _o.set(_j, "encoding", _p?.encoding); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFormat: _j - }; - } return _j; }, - jsonReturning(_p?: JsonReturning, isNode?: boolean): JsonReturning | { - JsonReturning: JsonReturning; - } { + jsonReturning(_p?: JsonReturning): JsonReturning { const _j = {} as JsonReturning; _o.set(_j, "format", _p?.format); _o.set(_j, "typid", _p?.typid); _o.set(_j, "typmod", _p?.typmod); - if (isNode) { - return { - JsonReturning: _j - }; - } return _j; }, - jsonValueExpr(_p?: JsonValueExpr, isNode?: boolean): JsonValueExpr | { - JsonValueExpr: JsonValueExpr; - } { + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { const _j = {} as JsonValueExpr; _o.set(_j, "raw_expr", _p?.raw_expr); _o.set(_j, "formatted_expr", _p?.formatted_expr); _o.set(_j, "format", _p?.format); - if (isNode) { - return { - JsonValueExpr: _j - }; - } return _j; }, - jsonConstructorExpr(_p?: JsonConstructorExpr, isNode?: boolean): JsonConstructorExpr | { - JsonConstructorExpr: JsonConstructorExpr; - } { + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { const _j = {} as JsonConstructorExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "type", _p?.type); @@ -5118,63 +4759,35 @@ export default { _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonConstructorExpr: _j - }; - } return _j; }, - jsonIsPredicate(_p?: JsonIsPredicate, isNode?: boolean): JsonIsPredicate | { - JsonIsPredicate: JsonIsPredicate; - } { + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { const _j = {} as JsonIsPredicate; _o.set(_j, "expr", _p?.expr); _o.set(_j, "format", _p?.format); _o.set(_j, "item_type", _p?.item_type); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonIsPredicate: _j - }; - } return _j; }, - nullTest(_p?: NullTest, isNode?: boolean): NullTest | { - NullTest: NullTest; - } { + nullTest(_p?: NullTest): NullTest { const _j = {} as NullTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "nulltesttype", _p?.nulltesttype); _o.set(_j, "argisrow", _p?.argisrow); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullTest: _j - }; - } return _j; }, - booleanTest(_p?: BooleanTest, isNode?: boolean): BooleanTest | { - BooleanTest: BooleanTest; - } { + booleanTest(_p?: BooleanTest): BooleanTest { const _j = {} as BooleanTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "booltesttype", _p?.booltesttype); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BooleanTest: _j - }; - } return _j; }, - coerceToDomain(_p?: CoerceToDomain, isNode?: boolean): CoerceToDomain | { - CoerceToDomain: CoerceToDomain; - } { + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { const _j = {} as CoerceToDomain; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -5183,92 +4796,50 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coercionformat", _p?.coercionformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomain: _j - }; - } return _j; }, - coerceToDomainValue(_p?: CoerceToDomainValue, isNode?: boolean): CoerceToDomainValue | { - CoerceToDomainValue: CoerceToDomainValue; - } { + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { const _j = {} as CoerceToDomainValue; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomainValue: _j - }; - } return _j; }, - setToDefault(_p?: SetToDefault, isNode?: boolean): SetToDefault | { - SetToDefault: SetToDefault; - } { + setToDefault(_p?: SetToDefault): SetToDefault { const _j = {} as SetToDefault; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SetToDefault: _j - }; - } return _j; }, - currentOfExpr(_p?: CurrentOfExpr, isNode?: boolean): CurrentOfExpr | { - CurrentOfExpr: CurrentOfExpr; - } { + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { const _j = {} as CurrentOfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "cvarno", _p?.cvarno); _o.set(_j, "cursor_name", _p?.cursor_name); _o.set(_j, "cursor_param", _p?.cursor_param); - if (isNode) { - return { - CurrentOfExpr: _j - }; - } return _j; }, - nextValueExpr(_p?: NextValueExpr, isNode?: boolean): NextValueExpr | { - NextValueExpr: NextValueExpr; - } { + nextValueExpr(_p?: NextValueExpr): NextValueExpr { const _j = {} as NextValueExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "seqid", _p?.seqid); _o.set(_j, "typeId", _p?.typeId); - if (isNode) { - return { - NextValueExpr: _j - }; - } return _j; }, - inferenceElem(_p?: InferenceElem, isNode?: boolean): InferenceElem | { - InferenceElem: InferenceElem; - } { + inferenceElem(_p?: InferenceElem): InferenceElem { const _j = {} as InferenceElem; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "infercollid", _p?.infercollid); _o.set(_j, "inferopclass", _p?.inferopclass); - if (isNode) { - return { - InferenceElem: _j - }; - } return _j; }, - targetEntry(_p?: TargetEntry, isNode?: boolean): TargetEntry | { - TargetEntry: TargetEntry; - } { + targetEntry(_p?: TargetEntry): TargetEntry { const _j = {} as TargetEntry; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); @@ -5278,28 +4849,14 @@ export default { _o.set(_j, "resorigtbl", _p?.resorigtbl); _o.set(_j, "resorigcol", _p?.resorigcol); _o.set(_j, "resjunk", _p?.resjunk); - if (isNode) { - return { - TargetEntry: _j - }; - } return _j; }, - rangeTblRef(_p?: RangeTblRef, isNode?: boolean): RangeTblRef | { - RangeTblRef: RangeTblRef; - } { + rangeTblRef(_p?: RangeTblRef): RangeTblRef { const _j = {} as RangeTblRef; _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - RangeTblRef: _j - }; - } return _j; }, - joinExpr(_p?: JoinExpr, isNode?: boolean): JoinExpr | { - JoinExpr: JoinExpr; - } { + joinExpr(_p?: JoinExpr): JoinExpr { const _j = {} as JoinExpr; _o.set(_j, "jointype", _p?.jointype); _o.set(_j, "isNatural", _p?.isNatural); @@ -5310,29 +4867,15 @@ export default { _o.set(_j, "quals", _p?.quals); _o.set(_j, "alias", _p?.alias); _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - JoinExpr: _j - }; - } return _j; }, - fromExpr(_p?: FromExpr, isNode?: boolean): FromExpr | { - FromExpr: FromExpr; - } { + fromExpr(_p?: FromExpr): FromExpr { const _j = {} as FromExpr; _o.set(_j, "fromlist", _p?.fromlist); _o.set(_j, "quals", _p?.quals); - if (isNode) { - return { - FromExpr: _j - }; - } return _j; }, - onConflictExpr(_p?: OnConflictExpr, isNode?: boolean): OnConflictExpr | { - OnConflictExpr: OnConflictExpr; - } { + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { const _j = {} as OnConflictExpr; _o.set(_j, "action", _p?.action); _o.set(_j, "arbiterElems", _p?.arbiterElems); @@ -5342,16 +4885,9 @@ export default { _o.set(_j, "onConflictWhere", _p?.onConflictWhere); _o.set(_j, "exclRelIndex", _p?.exclRelIndex); _o.set(_j, "exclRelTlist", _p?.exclRelTlist); - if (isNode) { - return { - OnConflictExpr: _j - }; - } return _j; }, - query(_p?: Query, isNode?: boolean): Query | { - Query: Query; - } { + query(_p?: Query): Query { const _j = {} as Query; _o.set(_j, "commandType", _p?.commandType); _o.set(_j, "querySource", _p?.querySource); @@ -5394,16 +4930,9 @@ export default { _o.set(_j, "withCheckOptions", _p?.withCheckOptions); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - Query: _j - }; - } return _j; }, - typeName(_p?: TypeName, isNode?: boolean): TypeName | { - TypeName: TypeName; - } { + typeName(_p?: TypeName): TypeName { const _j = {} as TypeName; _o.set(_j, "names", _p?.names); _o.set(_j, "typeOid", _p?.typeOid); @@ -5413,100 +4942,51 @@ export default { _o.set(_j, "typemod", _p?.typemod); _o.set(_j, "arrayBounds", _p?.arrayBounds); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeName: _j - }; - } return _j; }, - columnRef(_p?: ColumnRef, isNode?: boolean): ColumnRef | { - ColumnRef: ColumnRef; - } { + columnRef(_p?: ColumnRef): ColumnRef { const _j = {} as ColumnRef; _o.set(_j, "fields", _p?.fields); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnRef: _j - }; - } return _j; }, - paramRef(_p?: ParamRef, isNode?: boolean): ParamRef | { - ParamRef: ParamRef; - } { + paramRef(_p?: ParamRef): ParamRef { const _j = {} as ParamRef; _o.set(_j, "number", _p?.number); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ParamRef: _j - }; - } return _j; }, - aExpr(_p?: A_Expr, isNode?: boolean): A_Expr | { - A_Expr: A_Expr; - } { + aExpr(_p?: A_Expr): A_Expr { const _j = {} as A_Expr; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "lexpr", _p?.lexpr); _o.set(_j, "rexpr", _p?.rexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Expr: _j - }; - } return _j; }, - typeCast(_p?: TypeCast, isNode?: boolean): TypeCast | { - TypeCast: TypeCast; - } { + typeCast(_p?: TypeCast): TypeCast { const _j = {} as TypeCast; _o.set(_j, "arg", _p?.arg); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeCast: _j - }; - } return _j; }, - collateClause(_p?: CollateClause, isNode?: boolean): CollateClause | { - CollateClause: CollateClause; - } { + collateClause(_p?: CollateClause): CollateClause { const _j = {} as CollateClause; _o.set(_j, "arg", _p?.arg); _o.set(_j, "collname", _p?.collname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateClause: _j - }; - } return _j; }, - roleSpec(_p?: RoleSpec, isNode?: boolean): RoleSpec | { - RoleSpec: RoleSpec; - } { + roleSpec(_p?: RoleSpec): RoleSpec { const _j = {} as RoleSpec; _o.set(_j, "roletype", _p?.roletype); _o.set(_j, "rolename", _p?.rolename); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RoleSpec: _j - }; - } return _j; }, - funcCall(_p?: FuncCall, isNode?: boolean): FuncCall | { - FuncCall: FuncCall; - } { + funcCall(_p?: FuncCall): FuncCall { const _j = {} as FuncCall; _o.set(_j, "funcname", _p?.funcname); _o.set(_j, "args", _p?.args); @@ -5519,112 +4999,56 @@ export default { _o.set(_j, "func_variadic", _p?.func_variadic); _o.set(_j, "funcformat", _p?.funcformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncCall: _j - }; - } return _j; }, - aStar(_p?: A_Star, isNode?: boolean): A_Star | { - A_Star: A_Star; - } { + aStar(_p?: A_Star): A_Star { const _j = {} as A_Star; - if (isNode) { - return { - A_Star: _j - }; - } return _j; }, - aIndices(_p?: A_Indices, isNode?: boolean): A_Indices | { - A_Indices: A_Indices; - } { + aIndices(_p?: A_Indices): A_Indices { const _j = {} as A_Indices; _o.set(_j, "is_slice", _p?.is_slice); _o.set(_j, "lidx", _p?.lidx); _o.set(_j, "uidx", _p?.uidx); - if (isNode) { - return { - A_Indices: _j - }; - } return _j; }, - aIndirection(_p?: A_Indirection, isNode?: boolean): A_Indirection | { - A_Indirection: A_Indirection; - } { + aIndirection(_p?: A_Indirection): A_Indirection { const _j = {} as A_Indirection; _o.set(_j, "arg", _p?.arg); _o.set(_j, "indirection", _p?.indirection); - if (isNode) { - return { - A_Indirection: _j - }; - } return _j; }, - aArrayExpr(_p?: A_ArrayExpr, isNode?: boolean): A_ArrayExpr | { - A_ArrayExpr: A_ArrayExpr; - } { + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { const _j = {} as A_ArrayExpr; _o.set(_j, "elements", _p?.elements); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_ArrayExpr: _j - }; - } return _j; }, - resTarget(_p?: ResTarget, isNode?: boolean): ResTarget | { - ResTarget: ResTarget; - } { + resTarget(_p?: ResTarget): ResTarget { const _j = {} as ResTarget; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ResTarget: _j - }; - } return _j; }, - multiAssignRef(_p?: MultiAssignRef, isNode?: boolean): MultiAssignRef | { - MultiAssignRef: MultiAssignRef; - } { + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { const _j = {} as MultiAssignRef; _o.set(_j, "source", _p?.source); _o.set(_j, "colno", _p?.colno); _o.set(_j, "ncolumns", _p?.ncolumns); - if (isNode) { - return { - MultiAssignRef: _j - }; - } return _j; }, - sortBy(_p?: SortBy, isNode?: boolean): SortBy | { - SortBy: SortBy; - } { + sortBy(_p?: SortBy): SortBy { const _j = {} as SortBy; _o.set(_j, "node", _p?.node); _o.set(_j, "sortby_dir", _p?.sortby_dir); _o.set(_j, "sortby_nulls", _p?.sortby_nulls); _o.set(_j, "useOp", _p?.useOp); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SortBy: _j - }; - } return _j; }, - windowDef(_p?: WindowDef, isNode?: boolean): WindowDef | { - WindowDef: WindowDef; - } { + windowDef(_p?: WindowDef): WindowDef { const _j = {} as WindowDef; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -5634,30 +5058,16 @@ export default { _o.set(_j, "startOffset", _p?.startOffset); _o.set(_j, "endOffset", _p?.endOffset); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowDef: _j - }; - } return _j; }, - rangeSubselect(_p?: RangeSubselect, isNode?: boolean): RangeSubselect | { - RangeSubselect: RangeSubselect; - } { + rangeSubselect(_p?: RangeSubselect): RangeSubselect { const _j = {} as RangeSubselect; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "subquery", _p?.subquery); _o.set(_j, "alias", _p?.alias); - if (isNode) { - return { - RangeSubselect: _j - }; - } return _j; }, - rangeFunction(_p?: RangeFunction, isNode?: boolean): RangeFunction | { - RangeFunction: RangeFunction; - } { + rangeFunction(_p?: RangeFunction): RangeFunction { const _j = {} as RangeFunction; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "ordinality", _p?.ordinality); @@ -5665,16 +5075,9 @@ export default { _o.set(_j, "functions", _p?.functions); _o.set(_j, "alias", _p?.alias); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - RangeFunction: _j - }; - } return _j; }, - rangeTableFunc(_p?: RangeTableFunc, isNode?: boolean): RangeTableFunc | { - RangeTableFunc: RangeTableFunc; - } { + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { const _j = {} as RangeTableFunc; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "docexpr", _p?.docexpr); @@ -5683,16 +5086,9 @@ export default { _o.set(_j, "columns", _p?.columns); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFunc: _j - }; - } return _j; }, - rangeTableFuncCol(_p?: RangeTableFuncCol, isNode?: boolean): RangeTableFuncCol | { - RangeTableFuncCol: RangeTableFuncCol; - } { + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { const _j = {} as RangeTableFuncCol; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -5701,32 +5097,18 @@ export default { _o.set(_j, "colexpr", _p?.colexpr); _o.set(_j, "coldefexpr", _p?.coldefexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFuncCol: _j - }; - } return _j; }, - rangeTableSample(_p?: RangeTableSample, isNode?: boolean): RangeTableSample | { - RangeTableSample: RangeTableSample; - } { + rangeTableSample(_p?: RangeTableSample): RangeTableSample { const _j = {} as RangeTableSample; _o.set(_j, "relation", _p?.relation); _o.set(_j, "method", _p?.method); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableSample: _j - }; - } return _j; }, - columnDef(_p?: ColumnDef, isNode?: boolean): ColumnDef | { - ColumnDef: ColumnDef; - } { + columnDef(_p?: ColumnDef): ColumnDef { const _j = {} as ColumnDef; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -5747,30 +5129,16 @@ export default { _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "fdwoptions", _p?.fdwoptions); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnDef: _j - }; - } return _j; }, - tableLikeClause(_p?: TableLikeClause, isNode?: boolean): TableLikeClause | { - TableLikeClause: TableLikeClause; - } { + tableLikeClause(_p?: TableLikeClause): TableLikeClause { const _j = {} as TableLikeClause; _o.set(_j, "relation", _p?.relation); _o.set(_j, "options", _p?.options); _o.set(_j, "relationOid", _p?.relationOid); - if (isNode) { - return { - TableLikeClause: _j - }; - } return _j; }, - indexElem(_p?: IndexElem, isNode?: boolean): IndexElem | { - IndexElem: IndexElem; - } { + indexElem(_p?: IndexElem): IndexElem { const _j = {} as IndexElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); @@ -5780,92 +5148,50 @@ export default { _o.set(_j, "opclassopts", _p?.opclassopts); _o.set(_j, "ordering", _p?.ordering); _o.set(_j, "nulls_ordering", _p?.nulls_ordering); - if (isNode) { - return { - IndexElem: _j - }; - } return _j; }, - defElem(_p?: DefElem, isNode?: boolean): DefElem | { - DefElem: DefElem; - } { + defElem(_p?: DefElem): DefElem { const _j = {} as DefElem; _o.set(_j, "defnamespace", _p?.defnamespace); _o.set(_j, "defname", _p?.defname); _o.set(_j, "arg", _p?.arg); _o.set(_j, "defaction", _p?.defaction); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DefElem: _j - }; - } return _j; }, - lockingClause(_p?: LockingClause, isNode?: boolean): LockingClause | { - LockingClause: LockingClause; - } { + lockingClause(_p?: LockingClause): LockingClause { const _j = {} as LockingClause; _o.set(_j, "lockedRels", _p?.lockedRels); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); - if (isNode) { - return { - LockingClause: _j - }; - } return _j; }, - xmlSerialize(_p?: XmlSerialize, isNode?: boolean): XmlSerialize | { - XmlSerialize: XmlSerialize; - } { + xmlSerialize(_p?: XmlSerialize): XmlSerialize { const _j = {} as XmlSerialize; _o.set(_j, "xmloption", _p?.xmloption); _o.set(_j, "expr", _p?.expr); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "indent", _p?.indent); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlSerialize: _j - }; - } return _j; }, - partitionElem(_p?: PartitionElem, isNode?: boolean): PartitionElem | { - PartitionElem: PartitionElem; - } { + partitionElem(_p?: PartitionElem): PartitionElem { const _j = {} as PartitionElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); _o.set(_j, "collation", _p?.collation); _o.set(_j, "opclass", _p?.opclass); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionElem: _j - }; - } return _j; }, - partitionSpec(_p?: PartitionSpec, isNode?: boolean): PartitionSpec | { - PartitionSpec: PartitionSpec; - } { + partitionSpec(_p?: PartitionSpec): PartitionSpec { const _j = {} as PartitionSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "partParams", _p?.partParams); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionSpec: _j - }; - } return _j; }, - partitionBoundSpec(_p?: PartitionBoundSpec, isNode?: boolean): PartitionBoundSpec | { - PartitionBoundSpec: PartitionBoundSpec; - } { + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { const _j = {} as PartitionBoundSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "is_default", _p?.is_default); @@ -5875,44 +5201,23 @@ export default { _o.set(_j, "lowerdatums", _p?.lowerdatums); _o.set(_j, "upperdatums", _p?.upperdatums); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionBoundSpec: _j - }; - } return _j; }, - partitionRangeDatum(_p?: PartitionRangeDatum, isNode?: boolean): PartitionRangeDatum | { - PartitionRangeDatum: PartitionRangeDatum; - } { + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { const _j = {} as PartitionRangeDatum; _o.set(_j, "kind", _p?.kind); _o.set(_j, "value", _p?.value); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionRangeDatum: _j - }; - } return _j; }, - partitionCmd(_p?: PartitionCmd, isNode?: boolean): PartitionCmd | { - PartitionCmd: PartitionCmd; - } { + partitionCmd(_p?: PartitionCmd): PartitionCmd { const _j = {} as PartitionCmd; _o.set(_j, "name", _p?.name); _o.set(_j, "bound", _p?.bound); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - PartitionCmd: _j - }; - } return _j; }, - rangeTblEntry(_p?: RangeTblEntry, isNode?: boolean): RangeTblEntry | { - RangeTblEntry: RangeTblEntry; - } { + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { const _j = {} as RangeTblEntry; _o.set(_j, "rtekind", _p?.rtekind); _o.set(_j, "relid", _p?.relid); @@ -5946,16 +5251,9 @@ export default { _o.set(_j, "inh", _p?.inh); _o.set(_j, "inFromCl", _p?.inFromCl); _o.set(_j, "securityQuals", _p?.securityQuals); - if (isNode) { - return { - RangeTblEntry: _j - }; - } return _j; }, - rtePermissionInfo(_p?: RTEPermissionInfo, isNode?: boolean): RTEPermissionInfo | { - RTEPermissionInfo: RTEPermissionInfo; - } { + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { const _j = {} as RTEPermissionInfo; _o.set(_j, "relid", _p?.relid); _o.set(_j, "inh", _p?.inh); @@ -5964,16 +5262,9 @@ export default { _o.set(_j, "selectedCols", _p?.selectedCols); _o.set(_j, "insertedCols", _p?.insertedCols); _o.set(_j, "updatedCols", _p?.updatedCols); - if (isNode) { - return { - RTEPermissionInfo: _j - }; - } return _j; }, - rangeTblFunction(_p?: RangeTblFunction, isNode?: boolean): RangeTblFunction | { - RangeTblFunction: RangeTblFunction; - } { + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { const _j = {} as RangeTblFunction; _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "funccolcount", _p?.funccolcount); @@ -5982,76 +5273,41 @@ export default { _o.set(_j, "funccoltypmods", _p?.funccoltypmods); _o.set(_j, "funccolcollations", _p?.funccolcollations); _o.set(_j, "funcparams", _p?.funcparams); - if (isNode) { - return { - RangeTblFunction: _j - }; - } return _j; }, - tableSampleClause(_p?: TableSampleClause, isNode?: boolean): TableSampleClause | { - TableSampleClause: TableSampleClause; - } { + tableSampleClause(_p?: TableSampleClause): TableSampleClause { const _j = {} as TableSampleClause; _o.set(_j, "tsmhandler", _p?.tsmhandler); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); - if (isNode) { - return { - TableSampleClause: _j - }; - } return _j; }, - withCheckOption(_p?: WithCheckOption, isNode?: boolean): WithCheckOption | { - WithCheckOption: WithCheckOption; - } { + withCheckOption(_p?: WithCheckOption): WithCheckOption { const _j = {} as WithCheckOption; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relname", _p?.relname); _o.set(_j, "polname", _p?.polname); _o.set(_j, "qual", _p?.qual); _o.set(_j, "cascaded", _p?.cascaded); - if (isNode) { - return { - WithCheckOption: _j - }; - } return _j; }, - sortGroupClause(_p?: SortGroupClause, isNode?: boolean): SortGroupClause | { - SortGroupClause: SortGroupClause; - } { + sortGroupClause(_p?: SortGroupClause): SortGroupClause { const _j = {} as SortGroupClause; _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); _o.set(_j, "eqop", _p?.eqop); _o.set(_j, "sortop", _p?.sortop); _o.set(_j, "nulls_first", _p?.nulls_first); _o.set(_j, "hashable", _p?.hashable); - if (isNode) { - return { - SortGroupClause: _j - }; - } return _j; }, - groupingSet(_p?: GroupingSet, isNode?: boolean): GroupingSet | { - GroupingSet: GroupingSet; - } { + groupingSet(_p?: GroupingSet): GroupingSet { const _j = {} as GroupingSet; _o.set(_j, "kind", _p?.kind); _o.set(_j, "content", _p?.content); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingSet: _j - }; - } return _j; }, - windowClause(_p?: WindowClause, isNode?: boolean): WindowClause | { - WindowClause: WindowClause; - } { + windowClause(_p?: WindowClause): WindowClause { const _j = {} as WindowClause; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -6068,91 +5324,49 @@ export default { _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); _o.set(_j, "winref", _p?.winref); _o.set(_j, "copiedOrder", _p?.copiedOrder); - if (isNode) { - return { - WindowClause: _j - }; - } return _j; }, - rowMarkClause(_p?: RowMarkClause, isNode?: boolean): RowMarkClause | { - RowMarkClause: RowMarkClause; - } { + rowMarkClause(_p?: RowMarkClause): RowMarkClause { const _j = {} as RowMarkClause; _o.set(_j, "rti", _p?.rti); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); _o.set(_j, "pushedDown", _p?.pushedDown); - if (isNode) { - return { - RowMarkClause: _j - }; - } return _j; }, - withClause(_p?: WithClause, isNode?: boolean): WithClause | { - WithClause: WithClause; - } { + withClause(_p?: WithClause): WithClause { const _j = {} as WithClause; _o.set(_j, "ctes", _p?.ctes); _o.set(_j, "recursive", _p?.recursive); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WithClause: _j - }; - } return _j; }, - inferClause(_p?: InferClause, isNode?: boolean): InferClause | { - InferClause: InferClause; - } { + inferClause(_p?: InferClause): InferClause { const _j = {} as InferClause; _o.set(_j, "indexElems", _p?.indexElems); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "conname", _p?.conname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - InferClause: _j - }; - } return _j; }, - onConflictClause(_p?: OnConflictClause, isNode?: boolean): OnConflictClause | { - OnConflictClause: OnConflictClause; - } { + onConflictClause(_p?: OnConflictClause): OnConflictClause { const _j = {} as OnConflictClause; _o.set(_j, "action", _p?.action); _o.set(_j, "infer", _p?.infer); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OnConflictClause: _j - }; - } return _j; }, - cteSearchClause(_p?: CTESearchClause, isNode?: boolean): CTESearchClause | { - CTESearchClause: CTESearchClause; - } { + cteSearchClause(_p?: CTESearchClause): CTESearchClause { const _j = {} as CTESearchClause; _o.set(_j, "search_col_list", _p?.search_col_list); _o.set(_j, "search_breadth_first", _p?.search_breadth_first); _o.set(_j, "search_seq_column", _p?.search_seq_column); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CTESearchClause: _j - }; - } return _j; }, - cteCycleClause(_p?: CTECycleClause, isNode?: boolean): CTECycleClause | { - CTECycleClause: CTECycleClause; - } { + cteCycleClause(_p?: CTECycleClause): CTECycleClause { const _j = {} as CTECycleClause; _o.set(_j, "cycle_col_list", _p?.cycle_col_list); _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); @@ -6164,16 +5378,9 @@ export default { _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); - if (isNode) { - return { - CTECycleClause: _j - }; - } return _j; }, - commonTableExpr(_p?: CommonTableExpr, isNode?: boolean): CommonTableExpr | { - CommonTableExpr: CommonTableExpr; - } { + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { const _j = {} as CommonTableExpr; _o.set(_j, "ctename", _p?.ctename); _o.set(_j, "aliascolnames", _p?.aliascolnames); @@ -6188,16 +5395,9 @@ export default { _o.set(_j, "ctecoltypes", _p?.ctecoltypes); _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); _o.set(_j, "ctecolcollations", _p?.ctecolcollations); - if (isNode) { - return { - CommonTableExpr: _j - }; - } return _j; }, - mergeWhenClause(_p?: MergeWhenClause, isNode?: boolean): MergeWhenClause | { - MergeWhenClause: MergeWhenClause; - } { + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { const _j = {} as MergeWhenClause; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -6205,16 +5405,9 @@ export default { _o.set(_j, "condition", _p?.condition); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "values", _p?.values); - if (isNode) { - return { - MergeWhenClause: _j - }; - } return _j; }, - mergeAction(_p?: MergeAction, isNode?: boolean): MergeAction | { - MergeAction: MergeAction; - } { + mergeAction(_p?: MergeAction): MergeAction { const _j = {} as MergeAction; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -6222,162 +5415,85 @@ export default { _o.set(_j, "qual", _p?.qual); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "updateColnos", _p?.updateColnos); - if (isNode) { - return { - MergeAction: _j - }; - } return _j; }, - triggerTransition(_p?: TriggerTransition, isNode?: boolean): TriggerTransition | { - TriggerTransition: TriggerTransition; - } { + triggerTransition(_p?: TriggerTransition): TriggerTransition { const _j = {} as TriggerTransition; _o.set(_j, "name", _p?.name); _o.set(_j, "isNew", _p?.isNew); _o.set(_j, "isTable", _p?.isTable); - if (isNode) { - return { - TriggerTransition: _j - }; - } return _j; }, - jsonOutput(_p?: JsonOutput, isNode?: boolean): JsonOutput | { - JsonOutput: JsonOutput; - } { + jsonOutput(_p?: JsonOutput): JsonOutput { const _j = {} as JsonOutput; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "returning", _p?.returning); - if (isNode) { - return { - JsonOutput: _j - }; - } return _j; }, - jsonKeyValue(_p?: JsonKeyValue, isNode?: boolean): JsonKeyValue | { - JsonKeyValue: JsonKeyValue; - } { + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { const _j = {} as JsonKeyValue; _o.set(_j, "key", _p?.key); _o.set(_j, "value", _p?.value); - if (isNode) { - return { - JsonKeyValue: _j - }; - } return _j; }, - jsonObjectConstructor(_p?: JsonObjectConstructor, isNode?: boolean): JsonObjectConstructor | { - JsonObjectConstructor: JsonObjectConstructor; - } { + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { const _j = {} as JsonObjectConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonObjectConstructor: _j - }; - } return _j; }, - jsonArrayConstructor(_p?: JsonArrayConstructor, isNode?: boolean): JsonArrayConstructor | { - JsonArrayConstructor: JsonArrayConstructor; - } { + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { const _j = {} as JsonArrayConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayConstructor: _j - }; - } return _j; }, - jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor, isNode?: boolean): JsonArrayQueryConstructor | { - JsonArrayQueryConstructor: JsonArrayQueryConstructor; - } { + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { const _j = {} as JsonArrayQueryConstructor; _o.set(_j, "query", _p?.query); _o.set(_j, "output", _p?.output); _o.set(_j, "format", _p?.format); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayQueryConstructor: _j - }; - } return _j; }, - jsonAggConstructor(_p?: JsonAggConstructor, isNode?: boolean): JsonAggConstructor | { - JsonAggConstructor: JsonAggConstructor; - } { + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { const _j = {} as JsonAggConstructor; _o.set(_j, "output", _p?.output); _o.set(_j, "agg_filter", _p?.agg_filter); _o.set(_j, "agg_order", _p?.agg_order); _o.set(_j, "over", _p?.over); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonAggConstructor: _j - }; - } return _j; }, - jsonObjectAgg(_p?: JsonObjectAgg, isNode?: boolean): JsonObjectAgg | { - JsonObjectAgg: JsonObjectAgg; - } { + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { const _j = {} as JsonObjectAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); - if (isNode) { - return { - JsonObjectAgg: _j - }; - } return _j; }, - jsonArrayAgg(_p?: JsonArrayAgg, isNode?: boolean): JsonArrayAgg | { - JsonArrayAgg: JsonArrayAgg; - } { + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { const _j = {} as JsonArrayAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); - if (isNode) { - return { - JsonArrayAgg: _j - }; - } return _j; }, - rawStmt(_p?: RawStmt, isNode?: boolean): RawStmt | { - RawStmt: RawStmt; - } { + rawStmt(_p?: RawStmt): RawStmt { const _j = {} as RawStmt; _o.set(_j, "stmt", _p?.stmt); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - RawStmt: _j - }; - } return _j; }, - insertStmt(_p?: InsertStmt, isNode?: boolean): InsertStmt | { - InsertStmt: InsertStmt; - } { + insertStmt(_p?: InsertStmt): InsertStmt { const _j = {} as InsertStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cols", _p?.cols); @@ -6386,32 +5502,18 @@ export default { _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); _o.set(_j, "override", _p?.override); - if (isNode) { - return { - InsertStmt: _j - }; - } return _j; }, - deleteStmt(_p?: DeleteStmt, isNode?: boolean): DeleteStmt | { - DeleteStmt: DeleteStmt; - } { + deleteStmt(_p?: DeleteStmt): DeleteStmt { const _j = {} as DeleteStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "usingClause", _p?.usingClause); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - DeleteStmt: _j - }; - } return _j; }, - updateStmt(_p?: UpdateStmt, isNode?: boolean): UpdateStmt | { - UpdateStmt: UpdateStmt; - } { + updateStmt(_p?: UpdateStmt): UpdateStmt { const _j = {} as UpdateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "targetList", _p?.targetList); @@ -6419,32 +5521,18 @@ export default { _o.set(_j, "fromClause", _p?.fromClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - UpdateStmt: _j - }; - } return _j; }, - mergeStmt(_p?: MergeStmt, isNode?: boolean): MergeStmt | { - MergeStmt: MergeStmt; - } { + mergeStmt(_p?: MergeStmt): MergeStmt { const _j = {} as MergeStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "sourceRelation", _p?.sourceRelation); _o.set(_j, "joinCondition", _p?.joinCondition); _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - MergeStmt: _j - }; - } return _j; }, - selectStmt(_p?: SelectStmt, isNode?: boolean): SelectStmt | { - SelectStmt: SelectStmt; - } { + selectStmt(_p?: SelectStmt): SelectStmt { const _j = {} as SelectStmt; _o.set(_j, "distinctClause", _p?.distinctClause); _o.set(_j, "intoClause", _p?.intoClause); @@ -6466,16 +5554,9 @@ export default { _o.set(_j, "all", _p?.all); _o.set(_j, "larg", _p?.larg); _o.set(_j, "rarg", _p?.rarg); - if (isNode) { - return { - SelectStmt: _j - }; - } return _j; }, - setOperationStmt(_p?: SetOperationStmt, isNode?: boolean): SetOperationStmt | { - SetOperationStmt: SetOperationStmt; - } { + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { const _j = {} as SetOperationStmt; _o.set(_j, "op", _p?.op); _o.set(_j, "all", _p?.all); @@ -6485,87 +5566,45 @@ export default { _o.set(_j, "colTypmods", _p?.colTypmods); _o.set(_j, "colCollations", _p?.colCollations); _o.set(_j, "groupClauses", _p?.groupClauses); - if (isNode) { - return { - SetOperationStmt: _j - }; - } return _j; }, - returnStmt(_p?: ReturnStmt, isNode?: boolean): ReturnStmt | { - ReturnStmt: ReturnStmt; - } { + returnStmt(_p?: ReturnStmt): ReturnStmt { const _j = {} as ReturnStmt; _o.set(_j, "returnval", _p?.returnval); - if (isNode) { - return { - ReturnStmt: _j - }; - } return _j; }, - plAssignStmt(_p?: PLAssignStmt, isNode?: boolean): PLAssignStmt | { - PLAssignStmt: PLAssignStmt; - } { + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { const _j = {} as PLAssignStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "nnames", _p?.nnames); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PLAssignStmt: _j - }; - } return _j; }, - createSchemaStmt(_p?: CreateSchemaStmt, isNode?: boolean): CreateSchemaStmt | { - CreateSchemaStmt: CreateSchemaStmt; - } { + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { const _j = {} as CreateSchemaStmt; _o.set(_j, "schemaname", _p?.schemaname); _o.set(_j, "authrole", _p?.authrole); _o.set(_j, "schemaElts", _p?.schemaElts); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSchemaStmt: _j - }; - } return _j; }, - alterTableStmt(_p?: AlterTableStmt, isNode?: boolean): AlterTableStmt | { - AlterTableStmt: AlterTableStmt; - } { + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { const _j = {} as AlterTableStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cmds", _p?.cmds); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTableStmt: _j - }; - } return _j; }, - replicaIdentityStmt(_p?: ReplicaIdentityStmt, isNode?: boolean): ReplicaIdentityStmt | { - ReplicaIdentityStmt: ReplicaIdentityStmt; - } { + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { const _j = {} as ReplicaIdentityStmt; _o.set(_j, "identity_type", _p?.identity_type); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - ReplicaIdentityStmt: _j - }; - } return _j; }, - alterTableCmd(_p?: AlterTableCmd, isNode?: boolean): AlterTableCmd | { - AlterTableCmd: AlterTableCmd; - } { + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { const _j = {} as AlterTableCmd; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "name", _p?.name); @@ -6575,28 +5614,14 @@ export default { _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "recurse", _p?.recurse); - if (isNode) { - return { - AlterTableCmd: _j - }; - } return _j; }, - alterCollationStmt(_p?: AlterCollationStmt, isNode?: boolean): AlterCollationStmt | { - AlterCollationStmt: AlterCollationStmt; - } { + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { const _j = {} as AlterCollationStmt; _o.set(_j, "collname", _p?.collname); - if (isNode) { - return { - AlterCollationStmt: _j - }; - } return _j; }, - alterDomainStmt(_p?: AlterDomainStmt, isNode?: boolean): AlterDomainStmt | { - AlterDomainStmt: AlterDomainStmt; - } { + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { const _j = {} as AlterDomainStmt; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "typeName", _p?.typeName); @@ -6604,16 +5629,9 @@ export default { _o.set(_j, "def", _p?.def); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterDomainStmt: _j - }; - } return _j; }, - grantStmt(_p?: GrantStmt, isNode?: boolean): GrantStmt | { - GrantStmt: GrantStmt; - } { + grantStmt(_p?: GrantStmt): GrantStmt { const _j = {} as GrantStmt; _o.set(_j, "is_grant", _p?.is_grant); _o.set(_j, "targtype", _p?.targtype); @@ -6624,44 +5642,23 @@ export default { _o.set(_j, "grant_option", _p?.grant_option); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantStmt: _j - }; - } return _j; }, - objectWithArgs(_p?: ObjectWithArgs, isNode?: boolean): ObjectWithArgs | { - ObjectWithArgs: ObjectWithArgs; - } { + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { const _j = {} as ObjectWithArgs; _o.set(_j, "objname", _p?.objname); _o.set(_j, "objargs", _p?.objargs); _o.set(_j, "objfuncargs", _p?.objfuncargs); _o.set(_j, "args_unspecified", _p?.args_unspecified); - if (isNode) { - return { - ObjectWithArgs: _j - }; - } return _j; }, - accessPriv(_p?: AccessPriv, isNode?: boolean): AccessPriv | { - AccessPriv: AccessPriv; - } { + accessPriv(_p?: AccessPriv): AccessPriv { const _j = {} as AccessPriv; _o.set(_j, "priv_name", _p?.priv_name); _o.set(_j, "cols", _p?.cols); - if (isNode) { - return { - AccessPriv: _j - }; - } return _j; }, - grantRoleStmt(_p?: GrantRoleStmt, isNode?: boolean): GrantRoleStmt | { - GrantRoleStmt: GrantRoleStmt; - } { + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { const _j = {} as GrantRoleStmt; _o.set(_j, "granted_roles", _p?.granted_roles); _o.set(_j, "grantee_roles", _p?.grantee_roles); @@ -6669,29 +5666,15 @@ export default { _o.set(_j, "opt", _p?.opt); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantRoleStmt: _j - }; - } return _j; }, - alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt, isNode?: boolean): AlterDefaultPrivilegesStmt | { - AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; - } { + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { const _j = {} as AlterDefaultPrivilegesStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterDefaultPrivilegesStmt: _j - }; - } return _j; }, - copyStmt(_p?: CopyStmt, isNode?: boolean): CopyStmt | { - CopyStmt: CopyStmt; - } { + copyStmt(_p?: CopyStmt): CopyStmt { const _j = {} as CopyStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "query", _p?.query); @@ -6701,43 +5684,22 @@ export default { _o.set(_j, "filename", _p?.filename); _o.set(_j, "options", _p?.options); _o.set(_j, "whereClause", _p?.whereClause); - if (isNode) { - return { - CopyStmt: _j - }; - } return _j; }, - variableSetStmt(_p?: VariableSetStmt, isNode?: boolean): VariableSetStmt | { - VariableSetStmt: VariableSetStmt; - } { + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { const _j = {} as VariableSetStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "args", _p?.args); _o.set(_j, "is_local", _p?.is_local); - if (isNode) { - return { - VariableSetStmt: _j - }; - } return _j; }, - variableShowStmt(_p?: VariableShowStmt, isNode?: boolean): VariableShowStmt | { - VariableShowStmt: VariableShowStmt; - } { + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { const _j = {} as VariableShowStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - VariableShowStmt: _j - }; - } return _j; }, - createStmt(_p?: CreateStmt, isNode?: boolean): CreateStmt | { - CreateStmt: CreateStmt; - } { + createStmt(_p?: CreateStmt): CreateStmt { const _j = {} as CreateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "tableElts", _p?.tableElts); @@ -6751,16 +5713,9 @@ export default { _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "accessMethod", _p?.accessMethod); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStmt: _j - }; - } return _j; }, - constraint(_p?: Constraint, isNode?: boolean): Constraint | { - Constraint: Constraint; - } { + constraint(_p?: Constraint): Constraint { const _j = {} as Constraint; _o.set(_j, "contype", _p?.contype); _o.set(_j, "conname", _p?.conname); @@ -6792,144 +5747,74 @@ export default { _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); _o.set(_j, "skip_validation", _p?.skip_validation); _o.set(_j, "initially_valid", _p?.initially_valid); - if (isNode) { - return { - Constraint: _j - }; - } return _j; }, - createTableSpaceStmt(_p?: CreateTableSpaceStmt, isNode?: boolean): CreateTableSpaceStmt | { - CreateTableSpaceStmt: CreateTableSpaceStmt; - } { + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { const _j = {} as CreateTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "owner", _p?.owner); _o.set(_j, "location", _p?.location); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateTableSpaceStmt: _j - }; - } return _j; }, - dropTableSpaceStmt(_p?: DropTableSpaceStmt, isNode?: boolean): DropTableSpaceStmt | { - DropTableSpaceStmt: DropTableSpaceStmt; - } { + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { const _j = {} as DropTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropTableSpaceStmt: _j - }; - } return _j; }, - alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt, isNode?: boolean): AlterTableSpaceOptionsStmt | { - AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; - } { + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { const _j = {} as AlterTableSpaceOptionsStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "options", _p?.options); _o.set(_j, "isReset", _p?.isReset); - if (isNode) { - return { - AlterTableSpaceOptionsStmt: _j - }; - } return _j; }, - alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt, isNode?: boolean): AlterTableMoveAllStmt | { - AlterTableMoveAllStmt: AlterTableMoveAllStmt; - } { + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { const _j = {} as AlterTableMoveAllStmt; _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "roles", _p?.roles); _o.set(_j, "new_tablespacename", _p?.new_tablespacename); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - AlterTableMoveAllStmt: _j - }; - } return _j; }, - createExtensionStmt(_p?: CreateExtensionStmt, isNode?: boolean): CreateExtensionStmt | { - CreateExtensionStmt: CreateExtensionStmt; - } { + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { const _j = {} as CreateExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateExtensionStmt: _j - }; - } return _j; }, - alterExtensionStmt(_p?: AlterExtensionStmt, isNode?: boolean): AlterExtensionStmt | { - AlterExtensionStmt: AlterExtensionStmt; - } { + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { const _j = {} as AlterExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterExtensionStmt: _j - }; - } return _j; }, - alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt, isNode?: boolean): AlterExtensionContentsStmt | { - AlterExtensionContentsStmt: AlterExtensionContentsStmt; - } { + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { const _j = {} as AlterExtensionContentsStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "action", _p?.action); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); - if (isNode) { - return { - AlterExtensionContentsStmt: _j - }; - } return _j; }, - createFdwStmt(_p?: CreateFdwStmt, isNode?: boolean): CreateFdwStmt | { - CreateFdwStmt: CreateFdwStmt; - } { + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { const _j = {} as CreateFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateFdwStmt: _j - }; - } return _j; }, - alterFdwStmt(_p?: AlterFdwStmt, isNode?: boolean): AlterFdwStmt | { - AlterFdwStmt: AlterFdwStmt; - } { + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { const _j = {} as AlterFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterFdwStmt: _j - }; - } return _j; }, - createForeignServerStmt(_p?: CreateForeignServerStmt, isNode?: boolean): CreateForeignServerStmt | { - CreateForeignServerStmt: CreateForeignServerStmt; - } { + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { const _j = {} as CreateForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "servertype", _p?.servertype); @@ -6937,88 +5822,46 @@ export default { _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignServerStmt: _j - }; - } return _j; }, - alterForeignServerStmt(_p?: AlterForeignServerStmt, isNode?: boolean): AlterForeignServerStmt | { - AlterForeignServerStmt: AlterForeignServerStmt; - } { + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { const _j = {} as AlterForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "version", _p?.version); _o.set(_j, "options", _p?.options); _o.set(_j, "has_version", _p?.has_version); - if (isNode) { - return { - AlterForeignServerStmt: _j - }; - } return _j; }, - createForeignTableStmt(_p?: CreateForeignTableStmt, isNode?: boolean): CreateForeignTableStmt | { - CreateForeignTableStmt: CreateForeignTableStmt; - } { + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { const _j = {} as CreateForeignTableStmt; _o.set(_j, "base", _p?.base); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignTableStmt: _j - }; - } return _j; }, - createUserMappingStmt(_p?: CreateUserMappingStmt, isNode?: boolean): CreateUserMappingStmt | { - CreateUserMappingStmt: CreateUserMappingStmt; - } { + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { const _j = {} as CreateUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateUserMappingStmt: _j - }; - } return _j; }, - alterUserMappingStmt(_p?: AlterUserMappingStmt, isNode?: boolean): AlterUserMappingStmt | { - AlterUserMappingStmt: AlterUserMappingStmt; - } { + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { const _j = {} as AlterUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterUserMappingStmt: _j - }; - } return _j; }, - dropUserMappingStmt(_p?: DropUserMappingStmt, isNode?: boolean): DropUserMappingStmt | { - DropUserMappingStmt: DropUserMappingStmt; - } { + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { const _j = {} as DropUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropUserMappingStmt: _j - }; - } return _j; }, - importForeignSchemaStmt(_p?: ImportForeignSchemaStmt, isNode?: boolean): ImportForeignSchemaStmt | { - ImportForeignSchemaStmt: ImportForeignSchemaStmt; - } { + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { const _j = {} as ImportForeignSchemaStmt; _o.set(_j, "server_name", _p?.server_name); _o.set(_j, "remote_schema", _p?.remote_schema); @@ -7026,16 +5869,9 @@ export default { _o.set(_j, "list_type", _p?.list_type); _o.set(_j, "table_list", _p?.table_list); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ImportForeignSchemaStmt: _j - }; - } return _j; }, - createPolicyStmt(_p?: CreatePolicyStmt, isNode?: boolean): CreatePolicyStmt | { - CreatePolicyStmt: CreatePolicyStmt; - } { + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { const _j = {} as CreatePolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); @@ -7044,46 +5880,25 @@ export default { _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - CreatePolicyStmt: _j - }; - } return _j; }, - alterPolicyStmt(_p?: AlterPolicyStmt, isNode?: boolean): AlterPolicyStmt | { - AlterPolicyStmt: AlterPolicyStmt; - } { + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { const _j = {} as AlterPolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - AlterPolicyStmt: _j - }; - } return _j; }, - createAmStmt(_p?: CreateAmStmt, isNode?: boolean): CreateAmStmt | { - CreateAmStmt: CreateAmStmt; - } { + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { const _j = {} as CreateAmStmt; _o.set(_j, "amname", _p?.amname); _o.set(_j, "handler_name", _p?.handler_name); _o.set(_j, "amtype", _p?.amtype); - if (isNode) { - return { - CreateAmStmt: _j - }; - } return _j; }, - createTrigStmt(_p?: CreateTrigStmt, isNode?: boolean): CreateTrigStmt | { - CreateTrigStmt: CreateTrigStmt; - } { + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { const _j = {} as CreateTrigStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "isconstraint", _p?.isconstraint); @@ -7100,44 +5915,23 @@ export default { _o.set(_j, "deferrable", _p?.deferrable); _o.set(_j, "initdeferred", _p?.initdeferred); _o.set(_j, "constrrel", _p?.constrrel); - if (isNode) { - return { - CreateTrigStmt: _j - }; - } return _j; }, - createEventTrigStmt(_p?: CreateEventTrigStmt, isNode?: boolean): CreateEventTrigStmt | { - CreateEventTrigStmt: CreateEventTrigStmt; - } { + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { const _j = {} as CreateEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "eventname", _p?.eventname); _o.set(_j, "whenclause", _p?.whenclause); _o.set(_j, "funcname", _p?.funcname); - if (isNode) { - return { - CreateEventTrigStmt: _j - }; - } return _j; }, - alterEventTrigStmt(_p?: AlterEventTrigStmt, isNode?: boolean): AlterEventTrigStmt | { - AlterEventTrigStmt: AlterEventTrigStmt; - } { + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { const _j = {} as AlterEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "tgenabled", _p?.tgenabled); - if (isNode) { - return { - AlterEventTrigStmt: _j - }; - } return _j; }, - createpLangStmt(_p?: CreatePLangStmt, isNode?: boolean): CreatePLangStmt | { - CreatePLangStmt: CreatePLangStmt; - } { + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { const _j = {} as CreatePLangStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "plname", _p?.plname); @@ -7145,102 +5939,53 @@ export default { _o.set(_j, "plinline", _p?.plinline); _o.set(_j, "plvalidator", _p?.plvalidator); _o.set(_j, "pltrusted", _p?.pltrusted); - if (isNode) { - return { - CreatePLangStmt: _j - }; - } return _j; }, - createRoleStmt(_p?: CreateRoleStmt, isNode?: boolean): CreateRoleStmt | { - CreateRoleStmt: CreateRoleStmt; - } { + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { const _j = {} as CreateRoleStmt; _o.set(_j, "stmt_type", _p?.stmt_type); _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateRoleStmt: _j - }; - } return _j; }, - alterRoleStmt(_p?: AlterRoleStmt, isNode?: boolean): AlterRoleStmt | { - AlterRoleStmt: AlterRoleStmt; - } { + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { const _j = {} as AlterRoleStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterRoleStmt: _j - }; - } return _j; }, - alterRoleSetStmt(_p?: AlterRoleSetStmt, isNode?: boolean): AlterRoleSetStmt | { - AlterRoleSetStmt: AlterRoleSetStmt; - } { + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { const _j = {} as AlterRoleSetStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "database", _p?.database); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterRoleSetStmt: _j - }; - } return _j; }, - dropRoleStmt(_p?: DropRoleStmt, isNode?: boolean): DropRoleStmt | { - DropRoleStmt: DropRoleStmt; - } { + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { const _j = {} as DropRoleStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropRoleStmt: _j - }; - } return _j; }, - createSeqStmt(_p?: CreateSeqStmt, isNode?: boolean): CreateSeqStmt | { - CreateSeqStmt: CreateSeqStmt; - } { + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { const _j = {} as CreateSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "ownerId", _p?.ownerId); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSeqStmt: _j - }; - } return _j; }, - alterSeqStmt(_p?: AlterSeqStmt, isNode?: boolean): AlterSeqStmt | { - AlterSeqStmt: AlterSeqStmt; - } { + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { const _j = {} as AlterSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterSeqStmt: _j - }; - } return _j; }, - defineStmt(_p?: DefineStmt, isNode?: boolean): DefineStmt | { - DefineStmt: DefineStmt; - } { + defineStmt(_p?: DefineStmt): DefineStmt { const _j = {} as DefineStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "oldstyle", _p?.oldstyle); @@ -7249,31 +5994,17 @@ export default { _o.set(_j, "definition", _p?.definition); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - DefineStmt: _j - }; - } return _j; }, - createDomainStmt(_p?: CreateDomainStmt, isNode?: boolean): CreateDomainStmt | { - CreateDomainStmt: CreateDomainStmt; - } { + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { const _j = {} as CreateDomainStmt; _o.set(_j, "domainname", _p?.domainname); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "collClause", _p?.collClause); _o.set(_j, "constraints", _p?.constraints); - if (isNode) { - return { - CreateDomainStmt: _j - }; - } return _j; }, - createOpClassStmt(_p?: CreateOpClassStmt, isNode?: boolean): CreateOpClassStmt | { - CreateOpClassStmt: CreateOpClassStmt; - } { + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { const _j = {} as CreateOpClassStmt; _o.set(_j, "opclassname", _p?.opclassname); _o.set(_j, "opfamilyname", _p?.opfamilyname); @@ -7281,16 +6012,9 @@ export default { _o.set(_j, "datatype", _p?.datatype); _o.set(_j, "items", _p?.items); _o.set(_j, "isDefault", _p?.isDefault); - if (isNode) { - return { - CreateOpClassStmt: _j - }; - } return _j; }, - createOpClassItem(_p?: CreateOpClassItem, isNode?: boolean): CreateOpClassItem | { - CreateOpClassItem: CreateOpClassItem; - } { + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { const _j = {} as CreateOpClassItem; _o.set(_j, "itemtype", _p?.itemtype); _o.set(_j, "name", _p?.name); @@ -7298,144 +6022,74 @@ export default { _o.set(_j, "order_family", _p?.order_family); _o.set(_j, "class_args", _p?.class_args); _o.set(_j, "storedtype", _p?.storedtype); - if (isNode) { - return { - CreateOpClassItem: _j - }; - } return _j; }, - createOpFamilyStmt(_p?: CreateOpFamilyStmt, isNode?: boolean): CreateOpFamilyStmt | { - CreateOpFamilyStmt: CreateOpFamilyStmt; - } { + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { const _j = {} as CreateOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); - if (isNode) { - return { - CreateOpFamilyStmt: _j - }; - } return _j; }, - alterOpFamilyStmt(_p?: AlterOpFamilyStmt, isNode?: boolean): AlterOpFamilyStmt | { - AlterOpFamilyStmt: AlterOpFamilyStmt; - } { + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { const _j = {} as AlterOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); _o.set(_j, "isDrop", _p?.isDrop); _o.set(_j, "items", _p?.items); - if (isNode) { - return { - AlterOpFamilyStmt: _j - }; - } return _j; }, - dropStmt(_p?: DropStmt, isNode?: boolean): DropStmt | { - DropStmt: DropStmt; - } { + dropStmt(_p?: DropStmt): DropStmt { const _j = {} as DropStmt; _o.set(_j, "objects", _p?.objects); _o.set(_j, "removeType", _p?.removeType); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - DropStmt: _j - }; - } return _j; }, - truncateStmt(_p?: TruncateStmt, isNode?: boolean): TruncateStmt | { - TruncateStmt: TruncateStmt; - } { + truncateStmt(_p?: TruncateStmt): TruncateStmt { const _j = {} as TruncateStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "restart_seqs", _p?.restart_seqs); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - TruncateStmt: _j - }; - } return _j; }, - commentStmt(_p?: CommentStmt, isNode?: boolean): CommentStmt | { - CommentStmt: CommentStmt; - } { + commentStmt(_p?: CommentStmt): CommentStmt { const _j = {} as CommentStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "comment", _p?.comment); - if (isNode) { - return { - CommentStmt: _j - }; - } return _j; }, - secLabelStmt(_p?: SecLabelStmt, isNode?: boolean): SecLabelStmt | { - SecLabelStmt: SecLabelStmt; - } { + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { const _j = {} as SecLabelStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "provider", _p?.provider); _o.set(_j, "label", _p?.label); - if (isNode) { - return { - SecLabelStmt: _j - }; - } return _j; }, - declareCursorStmt(_p?: DeclareCursorStmt, isNode?: boolean): DeclareCursorStmt | { - DeclareCursorStmt: DeclareCursorStmt; - } { + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { const _j = {} as DeclareCursorStmt; _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "options", _p?.options); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - DeclareCursorStmt: _j - }; - } return _j; }, - closePortalStmt(_p?: ClosePortalStmt, isNode?: boolean): ClosePortalStmt | { - ClosePortalStmt: ClosePortalStmt; - } { + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { const _j = {} as ClosePortalStmt; _o.set(_j, "portalname", _p?.portalname); - if (isNode) { - return { - ClosePortalStmt: _j - }; - } return _j; }, - fetchStmt(_p?: FetchStmt, isNode?: boolean): FetchStmt | { - FetchStmt: FetchStmt; - } { + fetchStmt(_p?: FetchStmt): FetchStmt { const _j = {} as FetchStmt; _o.set(_j, "direction", _p?.direction); _o.set(_j, "howMany", _p?.howMany); _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "ismove", _p?.ismove); - if (isNode) { - return { - FetchStmt: _j - }; - } return _j; }, - indexStmt(_p?: IndexStmt, isNode?: boolean): IndexStmt | { - IndexStmt: IndexStmt; - } { + indexStmt(_p?: IndexStmt): IndexStmt { const _j = {} as IndexStmt; _o.set(_j, "idxname", _p?.idxname); _o.set(_j, "relation", _p?.relation); @@ -7461,16 +6115,9 @@ export default { _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); - if (isNode) { - return { - IndexStmt: _j - }; - } return _j; }, - createStatsStmt(_p?: CreateStatsStmt, isNode?: boolean): CreateStatsStmt | { - CreateStatsStmt: CreateStatsStmt; - } { + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { const _j = {} as CreateStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stat_types", _p?.stat_types); @@ -7479,43 +6126,22 @@ export default { _o.set(_j, "stxcomment", _p?.stxcomment); _o.set(_j, "transformed", _p?.transformed); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStatsStmt: _j - }; - } return _j; }, - statsElem(_p?: StatsElem, isNode?: boolean): StatsElem | { - StatsElem: StatsElem; - } { + statsElem(_p?: StatsElem): StatsElem { const _j = {} as StatsElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); - if (isNode) { - return { - StatsElem: _j - }; - } return _j; }, - alterStatsStmt(_p?: AlterStatsStmt, isNode?: boolean): AlterStatsStmt | { - AlterStatsStmt: AlterStatsStmt; - } { + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { const _j = {} as AlterStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stxstattarget", _p?.stxstattarget); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterStatsStmt: _j - }; - } return _j; }, - createFunctionStmt(_p?: CreateFunctionStmt, isNode?: boolean): CreateFunctionStmt | { - CreateFunctionStmt: CreateFunctionStmt; - } { + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { const _j = {} as CreateFunctionStmt; _o.set(_j, "is_procedure", _p?.is_procedure); _o.set(_j, "replace", _p?.replace); @@ -7524,98 +6150,49 @@ export default { _o.set(_j, "returnType", _p?.returnType); _o.set(_j, "options", _p?.options); _o.set(_j, "sql_body", _p?.sql_body); - if (isNode) { - return { - CreateFunctionStmt: _j - }; - } return _j; }, - functionParameter(_p?: FunctionParameter, isNode?: boolean): FunctionParameter | { - FunctionParameter: FunctionParameter; - } { + functionParameter(_p?: FunctionParameter): FunctionParameter { const _j = {} as FunctionParameter; _o.set(_j, "name", _p?.name); _o.set(_j, "argType", _p?.argType); _o.set(_j, "mode", _p?.mode); _o.set(_j, "defexpr", _p?.defexpr); - if (isNode) { - return { - FunctionParameter: _j - }; - } return _j; }, - alterFunctionStmt(_p?: AlterFunctionStmt, isNode?: boolean): AlterFunctionStmt | { - AlterFunctionStmt: AlterFunctionStmt; - } { + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { const _j = {} as AlterFunctionStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "func", _p?.func); _o.set(_j, "actions", _p?.actions); - if (isNode) { - return { - AlterFunctionStmt: _j - }; - } return _j; }, - doStmt(_p?: DoStmt, isNode?: boolean): DoStmt | { - DoStmt: DoStmt; - } { + doStmt(_p?: DoStmt): DoStmt { const _j = {} as DoStmt; _o.set(_j, "args", _p?.args); - if (isNode) { - return { - DoStmt: _j - }; - } return _j; }, - inlineCodeBlock(_p?: InlineCodeBlock, isNode?: boolean): InlineCodeBlock | { - InlineCodeBlock: InlineCodeBlock; - } { + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { const _j = {} as InlineCodeBlock; _o.set(_j, "source_text", _p?.source_text); _o.set(_j, "langOid", _p?.langOid); _o.set(_j, "langIsTrusted", _p?.langIsTrusted); _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - InlineCodeBlock: _j - }; - } return _j; }, - callStmt(_p?: CallStmt, isNode?: boolean): CallStmt | { - CallStmt: CallStmt; - } { + callStmt(_p?: CallStmt): CallStmt { const _j = {} as CallStmt; _o.set(_j, "funccall", _p?.funccall); _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "outargs", _p?.outargs); - if (isNode) { - return { - CallStmt: _j - }; - } return _j; }, - callContext(_p?: CallContext, isNode?: boolean): CallContext | { - CallContext: CallContext; - } { + callContext(_p?: CallContext): CallContext { const _j = {} as CallContext; _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - CallContext: _j - }; - } return _j; }, - renameStmt(_p?: RenameStmt, isNode?: boolean): RenameStmt | { - RenameStmt: RenameStmt; - } { + renameStmt(_p?: RenameStmt): RenameStmt { const _j = {} as RenameStmt; _o.set(_j, "renameType", _p?.renameType); _o.set(_j, "relationType", _p?.relationType); @@ -7625,89 +6202,47 @@ export default { _o.set(_j, "newname", _p?.newname); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - RenameStmt: _j - }; - } return _j; }, - alterObjectDependsStmt(_p?: AlterObjectDependsStmt, isNode?: boolean): AlterObjectDependsStmt | { - AlterObjectDependsStmt: AlterObjectDependsStmt; - } { + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { const _j = {} as AlterObjectDependsStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "extname", _p?.extname); _o.set(_j, "remove", _p?.remove); - if (isNode) { - return { - AlterObjectDependsStmt: _j - }; - } return _j; }, - alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt, isNode?: boolean): AlterObjectSchemaStmt | { - AlterObjectSchemaStmt: AlterObjectSchemaStmt; - } { + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { const _j = {} as AlterObjectSchemaStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newschema", _p?.newschema); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterObjectSchemaStmt: _j - }; - } return _j; }, - alterOwnerStmt(_p?: AlterOwnerStmt, isNode?: boolean): AlterOwnerStmt | { - AlterOwnerStmt: AlterOwnerStmt; - } { + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { const _j = {} as AlterOwnerStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newowner", _p?.newowner); - if (isNode) { - return { - AlterOwnerStmt: _j - }; - } return _j; }, - alterOperatorStmt(_p?: AlterOperatorStmt, isNode?: boolean): AlterOperatorStmt | { - AlterOperatorStmt: AlterOperatorStmt; - } { + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { const _j = {} as AlterOperatorStmt; _o.set(_j, "opername", _p?.opername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterOperatorStmt: _j - }; - } return _j; }, - alterTypeStmt(_p?: AlterTypeStmt, isNode?: boolean): AlterTypeStmt | { - AlterTypeStmt: AlterTypeStmt; - } { + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { const _j = {} as AlterTypeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTypeStmt: _j - }; - } return _j; }, - ruleStmt(_p?: RuleStmt, isNode?: boolean): RuleStmt | { - RuleStmt: RuleStmt; - } { + ruleStmt(_p?: RuleStmt): RuleStmt { const _j = {} as RuleStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "rulename", _p?.rulename); @@ -7716,108 +6251,52 @@ export default { _o.set(_j, "instead", _p?.instead); _o.set(_j, "actions", _p?.actions); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - RuleStmt: _j - }; - } return _j; }, - notifyStmt(_p?: NotifyStmt, isNode?: boolean): NotifyStmt | { - NotifyStmt: NotifyStmt; - } { + notifyStmt(_p?: NotifyStmt): NotifyStmt { const _j = {} as NotifyStmt; _o.set(_j, "conditionname", _p?.conditionname); _o.set(_j, "payload", _p?.payload); - if (isNode) { - return { - NotifyStmt: _j - }; - } return _j; }, - listenStmt(_p?: ListenStmt, isNode?: boolean): ListenStmt | { - ListenStmt: ListenStmt; - } { + listenStmt(_p?: ListenStmt): ListenStmt { const _j = {} as ListenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - ListenStmt: _j - }; - } return _j; }, - unlistenStmt(_p?: UnlistenStmt, isNode?: boolean): UnlistenStmt | { - UnlistenStmt: UnlistenStmt; - } { + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { const _j = {} as UnlistenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - UnlistenStmt: _j - }; - } return _j; }, - transactionStmt(_p?: TransactionStmt, isNode?: boolean): TransactionStmt | { - TransactionStmt: TransactionStmt; - } { + transactionStmt(_p?: TransactionStmt): TransactionStmt { const _j = {} as TransactionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "options", _p?.options); _o.set(_j, "savepoint_name", _p?.savepoint_name); _o.set(_j, "gid", _p?.gid); _o.set(_j, "chain", _p?.chain); - if (isNode) { - return { - TransactionStmt: _j - }; - } return _j; }, - compositeTypeStmt(_p?: CompositeTypeStmt, isNode?: boolean): CompositeTypeStmt | { - CompositeTypeStmt: CompositeTypeStmt; - } { + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { const _j = {} as CompositeTypeStmt; _o.set(_j, "typevar", _p?.typevar); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - CompositeTypeStmt: _j - }; - } return _j; }, - createEnumStmt(_p?: CreateEnumStmt, isNode?: boolean): CreateEnumStmt | { - CreateEnumStmt: CreateEnumStmt; - } { + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { const _j = {} as CreateEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "vals", _p?.vals); - if (isNode) { - return { - CreateEnumStmt: _j - }; - } return _j; }, - createRangeStmt(_p?: CreateRangeStmt, isNode?: boolean): CreateRangeStmt | { - CreateRangeStmt: CreateRangeStmt; - } { + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { const _j = {} as CreateRangeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - CreateRangeStmt: _j - }; - } return _j; }, - alterEnumStmt(_p?: AlterEnumStmt, isNode?: boolean): AlterEnumStmt | { - AlterEnumStmt: AlterEnumStmt; - } { + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { const _j = {} as AlterEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "oldVal", _p?.oldVal); @@ -7825,16 +6304,9 @@ export default { _o.set(_j, "newValNeighbor", _p?.newValNeighbor); _o.set(_j, "newValIsAfter", _p?.newValIsAfter); _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); - if (isNode) { - return { - AlterEnumStmt: _j - }; - } return _j; }, - viewStmt(_p?: ViewStmt, isNode?: boolean): ViewStmt | { - ViewStmt: ViewStmt; - } { + viewStmt(_p?: ViewStmt): ViewStmt { const _j = {} as ViewStmt; _o.set(_j, "view", _p?.view); _o.set(_j, "aliases", _p?.aliases); @@ -7842,381 +6314,185 @@ export default { _o.set(_j, "replace", _p?.replace); _o.set(_j, "options", _p?.options); _o.set(_j, "withCheckOption", _p?.withCheckOption); - if (isNode) { - return { - ViewStmt: _j - }; - } return _j; }, - loadStmt(_p?: LoadStmt, isNode?: boolean): LoadStmt | { - LoadStmt: LoadStmt; - } { + loadStmt(_p?: LoadStmt): LoadStmt { const _j = {} as LoadStmt; _o.set(_j, "filename", _p?.filename); - if (isNode) { - return { - LoadStmt: _j - }; - } return _j; }, - createdbStmt(_p?: CreatedbStmt, isNode?: boolean): CreatedbStmt | { - CreatedbStmt: CreatedbStmt; - } { + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { const _j = {} as CreatedbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreatedbStmt: _j - }; - } return _j; }, - alterDatabaseStmt(_p?: AlterDatabaseStmt, isNode?: boolean): AlterDatabaseStmt | { - AlterDatabaseStmt: AlterDatabaseStmt; - } { + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { const _j = {} as AlterDatabaseStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterDatabaseStmt: _j - }; - } return _j; }, - alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt, isNode?: boolean): AlterDatabaseRefreshCollStmt | { - AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; - } { + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { const _j = {} as AlterDatabaseRefreshCollStmt; _o.set(_j, "dbname", _p?.dbname); - if (isNode) { - return { - AlterDatabaseRefreshCollStmt: _j - }; - } return _j; }, - alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt, isNode?: boolean): AlterDatabaseSetStmt | { - AlterDatabaseSetStmt: AlterDatabaseSetStmt; - } { + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { const _j = {} as AlterDatabaseSetStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterDatabaseSetStmt: _j - }; - } return _j; }, - dropdbStmt(_p?: DropdbStmt, isNode?: boolean): DropdbStmt | { - DropdbStmt: DropdbStmt; - } { + dropdbStmt(_p?: DropdbStmt): DropdbStmt { const _j = {} as DropdbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - DropdbStmt: _j - }; - } return _j; }, - alterSystemStmt(_p?: AlterSystemStmt, isNode?: boolean): AlterSystemStmt | { - AlterSystemStmt: AlterSystemStmt; - } { + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { const _j = {} as AlterSystemStmt; _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterSystemStmt: _j - }; - } return _j; }, - clusterStmt(_p?: ClusterStmt, isNode?: boolean): ClusterStmt | { - ClusterStmt: ClusterStmt; - } { + clusterStmt(_p?: ClusterStmt): ClusterStmt { const _j = {} as ClusterStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "indexname", _p?.indexname); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ClusterStmt: _j - }; - } return _j; }, - vacuumStmt(_p?: VacuumStmt, isNode?: boolean): VacuumStmt | { - VacuumStmt: VacuumStmt; - } { + vacuumStmt(_p?: VacuumStmt): VacuumStmt { const _j = {} as VacuumStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "rels", _p?.rels); _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); - if (isNode) { - return { - VacuumStmt: _j - }; - } return _j; }, - vacuumRelation(_p?: VacuumRelation, isNode?: boolean): VacuumRelation | { - VacuumRelation: VacuumRelation; - } { + vacuumRelation(_p?: VacuumRelation): VacuumRelation { const _j = {} as VacuumRelation; _o.set(_j, "relation", _p?.relation); _o.set(_j, "oid", _p?.oid); _o.set(_j, "va_cols", _p?.va_cols); - if (isNode) { - return { - VacuumRelation: _j - }; - } return _j; }, - explainStmt(_p?: ExplainStmt, isNode?: boolean): ExplainStmt | { - ExplainStmt: ExplainStmt; - } { + explainStmt(_p?: ExplainStmt): ExplainStmt { const _j = {} as ExplainStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ExplainStmt: _j - }; - } return _j; }, - createTableAsStmt(_p?: CreateTableAsStmt, isNode?: boolean): CreateTableAsStmt | { - CreateTableAsStmt: CreateTableAsStmt; - } { + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { const _j = {} as CreateTableAsStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "into", _p?.into); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "is_select_into", _p?.is_select_into); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateTableAsStmt: _j - }; - } return _j; }, - refreshMatViewStmt(_p?: RefreshMatViewStmt, isNode?: boolean): RefreshMatViewStmt | { - RefreshMatViewStmt: RefreshMatViewStmt; - } { + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { const _j = {} as RefreshMatViewStmt; _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "skipData", _p?.skipData); _o.set(_j, "relation", _p?.relation); - if (isNode) { - return { - RefreshMatViewStmt: _j - }; - } return _j; }, - checkPointStmt(_p?: CheckPointStmt, isNode?: boolean): CheckPointStmt | { - CheckPointStmt: CheckPointStmt; - } { + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { const _j = {} as CheckPointStmt; - if (isNode) { - return { - CheckPointStmt: _j - }; - } return _j; }, - discardStmt(_p?: DiscardStmt, isNode?: boolean): DiscardStmt | { - DiscardStmt: DiscardStmt; - } { + discardStmt(_p?: DiscardStmt): DiscardStmt { const _j = {} as DiscardStmt; _o.set(_j, "target", _p?.target); - if (isNode) { - return { - DiscardStmt: _j - }; - } return _j; }, - lockStmt(_p?: LockStmt, isNode?: boolean): LockStmt | { - LockStmt: LockStmt; - } { + lockStmt(_p?: LockStmt): LockStmt { const _j = {} as LockStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "mode", _p?.mode); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - LockStmt: _j - }; - } return _j; }, - constraintsSetStmt(_p?: ConstraintsSetStmt, isNode?: boolean): ConstraintsSetStmt | { - ConstraintsSetStmt: ConstraintsSetStmt; - } { + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { const _j = {} as ConstraintsSetStmt; _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "deferred", _p?.deferred); - if (isNode) { - return { - ConstraintsSetStmt: _j - }; - } return _j; }, - reindexStmt(_p?: ReindexStmt, isNode?: boolean): ReindexStmt | { - ReindexStmt: ReindexStmt; - } { + reindexStmt(_p?: ReindexStmt): ReindexStmt { const _j = {} as ReindexStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relation", _p?.relation); _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ReindexStmt: _j - }; - } return _j; }, - createConversionStmt(_p?: CreateConversionStmt, isNode?: boolean): CreateConversionStmt | { - CreateConversionStmt: CreateConversionStmt; - } { + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { const _j = {} as CreateConversionStmt; _o.set(_j, "conversion_name", _p?.conversion_name); _o.set(_j, "for_encoding_name", _p?.for_encoding_name); _o.set(_j, "to_encoding_name", _p?.to_encoding_name); _o.set(_j, "func_name", _p?.func_name); _o.set(_j, "def", _p?.def); - if (isNode) { - return { - CreateConversionStmt: _j - }; - } return _j; }, - createCastStmt(_p?: CreateCastStmt, isNode?: boolean): CreateCastStmt | { - CreateCastStmt: CreateCastStmt; - } { + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { const _j = {} as CreateCastStmt; _o.set(_j, "sourcetype", _p?.sourcetype); _o.set(_j, "targettype", _p?.targettype); _o.set(_j, "func", _p?.func); _o.set(_j, "context", _p?.context); _o.set(_j, "inout", _p?.inout); - if (isNode) { - return { - CreateCastStmt: _j - }; - } return _j; }, - createTransformStmt(_p?: CreateTransformStmt, isNode?: boolean): CreateTransformStmt | { - CreateTransformStmt: CreateTransformStmt; - } { + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { const _j = {} as CreateTransformStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "type_name", _p?.type_name); _o.set(_j, "lang", _p?.lang); _o.set(_j, "fromsql", _p?.fromsql); _o.set(_j, "tosql", _p?.tosql); - if (isNode) { - return { - CreateTransformStmt: _j - }; - } return _j; }, - prepareStmt(_p?: PrepareStmt, isNode?: boolean): PrepareStmt | { - PrepareStmt: PrepareStmt; - } { + prepareStmt(_p?: PrepareStmt): PrepareStmt { const _j = {} as PrepareStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "argtypes", _p?.argtypes); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - PrepareStmt: _j - }; - } return _j; }, - executeStmt(_p?: ExecuteStmt, isNode?: boolean): ExecuteStmt | { - ExecuteStmt: ExecuteStmt; - } { + executeStmt(_p?: ExecuteStmt): ExecuteStmt { const _j = {} as ExecuteStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ExecuteStmt: _j - }; - } return _j; }, - deallocateStmt(_p?: DeallocateStmt, isNode?: boolean): DeallocateStmt | { - DeallocateStmt: DeallocateStmt; - } { + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { const _j = {} as DeallocateStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - DeallocateStmt: _j - }; - } return _j; }, - dropOwnedStmt(_p?: DropOwnedStmt, isNode?: boolean): DropOwnedStmt | { - DropOwnedStmt: DropOwnedStmt; - } { + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { const _j = {} as DropOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropOwnedStmt: _j - }; - } return _j; }, - reassignOwnedStmt(_p?: ReassignOwnedStmt, isNode?: boolean): ReassignOwnedStmt | { - ReassignOwnedStmt: ReassignOwnedStmt; - } { + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { const _j = {} as ReassignOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "newrole", _p?.newrole); - if (isNode) { - return { - ReassignOwnedStmt: _j - }; - } return _j; }, - altertsDictionaryStmt(_p?: AlterTSDictionaryStmt, isNode?: boolean): AlterTSDictionaryStmt | { - AlterTSDictionaryStmt: AlterTSDictionaryStmt; - } { + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { const _j = {} as AlterTSDictionaryStmt; _o.set(_j, "dictname", _p?.dictname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTSDictionaryStmt: _j - }; - } return _j; }, - altertsConfigurationStmt(_p?: AlterTSConfigurationStmt, isNode?: boolean): AlterTSConfigurationStmt | { - AlterTSConfigurationStmt: AlterTSConfigurationStmt; - } { + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { const _j = {} as AlterTSConfigurationStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "cfgname", _p?.cfgname); @@ -8225,131 +6501,70 @@ export default { _o.set(_j, "override", _p?.override); _o.set(_j, "replace", _p?.replace); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTSConfigurationStmt: _j - }; - } return _j; }, - publicationTable(_p?: PublicationTable, isNode?: boolean): PublicationTable | { - PublicationTable: PublicationTable; - } { + publicationTable(_p?: PublicationTable): PublicationTable { const _j = {} as PublicationTable; _o.set(_j, "relation", _p?.relation); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "columns", _p?.columns); - if (isNode) { - return { - PublicationTable: _j - }; - } return _j; }, - publicationObjSpec(_p?: PublicationObjSpec, isNode?: boolean): PublicationObjSpec | { - PublicationObjSpec: PublicationObjSpec; - } { + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { const _j = {} as PublicationObjSpec; _o.set(_j, "pubobjtype", _p?.pubobjtype); _o.set(_j, "name", _p?.name); _o.set(_j, "pubtable", _p?.pubtable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PublicationObjSpec: _j - }; - } return _j; }, - createPublicationStmt(_p?: CreatePublicationStmt, isNode?: boolean): CreatePublicationStmt | { - CreatePublicationStmt: CreatePublicationStmt; - } { + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { const _j = {} as CreatePublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); - if (isNode) { - return { - CreatePublicationStmt: _j - }; - } return _j; }, - alterPublicationStmt(_p?: AlterPublicationStmt, isNode?: boolean): AlterPublicationStmt | { - AlterPublicationStmt: AlterPublicationStmt; - } { + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { const _j = {} as AlterPublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterPublicationStmt: _j - }; - } return _j; }, - createSubscriptionStmt(_p?: CreateSubscriptionStmt, isNode?: boolean): CreateSubscriptionStmt | { - CreateSubscriptionStmt: CreateSubscriptionStmt; - } { + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { const _j = {} as CreateSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateSubscriptionStmt: _j - }; - } return _j; }, - alterSubscriptionStmt(_p?: AlterSubscriptionStmt, isNode?: boolean): AlterSubscriptionStmt | { - AlterSubscriptionStmt: AlterSubscriptionStmt; - } { + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { const _j = {} as AlterSubscriptionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterSubscriptionStmt: _j - }; - } return _j; }, - dropSubscriptionStmt(_p?: DropSubscriptionStmt, isNode?: boolean): DropSubscriptionStmt | { - DropSubscriptionStmt: DropSubscriptionStmt; - } { + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { const _j = {} as DropSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropSubscriptionStmt: _j - }; - } return _j; }, - scanToken(_p?: ScanToken, isNode?: boolean): ScanToken | { - ScanToken: ScanToken; - } { + scanToken(_p?: ScanToken): ScanToken { const _j = {} as ScanToken; _o.set(_j, "start", _p?.start); _o.set(_j, "end", _p?.end); _o.set(_j, "token", _p?.token); _o.set(_j, "keywordKind", _p?.keywordKind); - if (isNode) { - return { - ScanToken: _j - }; - } return _j; } };", @@ -16877,131 +15092,59 @@ export type Token = "NUL" | "ASCII_36" | "ASCII_37" | "ASCII_40" | "ASCII_41" | import _o from "./path-obj"; import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; export default { - parseResult(_p?: ParseResult, isNode?: boolean): ParseResult | { - ParseResult: ParseResult; - } { + parseResult(_p?: ParseResult): ParseResult { const _j = {} as ParseResult; _o.set(_j, "version", _p?.version); _o.set(_j, "stmts", _p?.stmts); - if (isNode) { - return { - ParseResult: _j - }; - } return _j; }, - scanResult(_p?: ScanResult, isNode?: boolean): ScanResult | { - ScanResult: ScanResult; - } { + scanResult(_p?: ScanResult): ScanResult { const _j = {} as ScanResult; _o.set(_j, "version", _p?.version); _o.set(_j, "tokens", _p?.tokens); - if (isNode) { - return { - ScanResult: _j - }; - } return _j; }, - integer(_p?: Integer, isNode?: boolean): Integer | { - Integer: Integer; - } { + integer(_p?: Integer): Integer { const _j = {} as Integer; _o.set(_j, "ival", _p?.ival); - if (isNode) { - return { - Integer: _j - }; - } return _j; }, - float(_p?: Float, isNode?: boolean): Float | { - Float: Float; - } { + float(_p?: Float): Float { const _j = {} as Float; _o.set(_j, "fval", _p?.fval); - if (isNode) { - return { - Float: _j - }; - } return _j; }, - boolean(_p?: Boolean, isNode?: boolean): Boolean | { - Boolean: Boolean; - } { + boolean(_p?: Boolean): Boolean { const _j = {} as Boolean; _o.set(_j, "boolval", _p?.boolval); - if (isNode) { - return { - Boolean: _j - }; - } return _j; }, - string(_p?: String, isNode?: boolean): String | { - String: String; - } { + string(_p?: String): String { const _j = {} as String; _o.set(_j, "sval", _p?.sval); - if (isNode) { - return { - String: _j - }; - } return _j; }, - bitString(_p?: BitString, isNode?: boolean): BitString | { - BitString: BitString; - } { + bitString(_p?: BitString): BitString { const _j = {} as BitString; _o.set(_j, "bsval", _p?.bsval); - if (isNode) { - return { - BitString: _j - }; - } return _j; }, - list(_p?: List, isNode?: boolean): List | { - List: List; - } { + list(_p?: List): List { const _j = {} as List; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - List: _j - }; - } return _j; }, - oidList(_p?: OidList, isNode?: boolean): OidList | { - OidList: OidList; - } { + oidList(_p?: OidList): OidList { const _j = {} as OidList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - OidList: _j - }; - } return _j; }, - intList(_p?: IntList, isNode?: boolean): IntList | { - IntList: IntList; - } { + intList(_p?: IntList): IntList { const _j = {} as IntList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - IntList: _j - }; - } return _j; }, - aConst(_p?: A_Const, isNode?: boolean): A_Const | { - A_Const: A_Const; - } { + aConst(_p?: A_Const): A_Const { const _j = {} as A_Const; _o.set(_j, "ival", _p?.ival); _o.set(_j, "fval", _p?.fval); @@ -17010,29 +15153,15 @@ export default { _o.set(_j, "bsval", _p?.bsval); _o.set(_j, "isnull", _p?.isnull); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Const: _j - }; - } return _j; }, - alias(_p?: Alias, isNode?: boolean): Alias | { - Alias: Alias; - } { + alias(_p?: Alias): Alias { const _j = {} as Alias; _o.set(_j, "aliasname", _p?.aliasname); _o.set(_j, "colnames", _p?.colnames); - if (isNode) { - return { - Alias: _j - }; - } return _j; }, - rangeVar(_p?: RangeVar, isNode?: boolean): RangeVar | { - RangeVar: RangeVar; - } { + rangeVar(_p?: RangeVar): RangeVar { const _j = {} as RangeVar; _o.set(_j, "catalogname", _p?.catalogname); _o.set(_j, "schemaname", _p?.schemaname); @@ -17041,16 +15170,9 @@ export default { _o.set(_j, "relpersistence", _p?.relpersistence); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeVar: _j - }; - } return _j; }, - tableFunc(_p?: TableFunc, isNode?: boolean): TableFunc | { - TableFunc: TableFunc; - } { + tableFunc(_p?: TableFunc): TableFunc { const _j = {} as TableFunc; _o.set(_j, "ns_uris", _p?.ns_uris); _o.set(_j, "ns_names", _p?.ns_names); @@ -17065,16 +15187,9 @@ export default { _o.set(_j, "notnulls", _p?.notnulls); _o.set(_j, "ordinalitycol", _p?.ordinalitycol); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TableFunc: _j - }; - } return _j; }, - intoClause(_p?: IntoClause, isNode?: boolean): IntoClause | { - IntoClause: IntoClause; - } { + intoClause(_p?: IntoClause): IntoClause { const _j = {} as IntoClause; _o.set(_j, "rel", _p?.rel); _o.set(_j, "colNames", _p?.colNames); @@ -17084,16 +15199,9 @@ export default { _o.set(_j, "tableSpaceName", _p?.tableSpaceName); _o.set(_j, "viewQuery", _p?.viewQuery); _o.set(_j, "skipData", _p?.skipData); - if (isNode) { - return { - IntoClause: _j - }; - } return _j; }, - var(_p?: Var, isNode?: boolean): Var | { - Var: Var; - } { + var(_p?: Var): Var { const _j = {} as Var; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "varno", _p?.varno); @@ -17104,16 +15212,9 @@ export default { _o.set(_j, "varnullingrels", _p?.varnullingrels); _o.set(_j, "varlevelsup", _p?.varlevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Var: _j - }; - } return _j; }, - param(_p?: Param, isNode?: boolean): Param | { - Param: Param; - } { + param(_p?: Param): Param { const _j = {} as Param; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "paramkind", _p?.paramkind); @@ -17122,16 +15223,9 @@ export default { _o.set(_j, "paramtypmod", _p?.paramtypmod); _o.set(_j, "paramcollid", _p?.paramcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Param: _j - }; - } return _j; }, - aggref(_p?: Aggref, isNode?: boolean): Aggref | { - Aggref: Aggref; - } { + aggref(_p?: Aggref): Aggref { const _j = {} as Aggref; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "aggfnoid", _p?.aggfnoid); @@ -17152,32 +15246,18 @@ export default { _o.set(_j, "aggno", _p?.aggno); _o.set(_j, "aggtransno", _p?.aggtransno); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Aggref: _j - }; - } return _j; }, - groupingFunc(_p?: GroupingFunc, isNode?: boolean): GroupingFunc | { - GroupingFunc: GroupingFunc; - } { + groupingFunc(_p?: GroupingFunc): GroupingFunc { const _j = {} as GroupingFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); _o.set(_j, "refs", _p?.refs); _o.set(_j, "agglevelsup", _p?.agglevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingFunc: _j - }; - } return _j; }, - windowFunc(_p?: WindowFunc, isNode?: boolean): WindowFunc | { - WindowFunc: WindowFunc; - } { + windowFunc(_p?: WindowFunc): WindowFunc { const _j = {} as WindowFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "winfnoid", _p?.winfnoid); @@ -17190,16 +15270,9 @@ export default { _o.set(_j, "winstar", _p?.winstar); _o.set(_j, "winagg", _p?.winagg); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowFunc: _j - }; - } return _j; }, - subscriptingRef(_p?: SubscriptingRef, isNode?: boolean): SubscriptingRef | { - SubscriptingRef: SubscriptingRef; - } { + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { const _j = {} as SubscriptingRef; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "refcontainertype", _p?.refcontainertype); @@ -17211,16 +15284,9 @@ export default { _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); _o.set(_j, "refexpr", _p?.refexpr); _o.set(_j, "refassgnexpr", _p?.refassgnexpr); - if (isNode) { - return { - SubscriptingRef: _j - }; - } return _j; }, - funcExpr(_p?: FuncExpr, isNode?: boolean): FuncExpr | { - FuncExpr: FuncExpr; - } { + funcExpr(_p?: FuncExpr): FuncExpr { const _j = {} as FuncExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "funcid", _p?.funcid); @@ -17232,32 +15298,18 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncExpr: _j - }; - } return _j; }, - namedArgExpr(_p?: NamedArgExpr, isNode?: boolean): NamedArgExpr | { - NamedArgExpr: NamedArgExpr; - } { + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { const _j = {} as NamedArgExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "name", _p?.name); _o.set(_j, "argnumber", _p?.argnumber); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NamedArgExpr: _j - }; - } return _j; }, - opExpr(_p?: OpExpr, isNode?: boolean): OpExpr | { - OpExpr: OpExpr; - } { + opExpr(_p?: OpExpr): OpExpr { const _j = {} as OpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -17267,16 +15319,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OpExpr: _j - }; - } return _j; }, - distinctExpr(_p?: DistinctExpr, isNode?: boolean): DistinctExpr | { - DistinctExpr: DistinctExpr; - } { + distinctExpr(_p?: DistinctExpr): DistinctExpr { const _j = {} as DistinctExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -17286,16 +15331,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DistinctExpr: _j - }; - } return _j; }, - nullIfExpr(_p?: NullIfExpr, isNode?: boolean): NullIfExpr | { - NullIfExpr: NullIfExpr; - } { + nullIfExpr(_p?: NullIfExpr): NullIfExpr { const _j = {} as NullIfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -17305,16 +15343,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullIfExpr: _j - }; - } return _j; }, - scalarArrayOpExpr(_p?: ScalarArrayOpExpr, isNode?: boolean): ScalarArrayOpExpr | { - ScalarArrayOpExpr: ScalarArrayOpExpr; - } { + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { const _j = {} as ScalarArrayOpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -17322,31 +15353,17 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ScalarArrayOpExpr: _j - }; - } return _j; }, - boolExpr(_p?: BoolExpr, isNode?: boolean): BoolExpr | { - BoolExpr: BoolExpr; - } { + boolExpr(_p?: BoolExpr): BoolExpr { const _j = {} as BoolExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "boolop", _p?.boolop); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BoolExpr: _j - }; - } return _j; }, - subLink(_p?: SubLink, isNode?: boolean): SubLink | { - SubLink: SubLink; - } { + subLink(_p?: SubLink): SubLink { const _j = {} as SubLink; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -17355,16 +15372,9 @@ export default { _o.set(_j, "operName", _p?.operName); _o.set(_j, "subselect", _p?.subselect); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SubLink: _j - }; - } return _j; }, - subPlan(_p?: SubPlan, isNode?: boolean): SubPlan | { - SubPlan: SubPlan; - } { + subPlan(_p?: SubPlan): SubPlan { const _j = {} as SubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -17383,29 +15393,15 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "startup_cost", _p?.startup_cost); _o.set(_j, "per_call_cost", _p?.per_call_cost); - if (isNode) { - return { - SubPlan: _j - }; - } return _j; }, - alternativeSubPlan(_p?: AlternativeSubPlan, isNode?: boolean): AlternativeSubPlan | { - AlternativeSubPlan: AlternativeSubPlan; - } { + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { const _j = {} as AlternativeSubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subplans", _p?.subplans); - if (isNode) { - return { - AlternativeSubPlan: _j - }; - } return _j; }, - fieldSelect(_p?: FieldSelect, isNode?: boolean): FieldSelect | { - FieldSelect: FieldSelect; - } { + fieldSelect(_p?: FieldSelect): FieldSelect { const _j = {} as FieldSelect; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -17413,32 +15409,18 @@ export default { _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "resulttypmod", _p?.resulttypmod); _o.set(_j, "resultcollid", _p?.resultcollid); - if (isNode) { - return { - FieldSelect: _j - }; - } return _j; }, - fieldStore(_p?: FieldStore, isNode?: boolean): FieldStore | { - FieldStore: FieldStore; - } { + fieldStore(_p?: FieldStore): FieldStore { const _j = {} as FieldStore; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "newvals", _p?.newvals); _o.set(_j, "fieldnums", _p?.fieldnums); _o.set(_j, "resulttype", _p?.resulttype); - if (isNode) { - return { - FieldStore: _j - }; - } return _j; }, - relabelType(_p?: RelabelType, isNode?: boolean): RelabelType | { - RelabelType: RelabelType; - } { + relabelType(_p?: RelabelType): RelabelType { const _j = {} as RelabelType; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -17447,16 +15429,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "relabelformat", _p?.relabelformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RelabelType: _j - }; - } return _j; }, - coerceViaio(_p?: CoerceViaIO, isNode?: boolean): CoerceViaIO | { - CoerceViaIO: CoerceViaIO; - } { + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { const _j = {} as CoerceViaIO; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -17464,16 +15439,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceViaIO: _j - }; - } return _j; }, - arrayCoerceExpr(_p?: ArrayCoerceExpr, isNode?: boolean): ArrayCoerceExpr | { - ArrayCoerceExpr: ArrayCoerceExpr; - } { + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { const _j = {} as ArrayCoerceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -17483,47 +15451,26 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayCoerceExpr: _j - }; - } return _j; }, - convertRowtypeExpr(_p?: ConvertRowtypeExpr, isNode?: boolean): ConvertRowtypeExpr | { - ConvertRowtypeExpr: ConvertRowtypeExpr; - } { + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { const _j = {} as ConvertRowtypeExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "convertformat", _p?.convertformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ConvertRowtypeExpr: _j - }; - } return _j; }, - collateExpr(_p?: CollateExpr, isNode?: boolean): CollateExpr | { - CollateExpr: CollateExpr; - } { + collateExpr(_p?: CollateExpr): CollateExpr { const _j = {} as CollateExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "collOid", _p?.collOid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateExpr: _j - }; - } return _j; }, - caseExpr(_p?: CaseExpr, isNode?: boolean): CaseExpr | { - CaseExpr: CaseExpr; - } { + caseExpr(_p?: CaseExpr): CaseExpr { const _j = {} as CaseExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "casetype", _p?.casetype); @@ -17532,46 +15479,25 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "defresult", _p?.defresult); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseExpr: _j - }; - } return _j; }, - caseWhen(_p?: CaseWhen, isNode?: boolean): CaseWhen | { - CaseWhen: CaseWhen; - } { + caseWhen(_p?: CaseWhen): CaseWhen { const _j = {} as CaseWhen; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "result", _p?.result); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseWhen: _j - }; - } return _j; }, - caseTestExpr(_p?: CaseTestExpr, isNode?: boolean): CaseTestExpr | { - CaseTestExpr: CaseTestExpr; - } { + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { const _j = {} as CaseTestExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); - if (isNode) { - return { - CaseTestExpr: _j - }; - } return _j; }, - arrayExpr(_p?: ArrayExpr, isNode?: boolean): ArrayExpr | { - ArrayExpr: ArrayExpr; - } { + arrayExpr(_p?: ArrayExpr): ArrayExpr { const _j = {} as ArrayExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "array_typeid", _p?.array_typeid); @@ -17580,16 +15506,9 @@ export default { _o.set(_j, "elements", _p?.elements); _o.set(_j, "multidims", _p?.multidims); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayExpr: _j - }; - } return _j; }, - rowExpr(_p?: RowExpr, isNode?: boolean): RowExpr | { - RowExpr: RowExpr; - } { + rowExpr(_p?: RowExpr): RowExpr { const _j = {} as RowExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); @@ -17597,16 +15516,9 @@ export default { _o.set(_j, "row_format", _p?.row_format); _o.set(_j, "colnames", _p?.colnames); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RowExpr: _j - }; - } return _j; }, - rowCompareExpr(_p?: RowCompareExpr, isNode?: boolean): RowCompareExpr | { - RowCompareExpr: RowCompareExpr; - } { + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { const _j = {} as RowCompareExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "rctype", _p?.rctype); @@ -17615,32 +15527,18 @@ export default { _o.set(_j, "inputcollids", _p?.inputcollids); _o.set(_j, "largs", _p?.largs); _o.set(_j, "rargs", _p?.rargs); - if (isNode) { - return { - RowCompareExpr: _j - }; - } return _j; }, - coalesceExpr(_p?: CoalesceExpr, isNode?: boolean): CoalesceExpr | { - CoalesceExpr: CoalesceExpr; - } { + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { const _j = {} as CoalesceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "coalescetype", _p?.coalescetype); _o.set(_j, "coalescecollid", _p?.coalescecollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoalesceExpr: _j - }; - } return _j; }, - minMaxExpr(_p?: MinMaxExpr, isNode?: boolean): MinMaxExpr | { - MinMaxExpr: MinMaxExpr; - } { + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { const _j = {} as MinMaxExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "minmaxtype", _p?.minmaxtype); @@ -17649,32 +15547,18 @@ export default { _o.set(_j, "op", _p?.op); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MinMaxExpr: _j - }; - } return _j; }, - sqlValueFunction(_p?: SQLValueFunction, isNode?: boolean): SQLValueFunction | { - SQLValueFunction: SQLValueFunction; - } { + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { const _j = {} as SQLValueFunction; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SQLValueFunction: _j - }; - } return _j; }, - xmlExpr(_p?: XmlExpr, isNode?: boolean): XmlExpr | { - XmlExpr: XmlExpr; - } { + xmlExpr(_p?: XmlExpr): XmlExpr { const _j = {} as XmlExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -17687,58 +15571,30 @@ export default { _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlExpr: _j - }; - } return _j; }, - jsonFormat(_p?: JsonFormat, isNode?: boolean): JsonFormat | { - JsonFormat: JsonFormat; - } { + jsonFormat(_p?: JsonFormat): JsonFormat { const _j = {} as JsonFormat; _o.set(_j, "format_type", _p?.format_type); _o.set(_j, "encoding", _p?.encoding); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFormat: _j - }; - } return _j; }, - jsonReturning(_p?: JsonReturning, isNode?: boolean): JsonReturning | { - JsonReturning: JsonReturning; - } { + jsonReturning(_p?: JsonReturning): JsonReturning { const _j = {} as JsonReturning; _o.set(_j, "format", _p?.format); _o.set(_j, "typid", _p?.typid); _o.set(_j, "typmod", _p?.typmod); - if (isNode) { - return { - JsonReturning: _j - }; - } return _j; }, - jsonValueExpr(_p?: JsonValueExpr, isNode?: boolean): JsonValueExpr | { - JsonValueExpr: JsonValueExpr; - } { + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { const _j = {} as JsonValueExpr; _o.set(_j, "raw_expr", _p?.raw_expr); _o.set(_j, "formatted_expr", _p?.formatted_expr); _o.set(_j, "format", _p?.format); - if (isNode) { - return { - JsonValueExpr: _j - }; - } return _j; }, - jsonConstructorExpr(_p?: JsonConstructorExpr, isNode?: boolean): JsonConstructorExpr | { - JsonConstructorExpr: JsonConstructorExpr; - } { + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { const _j = {} as JsonConstructorExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "type", _p?.type); @@ -17749,63 +15605,35 @@ export default { _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonConstructorExpr: _j - }; - } return _j; }, - jsonIsPredicate(_p?: JsonIsPredicate, isNode?: boolean): JsonIsPredicate | { - JsonIsPredicate: JsonIsPredicate; - } { + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { const _j = {} as JsonIsPredicate; _o.set(_j, "expr", _p?.expr); _o.set(_j, "format", _p?.format); _o.set(_j, "item_type", _p?.item_type); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonIsPredicate: _j - }; - } return _j; }, - nullTest(_p?: NullTest, isNode?: boolean): NullTest | { - NullTest: NullTest; - } { + nullTest(_p?: NullTest): NullTest { const _j = {} as NullTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "nulltesttype", _p?.nulltesttype); _o.set(_j, "argisrow", _p?.argisrow); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullTest: _j - }; - } return _j; }, - booleanTest(_p?: BooleanTest, isNode?: boolean): BooleanTest | { - BooleanTest: BooleanTest; - } { + booleanTest(_p?: BooleanTest): BooleanTest { const _j = {} as BooleanTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "booltesttype", _p?.booltesttype); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BooleanTest: _j - }; - } return _j; }, - coerceToDomain(_p?: CoerceToDomain, isNode?: boolean): CoerceToDomain | { - CoerceToDomain: CoerceToDomain; - } { + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { const _j = {} as CoerceToDomain; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -17814,92 +15642,50 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coercionformat", _p?.coercionformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomain: _j - }; - } return _j; }, - coerceToDomainValue(_p?: CoerceToDomainValue, isNode?: boolean): CoerceToDomainValue | { - CoerceToDomainValue: CoerceToDomainValue; - } { + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { const _j = {} as CoerceToDomainValue; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomainValue: _j - }; - } return _j; }, - setToDefault(_p?: SetToDefault, isNode?: boolean): SetToDefault | { - SetToDefault: SetToDefault; - } { + setToDefault(_p?: SetToDefault): SetToDefault { const _j = {} as SetToDefault; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SetToDefault: _j - }; - } return _j; }, - currentOfExpr(_p?: CurrentOfExpr, isNode?: boolean): CurrentOfExpr | { - CurrentOfExpr: CurrentOfExpr; - } { + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { const _j = {} as CurrentOfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "cvarno", _p?.cvarno); _o.set(_j, "cursor_name", _p?.cursor_name); _o.set(_j, "cursor_param", _p?.cursor_param); - if (isNode) { - return { - CurrentOfExpr: _j - }; - } return _j; }, - nextValueExpr(_p?: NextValueExpr, isNode?: boolean): NextValueExpr | { - NextValueExpr: NextValueExpr; - } { + nextValueExpr(_p?: NextValueExpr): NextValueExpr { const _j = {} as NextValueExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "seqid", _p?.seqid); _o.set(_j, "typeId", _p?.typeId); - if (isNode) { - return { - NextValueExpr: _j - }; - } return _j; }, - inferenceElem(_p?: InferenceElem, isNode?: boolean): InferenceElem | { - InferenceElem: InferenceElem; - } { + inferenceElem(_p?: InferenceElem): InferenceElem { const _j = {} as InferenceElem; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "infercollid", _p?.infercollid); _o.set(_j, "inferopclass", _p?.inferopclass); - if (isNode) { - return { - InferenceElem: _j - }; - } return _j; }, - targetEntry(_p?: TargetEntry, isNode?: boolean): TargetEntry | { - TargetEntry: TargetEntry; - } { + targetEntry(_p?: TargetEntry): TargetEntry { const _j = {} as TargetEntry; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); @@ -17909,28 +15695,14 @@ export default { _o.set(_j, "resorigtbl", _p?.resorigtbl); _o.set(_j, "resorigcol", _p?.resorigcol); _o.set(_j, "resjunk", _p?.resjunk); - if (isNode) { - return { - TargetEntry: _j - }; - } return _j; }, - rangeTblRef(_p?: RangeTblRef, isNode?: boolean): RangeTblRef | { - RangeTblRef: RangeTblRef; - } { + rangeTblRef(_p?: RangeTblRef): RangeTblRef { const _j = {} as RangeTblRef; _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - RangeTblRef: _j - }; - } return _j; }, - joinExpr(_p?: JoinExpr, isNode?: boolean): JoinExpr | { - JoinExpr: JoinExpr; - } { + joinExpr(_p?: JoinExpr): JoinExpr { const _j = {} as JoinExpr; _o.set(_j, "jointype", _p?.jointype); _o.set(_j, "isNatural", _p?.isNatural); @@ -17941,29 +15713,15 @@ export default { _o.set(_j, "quals", _p?.quals); _o.set(_j, "alias", _p?.alias); _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - JoinExpr: _j - }; - } return _j; }, - fromExpr(_p?: FromExpr, isNode?: boolean): FromExpr | { - FromExpr: FromExpr; - } { + fromExpr(_p?: FromExpr): FromExpr { const _j = {} as FromExpr; _o.set(_j, "fromlist", _p?.fromlist); _o.set(_j, "quals", _p?.quals); - if (isNode) { - return { - FromExpr: _j - }; - } return _j; }, - onConflictExpr(_p?: OnConflictExpr, isNode?: boolean): OnConflictExpr | { - OnConflictExpr: OnConflictExpr; - } { + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { const _j = {} as OnConflictExpr; _o.set(_j, "action", _p?.action); _o.set(_j, "arbiterElems", _p?.arbiterElems); @@ -17973,16 +15731,9 @@ export default { _o.set(_j, "onConflictWhere", _p?.onConflictWhere); _o.set(_j, "exclRelIndex", _p?.exclRelIndex); _o.set(_j, "exclRelTlist", _p?.exclRelTlist); - if (isNode) { - return { - OnConflictExpr: _j - }; - } return _j; }, - query(_p?: Query, isNode?: boolean): Query | { - Query: Query; - } { + query(_p?: Query): Query { const _j = {} as Query; _o.set(_j, "commandType", _p?.commandType); _o.set(_j, "querySource", _p?.querySource); @@ -18025,16 +15776,9 @@ export default { _o.set(_j, "withCheckOptions", _p?.withCheckOptions); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - Query: _j - }; - } return _j; }, - typeName(_p?: TypeName, isNode?: boolean): TypeName | { - TypeName: TypeName; - } { + typeName(_p?: TypeName): TypeName { const _j = {} as TypeName; _o.set(_j, "names", _p?.names); _o.set(_j, "typeOid", _p?.typeOid); @@ -18044,100 +15788,51 @@ export default { _o.set(_j, "typemod", _p?.typemod); _o.set(_j, "arrayBounds", _p?.arrayBounds); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeName: _j - }; - } return _j; }, - columnRef(_p?: ColumnRef, isNode?: boolean): ColumnRef | { - ColumnRef: ColumnRef; - } { + columnRef(_p?: ColumnRef): ColumnRef { const _j = {} as ColumnRef; _o.set(_j, "fields", _p?.fields); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnRef: _j - }; - } return _j; }, - paramRef(_p?: ParamRef, isNode?: boolean): ParamRef | { - ParamRef: ParamRef; - } { + paramRef(_p?: ParamRef): ParamRef { const _j = {} as ParamRef; _o.set(_j, "number", _p?.number); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ParamRef: _j - }; - } return _j; }, - aExpr(_p?: A_Expr, isNode?: boolean): A_Expr | { - A_Expr: A_Expr; - } { + aExpr(_p?: A_Expr): A_Expr { const _j = {} as A_Expr; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "lexpr", _p?.lexpr); _o.set(_j, "rexpr", _p?.rexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Expr: _j - }; - } return _j; }, - typeCast(_p?: TypeCast, isNode?: boolean): TypeCast | { - TypeCast: TypeCast; - } { + typeCast(_p?: TypeCast): TypeCast { const _j = {} as TypeCast; _o.set(_j, "arg", _p?.arg); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeCast: _j - }; - } return _j; }, - collateClause(_p?: CollateClause, isNode?: boolean): CollateClause | { - CollateClause: CollateClause; - } { + collateClause(_p?: CollateClause): CollateClause { const _j = {} as CollateClause; _o.set(_j, "arg", _p?.arg); _o.set(_j, "collname", _p?.collname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateClause: _j - }; - } return _j; }, - roleSpec(_p?: RoleSpec, isNode?: boolean): RoleSpec | { - RoleSpec: RoleSpec; - } { + roleSpec(_p?: RoleSpec): RoleSpec { const _j = {} as RoleSpec; _o.set(_j, "roletype", _p?.roletype); _o.set(_j, "rolename", _p?.rolename); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RoleSpec: _j - }; - } return _j; }, - funcCall(_p?: FuncCall, isNode?: boolean): FuncCall | { - FuncCall: FuncCall; - } { + funcCall(_p?: FuncCall): FuncCall { const _j = {} as FuncCall; _o.set(_j, "funcname", _p?.funcname); _o.set(_j, "args", _p?.args); @@ -18150,112 +15845,56 @@ export default { _o.set(_j, "func_variadic", _p?.func_variadic); _o.set(_j, "funcformat", _p?.funcformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncCall: _j - }; - } return _j; }, - aStar(_p?: A_Star, isNode?: boolean): A_Star | { - A_Star: A_Star; - } { + aStar(_p?: A_Star): A_Star { const _j = {} as A_Star; - if (isNode) { - return { - A_Star: _j - }; - } return _j; }, - aIndices(_p?: A_Indices, isNode?: boolean): A_Indices | { - A_Indices: A_Indices; - } { + aIndices(_p?: A_Indices): A_Indices { const _j = {} as A_Indices; _o.set(_j, "is_slice", _p?.is_slice); _o.set(_j, "lidx", _p?.lidx); _o.set(_j, "uidx", _p?.uidx); - if (isNode) { - return { - A_Indices: _j - }; - } return _j; }, - aIndirection(_p?: A_Indirection, isNode?: boolean): A_Indirection | { - A_Indirection: A_Indirection; - } { + aIndirection(_p?: A_Indirection): A_Indirection { const _j = {} as A_Indirection; _o.set(_j, "arg", _p?.arg); _o.set(_j, "indirection", _p?.indirection); - if (isNode) { - return { - A_Indirection: _j - }; - } return _j; }, - aArrayExpr(_p?: A_ArrayExpr, isNode?: boolean): A_ArrayExpr | { - A_ArrayExpr: A_ArrayExpr; - } { + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { const _j = {} as A_ArrayExpr; _o.set(_j, "elements", _p?.elements); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_ArrayExpr: _j - }; - } return _j; }, - resTarget(_p?: ResTarget, isNode?: boolean): ResTarget | { - ResTarget: ResTarget; - } { + resTarget(_p?: ResTarget): ResTarget { const _j = {} as ResTarget; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ResTarget: _j - }; - } return _j; }, - multiAssignRef(_p?: MultiAssignRef, isNode?: boolean): MultiAssignRef | { - MultiAssignRef: MultiAssignRef; - } { + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { const _j = {} as MultiAssignRef; _o.set(_j, "source", _p?.source); _o.set(_j, "colno", _p?.colno); _o.set(_j, "ncolumns", _p?.ncolumns); - if (isNode) { - return { - MultiAssignRef: _j - }; - } return _j; }, - sortBy(_p?: SortBy, isNode?: boolean): SortBy | { - SortBy: SortBy; - } { + sortBy(_p?: SortBy): SortBy { const _j = {} as SortBy; _o.set(_j, "node", _p?.node); _o.set(_j, "sortby_dir", _p?.sortby_dir); _o.set(_j, "sortby_nulls", _p?.sortby_nulls); _o.set(_j, "useOp", _p?.useOp); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SortBy: _j - }; - } return _j; }, - windowDef(_p?: WindowDef, isNode?: boolean): WindowDef | { - WindowDef: WindowDef; - } { + windowDef(_p?: WindowDef): WindowDef { const _j = {} as WindowDef; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -18265,30 +15904,16 @@ export default { _o.set(_j, "startOffset", _p?.startOffset); _o.set(_j, "endOffset", _p?.endOffset); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowDef: _j - }; - } return _j; }, - rangeSubselect(_p?: RangeSubselect, isNode?: boolean): RangeSubselect | { - RangeSubselect: RangeSubselect; - } { + rangeSubselect(_p?: RangeSubselect): RangeSubselect { const _j = {} as RangeSubselect; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "subquery", _p?.subquery); _o.set(_j, "alias", _p?.alias); - if (isNode) { - return { - RangeSubselect: _j - }; - } return _j; }, - rangeFunction(_p?: RangeFunction, isNode?: boolean): RangeFunction | { - RangeFunction: RangeFunction; - } { + rangeFunction(_p?: RangeFunction): RangeFunction { const _j = {} as RangeFunction; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "ordinality", _p?.ordinality); @@ -18296,16 +15921,9 @@ export default { _o.set(_j, "functions", _p?.functions); _o.set(_j, "alias", _p?.alias); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - RangeFunction: _j - }; - } return _j; }, - rangeTableFunc(_p?: RangeTableFunc, isNode?: boolean): RangeTableFunc | { - RangeTableFunc: RangeTableFunc; - } { + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { const _j = {} as RangeTableFunc; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "docexpr", _p?.docexpr); @@ -18314,16 +15932,9 @@ export default { _o.set(_j, "columns", _p?.columns); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFunc: _j - }; - } return _j; }, - rangeTableFuncCol(_p?: RangeTableFuncCol, isNode?: boolean): RangeTableFuncCol | { - RangeTableFuncCol: RangeTableFuncCol; - } { + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { const _j = {} as RangeTableFuncCol; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -18332,32 +15943,18 @@ export default { _o.set(_j, "colexpr", _p?.colexpr); _o.set(_j, "coldefexpr", _p?.coldefexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFuncCol: _j - }; - } return _j; }, - rangeTableSample(_p?: RangeTableSample, isNode?: boolean): RangeTableSample | { - RangeTableSample: RangeTableSample; - } { + rangeTableSample(_p?: RangeTableSample): RangeTableSample { const _j = {} as RangeTableSample; _o.set(_j, "relation", _p?.relation); _o.set(_j, "method", _p?.method); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableSample: _j - }; - } return _j; }, - columnDef(_p?: ColumnDef, isNode?: boolean): ColumnDef | { - ColumnDef: ColumnDef; - } { + columnDef(_p?: ColumnDef): ColumnDef { const _j = {} as ColumnDef; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -18378,30 +15975,16 @@ export default { _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "fdwoptions", _p?.fdwoptions); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnDef: _j - }; - } return _j; }, - tableLikeClause(_p?: TableLikeClause, isNode?: boolean): TableLikeClause | { - TableLikeClause: TableLikeClause; - } { + tableLikeClause(_p?: TableLikeClause): TableLikeClause { const _j = {} as TableLikeClause; _o.set(_j, "relation", _p?.relation); _o.set(_j, "options", _p?.options); _o.set(_j, "relationOid", _p?.relationOid); - if (isNode) { - return { - TableLikeClause: _j - }; - } return _j; }, - indexElem(_p?: IndexElem, isNode?: boolean): IndexElem | { - IndexElem: IndexElem; - } { + indexElem(_p?: IndexElem): IndexElem { const _j = {} as IndexElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); @@ -18411,92 +15994,50 @@ export default { _o.set(_j, "opclassopts", _p?.opclassopts); _o.set(_j, "ordering", _p?.ordering); _o.set(_j, "nulls_ordering", _p?.nulls_ordering); - if (isNode) { - return { - IndexElem: _j - }; - } return _j; }, - defElem(_p?: DefElem, isNode?: boolean): DefElem | { - DefElem: DefElem; - } { + defElem(_p?: DefElem): DefElem { const _j = {} as DefElem; _o.set(_j, "defnamespace", _p?.defnamespace); _o.set(_j, "defname", _p?.defname); _o.set(_j, "arg", _p?.arg); _o.set(_j, "defaction", _p?.defaction); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DefElem: _j - }; - } return _j; }, - lockingClause(_p?: LockingClause, isNode?: boolean): LockingClause | { - LockingClause: LockingClause; - } { + lockingClause(_p?: LockingClause): LockingClause { const _j = {} as LockingClause; _o.set(_j, "lockedRels", _p?.lockedRels); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); - if (isNode) { - return { - LockingClause: _j - }; - } return _j; }, - xmlSerialize(_p?: XmlSerialize, isNode?: boolean): XmlSerialize | { - XmlSerialize: XmlSerialize; - } { + xmlSerialize(_p?: XmlSerialize): XmlSerialize { const _j = {} as XmlSerialize; _o.set(_j, "xmloption", _p?.xmloption); _o.set(_j, "expr", _p?.expr); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "indent", _p?.indent); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlSerialize: _j - }; - } return _j; }, - partitionElem(_p?: PartitionElem, isNode?: boolean): PartitionElem | { - PartitionElem: PartitionElem; - } { + partitionElem(_p?: PartitionElem): PartitionElem { const _j = {} as PartitionElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); _o.set(_j, "collation", _p?.collation); _o.set(_j, "opclass", _p?.opclass); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionElem: _j - }; - } return _j; }, - partitionSpec(_p?: PartitionSpec, isNode?: boolean): PartitionSpec | { - PartitionSpec: PartitionSpec; - } { + partitionSpec(_p?: PartitionSpec): PartitionSpec { const _j = {} as PartitionSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "partParams", _p?.partParams); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionSpec: _j - }; - } return _j; }, - partitionBoundSpec(_p?: PartitionBoundSpec, isNode?: boolean): PartitionBoundSpec | { - PartitionBoundSpec: PartitionBoundSpec; - } { + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { const _j = {} as PartitionBoundSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "is_default", _p?.is_default); @@ -18506,44 +16047,23 @@ export default { _o.set(_j, "lowerdatums", _p?.lowerdatums); _o.set(_j, "upperdatums", _p?.upperdatums); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionBoundSpec: _j - }; - } return _j; }, - partitionRangeDatum(_p?: PartitionRangeDatum, isNode?: boolean): PartitionRangeDatum | { - PartitionRangeDatum: PartitionRangeDatum; - } { + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { const _j = {} as PartitionRangeDatum; _o.set(_j, "kind", _p?.kind); _o.set(_j, "value", _p?.value); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionRangeDatum: _j - }; - } return _j; }, - partitionCmd(_p?: PartitionCmd, isNode?: boolean): PartitionCmd | { - PartitionCmd: PartitionCmd; - } { + partitionCmd(_p?: PartitionCmd): PartitionCmd { const _j = {} as PartitionCmd; _o.set(_j, "name", _p?.name); _o.set(_j, "bound", _p?.bound); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - PartitionCmd: _j - }; - } return _j; }, - rangeTblEntry(_p?: RangeTblEntry, isNode?: boolean): RangeTblEntry | { - RangeTblEntry: RangeTblEntry; - } { + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { const _j = {} as RangeTblEntry; _o.set(_j, "rtekind", _p?.rtekind); _o.set(_j, "relid", _p?.relid); @@ -18577,16 +16097,9 @@ export default { _o.set(_j, "inh", _p?.inh); _o.set(_j, "inFromCl", _p?.inFromCl); _o.set(_j, "securityQuals", _p?.securityQuals); - if (isNode) { - return { - RangeTblEntry: _j - }; - } return _j; }, - rtePermissionInfo(_p?: RTEPermissionInfo, isNode?: boolean): RTEPermissionInfo | { - RTEPermissionInfo: RTEPermissionInfo; - } { + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { const _j = {} as RTEPermissionInfo; _o.set(_j, "relid", _p?.relid); _o.set(_j, "inh", _p?.inh); @@ -18595,16 +16108,9 @@ export default { _o.set(_j, "selectedCols", _p?.selectedCols); _o.set(_j, "insertedCols", _p?.insertedCols); _o.set(_j, "updatedCols", _p?.updatedCols); - if (isNode) { - return { - RTEPermissionInfo: _j - }; - } return _j; }, - rangeTblFunction(_p?: RangeTblFunction, isNode?: boolean): RangeTblFunction | { - RangeTblFunction: RangeTblFunction; - } { + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { const _j = {} as RangeTblFunction; _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "funccolcount", _p?.funccolcount); @@ -18613,76 +16119,41 @@ export default { _o.set(_j, "funccoltypmods", _p?.funccoltypmods); _o.set(_j, "funccolcollations", _p?.funccolcollations); _o.set(_j, "funcparams", _p?.funcparams); - if (isNode) { - return { - RangeTblFunction: _j - }; - } return _j; }, - tableSampleClause(_p?: TableSampleClause, isNode?: boolean): TableSampleClause | { - TableSampleClause: TableSampleClause; - } { + tableSampleClause(_p?: TableSampleClause): TableSampleClause { const _j = {} as TableSampleClause; _o.set(_j, "tsmhandler", _p?.tsmhandler); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); - if (isNode) { - return { - TableSampleClause: _j - }; - } return _j; }, - withCheckOption(_p?: WithCheckOption, isNode?: boolean): WithCheckOption | { - WithCheckOption: WithCheckOption; - } { + withCheckOption(_p?: WithCheckOption): WithCheckOption { const _j = {} as WithCheckOption; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relname", _p?.relname); _o.set(_j, "polname", _p?.polname); _o.set(_j, "qual", _p?.qual); _o.set(_j, "cascaded", _p?.cascaded); - if (isNode) { - return { - WithCheckOption: _j - }; - } return _j; }, - sortGroupClause(_p?: SortGroupClause, isNode?: boolean): SortGroupClause | { - SortGroupClause: SortGroupClause; - } { + sortGroupClause(_p?: SortGroupClause): SortGroupClause { const _j = {} as SortGroupClause; _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); _o.set(_j, "eqop", _p?.eqop); _o.set(_j, "sortop", _p?.sortop); _o.set(_j, "nulls_first", _p?.nulls_first); _o.set(_j, "hashable", _p?.hashable); - if (isNode) { - return { - SortGroupClause: _j - }; - } return _j; }, - groupingSet(_p?: GroupingSet, isNode?: boolean): GroupingSet | { - GroupingSet: GroupingSet; - } { + groupingSet(_p?: GroupingSet): GroupingSet { const _j = {} as GroupingSet; _o.set(_j, "kind", _p?.kind); _o.set(_j, "content", _p?.content); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingSet: _j - }; - } return _j; }, - windowClause(_p?: WindowClause, isNode?: boolean): WindowClause | { - WindowClause: WindowClause; - } { + windowClause(_p?: WindowClause): WindowClause { const _j = {} as WindowClause; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -18699,91 +16170,49 @@ export default { _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); _o.set(_j, "winref", _p?.winref); _o.set(_j, "copiedOrder", _p?.copiedOrder); - if (isNode) { - return { - WindowClause: _j - }; - } return _j; }, - rowMarkClause(_p?: RowMarkClause, isNode?: boolean): RowMarkClause | { - RowMarkClause: RowMarkClause; - } { + rowMarkClause(_p?: RowMarkClause): RowMarkClause { const _j = {} as RowMarkClause; _o.set(_j, "rti", _p?.rti); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); _o.set(_j, "pushedDown", _p?.pushedDown); - if (isNode) { - return { - RowMarkClause: _j - }; - } return _j; }, - withClause(_p?: WithClause, isNode?: boolean): WithClause | { - WithClause: WithClause; - } { + withClause(_p?: WithClause): WithClause { const _j = {} as WithClause; _o.set(_j, "ctes", _p?.ctes); _o.set(_j, "recursive", _p?.recursive); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WithClause: _j - }; - } return _j; }, - inferClause(_p?: InferClause, isNode?: boolean): InferClause | { - InferClause: InferClause; - } { + inferClause(_p?: InferClause): InferClause { const _j = {} as InferClause; _o.set(_j, "indexElems", _p?.indexElems); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "conname", _p?.conname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - InferClause: _j - }; - } return _j; }, - onConflictClause(_p?: OnConflictClause, isNode?: boolean): OnConflictClause | { - OnConflictClause: OnConflictClause; - } { + onConflictClause(_p?: OnConflictClause): OnConflictClause { const _j = {} as OnConflictClause; _o.set(_j, "action", _p?.action); _o.set(_j, "infer", _p?.infer); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OnConflictClause: _j - }; - } return _j; }, - cteSearchClause(_p?: CTESearchClause, isNode?: boolean): CTESearchClause | { - CTESearchClause: CTESearchClause; - } { + cteSearchClause(_p?: CTESearchClause): CTESearchClause { const _j = {} as CTESearchClause; _o.set(_j, "search_col_list", _p?.search_col_list); _o.set(_j, "search_breadth_first", _p?.search_breadth_first); _o.set(_j, "search_seq_column", _p?.search_seq_column); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CTESearchClause: _j - }; - } return _j; }, - cteCycleClause(_p?: CTECycleClause, isNode?: boolean): CTECycleClause | { - CTECycleClause: CTECycleClause; - } { + cteCycleClause(_p?: CTECycleClause): CTECycleClause { const _j = {} as CTECycleClause; _o.set(_j, "cycle_col_list", _p?.cycle_col_list); _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); @@ -18795,16 +16224,9 @@ export default { _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); - if (isNode) { - return { - CTECycleClause: _j - }; - } return _j; }, - commonTableExpr(_p?: CommonTableExpr, isNode?: boolean): CommonTableExpr | { - CommonTableExpr: CommonTableExpr; - } { + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { const _j = {} as CommonTableExpr; _o.set(_j, "ctename", _p?.ctename); _o.set(_j, "aliascolnames", _p?.aliascolnames); @@ -18819,16 +16241,9 @@ export default { _o.set(_j, "ctecoltypes", _p?.ctecoltypes); _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); _o.set(_j, "ctecolcollations", _p?.ctecolcollations); - if (isNode) { - return { - CommonTableExpr: _j - }; - } return _j; }, - mergeWhenClause(_p?: MergeWhenClause, isNode?: boolean): MergeWhenClause | { - MergeWhenClause: MergeWhenClause; - } { + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { const _j = {} as MergeWhenClause; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -18836,16 +16251,9 @@ export default { _o.set(_j, "condition", _p?.condition); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "values", _p?.values); - if (isNode) { - return { - MergeWhenClause: _j - }; - } return _j; }, - mergeAction(_p?: MergeAction, isNode?: boolean): MergeAction | { - MergeAction: MergeAction; - } { + mergeAction(_p?: MergeAction): MergeAction { const _j = {} as MergeAction; _o.set(_j, "matched", _p?.matched); _o.set(_j, "commandType", _p?.commandType); @@ -18853,162 +16261,85 @@ export default { _o.set(_j, "qual", _p?.qual); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "updateColnos", _p?.updateColnos); - if (isNode) { - return { - MergeAction: _j - }; - } return _j; }, - triggerTransition(_p?: TriggerTransition, isNode?: boolean): TriggerTransition | { - TriggerTransition: TriggerTransition; - } { + triggerTransition(_p?: TriggerTransition): TriggerTransition { const _j = {} as TriggerTransition; _o.set(_j, "name", _p?.name); _o.set(_j, "isNew", _p?.isNew); _o.set(_j, "isTable", _p?.isTable); - if (isNode) { - return { - TriggerTransition: _j - }; - } return _j; }, - jsonOutput(_p?: JsonOutput, isNode?: boolean): JsonOutput | { - JsonOutput: JsonOutput; - } { + jsonOutput(_p?: JsonOutput): JsonOutput { const _j = {} as JsonOutput; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "returning", _p?.returning); - if (isNode) { - return { - JsonOutput: _j - }; - } return _j; }, - jsonKeyValue(_p?: JsonKeyValue, isNode?: boolean): JsonKeyValue | { - JsonKeyValue: JsonKeyValue; - } { + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { const _j = {} as JsonKeyValue; _o.set(_j, "key", _p?.key); _o.set(_j, "value", _p?.value); - if (isNode) { - return { - JsonKeyValue: _j - }; - } return _j; }, - jsonObjectConstructor(_p?: JsonObjectConstructor, isNode?: boolean): JsonObjectConstructor | { - JsonObjectConstructor: JsonObjectConstructor; - } { + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { const _j = {} as JsonObjectConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonObjectConstructor: _j - }; - } return _j; }, - jsonArrayConstructor(_p?: JsonArrayConstructor, isNode?: boolean): JsonArrayConstructor | { - JsonArrayConstructor: JsonArrayConstructor; - } { + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { const _j = {} as JsonArrayConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayConstructor: _j - }; - } return _j; }, - jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor, isNode?: boolean): JsonArrayQueryConstructor | { - JsonArrayQueryConstructor: JsonArrayQueryConstructor; - } { + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { const _j = {} as JsonArrayQueryConstructor; _o.set(_j, "query", _p?.query); _o.set(_j, "output", _p?.output); _o.set(_j, "format", _p?.format); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayQueryConstructor: _j - }; - } return _j; }, - jsonAggConstructor(_p?: JsonAggConstructor, isNode?: boolean): JsonAggConstructor | { - JsonAggConstructor: JsonAggConstructor; - } { + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { const _j = {} as JsonAggConstructor; _o.set(_j, "output", _p?.output); _o.set(_j, "agg_filter", _p?.agg_filter); _o.set(_j, "agg_order", _p?.agg_order); _o.set(_j, "over", _p?.over); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonAggConstructor: _j - }; - } return _j; }, - jsonObjectAgg(_p?: JsonObjectAgg, isNode?: boolean): JsonObjectAgg | { - JsonObjectAgg: JsonObjectAgg; - } { + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { const _j = {} as JsonObjectAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); - if (isNode) { - return { - JsonObjectAgg: _j - }; - } return _j; }, - jsonArrayAgg(_p?: JsonArrayAgg, isNode?: boolean): JsonArrayAgg | { - JsonArrayAgg: JsonArrayAgg; - } { + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { const _j = {} as JsonArrayAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); - if (isNode) { - return { - JsonArrayAgg: _j - }; - } return _j; }, - rawStmt(_p?: RawStmt, isNode?: boolean): RawStmt | { - RawStmt: RawStmt; - } { + rawStmt(_p?: RawStmt): RawStmt { const _j = {} as RawStmt; _o.set(_j, "stmt", _p?.stmt); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - RawStmt: _j - }; - } return _j; }, - insertStmt(_p?: InsertStmt, isNode?: boolean): InsertStmt | { - InsertStmt: InsertStmt; - } { + insertStmt(_p?: InsertStmt): InsertStmt { const _j = {} as InsertStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cols", _p?.cols); @@ -19017,32 +16348,18 @@ export default { _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); _o.set(_j, "override", _p?.override); - if (isNode) { - return { - InsertStmt: _j - }; - } return _j; }, - deleteStmt(_p?: DeleteStmt, isNode?: boolean): DeleteStmt | { - DeleteStmt: DeleteStmt; - } { + deleteStmt(_p?: DeleteStmt): DeleteStmt { const _j = {} as DeleteStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "usingClause", _p?.usingClause); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - DeleteStmt: _j - }; - } return _j; }, - updateStmt(_p?: UpdateStmt, isNode?: boolean): UpdateStmt | { - UpdateStmt: UpdateStmt; - } { + updateStmt(_p?: UpdateStmt): UpdateStmt { const _j = {} as UpdateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "targetList", _p?.targetList); @@ -19050,32 +16367,18 @@ export default { _o.set(_j, "fromClause", _p?.fromClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - UpdateStmt: _j - }; - } return _j; }, - mergeStmt(_p?: MergeStmt, isNode?: boolean): MergeStmt | { - MergeStmt: MergeStmt; - } { + mergeStmt(_p?: MergeStmt): MergeStmt { const _j = {} as MergeStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "sourceRelation", _p?.sourceRelation); _o.set(_j, "joinCondition", _p?.joinCondition); _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - MergeStmt: _j - }; - } return _j; }, - selectStmt(_p?: SelectStmt, isNode?: boolean): SelectStmt | { - SelectStmt: SelectStmt; - } { + selectStmt(_p?: SelectStmt): SelectStmt { const _j = {} as SelectStmt; _o.set(_j, "distinctClause", _p?.distinctClause); _o.set(_j, "intoClause", _p?.intoClause); @@ -19097,16 +16400,9 @@ export default { _o.set(_j, "all", _p?.all); _o.set(_j, "larg", _p?.larg); _o.set(_j, "rarg", _p?.rarg); - if (isNode) { - return { - SelectStmt: _j - }; - } return _j; }, - setOperationStmt(_p?: SetOperationStmt, isNode?: boolean): SetOperationStmt | { - SetOperationStmt: SetOperationStmt; - } { + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { const _j = {} as SetOperationStmt; _o.set(_j, "op", _p?.op); _o.set(_j, "all", _p?.all); @@ -19116,87 +16412,45 @@ export default { _o.set(_j, "colTypmods", _p?.colTypmods); _o.set(_j, "colCollations", _p?.colCollations); _o.set(_j, "groupClauses", _p?.groupClauses); - if (isNode) { - return { - SetOperationStmt: _j - }; - } return _j; }, - returnStmt(_p?: ReturnStmt, isNode?: boolean): ReturnStmt | { - ReturnStmt: ReturnStmt; - } { + returnStmt(_p?: ReturnStmt): ReturnStmt { const _j = {} as ReturnStmt; _o.set(_j, "returnval", _p?.returnval); - if (isNode) { - return { - ReturnStmt: _j - }; - } return _j; }, - plAssignStmt(_p?: PLAssignStmt, isNode?: boolean): PLAssignStmt | { - PLAssignStmt: PLAssignStmt; - } { + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { const _j = {} as PLAssignStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "nnames", _p?.nnames); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PLAssignStmt: _j - }; - } return _j; }, - createSchemaStmt(_p?: CreateSchemaStmt, isNode?: boolean): CreateSchemaStmt | { - CreateSchemaStmt: CreateSchemaStmt; - } { + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { const _j = {} as CreateSchemaStmt; _o.set(_j, "schemaname", _p?.schemaname); _o.set(_j, "authrole", _p?.authrole); _o.set(_j, "schemaElts", _p?.schemaElts); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSchemaStmt: _j - }; - } return _j; }, - alterTableStmt(_p?: AlterTableStmt, isNode?: boolean): AlterTableStmt | { - AlterTableStmt: AlterTableStmt; - } { + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { const _j = {} as AlterTableStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cmds", _p?.cmds); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTableStmt: _j - }; - } return _j; }, - replicaIdentityStmt(_p?: ReplicaIdentityStmt, isNode?: boolean): ReplicaIdentityStmt | { - ReplicaIdentityStmt: ReplicaIdentityStmt; - } { + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { const _j = {} as ReplicaIdentityStmt; _o.set(_j, "identity_type", _p?.identity_type); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - ReplicaIdentityStmt: _j - }; - } return _j; }, - alterTableCmd(_p?: AlterTableCmd, isNode?: boolean): AlterTableCmd | { - AlterTableCmd: AlterTableCmd; - } { + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { const _j = {} as AlterTableCmd; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "name", _p?.name); @@ -19206,28 +16460,14 @@ export default { _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "recurse", _p?.recurse); - if (isNode) { - return { - AlterTableCmd: _j - }; - } return _j; }, - alterCollationStmt(_p?: AlterCollationStmt, isNode?: boolean): AlterCollationStmt | { - AlterCollationStmt: AlterCollationStmt; - } { + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { const _j = {} as AlterCollationStmt; _o.set(_j, "collname", _p?.collname); - if (isNode) { - return { - AlterCollationStmt: _j - }; - } return _j; }, - alterDomainStmt(_p?: AlterDomainStmt, isNode?: boolean): AlterDomainStmt | { - AlterDomainStmt: AlterDomainStmt; - } { + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { const _j = {} as AlterDomainStmt; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "typeName", _p?.typeName); @@ -19235,16 +16475,9 @@ export default { _o.set(_j, "def", _p?.def); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterDomainStmt: _j - }; - } return _j; }, - grantStmt(_p?: GrantStmt, isNode?: boolean): GrantStmt | { - GrantStmt: GrantStmt; - } { + grantStmt(_p?: GrantStmt): GrantStmt { const _j = {} as GrantStmt; _o.set(_j, "is_grant", _p?.is_grant); _o.set(_j, "targtype", _p?.targtype); @@ -19255,44 +16488,23 @@ export default { _o.set(_j, "grant_option", _p?.grant_option); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantStmt: _j - }; - } return _j; }, - objectWithArgs(_p?: ObjectWithArgs, isNode?: boolean): ObjectWithArgs | { - ObjectWithArgs: ObjectWithArgs; - } { + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { const _j = {} as ObjectWithArgs; _o.set(_j, "objname", _p?.objname); _o.set(_j, "objargs", _p?.objargs); _o.set(_j, "objfuncargs", _p?.objfuncargs); _o.set(_j, "args_unspecified", _p?.args_unspecified); - if (isNode) { - return { - ObjectWithArgs: _j - }; - } return _j; }, - accessPriv(_p?: AccessPriv, isNode?: boolean): AccessPriv | { - AccessPriv: AccessPriv; - } { + accessPriv(_p?: AccessPriv): AccessPriv { const _j = {} as AccessPriv; _o.set(_j, "priv_name", _p?.priv_name); _o.set(_j, "cols", _p?.cols); - if (isNode) { - return { - AccessPriv: _j - }; - } return _j; }, - grantRoleStmt(_p?: GrantRoleStmt, isNode?: boolean): GrantRoleStmt | { - GrantRoleStmt: GrantRoleStmt; - } { + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { const _j = {} as GrantRoleStmt; _o.set(_j, "granted_roles", _p?.granted_roles); _o.set(_j, "grantee_roles", _p?.grantee_roles); @@ -19300,29 +16512,15 @@ export default { _o.set(_j, "opt", _p?.opt); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantRoleStmt: _j - }; - } return _j; }, - alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt, isNode?: boolean): AlterDefaultPrivilegesStmt | { - AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; - } { + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { const _j = {} as AlterDefaultPrivilegesStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterDefaultPrivilegesStmt: _j - }; - } return _j; }, - copyStmt(_p?: CopyStmt, isNode?: boolean): CopyStmt | { - CopyStmt: CopyStmt; - } { + copyStmt(_p?: CopyStmt): CopyStmt { const _j = {} as CopyStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "query", _p?.query); @@ -19332,43 +16530,22 @@ export default { _o.set(_j, "filename", _p?.filename); _o.set(_j, "options", _p?.options); _o.set(_j, "whereClause", _p?.whereClause); - if (isNode) { - return { - CopyStmt: _j - }; - } return _j; }, - variableSetStmt(_p?: VariableSetStmt, isNode?: boolean): VariableSetStmt | { - VariableSetStmt: VariableSetStmt; - } { + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { const _j = {} as VariableSetStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "args", _p?.args); _o.set(_j, "is_local", _p?.is_local); - if (isNode) { - return { - VariableSetStmt: _j - }; - } return _j; }, - variableShowStmt(_p?: VariableShowStmt, isNode?: boolean): VariableShowStmt | { - VariableShowStmt: VariableShowStmt; - } { + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { const _j = {} as VariableShowStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - VariableShowStmt: _j - }; - } return _j; }, - createStmt(_p?: CreateStmt, isNode?: boolean): CreateStmt | { - CreateStmt: CreateStmt; - } { + createStmt(_p?: CreateStmt): CreateStmt { const _j = {} as CreateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "tableElts", _p?.tableElts); @@ -19382,16 +16559,9 @@ export default { _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "accessMethod", _p?.accessMethod); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStmt: _j - }; - } return _j; }, - constraint(_p?: Constraint, isNode?: boolean): Constraint | { - Constraint: Constraint; - } { + constraint(_p?: Constraint): Constraint { const _j = {} as Constraint; _o.set(_j, "contype", _p?.contype); _o.set(_j, "conname", _p?.conname); @@ -19423,144 +16593,74 @@ export default { _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); _o.set(_j, "skip_validation", _p?.skip_validation); _o.set(_j, "initially_valid", _p?.initially_valid); - if (isNode) { - return { - Constraint: _j - }; - } return _j; }, - createTableSpaceStmt(_p?: CreateTableSpaceStmt, isNode?: boolean): CreateTableSpaceStmt | { - CreateTableSpaceStmt: CreateTableSpaceStmt; - } { + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { const _j = {} as CreateTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "owner", _p?.owner); _o.set(_j, "location", _p?.location); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateTableSpaceStmt: _j - }; - } return _j; }, - dropTableSpaceStmt(_p?: DropTableSpaceStmt, isNode?: boolean): DropTableSpaceStmt | { - DropTableSpaceStmt: DropTableSpaceStmt; - } { + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { const _j = {} as DropTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropTableSpaceStmt: _j - }; - } return _j; }, - alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt, isNode?: boolean): AlterTableSpaceOptionsStmt | { - AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; - } { + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { const _j = {} as AlterTableSpaceOptionsStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "options", _p?.options); _o.set(_j, "isReset", _p?.isReset); - if (isNode) { - return { - AlterTableSpaceOptionsStmt: _j - }; - } return _j; }, - alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt, isNode?: boolean): AlterTableMoveAllStmt | { - AlterTableMoveAllStmt: AlterTableMoveAllStmt; - } { + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { const _j = {} as AlterTableMoveAllStmt; _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "roles", _p?.roles); _o.set(_j, "new_tablespacename", _p?.new_tablespacename); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - AlterTableMoveAllStmt: _j - }; - } return _j; }, - createExtensionStmt(_p?: CreateExtensionStmt, isNode?: boolean): CreateExtensionStmt | { - CreateExtensionStmt: CreateExtensionStmt; - } { + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { const _j = {} as CreateExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateExtensionStmt: _j - }; - } return _j; }, - alterExtensionStmt(_p?: AlterExtensionStmt, isNode?: boolean): AlterExtensionStmt | { - AlterExtensionStmt: AlterExtensionStmt; - } { + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { const _j = {} as AlterExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterExtensionStmt: _j - }; - } return _j; }, - alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt, isNode?: boolean): AlterExtensionContentsStmt | { - AlterExtensionContentsStmt: AlterExtensionContentsStmt; - } { + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { const _j = {} as AlterExtensionContentsStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "action", _p?.action); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); - if (isNode) { - return { - AlterExtensionContentsStmt: _j - }; - } return _j; }, - createFdwStmt(_p?: CreateFdwStmt, isNode?: boolean): CreateFdwStmt | { - CreateFdwStmt: CreateFdwStmt; - } { + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { const _j = {} as CreateFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateFdwStmt: _j - }; - } return _j; }, - alterFdwStmt(_p?: AlterFdwStmt, isNode?: boolean): AlterFdwStmt | { - AlterFdwStmt: AlterFdwStmt; - } { + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { const _j = {} as AlterFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterFdwStmt: _j - }; - } return _j; }, - createForeignServerStmt(_p?: CreateForeignServerStmt, isNode?: boolean): CreateForeignServerStmt | { - CreateForeignServerStmt: CreateForeignServerStmt; - } { + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { const _j = {} as CreateForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "servertype", _p?.servertype); @@ -19568,88 +16668,46 @@ export default { _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignServerStmt: _j - }; - } return _j; }, - alterForeignServerStmt(_p?: AlterForeignServerStmt, isNode?: boolean): AlterForeignServerStmt | { - AlterForeignServerStmt: AlterForeignServerStmt; - } { + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { const _j = {} as AlterForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "version", _p?.version); _o.set(_j, "options", _p?.options); _o.set(_j, "has_version", _p?.has_version); - if (isNode) { - return { - AlterForeignServerStmt: _j - }; - } return _j; }, - createForeignTableStmt(_p?: CreateForeignTableStmt, isNode?: boolean): CreateForeignTableStmt | { - CreateForeignTableStmt: CreateForeignTableStmt; - } { + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { const _j = {} as CreateForeignTableStmt; _o.set(_j, "base", _p?.base); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignTableStmt: _j - }; - } return _j; }, - createUserMappingStmt(_p?: CreateUserMappingStmt, isNode?: boolean): CreateUserMappingStmt | { - CreateUserMappingStmt: CreateUserMappingStmt; - } { + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { const _j = {} as CreateUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateUserMappingStmt: _j - }; - } return _j; }, - alterUserMappingStmt(_p?: AlterUserMappingStmt, isNode?: boolean): AlterUserMappingStmt | { - AlterUserMappingStmt: AlterUserMappingStmt; - } { + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { const _j = {} as AlterUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterUserMappingStmt: _j - }; - } return _j; }, - dropUserMappingStmt(_p?: DropUserMappingStmt, isNode?: boolean): DropUserMappingStmt | { - DropUserMappingStmt: DropUserMappingStmt; - } { + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { const _j = {} as DropUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropUserMappingStmt: _j - }; - } return _j; }, - importForeignSchemaStmt(_p?: ImportForeignSchemaStmt, isNode?: boolean): ImportForeignSchemaStmt | { - ImportForeignSchemaStmt: ImportForeignSchemaStmt; - } { + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { const _j = {} as ImportForeignSchemaStmt; _o.set(_j, "server_name", _p?.server_name); _o.set(_j, "remote_schema", _p?.remote_schema); @@ -19657,16 +16715,9 @@ export default { _o.set(_j, "list_type", _p?.list_type); _o.set(_j, "table_list", _p?.table_list); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ImportForeignSchemaStmt: _j - }; - } return _j; }, - createPolicyStmt(_p?: CreatePolicyStmt, isNode?: boolean): CreatePolicyStmt | { - CreatePolicyStmt: CreatePolicyStmt; - } { + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { const _j = {} as CreatePolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); @@ -19675,46 +16726,25 @@ export default { _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - CreatePolicyStmt: _j - }; - } return _j; }, - alterPolicyStmt(_p?: AlterPolicyStmt, isNode?: boolean): AlterPolicyStmt | { - AlterPolicyStmt: AlterPolicyStmt; - } { + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { const _j = {} as AlterPolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - AlterPolicyStmt: _j - }; - } return _j; }, - createAmStmt(_p?: CreateAmStmt, isNode?: boolean): CreateAmStmt | { - CreateAmStmt: CreateAmStmt; - } { + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { const _j = {} as CreateAmStmt; _o.set(_j, "amname", _p?.amname); _o.set(_j, "handler_name", _p?.handler_name); _o.set(_j, "amtype", _p?.amtype); - if (isNode) { - return { - CreateAmStmt: _j - }; - } return _j; }, - createTrigStmt(_p?: CreateTrigStmt, isNode?: boolean): CreateTrigStmt | { - CreateTrigStmt: CreateTrigStmt; - } { + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { const _j = {} as CreateTrigStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "isconstraint", _p?.isconstraint); @@ -19731,44 +16761,23 @@ export default { _o.set(_j, "deferrable", _p?.deferrable); _o.set(_j, "initdeferred", _p?.initdeferred); _o.set(_j, "constrrel", _p?.constrrel); - if (isNode) { - return { - CreateTrigStmt: _j - }; - } return _j; }, - createEventTrigStmt(_p?: CreateEventTrigStmt, isNode?: boolean): CreateEventTrigStmt | { - CreateEventTrigStmt: CreateEventTrigStmt; - } { + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { const _j = {} as CreateEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "eventname", _p?.eventname); _o.set(_j, "whenclause", _p?.whenclause); _o.set(_j, "funcname", _p?.funcname); - if (isNode) { - return { - CreateEventTrigStmt: _j - }; - } return _j; }, - alterEventTrigStmt(_p?: AlterEventTrigStmt, isNode?: boolean): AlterEventTrigStmt | { - AlterEventTrigStmt: AlterEventTrigStmt; - } { + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { const _j = {} as AlterEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "tgenabled", _p?.tgenabled); - if (isNode) { - return { - AlterEventTrigStmt: _j - }; - } return _j; }, - createpLangStmt(_p?: CreatePLangStmt, isNode?: boolean): CreatePLangStmt | { - CreatePLangStmt: CreatePLangStmt; - } { + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { const _j = {} as CreatePLangStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "plname", _p?.plname); @@ -19776,102 +16785,53 @@ export default { _o.set(_j, "plinline", _p?.plinline); _o.set(_j, "plvalidator", _p?.plvalidator); _o.set(_j, "pltrusted", _p?.pltrusted); - if (isNode) { - return { - CreatePLangStmt: _j - }; - } return _j; }, - createRoleStmt(_p?: CreateRoleStmt, isNode?: boolean): CreateRoleStmt | { - CreateRoleStmt: CreateRoleStmt; - } { + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { const _j = {} as CreateRoleStmt; _o.set(_j, "stmt_type", _p?.stmt_type); _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateRoleStmt: _j - }; - } return _j; }, - alterRoleStmt(_p?: AlterRoleStmt, isNode?: boolean): AlterRoleStmt | { - AlterRoleStmt: AlterRoleStmt; - } { + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { const _j = {} as AlterRoleStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterRoleStmt: _j - }; - } return _j; }, - alterRoleSetStmt(_p?: AlterRoleSetStmt, isNode?: boolean): AlterRoleSetStmt | { - AlterRoleSetStmt: AlterRoleSetStmt; - } { + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { const _j = {} as AlterRoleSetStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "database", _p?.database); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterRoleSetStmt: _j - }; - } return _j; }, - dropRoleStmt(_p?: DropRoleStmt, isNode?: boolean): DropRoleStmt | { - DropRoleStmt: DropRoleStmt; - } { + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { const _j = {} as DropRoleStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropRoleStmt: _j - }; - } return _j; }, - createSeqStmt(_p?: CreateSeqStmt, isNode?: boolean): CreateSeqStmt | { - CreateSeqStmt: CreateSeqStmt; - } { + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { const _j = {} as CreateSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "ownerId", _p?.ownerId); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSeqStmt: _j - }; - } return _j; }, - alterSeqStmt(_p?: AlterSeqStmt, isNode?: boolean): AlterSeqStmt | { - AlterSeqStmt: AlterSeqStmt; - } { + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { const _j = {} as AlterSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterSeqStmt: _j - }; - } return _j; }, - defineStmt(_p?: DefineStmt, isNode?: boolean): DefineStmt | { - DefineStmt: DefineStmt; - } { + defineStmt(_p?: DefineStmt): DefineStmt { const _j = {} as DefineStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "oldstyle", _p?.oldstyle); @@ -19880,31 +16840,17 @@ export default { _o.set(_j, "definition", _p?.definition); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - DefineStmt: _j - }; - } return _j; }, - createDomainStmt(_p?: CreateDomainStmt, isNode?: boolean): CreateDomainStmt | { - CreateDomainStmt: CreateDomainStmt; - } { + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { const _j = {} as CreateDomainStmt; _o.set(_j, "domainname", _p?.domainname); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "collClause", _p?.collClause); _o.set(_j, "constraints", _p?.constraints); - if (isNode) { - return { - CreateDomainStmt: _j - }; - } return _j; }, - createOpClassStmt(_p?: CreateOpClassStmt, isNode?: boolean): CreateOpClassStmt | { - CreateOpClassStmt: CreateOpClassStmt; - } { + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { const _j = {} as CreateOpClassStmt; _o.set(_j, "opclassname", _p?.opclassname); _o.set(_j, "opfamilyname", _p?.opfamilyname); @@ -19912,16 +16858,9 @@ export default { _o.set(_j, "datatype", _p?.datatype); _o.set(_j, "items", _p?.items); _o.set(_j, "isDefault", _p?.isDefault); - if (isNode) { - return { - CreateOpClassStmt: _j - }; - } return _j; }, - createOpClassItem(_p?: CreateOpClassItem, isNode?: boolean): CreateOpClassItem | { - CreateOpClassItem: CreateOpClassItem; - } { + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { const _j = {} as CreateOpClassItem; _o.set(_j, "itemtype", _p?.itemtype); _o.set(_j, "name", _p?.name); @@ -19929,144 +16868,74 @@ export default { _o.set(_j, "order_family", _p?.order_family); _o.set(_j, "class_args", _p?.class_args); _o.set(_j, "storedtype", _p?.storedtype); - if (isNode) { - return { - CreateOpClassItem: _j - }; - } return _j; }, - createOpFamilyStmt(_p?: CreateOpFamilyStmt, isNode?: boolean): CreateOpFamilyStmt | { - CreateOpFamilyStmt: CreateOpFamilyStmt; - } { + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { const _j = {} as CreateOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); - if (isNode) { - return { - CreateOpFamilyStmt: _j - }; - } return _j; }, - alterOpFamilyStmt(_p?: AlterOpFamilyStmt, isNode?: boolean): AlterOpFamilyStmt | { - AlterOpFamilyStmt: AlterOpFamilyStmt; - } { + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { const _j = {} as AlterOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); _o.set(_j, "isDrop", _p?.isDrop); _o.set(_j, "items", _p?.items); - if (isNode) { - return { - AlterOpFamilyStmt: _j - }; - } return _j; }, - dropStmt(_p?: DropStmt, isNode?: boolean): DropStmt | { - DropStmt: DropStmt; - } { + dropStmt(_p?: DropStmt): DropStmt { const _j = {} as DropStmt; _o.set(_j, "objects", _p?.objects); _o.set(_j, "removeType", _p?.removeType); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - DropStmt: _j - }; - } return _j; }, - truncateStmt(_p?: TruncateStmt, isNode?: boolean): TruncateStmt | { - TruncateStmt: TruncateStmt; - } { + truncateStmt(_p?: TruncateStmt): TruncateStmt { const _j = {} as TruncateStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "restart_seqs", _p?.restart_seqs); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - TruncateStmt: _j - }; - } return _j; }, - commentStmt(_p?: CommentStmt, isNode?: boolean): CommentStmt | { - CommentStmt: CommentStmt; - } { + commentStmt(_p?: CommentStmt): CommentStmt { const _j = {} as CommentStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "comment", _p?.comment); - if (isNode) { - return { - CommentStmt: _j - }; - } return _j; }, - secLabelStmt(_p?: SecLabelStmt, isNode?: boolean): SecLabelStmt | { - SecLabelStmt: SecLabelStmt; - } { + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { const _j = {} as SecLabelStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "provider", _p?.provider); _o.set(_j, "label", _p?.label); - if (isNode) { - return { - SecLabelStmt: _j - }; - } return _j; }, - declareCursorStmt(_p?: DeclareCursorStmt, isNode?: boolean): DeclareCursorStmt | { - DeclareCursorStmt: DeclareCursorStmt; - } { + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { const _j = {} as DeclareCursorStmt; _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "options", _p?.options); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - DeclareCursorStmt: _j - }; - } return _j; }, - closePortalStmt(_p?: ClosePortalStmt, isNode?: boolean): ClosePortalStmt | { - ClosePortalStmt: ClosePortalStmt; - } { + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { const _j = {} as ClosePortalStmt; _o.set(_j, "portalname", _p?.portalname); - if (isNode) { - return { - ClosePortalStmt: _j - }; - } return _j; }, - fetchStmt(_p?: FetchStmt, isNode?: boolean): FetchStmt | { - FetchStmt: FetchStmt; - } { + fetchStmt(_p?: FetchStmt): FetchStmt { const _j = {} as FetchStmt; _o.set(_j, "direction", _p?.direction); _o.set(_j, "howMany", _p?.howMany); _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "ismove", _p?.ismove); - if (isNode) { - return { - FetchStmt: _j - }; - } return _j; }, - indexStmt(_p?: IndexStmt, isNode?: boolean): IndexStmt | { - IndexStmt: IndexStmt; - } { + indexStmt(_p?: IndexStmt): IndexStmt { const _j = {} as IndexStmt; _o.set(_j, "idxname", _p?.idxname); _o.set(_j, "relation", _p?.relation); @@ -20092,16 +16961,9 @@ export default { _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); - if (isNode) { - return { - IndexStmt: _j - }; - } return _j; }, - createStatsStmt(_p?: CreateStatsStmt, isNode?: boolean): CreateStatsStmt | { - CreateStatsStmt: CreateStatsStmt; - } { + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { const _j = {} as CreateStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stat_types", _p?.stat_types); @@ -20110,43 +16972,22 @@ export default { _o.set(_j, "stxcomment", _p?.stxcomment); _o.set(_j, "transformed", _p?.transformed); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStatsStmt: _j - }; - } return _j; }, - statsElem(_p?: StatsElem, isNode?: boolean): StatsElem | { - StatsElem: StatsElem; - } { + statsElem(_p?: StatsElem): StatsElem { const _j = {} as StatsElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); - if (isNode) { - return { - StatsElem: _j - }; - } return _j; }, - alterStatsStmt(_p?: AlterStatsStmt, isNode?: boolean): AlterStatsStmt | { - AlterStatsStmt: AlterStatsStmt; - } { + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { const _j = {} as AlterStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stxstattarget", _p?.stxstattarget); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterStatsStmt: _j - }; - } return _j; }, - createFunctionStmt(_p?: CreateFunctionStmt, isNode?: boolean): CreateFunctionStmt | { - CreateFunctionStmt: CreateFunctionStmt; - } { + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { const _j = {} as CreateFunctionStmt; _o.set(_j, "is_procedure", _p?.is_procedure); _o.set(_j, "replace", _p?.replace); @@ -20155,98 +16996,49 @@ export default { _o.set(_j, "returnType", _p?.returnType); _o.set(_j, "options", _p?.options); _o.set(_j, "sql_body", _p?.sql_body); - if (isNode) { - return { - CreateFunctionStmt: _j - }; - } return _j; }, - functionParameter(_p?: FunctionParameter, isNode?: boolean): FunctionParameter | { - FunctionParameter: FunctionParameter; - } { + functionParameter(_p?: FunctionParameter): FunctionParameter { const _j = {} as FunctionParameter; _o.set(_j, "name", _p?.name); _o.set(_j, "argType", _p?.argType); _o.set(_j, "mode", _p?.mode); _o.set(_j, "defexpr", _p?.defexpr); - if (isNode) { - return { - FunctionParameter: _j - }; - } return _j; }, - alterFunctionStmt(_p?: AlterFunctionStmt, isNode?: boolean): AlterFunctionStmt | { - AlterFunctionStmt: AlterFunctionStmt; - } { + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { const _j = {} as AlterFunctionStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "func", _p?.func); _o.set(_j, "actions", _p?.actions); - if (isNode) { - return { - AlterFunctionStmt: _j - }; - } return _j; }, - doStmt(_p?: DoStmt, isNode?: boolean): DoStmt | { - DoStmt: DoStmt; - } { + doStmt(_p?: DoStmt): DoStmt { const _j = {} as DoStmt; _o.set(_j, "args", _p?.args); - if (isNode) { - return { - DoStmt: _j - }; - } return _j; }, - inlineCodeBlock(_p?: InlineCodeBlock, isNode?: boolean): InlineCodeBlock | { - InlineCodeBlock: InlineCodeBlock; - } { + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { const _j = {} as InlineCodeBlock; _o.set(_j, "source_text", _p?.source_text); _o.set(_j, "langOid", _p?.langOid); _o.set(_j, "langIsTrusted", _p?.langIsTrusted); _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - InlineCodeBlock: _j - }; - } return _j; }, - callStmt(_p?: CallStmt, isNode?: boolean): CallStmt | { - CallStmt: CallStmt; - } { + callStmt(_p?: CallStmt): CallStmt { const _j = {} as CallStmt; _o.set(_j, "funccall", _p?.funccall); _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "outargs", _p?.outargs); - if (isNode) { - return { - CallStmt: _j - }; - } return _j; }, - callContext(_p?: CallContext, isNode?: boolean): CallContext | { - CallContext: CallContext; - } { + callContext(_p?: CallContext): CallContext { const _j = {} as CallContext; _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - CallContext: _j - }; - } return _j; }, - renameStmt(_p?: RenameStmt, isNode?: boolean): RenameStmt | { - RenameStmt: RenameStmt; - } { + renameStmt(_p?: RenameStmt): RenameStmt { const _j = {} as RenameStmt; _o.set(_j, "renameType", _p?.renameType); _o.set(_j, "relationType", _p?.relationType); @@ -20256,89 +17048,47 @@ export default { _o.set(_j, "newname", _p?.newname); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - RenameStmt: _j - }; - } return _j; }, - alterObjectDependsStmt(_p?: AlterObjectDependsStmt, isNode?: boolean): AlterObjectDependsStmt | { - AlterObjectDependsStmt: AlterObjectDependsStmt; - } { + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { const _j = {} as AlterObjectDependsStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "extname", _p?.extname); _o.set(_j, "remove", _p?.remove); - if (isNode) { - return { - AlterObjectDependsStmt: _j - }; - } return _j; }, - alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt, isNode?: boolean): AlterObjectSchemaStmt | { - AlterObjectSchemaStmt: AlterObjectSchemaStmt; - } { + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { const _j = {} as AlterObjectSchemaStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newschema", _p?.newschema); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterObjectSchemaStmt: _j - }; - } return _j; }, - alterOwnerStmt(_p?: AlterOwnerStmt, isNode?: boolean): AlterOwnerStmt | { - AlterOwnerStmt: AlterOwnerStmt; - } { + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { const _j = {} as AlterOwnerStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newowner", _p?.newowner); - if (isNode) { - return { - AlterOwnerStmt: _j - }; - } return _j; }, - alterOperatorStmt(_p?: AlterOperatorStmt, isNode?: boolean): AlterOperatorStmt | { - AlterOperatorStmt: AlterOperatorStmt; - } { + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { const _j = {} as AlterOperatorStmt; _o.set(_j, "opername", _p?.opername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterOperatorStmt: _j - }; - } return _j; }, - alterTypeStmt(_p?: AlterTypeStmt, isNode?: boolean): AlterTypeStmt | { - AlterTypeStmt: AlterTypeStmt; - } { + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { const _j = {} as AlterTypeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTypeStmt: _j - }; - } return _j; }, - ruleStmt(_p?: RuleStmt, isNode?: boolean): RuleStmt | { - RuleStmt: RuleStmt; - } { + ruleStmt(_p?: RuleStmt): RuleStmt { const _j = {} as RuleStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "rulename", _p?.rulename); @@ -20347,108 +17097,52 @@ export default { _o.set(_j, "instead", _p?.instead); _o.set(_j, "actions", _p?.actions); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - RuleStmt: _j - }; - } return _j; }, - notifyStmt(_p?: NotifyStmt, isNode?: boolean): NotifyStmt | { - NotifyStmt: NotifyStmt; - } { + notifyStmt(_p?: NotifyStmt): NotifyStmt { const _j = {} as NotifyStmt; _o.set(_j, "conditionname", _p?.conditionname); _o.set(_j, "payload", _p?.payload); - if (isNode) { - return { - NotifyStmt: _j - }; - } return _j; }, - listenStmt(_p?: ListenStmt, isNode?: boolean): ListenStmt | { - ListenStmt: ListenStmt; - } { + listenStmt(_p?: ListenStmt): ListenStmt { const _j = {} as ListenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - ListenStmt: _j - }; - } return _j; }, - unlistenStmt(_p?: UnlistenStmt, isNode?: boolean): UnlistenStmt | { - UnlistenStmt: UnlistenStmt; - } { + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { const _j = {} as UnlistenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - UnlistenStmt: _j - }; - } return _j; }, - transactionStmt(_p?: TransactionStmt, isNode?: boolean): TransactionStmt | { - TransactionStmt: TransactionStmt; - } { + transactionStmt(_p?: TransactionStmt): TransactionStmt { const _j = {} as TransactionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "options", _p?.options); _o.set(_j, "savepoint_name", _p?.savepoint_name); _o.set(_j, "gid", _p?.gid); _o.set(_j, "chain", _p?.chain); - if (isNode) { - return { - TransactionStmt: _j - }; - } return _j; }, - compositeTypeStmt(_p?: CompositeTypeStmt, isNode?: boolean): CompositeTypeStmt | { - CompositeTypeStmt: CompositeTypeStmt; - } { + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { const _j = {} as CompositeTypeStmt; _o.set(_j, "typevar", _p?.typevar); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - CompositeTypeStmt: _j - }; - } return _j; }, - createEnumStmt(_p?: CreateEnumStmt, isNode?: boolean): CreateEnumStmt | { - CreateEnumStmt: CreateEnumStmt; - } { + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { const _j = {} as CreateEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "vals", _p?.vals); - if (isNode) { - return { - CreateEnumStmt: _j - }; - } return _j; }, - createRangeStmt(_p?: CreateRangeStmt, isNode?: boolean): CreateRangeStmt | { - CreateRangeStmt: CreateRangeStmt; - } { + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { const _j = {} as CreateRangeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - CreateRangeStmt: _j - }; - } return _j; }, - alterEnumStmt(_p?: AlterEnumStmt, isNode?: boolean): AlterEnumStmt | { - AlterEnumStmt: AlterEnumStmt; - } { + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { const _j = {} as AlterEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "oldVal", _p?.oldVal); @@ -20456,16 +17150,9 @@ export default { _o.set(_j, "newValNeighbor", _p?.newValNeighbor); _o.set(_j, "newValIsAfter", _p?.newValIsAfter); _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); - if (isNode) { - return { - AlterEnumStmt: _j - }; - } return _j; }, - viewStmt(_p?: ViewStmt, isNode?: boolean): ViewStmt | { - ViewStmt: ViewStmt; - } { + viewStmt(_p?: ViewStmt): ViewStmt { const _j = {} as ViewStmt; _o.set(_j, "view", _p?.view); _o.set(_j, "aliases", _p?.aliases); @@ -20473,381 +17160,185 @@ export default { _o.set(_j, "replace", _p?.replace); _o.set(_j, "options", _p?.options); _o.set(_j, "withCheckOption", _p?.withCheckOption); - if (isNode) { - return { - ViewStmt: _j - }; - } return _j; }, - loadStmt(_p?: LoadStmt, isNode?: boolean): LoadStmt | { - LoadStmt: LoadStmt; - } { + loadStmt(_p?: LoadStmt): LoadStmt { const _j = {} as LoadStmt; _o.set(_j, "filename", _p?.filename); - if (isNode) { - return { - LoadStmt: _j - }; - } return _j; }, - createdbStmt(_p?: CreatedbStmt, isNode?: boolean): CreatedbStmt | { - CreatedbStmt: CreatedbStmt; - } { + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { const _j = {} as CreatedbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreatedbStmt: _j - }; - } return _j; }, - alterDatabaseStmt(_p?: AlterDatabaseStmt, isNode?: boolean): AlterDatabaseStmt | { - AlterDatabaseStmt: AlterDatabaseStmt; - } { + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { const _j = {} as AlterDatabaseStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterDatabaseStmt: _j - }; - } return _j; }, - alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt, isNode?: boolean): AlterDatabaseRefreshCollStmt | { - AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; - } { + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { const _j = {} as AlterDatabaseRefreshCollStmt; _o.set(_j, "dbname", _p?.dbname); - if (isNode) { - return { - AlterDatabaseRefreshCollStmt: _j - }; - } return _j; }, - alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt, isNode?: boolean): AlterDatabaseSetStmt | { - AlterDatabaseSetStmt: AlterDatabaseSetStmt; - } { + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { const _j = {} as AlterDatabaseSetStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterDatabaseSetStmt: _j - }; - } return _j; }, - dropdbStmt(_p?: DropdbStmt, isNode?: boolean): DropdbStmt | { - DropdbStmt: DropdbStmt; - } { + dropdbStmt(_p?: DropdbStmt): DropdbStmt { const _j = {} as DropdbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - DropdbStmt: _j - }; - } return _j; }, - alterSystemStmt(_p?: AlterSystemStmt, isNode?: boolean): AlterSystemStmt | { - AlterSystemStmt: AlterSystemStmt; - } { + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { const _j = {} as AlterSystemStmt; _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterSystemStmt: _j - }; - } return _j; }, - clusterStmt(_p?: ClusterStmt, isNode?: boolean): ClusterStmt | { - ClusterStmt: ClusterStmt; - } { + clusterStmt(_p?: ClusterStmt): ClusterStmt { const _j = {} as ClusterStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "indexname", _p?.indexname); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ClusterStmt: _j - }; - } return _j; }, - vacuumStmt(_p?: VacuumStmt, isNode?: boolean): VacuumStmt | { - VacuumStmt: VacuumStmt; - } { + vacuumStmt(_p?: VacuumStmt): VacuumStmt { const _j = {} as VacuumStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "rels", _p?.rels); _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); - if (isNode) { - return { - VacuumStmt: _j - }; - } return _j; }, - vacuumRelation(_p?: VacuumRelation, isNode?: boolean): VacuumRelation | { - VacuumRelation: VacuumRelation; - } { + vacuumRelation(_p?: VacuumRelation): VacuumRelation { const _j = {} as VacuumRelation; _o.set(_j, "relation", _p?.relation); _o.set(_j, "oid", _p?.oid); _o.set(_j, "va_cols", _p?.va_cols); - if (isNode) { - return { - VacuumRelation: _j - }; - } return _j; }, - explainStmt(_p?: ExplainStmt, isNode?: boolean): ExplainStmt | { - ExplainStmt: ExplainStmt; - } { + explainStmt(_p?: ExplainStmt): ExplainStmt { const _j = {} as ExplainStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ExplainStmt: _j - }; - } return _j; }, - createTableAsStmt(_p?: CreateTableAsStmt, isNode?: boolean): CreateTableAsStmt | { - CreateTableAsStmt: CreateTableAsStmt; - } { + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { const _j = {} as CreateTableAsStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "into", _p?.into); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "is_select_into", _p?.is_select_into); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateTableAsStmt: _j - }; - } return _j; }, - refreshMatViewStmt(_p?: RefreshMatViewStmt, isNode?: boolean): RefreshMatViewStmt | { - RefreshMatViewStmt: RefreshMatViewStmt; - } { + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { const _j = {} as RefreshMatViewStmt; _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "skipData", _p?.skipData); _o.set(_j, "relation", _p?.relation); - if (isNode) { - return { - RefreshMatViewStmt: _j - }; - } return _j; }, - checkPointStmt(_p?: CheckPointStmt, isNode?: boolean): CheckPointStmt | { - CheckPointStmt: CheckPointStmt; - } { + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { const _j = {} as CheckPointStmt; - if (isNode) { - return { - CheckPointStmt: _j - }; - } return _j; }, - discardStmt(_p?: DiscardStmt, isNode?: boolean): DiscardStmt | { - DiscardStmt: DiscardStmt; - } { + discardStmt(_p?: DiscardStmt): DiscardStmt { const _j = {} as DiscardStmt; _o.set(_j, "target", _p?.target); - if (isNode) { - return { - DiscardStmt: _j - }; - } return _j; }, - lockStmt(_p?: LockStmt, isNode?: boolean): LockStmt | { - LockStmt: LockStmt; - } { + lockStmt(_p?: LockStmt): LockStmt { const _j = {} as LockStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "mode", _p?.mode); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - LockStmt: _j - }; - } return _j; }, - constraintsSetStmt(_p?: ConstraintsSetStmt, isNode?: boolean): ConstraintsSetStmt | { - ConstraintsSetStmt: ConstraintsSetStmt; - } { + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { const _j = {} as ConstraintsSetStmt; _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "deferred", _p?.deferred); - if (isNode) { - return { - ConstraintsSetStmt: _j - }; - } return _j; }, - reindexStmt(_p?: ReindexStmt, isNode?: boolean): ReindexStmt | { - ReindexStmt: ReindexStmt; - } { + reindexStmt(_p?: ReindexStmt): ReindexStmt { const _j = {} as ReindexStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relation", _p?.relation); _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ReindexStmt: _j - }; - } return _j; }, - createConversionStmt(_p?: CreateConversionStmt, isNode?: boolean): CreateConversionStmt | { - CreateConversionStmt: CreateConversionStmt; - } { + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { const _j = {} as CreateConversionStmt; _o.set(_j, "conversion_name", _p?.conversion_name); _o.set(_j, "for_encoding_name", _p?.for_encoding_name); _o.set(_j, "to_encoding_name", _p?.to_encoding_name); _o.set(_j, "func_name", _p?.func_name); _o.set(_j, "def", _p?.def); - if (isNode) { - return { - CreateConversionStmt: _j - }; - } return _j; }, - createCastStmt(_p?: CreateCastStmt, isNode?: boolean): CreateCastStmt | { - CreateCastStmt: CreateCastStmt; - } { + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { const _j = {} as CreateCastStmt; _o.set(_j, "sourcetype", _p?.sourcetype); _o.set(_j, "targettype", _p?.targettype); _o.set(_j, "func", _p?.func); _o.set(_j, "context", _p?.context); _o.set(_j, "inout", _p?.inout); - if (isNode) { - return { - CreateCastStmt: _j - }; - } return _j; }, - createTransformStmt(_p?: CreateTransformStmt, isNode?: boolean): CreateTransformStmt | { - CreateTransformStmt: CreateTransformStmt; - } { + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { const _j = {} as CreateTransformStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "type_name", _p?.type_name); _o.set(_j, "lang", _p?.lang); _o.set(_j, "fromsql", _p?.fromsql); _o.set(_j, "tosql", _p?.tosql); - if (isNode) { - return { - CreateTransformStmt: _j - }; - } return _j; }, - prepareStmt(_p?: PrepareStmt, isNode?: boolean): PrepareStmt | { - PrepareStmt: PrepareStmt; - } { + prepareStmt(_p?: PrepareStmt): PrepareStmt { const _j = {} as PrepareStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "argtypes", _p?.argtypes); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - PrepareStmt: _j - }; - } return _j; }, - executeStmt(_p?: ExecuteStmt, isNode?: boolean): ExecuteStmt | { - ExecuteStmt: ExecuteStmt; - } { + executeStmt(_p?: ExecuteStmt): ExecuteStmt { const _j = {} as ExecuteStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ExecuteStmt: _j - }; - } return _j; }, - deallocateStmt(_p?: DeallocateStmt, isNode?: boolean): DeallocateStmt | { - DeallocateStmt: DeallocateStmt; - } { + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { const _j = {} as DeallocateStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - DeallocateStmt: _j - }; - } return _j; }, - dropOwnedStmt(_p?: DropOwnedStmt, isNode?: boolean): DropOwnedStmt | { - DropOwnedStmt: DropOwnedStmt; - } { + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { const _j = {} as DropOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropOwnedStmt: _j - }; - } return _j; }, - reassignOwnedStmt(_p?: ReassignOwnedStmt, isNode?: boolean): ReassignOwnedStmt | { - ReassignOwnedStmt: ReassignOwnedStmt; - } { + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { const _j = {} as ReassignOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "newrole", _p?.newrole); - if (isNode) { - return { - ReassignOwnedStmt: _j - }; - } return _j; }, - altertsDictionaryStmt(_p?: AlterTSDictionaryStmt, isNode?: boolean): AlterTSDictionaryStmt | { - AlterTSDictionaryStmt: AlterTSDictionaryStmt; - } { + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { const _j = {} as AlterTSDictionaryStmt; _o.set(_j, "dictname", _p?.dictname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTSDictionaryStmt: _j - }; - } return _j; }, - altertsConfigurationStmt(_p?: AlterTSConfigurationStmt, isNode?: boolean): AlterTSConfigurationStmt | { - AlterTSConfigurationStmt: AlterTSConfigurationStmt; - } { + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { const _j = {} as AlterTSConfigurationStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "cfgname", _p?.cfgname); @@ -20856,131 +17347,70 @@ export default { _o.set(_j, "override", _p?.override); _o.set(_j, "replace", _p?.replace); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTSConfigurationStmt: _j - }; - } return _j; }, - publicationTable(_p?: PublicationTable, isNode?: boolean): PublicationTable | { - PublicationTable: PublicationTable; - } { + publicationTable(_p?: PublicationTable): PublicationTable { const _j = {} as PublicationTable; _o.set(_j, "relation", _p?.relation); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "columns", _p?.columns); - if (isNode) { - return { - PublicationTable: _j - }; - } return _j; }, - publicationObjSpec(_p?: PublicationObjSpec, isNode?: boolean): PublicationObjSpec | { - PublicationObjSpec: PublicationObjSpec; - } { + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { const _j = {} as PublicationObjSpec; _o.set(_j, "pubobjtype", _p?.pubobjtype); _o.set(_j, "name", _p?.name); _o.set(_j, "pubtable", _p?.pubtable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PublicationObjSpec: _j - }; - } return _j; }, - createPublicationStmt(_p?: CreatePublicationStmt, isNode?: boolean): CreatePublicationStmt | { - CreatePublicationStmt: CreatePublicationStmt; - } { + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { const _j = {} as CreatePublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); - if (isNode) { - return { - CreatePublicationStmt: _j - }; - } return _j; }, - alterPublicationStmt(_p?: AlterPublicationStmt, isNode?: boolean): AlterPublicationStmt | { - AlterPublicationStmt: AlterPublicationStmt; - } { + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { const _j = {} as AlterPublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterPublicationStmt: _j - }; - } return _j; }, - createSubscriptionStmt(_p?: CreateSubscriptionStmt, isNode?: boolean): CreateSubscriptionStmt | { - CreateSubscriptionStmt: CreateSubscriptionStmt; - } { + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { const _j = {} as CreateSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateSubscriptionStmt: _j - }; - } return _j; }, - alterSubscriptionStmt(_p?: AlterSubscriptionStmt, isNode?: boolean): AlterSubscriptionStmt | { - AlterSubscriptionStmt: AlterSubscriptionStmt; - } { + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { const _j = {} as AlterSubscriptionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterSubscriptionStmt: _j - }; - } return _j; }, - dropSubscriptionStmt(_p?: DropSubscriptionStmt, isNode?: boolean): DropSubscriptionStmt | { - DropSubscriptionStmt: DropSubscriptionStmt; - } { + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { const _j = {} as DropSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropSubscriptionStmt: _j - }; - } return _j; }, - scanToken(_p?: ScanToken, isNode?: boolean): ScanToken | { - ScanToken: ScanToken; - } { + scanToken(_p?: ScanToken): ScanToken { const _j = {} as ScanToken; _o.set(_j, "start", _p?.start); _o.set(_j, "end", _p?.end); _o.set(_j, "token", _p?.token); _o.set(_j, "keywordKind", _p?.keywordKind); - if (isNode) { - return { - ScanToken: _j - }; - } return _j; } };", @@ -20988,3 +17418,13710 @@ export default { }, ] `; + +exports[`utils both astHelpers and wrappedAstHelpers enabled 1`] = ` +[ + { + "code": "/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +};", + "file": "wrapped-asts.ts", + }, + { + "code": "/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +export type Node = { + ParseResult: ParseResult; +} | { + ScanResult: ScanResult; +} | { + Integer: Integer; +} | { + Float: Float; +} | { + Boolean: Boolean; +} | { + String: String; +} | { + BitString: BitString; +} | { + List: List; +} | { + OidList: OidList; +} | { + IntList: IntList; +} | { + A_Const: A_Const; +} | { + Alias: Alias; +} | { + RangeVar: RangeVar; +} | { + TableFunc: TableFunc; +} | { + IntoClause: IntoClause; +} | { + Var: Var; +} | { + Param: Param; +} | { + Aggref: Aggref; +} | { + GroupingFunc: GroupingFunc; +} | { + WindowFunc: WindowFunc; +} | { + SubscriptingRef: SubscriptingRef; +} | { + FuncExpr: FuncExpr; +} | { + NamedArgExpr: NamedArgExpr; +} | { + OpExpr: OpExpr; +} | { + DistinctExpr: DistinctExpr; +} | { + NullIfExpr: NullIfExpr; +} | { + ScalarArrayOpExpr: ScalarArrayOpExpr; +} | { + BoolExpr: BoolExpr; +} | { + SubLink: SubLink; +} | { + SubPlan: SubPlan; +} | { + AlternativeSubPlan: AlternativeSubPlan; +} | { + FieldSelect: FieldSelect; +} | { + FieldStore: FieldStore; +} | { + RelabelType: RelabelType; +} | { + CoerceViaIO: CoerceViaIO; +} | { + ArrayCoerceExpr: ArrayCoerceExpr; +} | { + ConvertRowtypeExpr: ConvertRowtypeExpr; +} | { + CollateExpr: CollateExpr; +} | { + CaseExpr: CaseExpr; +} | { + CaseWhen: CaseWhen; +} | { + CaseTestExpr: CaseTestExpr; +} | { + ArrayExpr: ArrayExpr; +} | { + RowExpr: RowExpr; +} | { + RowCompareExpr: RowCompareExpr; +} | { + CoalesceExpr: CoalesceExpr; +} | { + MinMaxExpr: MinMaxExpr; +} | { + SQLValueFunction: SQLValueFunction; +} | { + XmlExpr: XmlExpr; +} | { + JsonFormat: JsonFormat; +} | { + JsonReturning: JsonReturning; +} | { + JsonValueExpr: JsonValueExpr; +} | { + JsonConstructorExpr: JsonConstructorExpr; +} | { + JsonIsPredicate: JsonIsPredicate; +} | { + NullTest: NullTest; +} | { + BooleanTest: BooleanTest; +} | { + CoerceToDomain: CoerceToDomain; +} | { + CoerceToDomainValue: CoerceToDomainValue; +} | { + SetToDefault: SetToDefault; +} | { + CurrentOfExpr: CurrentOfExpr; +} | { + NextValueExpr: NextValueExpr; +} | { + InferenceElem: InferenceElem; +} | { + TargetEntry: TargetEntry; +} | { + RangeTblRef: RangeTblRef; +} | { + JoinExpr: JoinExpr; +} | { + FromExpr: FromExpr; +} | { + OnConflictExpr: OnConflictExpr; +} | { + Query: Query; +} | { + TypeName: TypeName; +} | { + ColumnRef: ColumnRef; +} | { + ParamRef: ParamRef; +} | { + A_Expr: A_Expr; +} | { + TypeCast: TypeCast; +} | { + CollateClause: CollateClause; +} | { + RoleSpec: RoleSpec; +} | { + FuncCall: FuncCall; +} | { + A_Star: A_Star; +} | { + A_Indices: A_Indices; +} | { + A_Indirection: A_Indirection; +} | { + A_ArrayExpr: A_ArrayExpr; +} | { + ResTarget: ResTarget; +} | { + MultiAssignRef: MultiAssignRef; +} | { + SortBy: SortBy; +} | { + WindowDef: WindowDef; +} | { + RangeSubselect: RangeSubselect; +} | { + RangeFunction: RangeFunction; +} | { + RangeTableFunc: RangeTableFunc; +} | { + RangeTableFuncCol: RangeTableFuncCol; +} | { + RangeTableSample: RangeTableSample; +} | { + ColumnDef: ColumnDef; +} | { + TableLikeClause: TableLikeClause; +} | { + IndexElem: IndexElem; +} | { + DefElem: DefElem; +} | { + LockingClause: LockingClause; +} | { + XmlSerialize: XmlSerialize; +} | { + PartitionElem: PartitionElem; +} | { + PartitionSpec: PartitionSpec; +} | { + PartitionBoundSpec: PartitionBoundSpec; +} | { + PartitionRangeDatum: PartitionRangeDatum; +} | { + PartitionCmd: PartitionCmd; +} | { + RangeTblEntry: RangeTblEntry; +} | { + RTEPermissionInfo: RTEPermissionInfo; +} | { + RangeTblFunction: RangeTblFunction; +} | { + TableSampleClause: TableSampleClause; +} | { + WithCheckOption: WithCheckOption; +} | { + SortGroupClause: SortGroupClause; +} | { + GroupingSet: GroupingSet; +} | { + WindowClause: WindowClause; +} | { + RowMarkClause: RowMarkClause; +} | { + WithClause: WithClause; +} | { + InferClause: InferClause; +} | { + OnConflictClause: OnConflictClause; +} | { + CTESearchClause: CTESearchClause; +} | { + CTECycleClause: CTECycleClause; +} | { + CommonTableExpr: CommonTableExpr; +} | { + MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; +} | { + TriggerTransition: TriggerTransition; +} | { + JsonOutput: JsonOutput; +} | { + JsonKeyValue: JsonKeyValue; +} | { + JsonObjectConstructor: JsonObjectConstructor; +} | { + JsonArrayConstructor: JsonArrayConstructor; +} | { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; +} | { + JsonAggConstructor: JsonAggConstructor; +} | { + JsonObjectAgg: JsonObjectAgg; +} | { + JsonArrayAgg: JsonArrayAgg; +} | { + RawStmt: RawStmt; +} | { + InsertStmt: InsertStmt; +} | { + DeleteStmt: DeleteStmt; +} | { + UpdateStmt: UpdateStmt; +} | { + MergeStmt: MergeStmt; +} | { + SelectStmt: SelectStmt; +} | { + SetOperationStmt: SetOperationStmt; +} | { + ReturnStmt: ReturnStmt; +} | { + PLAssignStmt: PLAssignStmt; +} | { + CreateSchemaStmt: CreateSchemaStmt; +} | { + AlterTableStmt: AlterTableStmt; +} | { + ReplicaIdentityStmt: ReplicaIdentityStmt; +} | { + AlterTableCmd: AlterTableCmd; +} | { + AlterCollationStmt: AlterCollationStmt; +} | { + AlterDomainStmt: AlterDomainStmt; +} | { + GrantStmt: GrantStmt; +} | { + ObjectWithArgs: ObjectWithArgs; +} | { + AccessPriv: AccessPriv; +} | { + GrantRoleStmt: GrantRoleStmt; +} | { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; +} | { + CopyStmt: CopyStmt; +} | { + VariableSetStmt: VariableSetStmt; +} | { + VariableShowStmt: VariableShowStmt; +} | { + CreateStmt: CreateStmt; +} | { + Constraint: Constraint; +} | { + CreateTableSpaceStmt: CreateTableSpaceStmt; +} | { + DropTableSpaceStmt: DropTableSpaceStmt; +} | { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; +} | { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; +} | { + CreateExtensionStmt: CreateExtensionStmt; +} | { + AlterExtensionStmt: AlterExtensionStmt; +} | { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; +} | { + CreateFdwStmt: CreateFdwStmt; +} | { + AlterFdwStmt: AlterFdwStmt; +} | { + CreateForeignServerStmt: CreateForeignServerStmt; +} | { + AlterForeignServerStmt: AlterForeignServerStmt; +} | { + CreateForeignTableStmt: CreateForeignTableStmt; +} | { + CreateUserMappingStmt: CreateUserMappingStmt; +} | { + AlterUserMappingStmt: AlterUserMappingStmt; +} | { + DropUserMappingStmt: DropUserMappingStmt; +} | { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; +} | { + CreatePolicyStmt: CreatePolicyStmt; +} | { + AlterPolicyStmt: AlterPolicyStmt; +} | { + CreateAmStmt: CreateAmStmt; +} | { + CreateTrigStmt: CreateTrigStmt; +} | { + CreateEventTrigStmt: CreateEventTrigStmt; +} | { + AlterEventTrigStmt: AlterEventTrigStmt; +} | { + CreatePLangStmt: CreatePLangStmt; +} | { + CreateRoleStmt: CreateRoleStmt; +} | { + AlterRoleStmt: AlterRoleStmt; +} | { + AlterRoleSetStmt: AlterRoleSetStmt; +} | { + DropRoleStmt: DropRoleStmt; +} | { + CreateSeqStmt: CreateSeqStmt; +} | { + AlterSeqStmt: AlterSeqStmt; +} | { + DefineStmt: DefineStmt; +} | { + CreateDomainStmt: CreateDomainStmt; +} | { + CreateOpClassStmt: CreateOpClassStmt; +} | { + CreateOpClassItem: CreateOpClassItem; +} | { + CreateOpFamilyStmt: CreateOpFamilyStmt; +} | { + AlterOpFamilyStmt: AlterOpFamilyStmt; +} | { + DropStmt: DropStmt; +} | { + TruncateStmt: TruncateStmt; +} | { + CommentStmt: CommentStmt; +} | { + SecLabelStmt: SecLabelStmt; +} | { + DeclareCursorStmt: DeclareCursorStmt; +} | { + ClosePortalStmt: ClosePortalStmt; +} | { + FetchStmt: FetchStmt; +} | { + IndexStmt: IndexStmt; +} | { + CreateStatsStmt: CreateStatsStmt; +} | { + StatsElem: StatsElem; +} | { + AlterStatsStmt: AlterStatsStmt; +} | { + CreateFunctionStmt: CreateFunctionStmt; +} | { + FunctionParameter: FunctionParameter; +} | { + AlterFunctionStmt: AlterFunctionStmt; +} | { + DoStmt: DoStmt; +} | { + InlineCodeBlock: InlineCodeBlock; +} | { + CallStmt: CallStmt; +} | { + CallContext: CallContext; +} | { + RenameStmt: RenameStmt; +} | { + AlterObjectDependsStmt: AlterObjectDependsStmt; +} | { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; +} | { + AlterOwnerStmt: AlterOwnerStmt; +} | { + AlterOperatorStmt: AlterOperatorStmt; +} | { + AlterTypeStmt: AlterTypeStmt; +} | { + RuleStmt: RuleStmt; +} | { + NotifyStmt: NotifyStmt; +} | { + ListenStmt: ListenStmt; +} | { + UnlistenStmt: UnlistenStmt; +} | { + TransactionStmt: TransactionStmt; +} | { + CompositeTypeStmt: CompositeTypeStmt; +} | { + CreateEnumStmt: CreateEnumStmt; +} | { + CreateRangeStmt: CreateRangeStmt; +} | { + AlterEnumStmt: AlterEnumStmt; +} | { + ViewStmt: ViewStmt; +} | { + LoadStmt: LoadStmt; +} | { + CreatedbStmt: CreatedbStmt; +} | { + AlterDatabaseStmt: AlterDatabaseStmt; +} | { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; +} | { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; +} | { + DropdbStmt: DropdbStmt; +} | { + AlterSystemStmt: AlterSystemStmt; +} | { + ClusterStmt: ClusterStmt; +} | { + VacuumStmt: VacuumStmt; +} | { + VacuumRelation: VacuumRelation; +} | { + ExplainStmt: ExplainStmt; +} | { + CreateTableAsStmt: CreateTableAsStmt; +} | { + RefreshMatViewStmt: RefreshMatViewStmt; +} | { + CheckPointStmt: CheckPointStmt; +} | { + DiscardStmt: DiscardStmt; +} | { + LockStmt: LockStmt; +} | { + ConstraintsSetStmt: ConstraintsSetStmt; +} | { + ReindexStmt: ReindexStmt; +} | { + CreateConversionStmt: CreateConversionStmt; +} | { + CreateCastStmt: CreateCastStmt; +} | { + CreateTransformStmt: CreateTransformStmt; +} | { + PrepareStmt: PrepareStmt; +} | { + ExecuteStmt: ExecuteStmt; +} | { + DeallocateStmt: DeallocateStmt; +} | { + DropOwnedStmt: DropOwnedStmt; +} | { + ReassignOwnedStmt: ReassignOwnedStmt; +} | { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; +} | { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; +} | { + PublicationTable: PublicationTable; +} | { + PublicationObjSpec: PublicationObjSpec; +} | { + CreatePublicationStmt: CreatePublicationStmt; +} | { + AlterPublicationStmt: AlterPublicationStmt; +} | { + CreateSubscriptionStmt: CreateSubscriptionStmt; +} | { + AlterSubscriptionStmt: AlterSubscriptionStmt; +} | { + DropSubscriptionStmt: DropSubscriptionStmt; +} | { + ScanToken: ScanToken; +}; +export interface ParseResult { + version?: number; + stmts?: RawStmt[]; +} +export interface ScanResult { + version?: number; + tokens?: ScanToken[]; +} +export interface Integer { + ival?: number; +} +export interface Float { + fval?: string; +} +export interface Boolean { + boolval?: boolean; +} +export interface String { + sval?: string; +} +export interface BitString { + bsval?: string; +} +export interface List { + items?: Node[]; +} +export interface OidList { + items?: Node[]; +} +export interface IntList { + items?: Node[]; +} +export interface A_Const { + ival?: Integer; + fval?: Float; + boolval?: Boolean; + sval?: String; + bsval?: BitString; + isnull?: boolean; + location?: number; +} +export interface Alias { + aliasname?: string; + colnames?: Node[]; +} +export interface RangeVar { + catalogname?: string; + schemaname?: string; + relname?: string; + inh?: boolean; + relpersistence?: string; + alias?: Alias; + location?: number; +} +export interface TableFunc { + ns_uris?: Node[]; + ns_names?: Node[]; + docexpr?: Node; + rowexpr?: Node; + colnames?: Node[]; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + colexprs?: Node[]; + coldefexprs?: Node[]; + notnulls?: bigint[]; + ordinalitycol?: number; + location?: number; +} +export interface IntoClause { + rel?: RangeVar; + colNames?: Node[]; + accessMethod?: string; + options?: Node[]; + onCommit?: OnCommitAction; + tableSpaceName?: string; + viewQuery?: Node; + skipData?: boolean; +} +export interface Var { + xpr?: Node; + varno?: number; + varattno?: number; + vartype?: number; + vartypmod?: number; + varcollid?: number; + varnullingrels?: bigint[]; + varlevelsup?: number; + location?: number; +} +export interface Param { + xpr?: Node; + paramkind?: ParamKind; + paramid?: number; + paramtype?: number; + paramtypmod?: number; + paramcollid?: number; + location?: number; +} +export interface Aggref { + xpr?: Node; + aggfnoid?: number; + aggtype?: number; + aggcollid?: number; + inputcollid?: number; + aggargtypes?: Node[]; + aggdirectargs?: Node[]; + args?: Node[]; + aggorder?: Node[]; + aggdistinct?: Node[]; + aggfilter?: Node; + aggstar?: boolean; + aggvariadic?: boolean; + aggkind?: string; + agglevelsup?: number; + aggsplit?: AggSplit; + aggno?: number; + aggtransno?: number; + location?: number; +} +export interface GroupingFunc { + xpr?: Node; + args?: Node[]; + refs?: Node[]; + agglevelsup?: number; + location?: number; +} +export interface WindowFunc { + xpr?: Node; + winfnoid?: number; + wintype?: number; + wincollid?: number; + inputcollid?: number; + args?: Node[]; + aggfilter?: Node; + winref?: number; + winstar?: boolean; + winagg?: boolean; + location?: number; +} +export interface SubscriptingRef { + xpr?: Node; + refcontainertype?: number; + refelemtype?: number; + refrestype?: number; + reftypmod?: number; + refcollid?: number; + refupperindexpr?: Node[]; + reflowerindexpr?: Node[]; + refexpr?: Node; + refassgnexpr?: Node; +} +export interface FuncExpr { + xpr?: Node; + funcid?: number; + funcresulttype?: number; + funcretset?: boolean; + funcvariadic?: boolean; + funcformat?: CoercionForm; + funccollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NamedArgExpr { + xpr?: Node; + arg?: Node; + name?: string; + argnumber?: number; + location?: number; +} +export interface OpExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface DistinctExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NullIfExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface ScalarArrayOpExpr { + xpr?: Node; + opno?: number; + useOr?: boolean; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface BoolExpr { + xpr?: Node; + boolop?: BoolExprType; + args?: Node[]; + location?: number; +} +export interface SubLink { + xpr?: Node; + subLinkType?: SubLinkType; + subLinkId?: number; + testexpr?: Node; + operName?: Node[]; + subselect?: Node; + location?: number; +} +export interface SubPlan { + xpr?: Node; + subLinkType?: SubLinkType; + testexpr?: Node; + paramIds?: Node[]; + plan_id?: number; + plan_name?: string; + firstColType?: number; + firstColTypmod?: number; + firstColCollation?: number; + useHashTable?: boolean; + unknownEqFalse?: boolean; + parallel_safe?: boolean; + setParam?: Node[]; + parParam?: Node[]; + args?: Node[]; + startup_cost?: number; + per_call_cost?: number; +} +export interface AlternativeSubPlan { + xpr?: Node; + subplans?: Node[]; +} +export interface FieldSelect { + xpr?: Node; + arg?: Node; + fieldnum?: number; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; +} +export interface FieldStore { + xpr?: Node; + arg?: Node; + newvals?: Node[]; + fieldnums?: Node[]; + resulttype?: number; +} +export interface RelabelType { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + relabelformat?: CoercionForm; + location?: number; +} +export interface CoerceViaIO { + xpr?: Node; + arg?: Node; + resulttype?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ArrayCoerceExpr { + xpr?: Node; + arg?: Node; + elemexpr?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ConvertRowtypeExpr { + xpr?: Node; + arg?: Node; + resulttype?: number; + convertformat?: CoercionForm; + location?: number; +} +export interface CollateExpr { + xpr?: Node; + arg?: Node; + collOid?: number; + location?: number; +} +export interface CaseExpr { + xpr?: Node; + casetype?: number; + casecollid?: number; + arg?: Node; + args?: Node[]; + defresult?: Node; + location?: number; +} +export interface CaseWhen { + xpr?: Node; + expr?: Node; + result?: Node; + location?: number; +} +export interface CaseTestExpr { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; +} +export interface ArrayExpr { + xpr?: Node; + array_typeid?: number; + array_collid?: number; + element_typeid?: number; + elements?: Node[]; + multidims?: boolean; + location?: number; +} +export interface RowExpr { + xpr?: Node; + args?: Node[]; + row_typeid?: number; + row_format?: CoercionForm; + colnames?: Node[]; + location?: number; +} +export interface RowCompareExpr { + xpr?: Node; + rctype?: RowCompareType; + opnos?: Node[]; + opfamilies?: Node[]; + inputcollids?: Node[]; + largs?: Node[]; + rargs?: Node[]; +} +export interface CoalesceExpr { + xpr?: Node; + coalescetype?: number; + coalescecollid?: number; + args?: Node[]; + location?: number; +} +export interface MinMaxExpr { + xpr?: Node; + minmaxtype?: number; + minmaxcollid?: number; + inputcollid?: number; + op?: MinMaxOp; + args?: Node[]; + location?: number; +} +export interface SQLValueFunction { + xpr?: Node; + op?: SQLValueFunctionOp; + type?: number; + typmod?: number; + location?: number; +} +export interface XmlExpr { + xpr?: Node; + op?: XmlExprOp; + name?: string; + named_args?: Node[]; + arg_names?: Node[]; + args?: Node[]; + xmloption?: XmlOptionType; + indent?: boolean; + type?: number; + typmod?: number; + location?: number; +} +export interface JsonFormat { + format_type?: JsonFormatType; + encoding?: JsonEncoding; + location?: number; +} +export interface JsonReturning { + format?: JsonFormat; + typid?: number; + typmod?: number; +} +export interface JsonValueExpr { + raw_expr?: Node; + formatted_expr?: Node; + format?: JsonFormat; +} +export interface JsonConstructorExpr { + xpr?: Node; + type?: JsonConstructorType; + args?: Node[]; + func?: Node; + coercion?: Node; + returning?: JsonReturning; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonIsPredicate { + expr?: Node; + format?: JsonFormat; + item_type?: JsonValueType; + unique_keys?: boolean; + location?: number; +} +export interface NullTest { + xpr?: Node; + arg?: Node; + nulltesttype?: NullTestType; + argisrow?: boolean; + location?: number; +} +export interface BooleanTest { + xpr?: Node; + arg?: Node; + booltesttype?: BoolTestType; + location?: number; +} +export interface CoerceToDomain { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coercionformat?: CoercionForm; + location?: number; +} +export interface CoerceToDomainValue { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface SetToDefault { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface CurrentOfExpr { + xpr?: Node; + cvarno?: number; + cursor_name?: string; + cursor_param?: number; +} +export interface NextValueExpr { + xpr?: Node; + seqid?: number; + typeId?: number; +} +export interface InferenceElem { + xpr?: Node; + expr?: Node; + infercollid?: number; + inferopclass?: number; +} +export interface TargetEntry { + xpr?: Node; + expr?: Node; + resno?: number; + resname?: string; + ressortgroupref?: number; + resorigtbl?: number; + resorigcol?: number; + resjunk?: boolean; +} +export interface RangeTblRef { + rtindex?: number; +} +export interface JoinExpr { + jointype?: JoinType; + isNatural?: boolean; + larg?: Node; + rarg?: Node; + usingClause?: Node[]; + join_using_alias?: Alias; + quals?: Node; + alias?: Alias; + rtindex?: number; +} +export interface FromExpr { + fromlist?: Node[]; + quals?: Node; +} +export interface OnConflictExpr { + action?: OnConflictAction; + arbiterElems?: Node[]; + arbiterWhere?: Node; + constraint?: number; + onConflictSet?: Node[]; + onConflictWhere?: Node; + exclRelIndex?: number; + exclRelTlist?: Node[]; +} +export interface Query { + commandType?: CmdType; + querySource?: QuerySource; + canSetTag?: boolean; + utilityStmt?: Node; + resultRelation?: number; + hasAggs?: boolean; + hasWindowFuncs?: boolean; + hasTargetSRFs?: boolean; + hasSubLinks?: boolean; + hasDistinctOn?: boolean; + hasRecursive?: boolean; + hasModifyingCTE?: boolean; + hasForUpdate?: boolean; + hasRowSecurity?: boolean; + isReturn?: boolean; + cteList?: Node[]; + rtable?: Node[]; + rteperminfos?: Node[]; + jointree?: FromExpr; + mergeActionList?: Node[]; + mergeUseOuterJoin?: boolean; + targetList?: Node[]; + override?: OverridingKind; + onConflict?: OnConflictExpr; + returningList?: Node[]; + groupClause?: Node[]; + groupDistinct?: boolean; + groupingSets?: Node[]; + havingQual?: Node; + windowClause?: Node[]; + distinctClause?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + rowMarks?: Node[]; + setOperations?: Node; + constraintDeps?: Node[]; + withCheckOptions?: Node[]; + stmt_location?: number; + stmt_len?: number; +} +export interface TypeName { + names?: Node[]; + typeOid?: number; + setof?: boolean; + pct_type?: boolean; + typmods?: Node[]; + typemod?: number; + arrayBounds?: Node[]; + location?: number; +} +export interface ColumnRef { + fields?: Node[]; + location?: number; +} +export interface ParamRef { + number?: number; + location?: number; +} +export interface A_Expr { + kind?: A_Expr_Kind; + name?: Node[]; + lexpr?: Node; + rexpr?: Node; + location?: number; +} +export interface TypeCast { + arg?: Node; + typeName?: TypeName; + location?: number; +} +export interface CollateClause { + arg?: Node; + collname?: Node[]; + location?: number; +} +export interface RoleSpec { + roletype?: RoleSpecType; + rolename?: string; + location?: number; +} +export interface FuncCall { + funcname?: Node[]; + args?: Node[]; + agg_order?: Node[]; + agg_filter?: Node; + over?: WindowDef; + agg_within_group?: boolean; + agg_star?: boolean; + agg_distinct?: boolean; + func_variadic?: boolean; + funcformat?: CoercionForm; + location?: number; +} +export interface A_Star {} +export interface A_Indices { + is_slice?: boolean; + lidx?: Node; + uidx?: Node; +} +export interface A_Indirection { + arg?: Node; + indirection?: Node[]; +} +export interface A_ArrayExpr { + elements?: Node[]; + location?: number; +} +export interface ResTarget { + name?: string; + indirection?: Node[]; + val?: Node; + location?: number; +} +export interface MultiAssignRef { + source?: Node; + colno?: number; + ncolumns?: number; +} +export interface SortBy { + node?: Node; + sortby_dir?: SortByDir; + sortby_nulls?: SortByNulls; + useOp?: Node[]; + location?: number; +} +export interface WindowDef { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + location?: number; +} +export interface RangeSubselect { + lateral?: boolean; + subquery?: Node; + alias?: Alias; +} +export interface RangeFunction { + lateral?: boolean; + ordinality?: boolean; + is_rowsfrom?: boolean; + functions?: Node[]; + alias?: Alias; + coldeflist?: Node[]; +} +export interface RangeTableFunc { + lateral?: boolean; + docexpr?: Node; + rowexpr?: Node; + namespaces?: Node[]; + columns?: Node[]; + alias?: Alias; + location?: number; +} +export interface RangeTableFuncCol { + colname?: string; + typeName?: TypeName; + for_ordinality?: boolean; + is_not_null?: boolean; + colexpr?: Node; + coldefexpr?: Node; + location?: number; +} +export interface RangeTableSample { + relation?: Node; + method?: Node[]; + args?: Node[]; + repeatable?: Node; + location?: number; +} +export interface ColumnDef { + colname?: string; + typeName?: TypeName; + compression?: string; + inhcount?: number; + is_local?: boolean; + is_not_null?: boolean; + is_from_type?: boolean; + storage?: string; + storage_name?: string; + raw_default?: Node; + cooked_default?: Node; + identity?: string; + identitySequence?: RangeVar; + generated?: string; + collClause?: CollateClause; + collOid?: number; + constraints?: Node[]; + fdwoptions?: Node[]; + location?: number; +} +export interface TableLikeClause { + relation?: RangeVar; + options?: number; + relationOid?: number; +} +export interface IndexElem { + name?: string; + expr?: Node; + indexcolname?: string; + collation?: Node[]; + opclass?: Node[]; + opclassopts?: Node[]; + ordering?: SortByDir; + nulls_ordering?: SortByNulls; +} +export interface DefElem { + defnamespace?: string; + defname?: string; + arg?: Node; + defaction?: DefElemAction; + location?: number; +} +export interface LockingClause { + lockedRels?: Node[]; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; +} +export interface XmlSerialize { + xmloption?: XmlOptionType; + expr?: Node; + typeName?: TypeName; + indent?: boolean; + location?: number; +} +export interface PartitionElem { + name?: string; + expr?: Node; + collation?: Node[]; + opclass?: Node[]; + location?: number; +} +export interface PartitionSpec { + strategy?: PartitionStrategy; + partParams?: Node[]; + location?: number; +} +export interface PartitionBoundSpec { + strategy?: string; + is_default?: boolean; + modulus?: number; + remainder?: number; + listdatums?: Node[]; + lowerdatums?: Node[]; + upperdatums?: Node[]; + location?: number; +} +export interface PartitionRangeDatum { + kind?: PartitionRangeDatumKind; + value?: Node; + location?: number; +} +export interface PartitionCmd { + name?: RangeVar; + bound?: PartitionBoundSpec; + concurrent?: boolean; +} +export interface RangeTblEntry { + rtekind?: RTEKind; + relid?: number; + relkind?: string; + rellockmode?: number; + tablesample?: TableSampleClause; + perminfoindex?: number; + subquery?: Query; + security_barrier?: boolean; + jointype?: JoinType; + joinmergedcols?: number; + joinaliasvars?: Node[]; + joinleftcols?: Node[]; + joinrightcols?: Node[]; + join_using_alias?: Alias; + functions?: Node[]; + funcordinality?: boolean; + tablefunc?: TableFunc; + values_lists?: Node[]; + ctename?: string; + ctelevelsup?: number; + self_reference?: boolean; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + enrname?: string; + enrtuples?: number; + alias?: Alias; + eref?: Alias; + lateral?: boolean; + inh?: boolean; + inFromCl?: boolean; + securityQuals?: Node[]; +} +export interface RTEPermissionInfo { + relid?: number; + inh?: boolean; + requiredPerms?: bigint; + checkAsUser?: number; + selectedCols?: bigint[]; + insertedCols?: bigint[]; + updatedCols?: bigint[]; +} +export interface RangeTblFunction { + funcexpr?: Node; + funccolcount?: number; + funccolnames?: Node[]; + funccoltypes?: Node[]; + funccoltypmods?: Node[]; + funccolcollations?: Node[]; + funcparams?: bigint[]; +} +export interface TableSampleClause { + tsmhandler?: number; + args?: Node[]; + repeatable?: Node; +} +export interface WithCheckOption { + kind?: WCOKind; + relname?: string; + polname?: string; + qual?: Node; + cascaded?: boolean; +} +export interface SortGroupClause { + tleSortGroupRef?: number; + eqop?: number; + sortop?: number; + nulls_first?: boolean; + hashable?: boolean; +} +export interface GroupingSet { + kind?: GroupingSetKind; + content?: Node[]; + location?: number; +} +export interface WindowClause { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + runCondition?: Node[]; + startInRangeFunc?: number; + endInRangeFunc?: number; + inRangeColl?: number; + inRangeAsc?: boolean; + inRangeNullsFirst?: boolean; + winref?: number; + copiedOrder?: boolean; +} +export interface RowMarkClause { + rti?: number; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; + pushedDown?: boolean; +} +export interface WithClause { + ctes?: Node[]; + recursive?: boolean; + location?: number; +} +export interface InferClause { + indexElems?: Node[]; + whereClause?: Node; + conname?: string; + location?: number; +} +export interface OnConflictClause { + action?: OnConflictAction; + infer?: InferClause; + targetList?: Node[]; + whereClause?: Node; + location?: number; +} +export interface CTESearchClause { + search_col_list?: Node[]; + search_breadth_first?: boolean; + search_seq_column?: string; + location?: number; +} +export interface CTECycleClause { + cycle_col_list?: Node[]; + cycle_mark_column?: string; + cycle_mark_value?: Node; + cycle_mark_default?: Node; + cycle_path_column?: string; + location?: number; + cycle_mark_type?: number; + cycle_mark_typmod?: number; + cycle_mark_collation?: number; + cycle_mark_neop?: number; +} +export interface CommonTableExpr { + ctename?: string; + aliascolnames?: Node[]; + ctematerialized?: CTEMaterialize; + ctequery?: Node; + search_clause?: CTESearchClause; + cycle_clause?: CTECycleClause; + location?: number; + cterecursive?: boolean; + cterefcount?: number; + ctecolnames?: Node[]; + ctecoltypes?: Node[]; + ctecoltypmods?: Node[]; + ctecolcollations?: Node[]; +} +export interface MergeWhenClause { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + condition?: Node; + targetList?: Node[]; + values?: Node[]; +} +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} +export interface TriggerTransition { + name?: string; + isNew?: boolean; + isTable?: boolean; +} +export interface JsonOutput { + typeName?: TypeName; + returning?: JsonReturning; +} +export interface JsonKeyValue { + key?: Node; + value?: JsonValueExpr; +} +export interface JsonObjectConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonArrayConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + location?: number; +} +export interface JsonArrayQueryConstructor { + query?: Node; + output?: JsonOutput; + format?: JsonFormat; + absent_on_null?: boolean; + location?: number; +} +export interface JsonAggConstructor { + output?: JsonOutput; + agg_filter?: Node; + agg_order?: Node[]; + over?: WindowDef; + location?: number; +} +export interface JsonObjectAgg { + constructor?: JsonAggConstructor; + arg?: JsonKeyValue; + absent_on_null?: boolean; + unique?: boolean; +} +export interface JsonArrayAgg { + constructor?: JsonAggConstructor; + arg?: JsonValueExpr; + absent_on_null?: boolean; +} +export interface RawStmt { + stmt?: Node; + stmt_location?: number; + stmt_len?: number; +} +export interface InsertStmt { + relation?: RangeVar; + cols?: Node[]; + selectStmt?: Node; + onConflictClause?: OnConflictClause; + returningList?: Node[]; + withClause?: WithClause; + override?: OverridingKind; +} +export interface DeleteStmt { + relation?: RangeVar; + usingClause?: Node[]; + whereClause?: Node; + returningList?: Node[]; + withClause?: WithClause; +} +export interface UpdateStmt { + relation?: RangeVar; + targetList?: Node[]; + whereClause?: Node; + fromClause?: Node[]; + returningList?: Node[]; + withClause?: WithClause; +} +export interface MergeStmt { + relation?: RangeVar; + sourceRelation?: Node; + joinCondition?: Node; + mergeWhenClauses?: Node[]; + withClause?: WithClause; +} +export interface SelectStmt { + distinctClause?: Node[]; + intoClause?: IntoClause; + targetList?: Node[]; + fromClause?: Node[]; + whereClause?: Node; + groupClause?: Node[]; + groupDistinct?: boolean; + havingClause?: Node; + windowClause?: Node[]; + valuesLists?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + lockingClause?: Node[]; + withClause?: WithClause; + op?: SetOperation; + all?: boolean; + larg?: SelectStmt; + rarg?: SelectStmt; +} +export interface SetOperationStmt { + op?: SetOperation; + all?: boolean; + larg?: Node; + rarg?: Node; + colTypes?: Node[]; + colTypmods?: Node[]; + colCollations?: Node[]; + groupClauses?: Node[]; +} +export interface ReturnStmt { + returnval?: Node; +} +export interface PLAssignStmt { + name?: string; + indirection?: Node[]; + nnames?: number; + val?: SelectStmt; + location?: number; +} +export interface CreateSchemaStmt { + schemaname?: string; + authrole?: RoleSpec; + schemaElts?: Node[]; + if_not_exists?: boolean; +} +export interface AlterTableStmt { + relation?: RangeVar; + cmds?: Node[]; + objtype?: ObjectType; + missing_ok?: boolean; +} +export interface ReplicaIdentityStmt { + identity_type?: string; + name?: string; +} +export interface AlterTableCmd { + subtype?: AlterTableType; + name?: string; + num?: number; + newowner?: RoleSpec; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; + recurse?: boolean; +} +export interface AlterCollationStmt { + collname?: Node[]; +} +export interface AlterDomainStmt { + subtype?: string; + typeName?: Node[]; + name?: string; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface GrantStmt { + is_grant?: boolean; + targtype?: GrantTargetType; + objtype?: ObjectType; + objects?: Node[]; + privileges?: Node[]; + grantees?: Node[]; + grant_option?: boolean; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface ObjectWithArgs { + objname?: Node[]; + objargs?: Node[]; + objfuncargs?: Node[]; + args_unspecified?: boolean; +} +export interface AccessPriv { + priv_name?: string; + cols?: Node[]; +} +export interface GrantRoleStmt { + granted_roles?: Node[]; + grantee_roles?: Node[]; + is_grant?: boolean; + opt?: Node[]; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface AlterDefaultPrivilegesStmt { + options?: Node[]; + action?: GrantStmt; +} +export interface CopyStmt { + relation?: RangeVar; + query?: Node; + attlist?: Node[]; + is_from?: boolean; + is_program?: boolean; + filename?: string; + options?: Node[]; + whereClause?: Node; +} +export interface VariableSetStmt { + kind?: VariableSetKind; + name?: string; + args?: Node[]; + is_local?: boolean; +} +export interface VariableShowStmt { + name?: string; +} +export interface CreateStmt { + relation?: RangeVar; + tableElts?: Node[]; + inhRelations?: Node[]; + partbound?: PartitionBoundSpec; + partspec?: PartitionSpec; + ofTypename?: TypeName; + constraints?: Node[]; + options?: Node[]; + oncommit?: OnCommitAction; + tablespacename?: string; + accessMethod?: string; + if_not_exists?: boolean; +} +export interface Constraint { + contype?: ConstrType; + conname?: string; + deferrable?: boolean; + initdeferred?: boolean; + location?: number; + is_no_inherit?: boolean; + raw_expr?: Node; + cooked_expr?: string; + generated_when?: string; + nulls_not_distinct?: boolean; + keys?: Node[]; + including?: Node[]; + exclusions?: Node[]; + options?: Node[]; + indexname?: string; + indexspace?: string; + reset_default_tblspc?: boolean; + access_method?: string; + where_clause?: Node; + pktable?: RangeVar; + fk_attrs?: Node[]; + pk_attrs?: Node[]; + fk_matchtype?: string; + fk_upd_action?: string; + fk_del_action?: string; + fk_del_set_cols?: Node[]; + old_conpfeqop?: Node[]; + old_pktable_oid?: number; + skip_validation?: boolean; + initially_valid?: boolean; +} +export interface CreateTableSpaceStmt { + tablespacename?: string; + owner?: RoleSpec; + location?: string; + options?: Node[]; +} +export interface DropTableSpaceStmt { + tablespacename?: string; + missing_ok?: boolean; +} +export interface AlterTableSpaceOptionsStmt { + tablespacename?: string; + options?: Node[]; + isReset?: boolean; +} +export interface AlterTableMoveAllStmt { + orig_tablespacename?: string; + objtype?: ObjectType; + roles?: Node[]; + new_tablespacename?: string; + nowait?: boolean; +} +export interface CreateExtensionStmt { + extname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterExtensionStmt { + extname?: string; + options?: Node[]; +} +export interface AlterExtensionContentsStmt { + extname?: string; + action?: number; + objtype?: ObjectType; + object?: Node; +} +export interface CreateFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface AlterFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface CreateForeignServerStmt { + servername?: string; + servertype?: string; + version?: string; + fdwname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterForeignServerStmt { + servername?: string; + version?: string; + options?: Node[]; + has_version?: boolean; +} +export interface CreateForeignTableStmt { + base?: CreateStmt; + servername?: string; + options?: Node[]; +} +export interface CreateUserMappingStmt { + user?: RoleSpec; + servername?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterUserMappingStmt { + user?: RoleSpec; + servername?: string; + options?: Node[]; +} +export interface DropUserMappingStmt { + user?: RoleSpec; + servername?: string; + missing_ok?: boolean; +} +export interface ImportForeignSchemaStmt { + server_name?: string; + remote_schema?: string; + local_schema?: string; + list_type?: ImportForeignSchemaType; + table_list?: Node[]; + options?: Node[]; +} +export interface CreatePolicyStmt { + policy_name?: string; + table?: RangeVar; + cmd_name?: string; + permissive?: boolean; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface AlterPolicyStmt { + policy_name?: string; + table?: RangeVar; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface CreateAmStmt { + amname?: string; + handler_name?: Node[]; + amtype?: string; +} +export interface CreateTrigStmt { + replace?: boolean; + isconstraint?: boolean; + trigname?: string; + relation?: RangeVar; + funcname?: Node[]; + args?: Node[]; + row?: boolean; + timing?: number; + events?: number; + columns?: Node[]; + whenClause?: Node; + transitionRels?: Node[]; + deferrable?: boolean; + initdeferred?: boolean; + constrrel?: RangeVar; +} +export interface CreateEventTrigStmt { + trigname?: string; + eventname?: string; + whenclause?: Node[]; + funcname?: Node[]; +} +export interface AlterEventTrigStmt { + trigname?: string; + tgenabled?: string; +} +export interface CreatePLangStmt { + replace?: boolean; + plname?: string; + plhandler?: Node[]; + plinline?: Node[]; + plvalidator?: Node[]; + pltrusted?: boolean; +} +export interface CreateRoleStmt { + stmt_type?: RoleStmtType; + role?: string; + options?: Node[]; +} +export interface AlterRoleStmt { + role?: RoleSpec; + options?: Node[]; + action?: number; +} +export interface AlterRoleSetStmt { + role?: RoleSpec; + database?: string; + setstmt?: VariableSetStmt; +} +export interface DropRoleStmt { + roles?: Node[]; + missing_ok?: boolean; +} +export interface CreateSeqStmt { + sequence?: RangeVar; + options?: Node[]; + ownerId?: number; + for_identity?: boolean; + if_not_exists?: boolean; +} +export interface AlterSeqStmt { + sequence?: RangeVar; + options?: Node[]; + for_identity?: boolean; + missing_ok?: boolean; +} +export interface DefineStmt { + kind?: ObjectType; + oldstyle?: boolean; + defnames?: Node[]; + args?: Node[]; + definition?: Node[]; + if_not_exists?: boolean; + replace?: boolean; +} +export interface CreateDomainStmt { + domainname?: Node[]; + typeName?: TypeName; + collClause?: CollateClause; + constraints?: Node[]; +} +export interface CreateOpClassStmt { + opclassname?: Node[]; + opfamilyname?: Node[]; + amname?: string; + datatype?: TypeName; + items?: Node[]; + isDefault?: boolean; +} +export interface CreateOpClassItem { + itemtype?: number; + name?: ObjectWithArgs; + number?: number; + order_family?: Node[]; + class_args?: Node[]; + storedtype?: TypeName; +} +export interface CreateOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; +} +export interface AlterOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; + isDrop?: boolean; + items?: Node[]; +} +export interface DropStmt { + objects?: Node[]; + removeType?: ObjectType; + behavior?: DropBehavior; + missing_ok?: boolean; + concurrent?: boolean; +} +export interface TruncateStmt { + relations?: Node[]; + restart_seqs?: boolean; + behavior?: DropBehavior; +} +export interface CommentStmt { + objtype?: ObjectType; + object?: Node; + comment?: string; +} +export interface SecLabelStmt { + objtype?: ObjectType; + object?: Node; + provider?: string; + label?: string; +} +export interface DeclareCursorStmt { + portalname?: string; + options?: number; + query?: Node; +} +export interface ClosePortalStmt { + portalname?: string; +} +export interface FetchStmt { + direction?: FetchDirection; + howMany?: bigint; + portalname?: string; + ismove?: boolean; +} +export interface IndexStmt { + idxname?: string; + relation?: RangeVar; + accessMethod?: string; + tableSpace?: string; + indexParams?: Node[]; + indexIncludingParams?: Node[]; + options?: Node[]; + whereClause?: Node; + excludeOpNames?: Node[]; + idxcomment?: string; + indexOid?: number; + oldNumber?: number; + oldCreateSubid?: number; + oldFirstRelfilelocatorSubid?: number; + unique?: boolean; + nulls_not_distinct?: boolean; + primary?: boolean; + isconstraint?: boolean; + deferrable?: boolean; + initdeferred?: boolean; + transformed?: boolean; + concurrent?: boolean; + if_not_exists?: boolean; + reset_default_tblspc?: boolean; +} +export interface CreateStatsStmt { + defnames?: Node[]; + stat_types?: Node[]; + exprs?: Node[]; + relations?: Node[]; + stxcomment?: string; + transformed?: boolean; + if_not_exists?: boolean; +} +export interface StatsElem { + name?: string; + expr?: Node; +} +export interface AlterStatsStmt { + defnames?: Node[]; + stxstattarget?: number; + missing_ok?: boolean; +} +export interface CreateFunctionStmt { + is_procedure?: boolean; + replace?: boolean; + funcname?: Node[]; + parameters?: Node[]; + returnType?: TypeName; + options?: Node[]; + sql_body?: Node; +} +export interface FunctionParameter { + name?: string; + argType?: TypeName; + mode?: FunctionParameterMode; + defexpr?: Node; +} +export interface AlterFunctionStmt { + objtype?: ObjectType; + func?: ObjectWithArgs; + actions?: Node[]; +} +export interface DoStmt { + args?: Node[]; +} +export interface InlineCodeBlock { + source_text?: string; + langOid?: number; + langIsTrusted?: boolean; + atomic?: boolean; +} +export interface CallStmt { + funccall?: FuncCall; + funcexpr?: FuncExpr; + outargs?: Node[]; +} +export interface CallContext { + atomic?: boolean; +} +export interface RenameStmt { + renameType?: ObjectType; + relationType?: ObjectType; + relation?: RangeVar; + object?: Node; + subname?: string; + newname?: string; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface AlterObjectDependsStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + extname?: String; + remove?: boolean; +} +export interface AlterObjectSchemaStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newschema?: string; + missing_ok?: boolean; +} +export interface AlterOwnerStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newowner?: RoleSpec; +} +export interface AlterOperatorStmt { + opername?: ObjectWithArgs; + options?: Node[]; +} +export interface AlterTypeStmt { + typeName?: Node[]; + options?: Node[]; +} +export interface RuleStmt { + relation?: RangeVar; + rulename?: string; + whereClause?: Node; + event?: CmdType; + instead?: boolean; + actions?: Node[]; + replace?: boolean; +} +export interface NotifyStmt { + conditionname?: string; + payload?: string; +} +export interface ListenStmt { + conditionname?: string; +} +export interface UnlistenStmt { + conditionname?: string; +} +export interface TransactionStmt { + kind?: TransactionStmtKind; + options?: Node[]; + savepoint_name?: string; + gid?: string; + chain?: boolean; +} +export interface CompositeTypeStmt { + typevar?: RangeVar; + coldeflist?: Node[]; +} +export interface CreateEnumStmt { + typeName?: Node[]; + vals?: Node[]; +} +export interface CreateRangeStmt { + typeName?: Node[]; + params?: Node[]; +} +export interface AlterEnumStmt { + typeName?: Node[]; + oldVal?: string; + newVal?: string; + newValNeighbor?: string; + newValIsAfter?: boolean; + skipIfNewValExists?: boolean; +} +export interface ViewStmt { + view?: RangeVar; + aliases?: Node[]; + query?: Node; + replace?: boolean; + options?: Node[]; + withCheckOption?: ViewCheckOption; +} +export interface LoadStmt { + filename?: string; +} +export interface CreatedbStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseRefreshCollStmt { + dbname?: string; +} +export interface AlterDatabaseSetStmt { + dbname?: string; + setstmt?: VariableSetStmt; +} +export interface DropdbStmt { + dbname?: string; + missing_ok?: boolean; + options?: Node[]; +} +export interface AlterSystemStmt { + setstmt?: VariableSetStmt; +} +export interface ClusterStmt { + relation?: RangeVar; + indexname?: string; + params?: Node[]; +} +export interface VacuumStmt { + options?: Node[]; + rels?: Node[]; + is_vacuumcmd?: boolean; +} +export interface VacuumRelation { + relation?: RangeVar; + oid?: number; + va_cols?: Node[]; +} +export interface ExplainStmt { + query?: Node; + options?: Node[]; +} +export interface CreateTableAsStmt { + query?: Node; + into?: IntoClause; + objtype?: ObjectType; + is_select_into?: boolean; + if_not_exists?: boolean; +} +export interface RefreshMatViewStmt { + concurrent?: boolean; + skipData?: boolean; + relation?: RangeVar; +} +export interface CheckPointStmt {} +export interface DiscardStmt { + target?: DiscardMode; +} +export interface LockStmt { + relations?: Node[]; + mode?: number; + nowait?: boolean; +} +export interface ConstraintsSetStmt { + constraints?: Node[]; + deferred?: boolean; +} +export interface ReindexStmt { + kind?: ReindexObjectType; + relation?: RangeVar; + name?: string; + params?: Node[]; +} +export interface CreateConversionStmt { + conversion_name?: Node[]; + for_encoding_name?: string; + to_encoding_name?: string; + func_name?: Node[]; + def?: boolean; +} +export interface CreateCastStmt { + sourcetype?: TypeName; + targettype?: TypeName; + func?: ObjectWithArgs; + context?: CoercionContext; + inout?: boolean; +} +export interface CreateTransformStmt { + replace?: boolean; + type_name?: TypeName; + lang?: string; + fromsql?: ObjectWithArgs; + tosql?: ObjectWithArgs; +} +export interface PrepareStmt { + name?: string; + argtypes?: Node[]; + query?: Node; +} +export interface ExecuteStmt { + name?: string; + params?: Node[]; +} +export interface DeallocateStmt { + name?: string; +} +export interface DropOwnedStmt { + roles?: Node[]; + behavior?: DropBehavior; +} +export interface ReassignOwnedStmt { + roles?: Node[]; + newrole?: RoleSpec; +} +export interface AlterTSDictionaryStmt { + dictname?: Node[]; + options?: Node[]; +} +export interface AlterTSConfigurationStmt { + kind?: AlterTSConfigType; + cfgname?: Node[]; + tokentype?: Node[]; + dicts?: Node[]; + override?: boolean; + replace?: boolean; + missing_ok?: boolean; +} +export interface PublicationTable { + relation?: RangeVar; + whereClause?: Node; + columns?: Node[]; +} +export interface PublicationObjSpec { + pubobjtype?: PublicationObjSpecType; + name?: string; + pubtable?: PublicationTable; + location?: number; +} +export interface CreatePublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; +} +export interface AlterPublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; + action?: AlterPublicationAction; +} +export interface CreateSubscriptionStmt { + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface AlterSubscriptionStmt { + kind?: AlterSubscriptionType; + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface DropSubscriptionStmt { + subname?: string; + missing_ok?: boolean; + behavior?: DropBehavior; +} +export interface ScanToken { + start?: number; + end?: number; + token?: Token; + keywordKind?: KeywordKind; +}", + "file": "types.ts", + }, + { + "code": "/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): ParseResult { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return _j; + }, + scanResult(_p?: ScanResult): ScanResult { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return _j; + }, + integer(_p?: Integer): Integer { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return _j; + }, + float(_p?: Float): Float { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return _j; + }, + boolean(_p?: Boolean): Boolean { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return _j; + }, + string(_p?: String): String { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return _j; + }, + bitString(_p?: BitString): BitString { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return _j; + }, + list(_p?: List): List { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return _j; + }, + oidList(_p?: OidList): OidList { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return _j; + }, + intList(_p?: IntList): IntList { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return _j; + }, + aConst(_p?: A_Const): A_Const { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return _j; + }, + alias(_p?: Alias): Alias { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return _j; + }, + rangeVar(_p?: RangeVar): RangeVar { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableFunc(_p?: TableFunc): TableFunc { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return _j; + }, + intoClause(_p?: IntoClause): IntoClause { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return _j; + }, + var(_p?: Var): Var { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + param(_p?: Param): Param { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return _j; + }, + aggref(_p?: Aggref): Aggref { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return _j; + }, + groupingFunc(_p?: GroupingFunc): GroupingFunc { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowFunc(_p?: WindowFunc): WindowFunc { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return _j; + }, + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return _j; + }, + funcExpr(_p?: FuncExpr): FuncExpr { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return _j; + }, + opExpr(_p?: OpExpr): OpExpr { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + distinctExpr(_p?: DistinctExpr): DistinctExpr { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullIfExpr(_p?: NullIfExpr): NullIfExpr { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + boolExpr(_p?: BoolExpr): BoolExpr { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + subLink(_p?: SubLink): SubLink { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return _j; + }, + subPlan(_p?: SubPlan): SubPlan { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return _j; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return _j; + }, + fieldSelect(_p?: FieldSelect): FieldSelect { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return _j; + }, + fieldStore(_p?: FieldStore): FieldStore { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return _j; + }, + relabelType(_p?: RelabelType): RelabelType { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateExpr(_p?: CollateExpr): CollateExpr { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseExpr(_p?: CaseExpr): CaseExpr { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseWhen(_p?: CaseWhen): CaseWhen { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return _j; + }, + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return _j; + }, + arrayExpr(_p?: ArrayExpr): ArrayExpr { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowExpr(_p?: RowExpr): RowExpr { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return _j; + }, + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return _j; + }, + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return _j; + }, + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + xmlExpr(_p?: XmlExpr): XmlExpr { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonFormat(_p?: JsonFormat): JsonFormat { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonReturning(_p?: JsonReturning): JsonReturning { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return _j; + }, + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return _j; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return _j; + }, + nullTest(_p?: NullTest): NullTest { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return _j; + }, + booleanTest(_p?: BooleanTest): BooleanTest { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + setToDefault(_p?: SetToDefault): SetToDefault { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return _j; + }, + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return _j; + }, + nextValueExpr(_p?: NextValueExpr): NextValueExpr { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return _j; + }, + inferenceElem(_p?: InferenceElem): InferenceElem { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return _j; + }, + targetEntry(_p?: TargetEntry): TargetEntry { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return _j; + }, + rangeTblRef(_p?: RangeTblRef): RangeTblRef { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + joinExpr(_p?: JoinExpr): JoinExpr { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return _j; + }, + fromExpr(_p?: FromExpr): FromExpr { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return _j; + }, + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return _j; + }, + query(_p?: Query): Query { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + typeName(_p?: TypeName): TypeName { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnRef(_p?: ColumnRef): ColumnRef { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return _j; + }, + paramRef(_p?: ParamRef): ParamRef { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return _j; + }, + aExpr(_p?: A_Expr): A_Expr { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + typeCast(_p?: TypeCast): TypeCast { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return _j; + }, + collateClause(_p?: CollateClause): CollateClause { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return _j; + }, + roleSpec(_p?: RoleSpec): RoleSpec { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return _j; + }, + funcCall(_p?: FuncCall): FuncCall { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return _j; + }, + aStar(_p?: A_Star): A_Star { + const _j = {} as A_Star; + return _j; + }, + aIndices(_p?: A_Indices): A_Indices { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return _j; + }, + aIndirection(_p?: A_Indirection): A_Indirection { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return _j; + }, + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return _j; + }, + resTarget(_p?: ResTarget): ResTarget { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return _j; + }, + sortBy(_p?: SortBy): SortBy { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowDef(_p?: WindowDef): WindowDef { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeSubselect(_p?: RangeSubselect): RangeSubselect { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return _j; + }, + rangeFunction(_p?: RangeFunction): RangeFunction { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return _j; + }, + rangeTableSample(_p?: RangeTableSample): RangeTableSample { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return _j; + }, + columnDef(_p?: ColumnDef): ColumnDef { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return _j; + }, + tableLikeClause(_p?: TableLikeClause): TableLikeClause { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return _j; + }, + indexElem(_p?: IndexElem): IndexElem { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return _j; + }, + defElem(_p?: DefElem): DefElem { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return _j; + }, + lockingClause(_p?: LockingClause): LockingClause { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return _j; + }, + xmlSerialize(_p?: XmlSerialize): XmlSerialize { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionElem(_p?: PartitionElem): PartitionElem { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionSpec(_p?: PartitionSpec): PartitionSpec { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return _j; + }, + partitionCmd(_p?: PartitionCmd): PartitionCmd { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return _j; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return _j; + }, + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return _j; + }, + tableSampleClause(_p?: TableSampleClause): TableSampleClause { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return _j; + }, + withCheckOption(_p?: WithCheckOption): WithCheckOption { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return _j; + }, + sortGroupClause(_p?: SortGroupClause): SortGroupClause { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return _j; + }, + groupingSet(_p?: GroupingSet): GroupingSet { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return _j; + }, + windowClause(_p?: WindowClause): WindowClause { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return _j; + }, + rowMarkClause(_p?: RowMarkClause): RowMarkClause { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return _j; + }, + withClause(_p?: WithClause): WithClause { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return _j; + }, + inferClause(_p?: InferClause): InferClause { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return _j; + }, + onConflictClause(_p?: OnConflictClause): OnConflictClause { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteSearchClause(_p?: CTESearchClause): CTESearchClause { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return _j; + }, + cteCycleClause(_p?: CTECycleClause): CTECycleClause { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return _j; + }, + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return _j; + }, + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return _j; + }, + mergeAction(_p?: MergeAction): MergeAction { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return _j; + }, + triggerTransition(_p?: TriggerTransition): TriggerTransition { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return _j; + }, + jsonOutput(_p?: JsonOutput): JsonOutput { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return _j; + }, + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return _j; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return _j; + }, + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return _j; + }, + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return _j; + }, + rawStmt(_p?: RawStmt): RawStmt { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return _j; + }, + insertStmt(_p?: InsertStmt): InsertStmt { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return _j; + }, + deleteStmt(_p?: DeleteStmt): DeleteStmt { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + updateStmt(_p?: UpdateStmt): UpdateStmt { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + mergeStmt(_p?: MergeStmt): MergeStmt { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return _j; + }, + selectStmt(_p?: SelectStmt): SelectStmt { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return _j; + }, + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return _j; + }, + returnStmt(_p?: ReturnStmt): ReturnStmt { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return _j; + }, + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return _j; + }, + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return _j; + }, + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return _j; + }, + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return _j; + }, + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + grantStmt(_p?: GrantStmt): GrantStmt { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return _j; + }, + accessPriv(_p?: AccessPriv): AccessPriv { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return _j; + }, + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + copyStmt(_p?: CopyStmt): CopyStmt { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return _j; + }, + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return _j; + }, + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + createStmt(_p?: CreateStmt): CreateStmt { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + constraint(_p?: Constraint): Constraint { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return _j; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return _j; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return _j; + }, + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return _j; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return _j; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return _j; + }, + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return _j; + }, + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return _j; + }, + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return _j; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return _j; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return _j; + }, + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return _j; + }, + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return _j; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + defineStmt(_p?: DefineStmt): DefineStmt { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return _j; + }, + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return _j; + }, + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return _j; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return _j; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return _j; + }, + dropStmt(_p?: DropStmt): DropStmt { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return _j; + }, + truncateStmt(_p?: TruncateStmt): TruncateStmt { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + commentStmt(_p?: CommentStmt): CommentStmt { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return _j; + }, + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return _j; + }, + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return _j; + }, + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return _j; + }, + fetchStmt(_p?: FetchStmt): FetchStmt { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return _j; + }, + indexStmt(_p?: IndexStmt): IndexStmt { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return _j; + }, + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + statsElem(_p?: StatsElem): StatsElem { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return _j; + }, + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return _j; + }, + functionParameter(_p?: FunctionParameter): FunctionParameter { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return _j; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return _j; + }, + doStmt(_p?: DoStmt): DoStmt { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return _j; + }, + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + callStmt(_p?: CallStmt): CallStmt { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return _j; + }, + callContext(_p?: CallContext): CallContext { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return _j; + }, + renameStmt(_p?: RenameStmt): RenameStmt { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return _j; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return _j; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return _j; + }, + ruleStmt(_p?: RuleStmt): RuleStmt { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return _j; + }, + notifyStmt(_p?: NotifyStmt): NotifyStmt { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return _j; + }, + listenStmt(_p?: ListenStmt): ListenStmt { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return _j; + }, + transactionStmt(_p?: TransactionStmt): TransactionStmt { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return _j; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return _j; + }, + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return _j; + }, + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return _j; + }, + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return _j; + }, + viewStmt(_p?: ViewStmt): ViewStmt { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return _j; + }, + loadStmt(_p?: LoadStmt): LoadStmt { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return _j; + }, + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return _j; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + dropdbStmt(_p?: DropdbStmt): DropdbStmt { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return _j; + }, + clusterStmt(_p?: ClusterStmt): ClusterStmt { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return _j; + }, + vacuumStmt(_p?: VacuumStmt): VacuumStmt { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return _j; + }, + vacuumRelation(_p?: VacuumRelation): VacuumRelation { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return _j; + }, + explainStmt(_p?: ExplainStmt): ExplainStmt { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return _j; + }, + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return _j; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return _j; + }, + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { + const _j = {} as CheckPointStmt; + return _j; + }, + discardStmt(_p?: DiscardStmt): DiscardStmt { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return _j; + }, + lockStmt(_p?: LockStmt): LockStmt { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return _j; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return _j; + }, + reindexStmt(_p?: ReindexStmt): ReindexStmt { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return _j; + }, + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return _j; + }, + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return _j; + }, + prepareStmt(_p?: PrepareStmt): PrepareStmt { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return _j; + }, + executeStmt(_p?: ExecuteStmt): ExecuteStmt { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return _j; + }, + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return _j; + }, + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return _j; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return _j; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return _j; + }, + publicationTable(_p?: PublicationTable): PublicationTable { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return _j; + }, + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return _j; + }, + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return _j; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return _j; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return _j; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return _j; + }, + scanToken(_p?: ScanToken): ScanToken { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return _j; + } +};", + "file": "asts.ts", + }, +] +`; + +exports[`utils wrappedAstHelpers enabled 1`] = ` +[ + { + "code": "/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, NullTest, BooleanTest, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, MergeAction, TriggerTransition, JsonOutput, JsonKeyValue, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "./types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeUseOuterJoin", _p?.mergeUseOuterJoin); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matched", _p?.matched); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "location", _p?.location); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +};", + "file": "wrapped-asts.ts", + }, + { + "code": "/** +* This file was automatically generated by pg-proto-parser@latest. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import { OverridingKind, QuerySource, SortByDir, SortByNulls, SetQuantifier, A_Expr_Kind, RoleSpecType, TableLikeOption, DefElemAction, PartitionStrategy, PartitionRangeDatumKind, RTEKind, WCOKind, GroupingSetKind, CTEMaterialize, SetOperation, ObjectType, DropBehavior, AlterTableType, GrantTargetType, VariableSetKind, ConstrType, ImportForeignSchemaType, RoleStmtType, FetchDirection, FunctionParameterMode, TransactionStmtKind, ViewCheckOption, DiscardMode, ReindexObjectType, AlterTSConfigType, PublicationObjSpecType, AlterPublicationAction, AlterSubscriptionType, OnCommitAction, ParamKind, CoercionContext, CoercionForm, BoolExprType, SubLinkType, RowCompareType, MinMaxOp, SQLValueFunctionOp, XmlExprOp, XmlOptionType, JsonEncoding, JsonFormatType, JsonConstructorType, JsonValueType, NullTestType, BoolTestType, CmdType, JoinType, AggStrategy, AggSplit, SetOpCmd, SetOpStrategy, OnConflictAction, LimitOption, LockClauseStrength, LockWaitPolicy, LockTupleMode, KeywordKind, Token } from "./enums"; +export type Node = { + ParseResult: ParseResult; +} | { + ScanResult: ScanResult; +} | { + Integer: Integer; +} | { + Float: Float; +} | { + Boolean: Boolean; +} | { + String: String; +} | { + BitString: BitString; +} | { + List: List; +} | { + OidList: OidList; +} | { + IntList: IntList; +} | { + A_Const: A_Const; +} | { + Alias: Alias; +} | { + RangeVar: RangeVar; +} | { + TableFunc: TableFunc; +} | { + IntoClause: IntoClause; +} | { + Var: Var; +} | { + Param: Param; +} | { + Aggref: Aggref; +} | { + GroupingFunc: GroupingFunc; +} | { + WindowFunc: WindowFunc; +} | { + SubscriptingRef: SubscriptingRef; +} | { + FuncExpr: FuncExpr; +} | { + NamedArgExpr: NamedArgExpr; +} | { + OpExpr: OpExpr; +} | { + DistinctExpr: DistinctExpr; +} | { + NullIfExpr: NullIfExpr; +} | { + ScalarArrayOpExpr: ScalarArrayOpExpr; +} | { + BoolExpr: BoolExpr; +} | { + SubLink: SubLink; +} | { + SubPlan: SubPlan; +} | { + AlternativeSubPlan: AlternativeSubPlan; +} | { + FieldSelect: FieldSelect; +} | { + FieldStore: FieldStore; +} | { + RelabelType: RelabelType; +} | { + CoerceViaIO: CoerceViaIO; +} | { + ArrayCoerceExpr: ArrayCoerceExpr; +} | { + ConvertRowtypeExpr: ConvertRowtypeExpr; +} | { + CollateExpr: CollateExpr; +} | { + CaseExpr: CaseExpr; +} | { + CaseWhen: CaseWhen; +} | { + CaseTestExpr: CaseTestExpr; +} | { + ArrayExpr: ArrayExpr; +} | { + RowExpr: RowExpr; +} | { + RowCompareExpr: RowCompareExpr; +} | { + CoalesceExpr: CoalesceExpr; +} | { + MinMaxExpr: MinMaxExpr; +} | { + SQLValueFunction: SQLValueFunction; +} | { + XmlExpr: XmlExpr; +} | { + JsonFormat: JsonFormat; +} | { + JsonReturning: JsonReturning; +} | { + JsonValueExpr: JsonValueExpr; +} | { + JsonConstructorExpr: JsonConstructorExpr; +} | { + JsonIsPredicate: JsonIsPredicate; +} | { + NullTest: NullTest; +} | { + BooleanTest: BooleanTest; +} | { + CoerceToDomain: CoerceToDomain; +} | { + CoerceToDomainValue: CoerceToDomainValue; +} | { + SetToDefault: SetToDefault; +} | { + CurrentOfExpr: CurrentOfExpr; +} | { + NextValueExpr: NextValueExpr; +} | { + InferenceElem: InferenceElem; +} | { + TargetEntry: TargetEntry; +} | { + RangeTblRef: RangeTblRef; +} | { + JoinExpr: JoinExpr; +} | { + FromExpr: FromExpr; +} | { + OnConflictExpr: OnConflictExpr; +} | { + Query: Query; +} | { + TypeName: TypeName; +} | { + ColumnRef: ColumnRef; +} | { + ParamRef: ParamRef; +} | { + A_Expr: A_Expr; +} | { + TypeCast: TypeCast; +} | { + CollateClause: CollateClause; +} | { + RoleSpec: RoleSpec; +} | { + FuncCall: FuncCall; +} | { + A_Star: A_Star; +} | { + A_Indices: A_Indices; +} | { + A_Indirection: A_Indirection; +} | { + A_ArrayExpr: A_ArrayExpr; +} | { + ResTarget: ResTarget; +} | { + MultiAssignRef: MultiAssignRef; +} | { + SortBy: SortBy; +} | { + WindowDef: WindowDef; +} | { + RangeSubselect: RangeSubselect; +} | { + RangeFunction: RangeFunction; +} | { + RangeTableFunc: RangeTableFunc; +} | { + RangeTableFuncCol: RangeTableFuncCol; +} | { + RangeTableSample: RangeTableSample; +} | { + ColumnDef: ColumnDef; +} | { + TableLikeClause: TableLikeClause; +} | { + IndexElem: IndexElem; +} | { + DefElem: DefElem; +} | { + LockingClause: LockingClause; +} | { + XmlSerialize: XmlSerialize; +} | { + PartitionElem: PartitionElem; +} | { + PartitionSpec: PartitionSpec; +} | { + PartitionBoundSpec: PartitionBoundSpec; +} | { + PartitionRangeDatum: PartitionRangeDatum; +} | { + PartitionCmd: PartitionCmd; +} | { + RangeTblEntry: RangeTblEntry; +} | { + RTEPermissionInfo: RTEPermissionInfo; +} | { + RangeTblFunction: RangeTblFunction; +} | { + TableSampleClause: TableSampleClause; +} | { + WithCheckOption: WithCheckOption; +} | { + SortGroupClause: SortGroupClause; +} | { + GroupingSet: GroupingSet; +} | { + WindowClause: WindowClause; +} | { + RowMarkClause: RowMarkClause; +} | { + WithClause: WithClause; +} | { + InferClause: InferClause; +} | { + OnConflictClause: OnConflictClause; +} | { + CTESearchClause: CTESearchClause; +} | { + CTECycleClause: CTECycleClause; +} | { + CommonTableExpr: CommonTableExpr; +} | { + MergeWhenClause: MergeWhenClause; +} | { + MergeAction: MergeAction; +} | { + TriggerTransition: TriggerTransition; +} | { + JsonOutput: JsonOutput; +} | { + JsonKeyValue: JsonKeyValue; +} | { + JsonObjectConstructor: JsonObjectConstructor; +} | { + JsonArrayConstructor: JsonArrayConstructor; +} | { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; +} | { + JsonAggConstructor: JsonAggConstructor; +} | { + JsonObjectAgg: JsonObjectAgg; +} | { + JsonArrayAgg: JsonArrayAgg; +} | { + RawStmt: RawStmt; +} | { + InsertStmt: InsertStmt; +} | { + DeleteStmt: DeleteStmt; +} | { + UpdateStmt: UpdateStmt; +} | { + MergeStmt: MergeStmt; +} | { + SelectStmt: SelectStmt; +} | { + SetOperationStmt: SetOperationStmt; +} | { + ReturnStmt: ReturnStmt; +} | { + PLAssignStmt: PLAssignStmt; +} | { + CreateSchemaStmt: CreateSchemaStmt; +} | { + AlterTableStmt: AlterTableStmt; +} | { + ReplicaIdentityStmt: ReplicaIdentityStmt; +} | { + AlterTableCmd: AlterTableCmd; +} | { + AlterCollationStmt: AlterCollationStmt; +} | { + AlterDomainStmt: AlterDomainStmt; +} | { + GrantStmt: GrantStmt; +} | { + ObjectWithArgs: ObjectWithArgs; +} | { + AccessPriv: AccessPriv; +} | { + GrantRoleStmt: GrantRoleStmt; +} | { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; +} | { + CopyStmt: CopyStmt; +} | { + VariableSetStmt: VariableSetStmt; +} | { + VariableShowStmt: VariableShowStmt; +} | { + CreateStmt: CreateStmt; +} | { + Constraint: Constraint; +} | { + CreateTableSpaceStmt: CreateTableSpaceStmt; +} | { + DropTableSpaceStmt: DropTableSpaceStmt; +} | { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; +} | { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; +} | { + CreateExtensionStmt: CreateExtensionStmt; +} | { + AlterExtensionStmt: AlterExtensionStmt; +} | { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; +} | { + CreateFdwStmt: CreateFdwStmt; +} | { + AlterFdwStmt: AlterFdwStmt; +} | { + CreateForeignServerStmt: CreateForeignServerStmt; +} | { + AlterForeignServerStmt: AlterForeignServerStmt; +} | { + CreateForeignTableStmt: CreateForeignTableStmt; +} | { + CreateUserMappingStmt: CreateUserMappingStmt; +} | { + AlterUserMappingStmt: AlterUserMappingStmt; +} | { + DropUserMappingStmt: DropUserMappingStmt; +} | { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; +} | { + CreatePolicyStmt: CreatePolicyStmt; +} | { + AlterPolicyStmt: AlterPolicyStmt; +} | { + CreateAmStmt: CreateAmStmt; +} | { + CreateTrigStmt: CreateTrigStmt; +} | { + CreateEventTrigStmt: CreateEventTrigStmt; +} | { + AlterEventTrigStmt: AlterEventTrigStmt; +} | { + CreatePLangStmt: CreatePLangStmt; +} | { + CreateRoleStmt: CreateRoleStmt; +} | { + AlterRoleStmt: AlterRoleStmt; +} | { + AlterRoleSetStmt: AlterRoleSetStmt; +} | { + DropRoleStmt: DropRoleStmt; +} | { + CreateSeqStmt: CreateSeqStmt; +} | { + AlterSeqStmt: AlterSeqStmt; +} | { + DefineStmt: DefineStmt; +} | { + CreateDomainStmt: CreateDomainStmt; +} | { + CreateOpClassStmt: CreateOpClassStmt; +} | { + CreateOpClassItem: CreateOpClassItem; +} | { + CreateOpFamilyStmt: CreateOpFamilyStmt; +} | { + AlterOpFamilyStmt: AlterOpFamilyStmt; +} | { + DropStmt: DropStmt; +} | { + TruncateStmt: TruncateStmt; +} | { + CommentStmt: CommentStmt; +} | { + SecLabelStmt: SecLabelStmt; +} | { + DeclareCursorStmt: DeclareCursorStmt; +} | { + ClosePortalStmt: ClosePortalStmt; +} | { + FetchStmt: FetchStmt; +} | { + IndexStmt: IndexStmt; +} | { + CreateStatsStmt: CreateStatsStmt; +} | { + StatsElem: StatsElem; +} | { + AlterStatsStmt: AlterStatsStmt; +} | { + CreateFunctionStmt: CreateFunctionStmt; +} | { + FunctionParameter: FunctionParameter; +} | { + AlterFunctionStmt: AlterFunctionStmt; +} | { + DoStmt: DoStmt; +} | { + InlineCodeBlock: InlineCodeBlock; +} | { + CallStmt: CallStmt; +} | { + CallContext: CallContext; +} | { + RenameStmt: RenameStmt; +} | { + AlterObjectDependsStmt: AlterObjectDependsStmt; +} | { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; +} | { + AlterOwnerStmt: AlterOwnerStmt; +} | { + AlterOperatorStmt: AlterOperatorStmt; +} | { + AlterTypeStmt: AlterTypeStmt; +} | { + RuleStmt: RuleStmt; +} | { + NotifyStmt: NotifyStmt; +} | { + ListenStmt: ListenStmt; +} | { + UnlistenStmt: UnlistenStmt; +} | { + TransactionStmt: TransactionStmt; +} | { + CompositeTypeStmt: CompositeTypeStmt; +} | { + CreateEnumStmt: CreateEnumStmt; +} | { + CreateRangeStmt: CreateRangeStmt; +} | { + AlterEnumStmt: AlterEnumStmt; +} | { + ViewStmt: ViewStmt; +} | { + LoadStmt: LoadStmt; +} | { + CreatedbStmt: CreatedbStmt; +} | { + AlterDatabaseStmt: AlterDatabaseStmt; +} | { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; +} | { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; +} | { + DropdbStmt: DropdbStmt; +} | { + AlterSystemStmt: AlterSystemStmt; +} | { + ClusterStmt: ClusterStmt; +} | { + VacuumStmt: VacuumStmt; +} | { + VacuumRelation: VacuumRelation; +} | { + ExplainStmt: ExplainStmt; +} | { + CreateTableAsStmt: CreateTableAsStmt; +} | { + RefreshMatViewStmt: RefreshMatViewStmt; +} | { + CheckPointStmt: CheckPointStmt; +} | { + DiscardStmt: DiscardStmt; +} | { + LockStmt: LockStmt; +} | { + ConstraintsSetStmt: ConstraintsSetStmt; +} | { + ReindexStmt: ReindexStmt; +} | { + CreateConversionStmt: CreateConversionStmt; +} | { + CreateCastStmt: CreateCastStmt; +} | { + CreateTransformStmt: CreateTransformStmt; +} | { + PrepareStmt: PrepareStmt; +} | { + ExecuteStmt: ExecuteStmt; +} | { + DeallocateStmt: DeallocateStmt; +} | { + DropOwnedStmt: DropOwnedStmt; +} | { + ReassignOwnedStmt: ReassignOwnedStmt; +} | { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; +} | { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; +} | { + PublicationTable: PublicationTable; +} | { + PublicationObjSpec: PublicationObjSpec; +} | { + CreatePublicationStmt: CreatePublicationStmt; +} | { + AlterPublicationStmt: AlterPublicationStmt; +} | { + CreateSubscriptionStmt: CreateSubscriptionStmt; +} | { + AlterSubscriptionStmt: AlterSubscriptionStmt; +} | { + DropSubscriptionStmt: DropSubscriptionStmt; +} | { + ScanToken: ScanToken; +}; +export interface ParseResult { + version?: number; + stmts?: RawStmt[]; +} +export interface ScanResult { + version?: number; + tokens?: ScanToken[]; +} +export interface Integer { + ival?: number; +} +export interface Float { + fval?: string; +} +export interface Boolean { + boolval?: boolean; +} +export interface String { + sval?: string; +} +export interface BitString { + bsval?: string; +} +export interface List { + items?: Node[]; +} +export interface OidList { + items?: Node[]; +} +export interface IntList { + items?: Node[]; +} +export interface A_Const { + ival?: Integer; + fval?: Float; + boolval?: Boolean; + sval?: String; + bsval?: BitString; + isnull?: boolean; + location?: number; +} +export interface Alias { + aliasname?: string; + colnames?: Node[]; +} +export interface RangeVar { + catalogname?: string; + schemaname?: string; + relname?: string; + inh?: boolean; + relpersistence?: string; + alias?: Alias; + location?: number; +} +export interface TableFunc { + ns_uris?: Node[]; + ns_names?: Node[]; + docexpr?: Node; + rowexpr?: Node; + colnames?: Node[]; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + colexprs?: Node[]; + coldefexprs?: Node[]; + notnulls?: bigint[]; + ordinalitycol?: number; + location?: number; +} +export interface IntoClause { + rel?: RangeVar; + colNames?: Node[]; + accessMethod?: string; + options?: Node[]; + onCommit?: OnCommitAction; + tableSpaceName?: string; + viewQuery?: Node; + skipData?: boolean; +} +export interface Var { + xpr?: Node; + varno?: number; + varattno?: number; + vartype?: number; + vartypmod?: number; + varcollid?: number; + varnullingrels?: bigint[]; + varlevelsup?: number; + location?: number; +} +export interface Param { + xpr?: Node; + paramkind?: ParamKind; + paramid?: number; + paramtype?: number; + paramtypmod?: number; + paramcollid?: number; + location?: number; +} +export interface Aggref { + xpr?: Node; + aggfnoid?: number; + aggtype?: number; + aggcollid?: number; + inputcollid?: number; + aggargtypes?: Node[]; + aggdirectargs?: Node[]; + args?: Node[]; + aggorder?: Node[]; + aggdistinct?: Node[]; + aggfilter?: Node; + aggstar?: boolean; + aggvariadic?: boolean; + aggkind?: string; + agglevelsup?: number; + aggsplit?: AggSplit; + aggno?: number; + aggtransno?: number; + location?: number; +} +export interface GroupingFunc { + xpr?: Node; + args?: Node[]; + refs?: Node[]; + agglevelsup?: number; + location?: number; +} +export interface WindowFunc { + xpr?: Node; + winfnoid?: number; + wintype?: number; + wincollid?: number; + inputcollid?: number; + args?: Node[]; + aggfilter?: Node; + winref?: number; + winstar?: boolean; + winagg?: boolean; + location?: number; +} +export interface SubscriptingRef { + xpr?: Node; + refcontainertype?: number; + refelemtype?: number; + refrestype?: number; + reftypmod?: number; + refcollid?: number; + refupperindexpr?: Node[]; + reflowerindexpr?: Node[]; + refexpr?: Node; + refassgnexpr?: Node; +} +export interface FuncExpr { + xpr?: Node; + funcid?: number; + funcresulttype?: number; + funcretset?: boolean; + funcvariadic?: boolean; + funcformat?: CoercionForm; + funccollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NamedArgExpr { + xpr?: Node; + arg?: Node; + name?: string; + argnumber?: number; + location?: number; +} +export interface OpExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface DistinctExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface NullIfExpr { + xpr?: Node; + opno?: number; + opresulttype?: number; + opretset?: boolean; + opcollid?: number; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface ScalarArrayOpExpr { + xpr?: Node; + opno?: number; + useOr?: boolean; + inputcollid?: number; + args?: Node[]; + location?: number; +} +export interface BoolExpr { + xpr?: Node; + boolop?: BoolExprType; + args?: Node[]; + location?: number; +} +export interface SubLink { + xpr?: Node; + subLinkType?: SubLinkType; + subLinkId?: number; + testexpr?: Node; + operName?: Node[]; + subselect?: Node; + location?: number; +} +export interface SubPlan { + xpr?: Node; + subLinkType?: SubLinkType; + testexpr?: Node; + paramIds?: Node[]; + plan_id?: number; + plan_name?: string; + firstColType?: number; + firstColTypmod?: number; + firstColCollation?: number; + useHashTable?: boolean; + unknownEqFalse?: boolean; + parallel_safe?: boolean; + setParam?: Node[]; + parParam?: Node[]; + args?: Node[]; + startup_cost?: number; + per_call_cost?: number; +} +export interface AlternativeSubPlan { + xpr?: Node; + subplans?: Node[]; +} +export interface FieldSelect { + xpr?: Node; + arg?: Node; + fieldnum?: number; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; +} +export interface FieldStore { + xpr?: Node; + arg?: Node; + newvals?: Node[]; + fieldnums?: Node[]; + resulttype?: number; +} +export interface RelabelType { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + relabelformat?: CoercionForm; + location?: number; +} +export interface CoerceViaIO { + xpr?: Node; + arg?: Node; + resulttype?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ArrayCoerceExpr { + xpr?: Node; + arg?: Node; + elemexpr?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coerceformat?: CoercionForm; + location?: number; +} +export interface ConvertRowtypeExpr { + xpr?: Node; + arg?: Node; + resulttype?: number; + convertformat?: CoercionForm; + location?: number; +} +export interface CollateExpr { + xpr?: Node; + arg?: Node; + collOid?: number; + location?: number; +} +export interface CaseExpr { + xpr?: Node; + casetype?: number; + casecollid?: number; + arg?: Node; + args?: Node[]; + defresult?: Node; + location?: number; +} +export interface CaseWhen { + xpr?: Node; + expr?: Node; + result?: Node; + location?: number; +} +export interface CaseTestExpr { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; +} +export interface ArrayExpr { + xpr?: Node; + array_typeid?: number; + array_collid?: number; + element_typeid?: number; + elements?: Node[]; + multidims?: boolean; + location?: number; +} +export interface RowExpr { + xpr?: Node; + args?: Node[]; + row_typeid?: number; + row_format?: CoercionForm; + colnames?: Node[]; + location?: number; +} +export interface RowCompareExpr { + xpr?: Node; + rctype?: RowCompareType; + opnos?: Node[]; + opfamilies?: Node[]; + inputcollids?: Node[]; + largs?: Node[]; + rargs?: Node[]; +} +export interface CoalesceExpr { + xpr?: Node; + coalescetype?: number; + coalescecollid?: number; + args?: Node[]; + location?: number; +} +export interface MinMaxExpr { + xpr?: Node; + minmaxtype?: number; + minmaxcollid?: number; + inputcollid?: number; + op?: MinMaxOp; + args?: Node[]; + location?: number; +} +export interface SQLValueFunction { + xpr?: Node; + op?: SQLValueFunctionOp; + type?: number; + typmod?: number; + location?: number; +} +export interface XmlExpr { + xpr?: Node; + op?: XmlExprOp; + name?: string; + named_args?: Node[]; + arg_names?: Node[]; + args?: Node[]; + xmloption?: XmlOptionType; + indent?: boolean; + type?: number; + typmod?: number; + location?: number; +} +export interface JsonFormat { + format_type?: JsonFormatType; + encoding?: JsonEncoding; + location?: number; +} +export interface JsonReturning { + format?: JsonFormat; + typid?: number; + typmod?: number; +} +export interface JsonValueExpr { + raw_expr?: Node; + formatted_expr?: Node; + format?: JsonFormat; +} +export interface JsonConstructorExpr { + xpr?: Node; + type?: JsonConstructorType; + args?: Node[]; + func?: Node; + coercion?: Node; + returning?: JsonReturning; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonIsPredicate { + expr?: Node; + format?: JsonFormat; + item_type?: JsonValueType; + unique_keys?: boolean; + location?: number; +} +export interface NullTest { + xpr?: Node; + arg?: Node; + nulltesttype?: NullTestType; + argisrow?: boolean; + location?: number; +} +export interface BooleanTest { + xpr?: Node; + arg?: Node; + booltesttype?: BoolTestType; + location?: number; +} +export interface CoerceToDomain { + xpr?: Node; + arg?: Node; + resulttype?: number; + resulttypmod?: number; + resultcollid?: number; + coercionformat?: CoercionForm; + location?: number; +} +export interface CoerceToDomainValue { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface SetToDefault { + xpr?: Node; + typeId?: number; + typeMod?: number; + collation?: number; + location?: number; +} +export interface CurrentOfExpr { + xpr?: Node; + cvarno?: number; + cursor_name?: string; + cursor_param?: number; +} +export interface NextValueExpr { + xpr?: Node; + seqid?: number; + typeId?: number; +} +export interface InferenceElem { + xpr?: Node; + expr?: Node; + infercollid?: number; + inferopclass?: number; +} +export interface TargetEntry { + xpr?: Node; + expr?: Node; + resno?: number; + resname?: string; + ressortgroupref?: number; + resorigtbl?: number; + resorigcol?: number; + resjunk?: boolean; +} +export interface RangeTblRef { + rtindex?: number; +} +export interface JoinExpr { + jointype?: JoinType; + isNatural?: boolean; + larg?: Node; + rarg?: Node; + usingClause?: Node[]; + join_using_alias?: Alias; + quals?: Node; + alias?: Alias; + rtindex?: number; +} +export interface FromExpr { + fromlist?: Node[]; + quals?: Node; +} +export interface OnConflictExpr { + action?: OnConflictAction; + arbiterElems?: Node[]; + arbiterWhere?: Node; + constraint?: number; + onConflictSet?: Node[]; + onConflictWhere?: Node; + exclRelIndex?: number; + exclRelTlist?: Node[]; +} +export interface Query { + commandType?: CmdType; + querySource?: QuerySource; + canSetTag?: boolean; + utilityStmt?: Node; + resultRelation?: number; + hasAggs?: boolean; + hasWindowFuncs?: boolean; + hasTargetSRFs?: boolean; + hasSubLinks?: boolean; + hasDistinctOn?: boolean; + hasRecursive?: boolean; + hasModifyingCTE?: boolean; + hasForUpdate?: boolean; + hasRowSecurity?: boolean; + isReturn?: boolean; + cteList?: Node[]; + rtable?: Node[]; + rteperminfos?: Node[]; + jointree?: FromExpr; + mergeActionList?: Node[]; + mergeUseOuterJoin?: boolean; + targetList?: Node[]; + override?: OverridingKind; + onConflict?: OnConflictExpr; + returningList?: Node[]; + groupClause?: Node[]; + groupDistinct?: boolean; + groupingSets?: Node[]; + havingQual?: Node; + windowClause?: Node[]; + distinctClause?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + rowMarks?: Node[]; + setOperations?: Node; + constraintDeps?: Node[]; + withCheckOptions?: Node[]; + stmt_location?: number; + stmt_len?: number; +} +export interface TypeName { + names?: Node[]; + typeOid?: number; + setof?: boolean; + pct_type?: boolean; + typmods?: Node[]; + typemod?: number; + arrayBounds?: Node[]; + location?: number; +} +export interface ColumnRef { + fields?: Node[]; + location?: number; +} +export interface ParamRef { + number?: number; + location?: number; +} +export interface A_Expr { + kind?: A_Expr_Kind; + name?: Node[]; + lexpr?: Node; + rexpr?: Node; + location?: number; +} +export interface TypeCast { + arg?: Node; + typeName?: TypeName; + location?: number; +} +export interface CollateClause { + arg?: Node; + collname?: Node[]; + location?: number; +} +export interface RoleSpec { + roletype?: RoleSpecType; + rolename?: string; + location?: number; +} +export interface FuncCall { + funcname?: Node[]; + args?: Node[]; + agg_order?: Node[]; + agg_filter?: Node; + over?: WindowDef; + agg_within_group?: boolean; + agg_star?: boolean; + agg_distinct?: boolean; + func_variadic?: boolean; + funcformat?: CoercionForm; + location?: number; +} +export interface A_Star {} +export interface A_Indices { + is_slice?: boolean; + lidx?: Node; + uidx?: Node; +} +export interface A_Indirection { + arg?: Node; + indirection?: Node[]; +} +export interface A_ArrayExpr { + elements?: Node[]; + location?: number; +} +export interface ResTarget { + name?: string; + indirection?: Node[]; + val?: Node; + location?: number; +} +export interface MultiAssignRef { + source?: Node; + colno?: number; + ncolumns?: number; +} +export interface SortBy { + node?: Node; + sortby_dir?: SortByDir; + sortby_nulls?: SortByNulls; + useOp?: Node[]; + location?: number; +} +export interface WindowDef { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + location?: number; +} +export interface RangeSubselect { + lateral?: boolean; + subquery?: Node; + alias?: Alias; +} +export interface RangeFunction { + lateral?: boolean; + ordinality?: boolean; + is_rowsfrom?: boolean; + functions?: Node[]; + alias?: Alias; + coldeflist?: Node[]; +} +export interface RangeTableFunc { + lateral?: boolean; + docexpr?: Node; + rowexpr?: Node; + namespaces?: Node[]; + columns?: Node[]; + alias?: Alias; + location?: number; +} +export interface RangeTableFuncCol { + colname?: string; + typeName?: TypeName; + for_ordinality?: boolean; + is_not_null?: boolean; + colexpr?: Node; + coldefexpr?: Node; + location?: number; +} +export interface RangeTableSample { + relation?: Node; + method?: Node[]; + args?: Node[]; + repeatable?: Node; + location?: number; +} +export interface ColumnDef { + colname?: string; + typeName?: TypeName; + compression?: string; + inhcount?: number; + is_local?: boolean; + is_not_null?: boolean; + is_from_type?: boolean; + storage?: string; + storage_name?: string; + raw_default?: Node; + cooked_default?: Node; + identity?: string; + identitySequence?: RangeVar; + generated?: string; + collClause?: CollateClause; + collOid?: number; + constraints?: Node[]; + fdwoptions?: Node[]; + location?: number; +} +export interface TableLikeClause { + relation?: RangeVar; + options?: number; + relationOid?: number; +} +export interface IndexElem { + name?: string; + expr?: Node; + indexcolname?: string; + collation?: Node[]; + opclass?: Node[]; + opclassopts?: Node[]; + ordering?: SortByDir; + nulls_ordering?: SortByNulls; +} +export interface DefElem { + defnamespace?: string; + defname?: string; + arg?: Node; + defaction?: DefElemAction; + location?: number; +} +export interface LockingClause { + lockedRels?: Node[]; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; +} +export interface XmlSerialize { + xmloption?: XmlOptionType; + expr?: Node; + typeName?: TypeName; + indent?: boolean; + location?: number; +} +export interface PartitionElem { + name?: string; + expr?: Node; + collation?: Node[]; + opclass?: Node[]; + location?: number; +} +export interface PartitionSpec { + strategy?: PartitionStrategy; + partParams?: Node[]; + location?: number; +} +export interface PartitionBoundSpec { + strategy?: string; + is_default?: boolean; + modulus?: number; + remainder?: number; + listdatums?: Node[]; + lowerdatums?: Node[]; + upperdatums?: Node[]; + location?: number; +} +export interface PartitionRangeDatum { + kind?: PartitionRangeDatumKind; + value?: Node; + location?: number; +} +export interface PartitionCmd { + name?: RangeVar; + bound?: PartitionBoundSpec; + concurrent?: boolean; +} +export interface RangeTblEntry { + rtekind?: RTEKind; + relid?: number; + relkind?: string; + rellockmode?: number; + tablesample?: TableSampleClause; + perminfoindex?: number; + subquery?: Query; + security_barrier?: boolean; + jointype?: JoinType; + joinmergedcols?: number; + joinaliasvars?: Node[]; + joinleftcols?: Node[]; + joinrightcols?: Node[]; + join_using_alias?: Alias; + functions?: Node[]; + funcordinality?: boolean; + tablefunc?: TableFunc; + values_lists?: Node[]; + ctename?: string; + ctelevelsup?: number; + self_reference?: boolean; + coltypes?: Node[]; + coltypmods?: Node[]; + colcollations?: Node[]; + enrname?: string; + enrtuples?: number; + alias?: Alias; + eref?: Alias; + lateral?: boolean; + inh?: boolean; + inFromCl?: boolean; + securityQuals?: Node[]; +} +export interface RTEPermissionInfo { + relid?: number; + inh?: boolean; + requiredPerms?: bigint; + checkAsUser?: number; + selectedCols?: bigint[]; + insertedCols?: bigint[]; + updatedCols?: bigint[]; +} +export interface RangeTblFunction { + funcexpr?: Node; + funccolcount?: number; + funccolnames?: Node[]; + funccoltypes?: Node[]; + funccoltypmods?: Node[]; + funccolcollations?: Node[]; + funcparams?: bigint[]; +} +export interface TableSampleClause { + tsmhandler?: number; + args?: Node[]; + repeatable?: Node; +} +export interface WithCheckOption { + kind?: WCOKind; + relname?: string; + polname?: string; + qual?: Node; + cascaded?: boolean; +} +export interface SortGroupClause { + tleSortGroupRef?: number; + eqop?: number; + sortop?: number; + nulls_first?: boolean; + hashable?: boolean; +} +export interface GroupingSet { + kind?: GroupingSetKind; + content?: Node[]; + location?: number; +} +export interface WindowClause { + name?: string; + refname?: string; + partitionClause?: Node[]; + orderClause?: Node[]; + frameOptions?: number; + startOffset?: Node; + endOffset?: Node; + runCondition?: Node[]; + startInRangeFunc?: number; + endInRangeFunc?: number; + inRangeColl?: number; + inRangeAsc?: boolean; + inRangeNullsFirst?: boolean; + winref?: number; + copiedOrder?: boolean; +} +export interface RowMarkClause { + rti?: number; + strength?: LockClauseStrength; + waitPolicy?: LockWaitPolicy; + pushedDown?: boolean; +} +export interface WithClause { + ctes?: Node[]; + recursive?: boolean; + location?: number; +} +export interface InferClause { + indexElems?: Node[]; + whereClause?: Node; + conname?: string; + location?: number; +} +export interface OnConflictClause { + action?: OnConflictAction; + infer?: InferClause; + targetList?: Node[]; + whereClause?: Node; + location?: number; +} +export interface CTESearchClause { + search_col_list?: Node[]; + search_breadth_first?: boolean; + search_seq_column?: string; + location?: number; +} +export interface CTECycleClause { + cycle_col_list?: Node[]; + cycle_mark_column?: string; + cycle_mark_value?: Node; + cycle_mark_default?: Node; + cycle_path_column?: string; + location?: number; + cycle_mark_type?: number; + cycle_mark_typmod?: number; + cycle_mark_collation?: number; + cycle_mark_neop?: number; +} +export interface CommonTableExpr { + ctename?: string; + aliascolnames?: Node[]; + ctematerialized?: CTEMaterialize; + ctequery?: Node; + search_clause?: CTESearchClause; + cycle_clause?: CTECycleClause; + location?: number; + cterecursive?: boolean; + cterefcount?: number; + ctecolnames?: Node[]; + ctecoltypes?: Node[]; + ctecoltypmods?: Node[]; + ctecolcollations?: Node[]; +} +export interface MergeWhenClause { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + condition?: Node; + targetList?: Node[]; + values?: Node[]; +} +export interface MergeAction { + matched?: boolean; + commandType?: CmdType; + override?: OverridingKind; + qual?: Node; + targetList?: Node[]; + updateColnos?: Node[]; +} +export interface TriggerTransition { + name?: string; + isNew?: boolean; + isTable?: boolean; +} +export interface JsonOutput { + typeName?: TypeName; + returning?: JsonReturning; +} +export interface JsonKeyValue { + key?: Node; + value?: JsonValueExpr; +} +export interface JsonObjectConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + unique?: boolean; + location?: number; +} +export interface JsonArrayConstructor { + exprs?: Node[]; + output?: JsonOutput; + absent_on_null?: boolean; + location?: number; +} +export interface JsonArrayQueryConstructor { + query?: Node; + output?: JsonOutput; + format?: JsonFormat; + absent_on_null?: boolean; + location?: number; +} +export interface JsonAggConstructor { + output?: JsonOutput; + agg_filter?: Node; + agg_order?: Node[]; + over?: WindowDef; + location?: number; +} +export interface JsonObjectAgg { + constructor?: JsonAggConstructor; + arg?: JsonKeyValue; + absent_on_null?: boolean; + unique?: boolean; +} +export interface JsonArrayAgg { + constructor?: JsonAggConstructor; + arg?: JsonValueExpr; + absent_on_null?: boolean; +} +export interface RawStmt { + stmt?: Node; + stmt_location?: number; + stmt_len?: number; +} +export interface InsertStmt { + relation?: RangeVar; + cols?: Node[]; + selectStmt?: Node; + onConflictClause?: OnConflictClause; + returningList?: Node[]; + withClause?: WithClause; + override?: OverridingKind; +} +export interface DeleteStmt { + relation?: RangeVar; + usingClause?: Node[]; + whereClause?: Node; + returningList?: Node[]; + withClause?: WithClause; +} +export interface UpdateStmt { + relation?: RangeVar; + targetList?: Node[]; + whereClause?: Node; + fromClause?: Node[]; + returningList?: Node[]; + withClause?: WithClause; +} +export interface MergeStmt { + relation?: RangeVar; + sourceRelation?: Node; + joinCondition?: Node; + mergeWhenClauses?: Node[]; + withClause?: WithClause; +} +export interface SelectStmt { + distinctClause?: Node[]; + intoClause?: IntoClause; + targetList?: Node[]; + fromClause?: Node[]; + whereClause?: Node; + groupClause?: Node[]; + groupDistinct?: boolean; + havingClause?: Node; + windowClause?: Node[]; + valuesLists?: Node[]; + sortClause?: Node[]; + limitOffset?: Node; + limitCount?: Node; + limitOption?: LimitOption; + lockingClause?: Node[]; + withClause?: WithClause; + op?: SetOperation; + all?: boolean; + larg?: SelectStmt; + rarg?: SelectStmt; +} +export interface SetOperationStmt { + op?: SetOperation; + all?: boolean; + larg?: Node; + rarg?: Node; + colTypes?: Node[]; + colTypmods?: Node[]; + colCollations?: Node[]; + groupClauses?: Node[]; +} +export interface ReturnStmt { + returnval?: Node; +} +export interface PLAssignStmt { + name?: string; + indirection?: Node[]; + nnames?: number; + val?: SelectStmt; + location?: number; +} +export interface CreateSchemaStmt { + schemaname?: string; + authrole?: RoleSpec; + schemaElts?: Node[]; + if_not_exists?: boolean; +} +export interface AlterTableStmt { + relation?: RangeVar; + cmds?: Node[]; + objtype?: ObjectType; + missing_ok?: boolean; +} +export interface ReplicaIdentityStmt { + identity_type?: string; + name?: string; +} +export interface AlterTableCmd { + subtype?: AlterTableType; + name?: string; + num?: number; + newowner?: RoleSpec; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; + recurse?: boolean; +} +export interface AlterCollationStmt { + collname?: Node[]; +} +export interface AlterDomainStmt { + subtype?: string; + typeName?: Node[]; + name?: string; + def?: Node; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface GrantStmt { + is_grant?: boolean; + targtype?: GrantTargetType; + objtype?: ObjectType; + objects?: Node[]; + privileges?: Node[]; + grantees?: Node[]; + grant_option?: boolean; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface ObjectWithArgs { + objname?: Node[]; + objargs?: Node[]; + objfuncargs?: Node[]; + args_unspecified?: boolean; +} +export interface AccessPriv { + priv_name?: string; + cols?: Node[]; +} +export interface GrantRoleStmt { + granted_roles?: Node[]; + grantee_roles?: Node[]; + is_grant?: boolean; + opt?: Node[]; + grantor?: RoleSpec; + behavior?: DropBehavior; +} +export interface AlterDefaultPrivilegesStmt { + options?: Node[]; + action?: GrantStmt; +} +export interface CopyStmt { + relation?: RangeVar; + query?: Node; + attlist?: Node[]; + is_from?: boolean; + is_program?: boolean; + filename?: string; + options?: Node[]; + whereClause?: Node; +} +export interface VariableSetStmt { + kind?: VariableSetKind; + name?: string; + args?: Node[]; + is_local?: boolean; +} +export interface VariableShowStmt { + name?: string; +} +export interface CreateStmt { + relation?: RangeVar; + tableElts?: Node[]; + inhRelations?: Node[]; + partbound?: PartitionBoundSpec; + partspec?: PartitionSpec; + ofTypename?: TypeName; + constraints?: Node[]; + options?: Node[]; + oncommit?: OnCommitAction; + tablespacename?: string; + accessMethod?: string; + if_not_exists?: boolean; +} +export interface Constraint { + contype?: ConstrType; + conname?: string; + deferrable?: boolean; + initdeferred?: boolean; + location?: number; + is_no_inherit?: boolean; + raw_expr?: Node; + cooked_expr?: string; + generated_when?: string; + nulls_not_distinct?: boolean; + keys?: Node[]; + including?: Node[]; + exclusions?: Node[]; + options?: Node[]; + indexname?: string; + indexspace?: string; + reset_default_tblspc?: boolean; + access_method?: string; + where_clause?: Node; + pktable?: RangeVar; + fk_attrs?: Node[]; + pk_attrs?: Node[]; + fk_matchtype?: string; + fk_upd_action?: string; + fk_del_action?: string; + fk_del_set_cols?: Node[]; + old_conpfeqop?: Node[]; + old_pktable_oid?: number; + skip_validation?: boolean; + initially_valid?: boolean; +} +export interface CreateTableSpaceStmt { + tablespacename?: string; + owner?: RoleSpec; + location?: string; + options?: Node[]; +} +export interface DropTableSpaceStmt { + tablespacename?: string; + missing_ok?: boolean; +} +export interface AlterTableSpaceOptionsStmt { + tablespacename?: string; + options?: Node[]; + isReset?: boolean; +} +export interface AlterTableMoveAllStmt { + orig_tablespacename?: string; + objtype?: ObjectType; + roles?: Node[]; + new_tablespacename?: string; + nowait?: boolean; +} +export interface CreateExtensionStmt { + extname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterExtensionStmt { + extname?: string; + options?: Node[]; +} +export interface AlterExtensionContentsStmt { + extname?: string; + action?: number; + objtype?: ObjectType; + object?: Node; +} +export interface CreateFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface AlterFdwStmt { + fdwname?: string; + func_options?: Node[]; + options?: Node[]; +} +export interface CreateForeignServerStmt { + servername?: string; + servertype?: string; + version?: string; + fdwname?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterForeignServerStmt { + servername?: string; + version?: string; + options?: Node[]; + has_version?: boolean; +} +export interface CreateForeignTableStmt { + base?: CreateStmt; + servername?: string; + options?: Node[]; +} +export interface CreateUserMappingStmt { + user?: RoleSpec; + servername?: string; + if_not_exists?: boolean; + options?: Node[]; +} +export interface AlterUserMappingStmt { + user?: RoleSpec; + servername?: string; + options?: Node[]; +} +export interface DropUserMappingStmt { + user?: RoleSpec; + servername?: string; + missing_ok?: boolean; +} +export interface ImportForeignSchemaStmt { + server_name?: string; + remote_schema?: string; + local_schema?: string; + list_type?: ImportForeignSchemaType; + table_list?: Node[]; + options?: Node[]; +} +export interface CreatePolicyStmt { + policy_name?: string; + table?: RangeVar; + cmd_name?: string; + permissive?: boolean; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface AlterPolicyStmt { + policy_name?: string; + table?: RangeVar; + roles?: Node[]; + qual?: Node; + with_check?: Node; +} +export interface CreateAmStmt { + amname?: string; + handler_name?: Node[]; + amtype?: string; +} +export interface CreateTrigStmt { + replace?: boolean; + isconstraint?: boolean; + trigname?: string; + relation?: RangeVar; + funcname?: Node[]; + args?: Node[]; + row?: boolean; + timing?: number; + events?: number; + columns?: Node[]; + whenClause?: Node; + transitionRels?: Node[]; + deferrable?: boolean; + initdeferred?: boolean; + constrrel?: RangeVar; +} +export interface CreateEventTrigStmt { + trigname?: string; + eventname?: string; + whenclause?: Node[]; + funcname?: Node[]; +} +export interface AlterEventTrigStmt { + trigname?: string; + tgenabled?: string; +} +export interface CreatePLangStmt { + replace?: boolean; + plname?: string; + plhandler?: Node[]; + plinline?: Node[]; + plvalidator?: Node[]; + pltrusted?: boolean; +} +export interface CreateRoleStmt { + stmt_type?: RoleStmtType; + role?: string; + options?: Node[]; +} +export interface AlterRoleStmt { + role?: RoleSpec; + options?: Node[]; + action?: number; +} +export interface AlterRoleSetStmt { + role?: RoleSpec; + database?: string; + setstmt?: VariableSetStmt; +} +export interface DropRoleStmt { + roles?: Node[]; + missing_ok?: boolean; +} +export interface CreateSeqStmt { + sequence?: RangeVar; + options?: Node[]; + ownerId?: number; + for_identity?: boolean; + if_not_exists?: boolean; +} +export interface AlterSeqStmt { + sequence?: RangeVar; + options?: Node[]; + for_identity?: boolean; + missing_ok?: boolean; +} +export interface DefineStmt { + kind?: ObjectType; + oldstyle?: boolean; + defnames?: Node[]; + args?: Node[]; + definition?: Node[]; + if_not_exists?: boolean; + replace?: boolean; +} +export interface CreateDomainStmt { + domainname?: Node[]; + typeName?: TypeName; + collClause?: CollateClause; + constraints?: Node[]; +} +export interface CreateOpClassStmt { + opclassname?: Node[]; + opfamilyname?: Node[]; + amname?: string; + datatype?: TypeName; + items?: Node[]; + isDefault?: boolean; +} +export interface CreateOpClassItem { + itemtype?: number; + name?: ObjectWithArgs; + number?: number; + order_family?: Node[]; + class_args?: Node[]; + storedtype?: TypeName; +} +export interface CreateOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; +} +export interface AlterOpFamilyStmt { + opfamilyname?: Node[]; + amname?: string; + isDrop?: boolean; + items?: Node[]; +} +export interface DropStmt { + objects?: Node[]; + removeType?: ObjectType; + behavior?: DropBehavior; + missing_ok?: boolean; + concurrent?: boolean; +} +export interface TruncateStmt { + relations?: Node[]; + restart_seqs?: boolean; + behavior?: DropBehavior; +} +export interface CommentStmt { + objtype?: ObjectType; + object?: Node; + comment?: string; +} +export interface SecLabelStmt { + objtype?: ObjectType; + object?: Node; + provider?: string; + label?: string; +} +export interface DeclareCursorStmt { + portalname?: string; + options?: number; + query?: Node; +} +export interface ClosePortalStmt { + portalname?: string; +} +export interface FetchStmt { + direction?: FetchDirection; + howMany?: bigint; + portalname?: string; + ismove?: boolean; +} +export interface IndexStmt { + idxname?: string; + relation?: RangeVar; + accessMethod?: string; + tableSpace?: string; + indexParams?: Node[]; + indexIncludingParams?: Node[]; + options?: Node[]; + whereClause?: Node; + excludeOpNames?: Node[]; + idxcomment?: string; + indexOid?: number; + oldNumber?: number; + oldCreateSubid?: number; + oldFirstRelfilelocatorSubid?: number; + unique?: boolean; + nulls_not_distinct?: boolean; + primary?: boolean; + isconstraint?: boolean; + deferrable?: boolean; + initdeferred?: boolean; + transformed?: boolean; + concurrent?: boolean; + if_not_exists?: boolean; + reset_default_tblspc?: boolean; +} +export interface CreateStatsStmt { + defnames?: Node[]; + stat_types?: Node[]; + exprs?: Node[]; + relations?: Node[]; + stxcomment?: string; + transformed?: boolean; + if_not_exists?: boolean; +} +export interface StatsElem { + name?: string; + expr?: Node; +} +export interface AlterStatsStmt { + defnames?: Node[]; + stxstattarget?: number; + missing_ok?: boolean; +} +export interface CreateFunctionStmt { + is_procedure?: boolean; + replace?: boolean; + funcname?: Node[]; + parameters?: Node[]; + returnType?: TypeName; + options?: Node[]; + sql_body?: Node; +} +export interface FunctionParameter { + name?: string; + argType?: TypeName; + mode?: FunctionParameterMode; + defexpr?: Node; +} +export interface AlterFunctionStmt { + objtype?: ObjectType; + func?: ObjectWithArgs; + actions?: Node[]; +} +export interface DoStmt { + args?: Node[]; +} +export interface InlineCodeBlock { + source_text?: string; + langOid?: number; + langIsTrusted?: boolean; + atomic?: boolean; +} +export interface CallStmt { + funccall?: FuncCall; + funcexpr?: FuncExpr; + outargs?: Node[]; +} +export interface CallContext { + atomic?: boolean; +} +export interface RenameStmt { + renameType?: ObjectType; + relationType?: ObjectType; + relation?: RangeVar; + object?: Node; + subname?: string; + newname?: string; + behavior?: DropBehavior; + missing_ok?: boolean; +} +export interface AlterObjectDependsStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + extname?: String; + remove?: boolean; +} +export interface AlterObjectSchemaStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newschema?: string; + missing_ok?: boolean; +} +export interface AlterOwnerStmt { + objectType?: ObjectType; + relation?: RangeVar; + object?: Node; + newowner?: RoleSpec; +} +export interface AlterOperatorStmt { + opername?: ObjectWithArgs; + options?: Node[]; +} +export interface AlterTypeStmt { + typeName?: Node[]; + options?: Node[]; +} +export interface RuleStmt { + relation?: RangeVar; + rulename?: string; + whereClause?: Node; + event?: CmdType; + instead?: boolean; + actions?: Node[]; + replace?: boolean; +} +export interface NotifyStmt { + conditionname?: string; + payload?: string; +} +export interface ListenStmt { + conditionname?: string; +} +export interface UnlistenStmt { + conditionname?: string; +} +export interface TransactionStmt { + kind?: TransactionStmtKind; + options?: Node[]; + savepoint_name?: string; + gid?: string; + chain?: boolean; +} +export interface CompositeTypeStmt { + typevar?: RangeVar; + coldeflist?: Node[]; +} +export interface CreateEnumStmt { + typeName?: Node[]; + vals?: Node[]; +} +export interface CreateRangeStmt { + typeName?: Node[]; + params?: Node[]; +} +export interface AlterEnumStmt { + typeName?: Node[]; + oldVal?: string; + newVal?: string; + newValNeighbor?: string; + newValIsAfter?: boolean; + skipIfNewValExists?: boolean; +} +export interface ViewStmt { + view?: RangeVar; + aliases?: Node[]; + query?: Node; + replace?: boolean; + options?: Node[]; + withCheckOption?: ViewCheckOption; +} +export interface LoadStmt { + filename?: string; +} +export interface CreatedbStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseStmt { + dbname?: string; + options?: Node[]; +} +export interface AlterDatabaseRefreshCollStmt { + dbname?: string; +} +export interface AlterDatabaseSetStmt { + dbname?: string; + setstmt?: VariableSetStmt; +} +export interface DropdbStmt { + dbname?: string; + missing_ok?: boolean; + options?: Node[]; +} +export interface AlterSystemStmt { + setstmt?: VariableSetStmt; +} +export interface ClusterStmt { + relation?: RangeVar; + indexname?: string; + params?: Node[]; +} +export interface VacuumStmt { + options?: Node[]; + rels?: Node[]; + is_vacuumcmd?: boolean; +} +export interface VacuumRelation { + relation?: RangeVar; + oid?: number; + va_cols?: Node[]; +} +export interface ExplainStmt { + query?: Node; + options?: Node[]; +} +export interface CreateTableAsStmt { + query?: Node; + into?: IntoClause; + objtype?: ObjectType; + is_select_into?: boolean; + if_not_exists?: boolean; +} +export interface RefreshMatViewStmt { + concurrent?: boolean; + skipData?: boolean; + relation?: RangeVar; +} +export interface CheckPointStmt {} +export interface DiscardStmt { + target?: DiscardMode; +} +export interface LockStmt { + relations?: Node[]; + mode?: number; + nowait?: boolean; +} +export interface ConstraintsSetStmt { + constraints?: Node[]; + deferred?: boolean; +} +export interface ReindexStmt { + kind?: ReindexObjectType; + relation?: RangeVar; + name?: string; + params?: Node[]; +} +export interface CreateConversionStmt { + conversion_name?: Node[]; + for_encoding_name?: string; + to_encoding_name?: string; + func_name?: Node[]; + def?: boolean; +} +export interface CreateCastStmt { + sourcetype?: TypeName; + targettype?: TypeName; + func?: ObjectWithArgs; + context?: CoercionContext; + inout?: boolean; +} +export interface CreateTransformStmt { + replace?: boolean; + type_name?: TypeName; + lang?: string; + fromsql?: ObjectWithArgs; + tosql?: ObjectWithArgs; +} +export interface PrepareStmt { + name?: string; + argtypes?: Node[]; + query?: Node; +} +export interface ExecuteStmt { + name?: string; + params?: Node[]; +} +export interface DeallocateStmt { + name?: string; +} +export interface DropOwnedStmt { + roles?: Node[]; + behavior?: DropBehavior; +} +export interface ReassignOwnedStmt { + roles?: Node[]; + newrole?: RoleSpec; +} +export interface AlterTSDictionaryStmt { + dictname?: Node[]; + options?: Node[]; +} +export interface AlterTSConfigurationStmt { + kind?: AlterTSConfigType; + cfgname?: Node[]; + tokentype?: Node[]; + dicts?: Node[]; + override?: boolean; + replace?: boolean; + missing_ok?: boolean; +} +export interface PublicationTable { + relation?: RangeVar; + whereClause?: Node; + columns?: Node[]; +} +export interface PublicationObjSpec { + pubobjtype?: PublicationObjSpecType; + name?: string; + pubtable?: PublicationTable; + location?: number; +} +export interface CreatePublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; +} +export interface AlterPublicationStmt { + pubname?: string; + options?: Node[]; + pubobjects?: Node[]; + for_all_tables?: boolean; + action?: AlterPublicationAction; +} +export interface CreateSubscriptionStmt { + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface AlterSubscriptionStmt { + kind?: AlterSubscriptionType; + subname?: string; + conninfo?: string; + publication?: Node[]; + options?: Node[]; +} +export interface DropSubscriptionStmt { + subname?: string; + missing_ok?: boolean; + behavior?: DropBehavior; +} +export interface ScanToken { + start?: number; + end?: number; + token?: Token; + keywordKind?: KeywordKind; +}", + "file": "types.ts", + }, +] +`; diff --git a/packages/proto-parser/__tests__/utils.test.ts b/packages/proto-parser/__tests__/utils.test.ts index 8a473d54..5fb11885 100644 --- a/packages/proto-parser/__tests__/utils.test.ts +++ b/packages/proto-parser/__tests__/utils.test.ts @@ -34,4 +34,33 @@ describe('utils', () => { } }); }); + + it('wrappedAstHelpers enabled', () => { + parseAndSnap('utils/wrappedAstHelpers/enabled', { + types: { + enabled: true + }, + utils: { + wrappedAstHelpers: { + enabled: true + } + } + }); + }); + + it('both astHelpers and wrappedAstHelpers enabled', () => { + parseAndSnap('utils/astHelpers/bothEnabled', { + types: { + enabled: true + }, + utils: { + astHelpers: { + enabled: true + }, + wrappedAstHelpers: { + enabled: true + } + } + }); + }); }); diff --git a/packages/proto-parser/src/ast/enums/enums-json.ts b/packages/proto-parser/src/ast/enums/enums-json.ts index 6321cf47..c1137511 100644 --- a/packages/proto-parser/src/ast/enums/enums-json.ts +++ b/packages/proto-parser/src/ast/enums/enums-json.ts @@ -3,6 +3,11 @@ import { Enum } from '@launchql/protobufjs'; type EnumValueToName = Record>; type EnumNameToValue = Record>; +/** + * Generates a JSON structure mapping enum numeric values to their string names. + * Output format: { EnumName: { 0: 'VALUE1', 1: 'VALUE2', ... } } + * Used for creating enum-to-string mapping files (JSON or TypeScript). + */ export const generateEnum2StrJSON = (enums: Enum[]): EnumValueToName => { const valueToName: EnumValueToName = {}; @@ -17,6 +22,11 @@ export const generateEnum2StrJSON = (enums: Enum[]): EnumValueToName => { return valueToName; }; +/** + * Generates a JSON structure mapping enum string names to their numeric values. + * Output format: { EnumName: { 'VALUE1': 0, 'VALUE2': 1, ... } } + * Used for creating string-to-enum mapping files (JSON or TypeScript). + */ export const generateEnum2IntJSON = (enums: Enum[]): EnumNameToValue => { const nameToValue: EnumNameToValue = {}; diff --git a/packages/proto-parser/src/ast/enums/enums.ts b/packages/proto-parser/src/ast/enums/enums.ts index 7d2ff66b..ef4d1514 100644 --- a/packages/proto-parser/src/ast/enums/enums.ts +++ b/packages/proto-parser/src/ast/enums/enums.ts @@ -2,6 +2,11 @@ import { Enum } from '@launchql/protobufjs'; import * as t from '@babel/types'; import { createNamedImport } from '../../utils'; +/** + * Converts a protobuf Enum into a TypeScript enum declaration. + * Example output: export enum MyEnum { VALUE1 = 0, VALUE2 = 1, ... } + * This is the traditional enum format that creates both type and value in TypeScript. + */ export const convertEnumToTsEnumDeclaration = (enumData: Enum) => { const members = Object.entries(enumData.values).map(([key, value]) => t.tsEnumMember(t.identifier(key), t.numericLiteral(value as number)) @@ -11,10 +16,20 @@ export const convertEnumToTsEnumDeclaration = (enumData: Enum) => { return t.exportNamedDeclaration(enumDeclaration); }; +/** + * Generates import statements for enums from a specified source module. + * Used when enums need to be imported into other generated files (like types.ts). + * Example output: import { Enum1, Enum2, ... } from './enums'; + */ export const generateEnumImports = (enums: Enum[], source: string) => { return createNamedImport(enums.map(e=>e.name), source); }; +/** + * Converts a protobuf Enum into a TypeScript union type of string literals. + * Example output: export type MyEnum = 'VALUE1' | 'VALUE2' | ... + * This creates a type-only representation without runtime values. + */ export const convertEnumToTsUnionType = (enumData: Enum) => { const literals = Object.keys(enumData.values).map(key => t.tsLiteralType(t.stringLiteral(key)) @@ -31,6 +46,11 @@ export const convertEnumToTsUnionType = (enumData: Enum) => { return t.exportNamedDeclaration(typeAlias); }; +/** + * Generates a bidirectional enum value converter function that can convert between string keys and numeric values. + * Creates getEnumValue(enumType, key) that accepts either string or number and returns the corresponding value. + * Example: getEnumValue('MyEnum', 'VALUE1') => 0, getEnumValue('MyEnum', 0) => 'VALUE1' + */ export const generateEnumValueFunctions = (enumData: Enum[]) => { // Create the union type for EnumType const enumTypeIdentifier = t.identifier('EnumType'); @@ -111,6 +131,11 @@ export const generateEnumValueFunctions = (enumData: Enum[]) => { return [exportedEnumTypeAlias, exportedFunction]; } +/** + * Generates a unidirectional function that converts enum string keys to their numeric values. + * Creates getEnumInt(enumType, key) that only accepts string keys and returns numbers. + * Example: getEnumInt('MyEnum', 'VALUE1') => 0 + */ export const generateEnumToIntFunctions = (enumData: Enum[]) => { // Create the union type for EnumType const enumTypeIdentifier = t.identifier('EnumType'); @@ -188,6 +213,11 @@ export const generateEnumToIntFunctions = (enumData: Enum[]) => { return [exportedEnumTypeAlias, exportedFunction]; } +/** + * Generates a nested object structure with individual converter functions for each enum. + * Creates enumToIntMap object where each enum has its own converter: enumToIntMap.MyEnum('VALUE1') => 0 + * This format provides better type safety and autocomplete for specific enums. + */ export const generateEnumToIntFunctionsNested = (enumData: Enum[]) => { // Create the union type for EnumType const enumTypeIdentifier = t.identifier('EnumType'); @@ -280,6 +310,11 @@ export const generateEnumToIntFunctionsNested = (enumData: Enum[]) => { return [exportedEnumType, exportedMapType, exportedObject]; } +/** + * Generates a nested object structure with functions to convert enum numeric values to string keys. + * Creates enumToStringMap object where each enum has its own converter: enumToStringMap.MyEnum(0) => 'VALUE1' + * Provides type-safe reverse mapping from numbers to string keys. + */ export const generateEnumToStringFunctionsNested = (enumData: Enum[]) => { // Create the union type for EnumType const enumTypeIdentifier = t.identifier('EnumType'); @@ -372,6 +407,11 @@ export const generateEnumToStringFunctionsNested = (enumData: Enum[]) => { return [exportedEnumType, exportedMapType, exportedObject]; } +/** + * Generates a unidirectional function that converts enum numeric values to their string keys. + * Creates getEnumString(enumType, key) that only accepts numbers and returns string keys. + * Example: getEnumString('MyEnum', 0) => 'VALUE1' + */ export const generateEnumToStringFunctions = (enumData: Enum[]) => { // Create the union type for EnumType const enumTypeIdentifier = t.identifier('EnumType'); diff --git a/packages/proto-parser/src/ast/types/types.ts b/packages/proto-parser/src/ast/types/types.ts index 52f96afb..3895c64d 100644 --- a/packages/proto-parser/src/ast/types/types.ts +++ b/packages/proto-parser/src/ast/types/types.ts @@ -5,12 +5,23 @@ import { PgProtoParserOptions } from '../../options'; import { NODE_TYPE } from '../../constants'; import { resolveTypeName } from './utils'; +/** + * Generates import statements for types from a specified source module. + * Can optionally add a suffix to imported type names (e.g., import { Type as TypeSuffix }) + * Used when types need to be imported into other generated files. + */ export const generateTypeImports = (types: Type[], source: string, suffix?: string) => { return suffix ? createNamedImportAsSuffix(types.map(e => e.name), source, suffix) : createNamedImport(types.map(e => e.name), source); }; +/** + * Generates helper factory methods for creating AST node instances. + * Creates an object with camelCase methods for each type (e.g., selectStmt() for SelectStmt type). + * Each method accepts optional initial values and returns the type directly. + * Example output: { selectStmt: (_p?: SelectStmt) => SelectStmt } + */ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclaration => { const creators = types.map((type: Type) => { const typeName = type.name; @@ -18,11 +29,6 @@ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclarat param.optional = true; param.typeAnnotation = t.tsTypeAnnotation(t.tsTypeReference(t.identifier(typeName))); - // Add isNode parameter - const isNodeParam = t.identifier('isNode'); - isNodeParam.optional = true; - isNodeParam.typeAnnotation = t.tsTypeAnnotation(t.tsBooleanKeyword()); - let init: any = []; // @ts-ignore @@ -57,17 +63,83 @@ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclarat ); }); - // Create the if statement for isNode check - const wrappedReturn = t.ifStatement( - t.identifier('isNode'), + // Ensures camel case + const methodName = toSpecialCamelCase(typeName); + + // Create the method + const method = t.objectMethod( + 'method', + t.identifier(methodName), + [param], t.blockStatement([ - t.returnStatement( - t.objectExpression([ - t.objectProperty( - t.identifier(typeName), - t.identifier('_j') - ) - ]) + astNodeInit, + ...setStatements, + t.returnStatement(t.identifier('_j')) + ]) + ); + + // Set return type to just the type + method.returnType = t.tsTypeAnnotation(t.tsTypeReference(t.identifier(typeName))); + + return method; + }); + + return t.exportDefaultDeclaration(t.objectExpression(creators)); +} + +/** + * Generates helper factory methods that return AST nodes wrapped in a type-specific object. + * Creates an object with camelCase methods for each type (e.g., selectStmt() for SelectStmt type). + * Each method accepts optional initial values and returns { TypeName: TypeInstance }. + * Example output: { selectStmt: (_p?: SelectStmt) => { SelectStmt: SelectStmt } } + */ +export const generateWrappedAstHelperMethods = (types: Type[]): t.ExportDefaultDeclaration => { + const creators = types.map((type: Type) => { + const typeName = type.name; + const param = t.identifier('_p'); + param.optional = true; + param.typeAnnotation = t.tsTypeAnnotation(t.tsTypeReference(t.identifier(typeName))); + + let init: any = []; + + // @ts-ignore + const fields: Field[] = type.fields; + const astNodeInit = t.variableDeclaration('const', [ + t.variableDeclarator( + t.identifier('_j'), + t.tsAsExpression( + t.objectExpression(init), + t.tsTypeReference(t.identifier(typeName)) + ) + ) + ]); + + const setStatements = Object.entries(fields) + .map(([fName, field]) => { + const fieldName = getFieldName(field, fName); + return t.expressionStatement( + t.callExpression( + t.memberExpression(t.identifier('_o'), t.identifier('set')), + [ + t.identifier('_j'), + t.stringLiteral(fieldName), + t.optionalMemberExpression( + t.identifier('_p'), + t.identifier(fieldName), + false, + true + ) + ] + ) + ); + }); + + // Return the wrapped object + const wrappedReturn = t.returnStatement( + t.objectExpression([ + t.objectProperty( + t.identifier(typeName), + t.identifier('_j') ) ]) ); @@ -79,16 +151,15 @@ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclarat const method = t.objectMethod( 'method', t.identifier(methodName), - [param, isNodeParam], + [param], t.blockStatement([ astNodeInit, ...setStatements, - wrappedReturn, - t.returnStatement(t.identifier('_j')) + wrappedReturn ]) ); - // Update return type to be union of Type | { Type: Type } + // Set return type to the wrapped type const wrappedType = t.tsTypeLiteral([ t.tsPropertySignature( t.identifier(typeName), @@ -96,12 +167,7 @@ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclarat ) ]); - method.returnType = t.tsTypeAnnotation( - t.tsUnionType([ - t.tsTypeReference(t.identifier(typeName)), - wrappedType - ]) - ); + method.returnType = t.tsTypeAnnotation(wrappedType); return method; }); @@ -109,7 +175,11 @@ export const generateAstHelperMethods = (types: Type[]): t.ExportDefaultDeclarat return t.exportDefaultDeclaration(t.objectExpression(creators)); } -// special for Node +/** + * Generates a TypeScript union type named 'Node' that includes all AST node types. + * Can generate either a simple union (Type1 | Type2 | ...) or wrapped objects ({ Type1: Type1 } | { Type2: Type2 } | ...) + * based on the wrappedNodeTypeExport option. This is the main type used to represent any AST node. + */ export const generateNodeUnionType = ( options: PgProtoParserOptions, types: Type[] @@ -129,6 +199,11 @@ export const generateNodeUnionType = ( }; +/** + * Generates a Node union type where each type is wrapped in an object with the type name as key. + * Example output: type Node = { SelectStmt: SelectStmt } | { InsertStmt: InsertStmt } | ... + * This format makes it easier to determine the specific type of a node at runtime. + */ export const generateNodeUnionTypeObjectKeys = (types: Type[]) => { // Mapping types to TypeScript object type annotations const unionTypeNames = types.map(type => @@ -184,6 +259,11 @@ const extractTypeFieldsAsTsProperties = ( return properties; } +/** + * Converts a protobuf Type definition into a TypeScript interface declaration. + * Handles field types, arrays (repeated fields), and optional fields based on options. + * Example: Type "SelectStmt" with fields becomes: export interface SelectStmt { field1?: Type1; ... } + */ export const convertTypeToTsInterface = ( type: Type, options: PgProtoParserOptions @@ -203,6 +283,11 @@ export const convertTypeToTsInterface = ( } +/** + * Generates import specifiers for types from the configured types source. + * Used in ast-helpers to import all the type definitions. + * Example output: import { SelectStmt, InsertStmt, ... } from './types'; + */ export const generateTypeImportSpecifiers = (types: Type[], options: PgProtoParserOptions) => { const importSpecifiers = types.map(type => t.importSpecifier(t.identifier(type.name), t.identifier(type.name)) diff --git a/packages/proto-parser/src/ast/types/utils.ts b/packages/proto-parser/src/ast/types/utils.ts index 3a14c020..c777897c 100644 --- a/packages/proto-parser/src/ast/types/utils.ts +++ b/packages/proto-parser/src/ast/types/utils.ts @@ -1,6 +1,11 @@ import * as t from '@babel/types'; import { isPrimitiveType } from '../../utils'; +/** + * Maps protobuf primitive types to their TypeScript equivalents. + * Handles numeric types, strings, booleans, bytes, and bigints. + * Falls back to type references for custom/non-primitive types. + */ export const getTSType = (type: string = 'any') => { switch (type) { case 'string': @@ -30,6 +35,11 @@ export const getTSType = (type: string = 'any') => { }; }; +/** + * Resolves a type name to its TypeScript AST representation. + * Delegates to getTSType for primitives, creates type references for custom types. + * This is the main entry point for type resolution in the code generator. + */ export const resolveTypeName = (type: string) => { if (isPrimitiveType(type)) { return getTSType(type); diff --git a/packages/proto-parser/src/options/defaults.ts b/packages/proto-parser/src/options/defaults.ts index b4f0802a..5b6bb425 100644 --- a/packages/proto-parser/src/options/defaults.ts +++ b/packages/proto-parser/src/options/defaults.ts @@ -23,6 +23,10 @@ export const defaultPgProtoParserOptions: PgProtoParserOptions = { inlineNestedObj: false, nestedObjFile: 'nested-obj.ts', filename: 'asts.ts', + }, + wrappedAstHelpers: { + enabled: false, + filename: 'wrapped-asts.ts' } }, types: { diff --git a/packages/proto-parser/src/options/types.ts b/packages/proto-parser/src/options/types.ts index 7cb90d68..9db023ad 100644 --- a/packages/proto-parser/src/options/types.ts +++ b/packages/proto-parser/src/options/types.ts @@ -42,6 +42,14 @@ export interface PgProtoStoreOptions { // ASTs helpers filename filename?: string; } + + // Wrapped AST helper functions. + wrappedAstHelpers?: { + // Whether to include wrapped TypeScript AST builders + enabled?: boolean; + // Wrapped ASTs helpers filename + filename?: string; + } }; // Options related to TypeScript types. diff --git a/packages/proto-parser/src/store.ts b/packages/proto-parser/src/store.ts index d612663c..9d6a926b 100644 --- a/packages/proto-parser/src/store.ts +++ b/packages/proto-parser/src/store.ts @@ -1,5 +1,5 @@ import { Service, Type, Field, Enum, Namespace, ReflectionObject } from '@launchql/protobufjs'; -import { generateEnumImports, generateAstHelperMethods, generateTypeImportSpecifiers, generateEnumValueFunctions, generateEnumToIntFunctions, generateEnumToStringFunctions, generateEnumToIntFunctionsNested, generateEnumToStringFunctionsNested, convertEnumToTsUnionType, convertEnumToTsEnumDeclaration, generateNodeUnionType, convertTypeToTsInterface } from './ast'; +import { generateEnumImports, generateAstHelperMethods, generateWrappedAstHelperMethods, generateTypeImportSpecifiers, generateEnumValueFunctions, generateEnumToIntFunctions, generateEnumToStringFunctions, generateEnumToIntFunctionsNested, generateEnumToStringFunctionsNested, convertEnumToTsUnionType, convertEnumToTsEnumDeclaration, generateNodeUnionType, convertTypeToTsInterface } from './ast'; import { RuntimeSchemaGenerator } from './runtime-schema'; import { generateEnum2IntJSON, generateEnum2StrJSON } from './ast/enums/enums-json'; import { jsStringify } from 'strfy-js'; @@ -97,6 +97,7 @@ export class ProtoStore implements IProtoStore { this.writeEnums(); this.writeUtilsEnums(); this.writeAstHelpers(); + this.writeWrappedAstHelpers(); this.writeRuntimeSchema(); } @@ -223,6 +224,21 @@ export class ProtoStore implements IProtoStore { } } + writeWrappedAstHelpers() { + if (this.options.utils.wrappedAstHelpers?.enabled) { + const imports = createDefaultImport('_o', 'nested-obj'); + + const typesToProcess = this.typesToProcess(); + const code = convertAstToCode([ + imports, + generateTypeImportSpecifiers(typesToProcess, this.options), + generateWrappedAstHelperMethods(typesToProcess) + ]); + + this.writeFile(this.options.utils.wrappedAstHelpers.filename, code); + } + } + writeRuntimeSchema() { if (!this.options.runtimeSchema?.enabled) { return; diff --git a/packages/transform/src/13/enums.ts b/packages/transform/src/13/enums.ts index 3bde585a..b755dd46 100644 --- a/packages/transform/src/13/enums.ts +++ b/packages/transform/src/13/enums.ts @@ -1,5 +1,5 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ diff --git a/packages/transform/src/13/types.ts b/packages/transform/src/13/types.ts index acae28de..50eb3a30 100644 --- a/packages/transform/src/13/types.ts +++ b/packages/transform/src/13/types.ts @@ -1,5 +1,5 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ diff --git a/packages/transform/src/17/enums.ts b/packages/transform/src/17/enums.ts index 8fd249c8..0446df6f 100644 --- a/packages/transform/src/17/enums.ts +++ b/packages/transform/src/17/enums.ts @@ -1,5 +1,5 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ diff --git a/packages/transform/src/17/types.ts b/packages/transform/src/17/types.ts index 9c2e0635..837af266 100644 --- a/packages/transform/src/17/types.ts +++ b/packages/transform/src/17/types.ts @@ -1,5 +1,5 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ diff --git a/packages/types/CHANGELOG.md b/packages/types/CHANGELOG.md deleted file mode 100644 index 166b880e..00000000 --- a/packages/types/CHANGELOG.md +++ /dev/null @@ -1,64 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -## [17.5.2](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.5.1...@pgsql/types@17.5.2) (2025-06-22) - -**Note:** Version bump only for package @pgsql/types - - - - - -## [17.5.1](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.5.0...@pgsql/types@17.5.1) (2025-06-22) - -**Note:** Version bump only for package @pgsql/types - - - - - -# [17.5.0](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.4.2...@pgsql/types@17.5.0) (2025-06-22) - -**Note:** Version bump only for package @pgsql/types - - - - - -## [17.4.2](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.4.1...@pgsql/types@17.4.2) (2025-06-22) - -**Note:** Version bump only for package @pgsql/types - - - - - -## [17.4.1](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.4.0...@pgsql/types@17.4.1) (2025-06-21) - -**Note:** Version bump only for package @pgsql/types - - - - - -# [17.4.0](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.1.0...@pgsql/types@17.4.0) (2025-06-21) - -**Note:** Version bump only for package @pgsql/types - - - - - -# [17.2.0](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@17.1.0...@pgsql/types@17.2.0) (2025-06-21) - -**Note:** Version bump only for package @pgsql/types - - - - - -# [17.1.0](https://github.com/launchql/pgsql-parser/compare/@pgsql/types@13.9.0...@pgsql/types@17.1.0) (2025-06-21) - -**Note:** Version bump only for package @pgsql/types diff --git a/packages/types/README.md b/packages/types/README.md deleted file mode 100644 index ac87727f..00000000 --- a/packages/types/README.md +++ /dev/null @@ -1,88 +0,0 @@ -# @pgsql/types - -

- -

- -

- - - - - - - -

- -`@pgsql/types` is a TypeScript library providing type definitions for PostgreSQL AST nodes, primarily used in conjunction with [`pgsql-parser`](https://github.com/launchql/pgsql-parser). It offers a comprehensive and type-safe way to interact with the AST nodes generated by PostgreSQL query parsing. - - -## Installation - -Install the package via npm: - -```bash -npm install @pgsql/types -``` - -## Usage - -`@pgsql/types` provides TypeScript type definitions for PostgreSQL Abstract Syntax Tree (AST) nodes. These types are useful for constructing, analyzing, or manipulating ASTs in a type-safe manner. - -Here are a few examples of how you can use these types in your TypeScript projects: - -### Validating AST Nodes - -You can use the types to validate AST nodes, ensuring they conform to the expected structure: - -```ts -import { CreateStmt } from '@pgsql/types'; - -function validateCreateStmt(stmt: CreateStmt) { - if (!stmt.relation || !stmt.tableElts) { - throw new Error('Invalid CreateStmt: missing required fields'); - } - // Add more validation logic as needed - console.log('CreateStmt is valid'); -} - -// Example usage -validateCreateStmt(createStmtObject); -``` - -### Constructing AST Nodes - -Types help ensure that you construct AST nodes correctly: - -```ts -import { CreateStmt, ColumnDef, Constraint } from '@pgsql/types'; - -const newColumn: ColumnDef = { - colname: 'id', - typeName: { names: [{ String: { str: 'int4' } }] }, - constraints: [{ Constraint: { contype: 'CONSTR_PRIMARY' } }], -}; - -const createStmt: CreateStmt = { - relation: { relname: 'new_table' }, - tableElts: [newColumn], -}; - -console.log(createStmt); -``` - -## Related - -* [pgsql-parser](https://github.com/launchql/pgsql-parser): The real PostgreSQL parser for Node.js, providing symmetric parsing and deparsing of SQL statements with actual PostgreSQL parser integration. -* [pgsql-deparser](https://github.com/launchql/pgsql-parser/tree/main/packages/deparser): A streamlined tool designed for converting PostgreSQL ASTs back into SQL queries, focusing solely on deparser functionality to complement `pgsql-parser`. -* [pgsql-enums](https://github.com/launchql/pgsql-parser/tree/main/packages/pgsql-enums): A utility package offering easy access to PostgreSQL enumeration types in JSON format, aiding in string and integer conversions of enums used within ASTs to compliment `pgsql-parser` -* [@pgsql/enums](https://github.com/launchql/pgsql-parser/tree/main/packages/enums): Provides PostgreSQL AST enums in TypeScript, enhancing type safety and usability in projects interacting with PostgreSQL AST nodes. -* [@pgsql/types](https://github.com/launchql/pgsql-parser/tree/main/packages/types): Offers TypeScript type definitions for PostgreSQL AST nodes, facilitating type-safe construction, analysis, and manipulation of ASTs. -* [@pgsql/utils](https://github.com/launchql/pgsql-parser/tree/main/packages/utils): A comprehensive utility library for PostgreSQL, offering type-safe AST node creation and enum value conversions, simplifying the construction and manipulation of PostgreSQL ASTs. -* [pg-proto-parser](https://github.com/launchql/pg-proto-parser): A TypeScript tool that parses PostgreSQL Protocol Buffers definitions to generate TypeScript interfaces, utility functions, and JSON mappings for enums. -* [libpg-query](https://github.com/launchql/libpg-query-node): The real PostgreSQL parser exposed for Node.js, used primarily in `pgsql-parser` for parsing and deparsing SQL queries. -## Disclaimer - -AS DESCRIBED IN THE LICENSES, THE SOFTWARE IS PROVIDED “AS IS”, AT YOUR OWN RISK, AND WITHOUT WARRANTIES OF ANY KIND. - -No developer or entity involved in creating Software will be liable for any claims or damages whatsoever associated with your use, inability to use, or your interaction with other users of the Software code or Software CLI, including any direct, indirect, incidental, special, exemplary, punitive or consequential damages, or loss of profits, cryptocurrencies, tokens, or anything else of value. \ No newline at end of file diff --git a/packages/types/__test__/types.test.ts b/packages/types/__test__/types.test.ts deleted file mode 100644 index 7beb2b85..00000000 --- a/packages/types/__test__/types.test.ts +++ /dev/null @@ -1,156 +0,0 @@ -import { CreateStmt } from '../src' - -const myTypedFunction = (createStmt: CreateStmt) => { - expect(createStmt).toBeTruthy(); -}; - -it('types', () => { - // here we just want to ensure there are no type errors - // purposefully a simple test - const ast: CreateStmt = { - relation: { - alias: { - aliasname: 'string', - colnames: [] - }, - catalogname: 'sdf', - inh: true, - location: 52, - relname: 'job_queues', - relpersistence: 'p', - schemaname: 'app_jobs', - }, - tableElts: [ - { - ColumnDef: { - colname: 'queue_name', - constraints: [ - { - Constraint: { - contype: 'CONSTR_NOTNULL', - location: 95, - }, - }, - { - Constraint: { - contype: 'CONSTR_PRIMARY', - location: 104, - }, - }, - ], - is_local: true, - location: 76, - typeName: { - location: 87, - names: [ - { - - String: { - sval: 'pg_catalog', - }, - }, - { - String: { - sval: 'varchar', - }, - }, - ], - typemod: -1, - }, - }, - }, - { - ColumnDef: { - colname: 'job_count', - constraints: [ - { - Constraint: { - contype: 'CONSTR_DEFAULT', - location: 133, - raw_expr: { - A_Const: { - location: 141, - ival: { - ival: 0 - }, - }, - }, - }, - }, - { - Constraint: { - contype: 'CONSTR_NOTNULL', - location: 143, - }, - }, - ], - is_local: true, - location: 119, - typeName: { - location: 129, - names: [ - { - String: { - sval: 'pg_catalog', - }, - }, - { - String: { - sval: 'int4', - }, - }, - ], - typemod: -1, - }, - }, - }, - { - ColumnDef: { - colname: 'locked_at', - is_local: true, - location: 155, - typeName: { - location: 165, - names: [ - { - String: { - sval: 'pg_catalog', - }, - }, - { - String: { - sval: 'timestamptz', - }, - }, - ], - typemod: -1, - }, - }, - }, - { - ColumnDef: { - colname: 'locked_by', - is_local: true, - location: 193, - typeName: { - location: 203, - names: [ - { - String: { - sval: 'pg_catalog', - }, - }, - { - String: { - sval: 'varchar', - }, - }, - ], - typemod: -1, - }, - }, - }, - ], - }; - myTypedFunction(ast); -}); \ No newline at end of file diff --git a/packages/types/jest.config.js b/packages/types/jest.config.js deleted file mode 100644 index 0aa3aaa4..00000000 --- a/packages/types/jest.config.js +++ /dev/null @@ -1,18 +0,0 @@ -/** @type {import('ts-jest').JestConfigWithTsJest} */ -module.exports = { - preset: "ts-jest", - testEnvironment: "node", - transform: { - "^.+\\.tsx?$": [ - "ts-jest", - { - babelConfig: false, - tsconfig: "tsconfig.json", - }, - ], - }, - transformIgnorePatterns: [`/node_modules/*`], - testRegex: "(/__tests__/.*|(\\.|/)(test|spec))\\.(jsx?|tsx?)$", - moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json", "node"], - modulePathIgnorePatterns: ["dist/*"] -}; diff --git a/packages/types/package.json b/packages/types/package.json deleted file mode 100644 index 7e883a00..00000000 --- a/packages/types/package.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "name": "@pgsql/types", - "version": "17.5.2", - "author": "Dan Lynch ", - "description": "PostgreSQL AST types for pgsql-parser", - "main": "index.js", - "module": "esm/index.js", - "types": "index.d.ts", - "homepage": "https://github.com/launchql/pgsql-parser", - "license": "SEE LICENSE IN LICENSE", - "publishConfig": { - "access": "public", - "directory": "dist" - }, - "repository": { - "type": "git", - "url": "https://github.com/launchql/pgsql-parser" - }, - "bugs": { - "url": "https://github.com/launchql/pgsql-parser/issues" - }, - "scripts": { - "copy": "copyfiles -f ../../LICENSE README.md package.json dist", - "clean": "rimraf dist", - "prepare": "npm run build", - "build": "npm run build:proto && npm run clean && tsc && tsc -p tsconfig.esm.json && npm run copy", - "build:dev": "npm run clean && tsc --declarationMap && tsc -p tsconfig.esm.json && npm run copy", - "build:proto": "ts-node scripts/pg-proto-parser", - "lint": "eslint . --fix", - "test": "jest", - "test:watch": "jest --watch" - }, - "devDependencies": { - "pg-proto-parser": "^1.28.2" - }, - "keywords": [] -} diff --git a/packages/types/scripts/pg-proto-parser.ts b/packages/types/scripts/pg-proto-parser.ts deleted file mode 100644 index 026790a1..00000000 --- a/packages/types/scripts/pg-proto-parser.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { PgProtoParser, PgProtoParserOptions } from 'pg-proto-parser'; -import { resolve, join } from 'path'; - -const inFile: string = join(__dirname, '../../../__fixtures__/proto/17-latest.proto'); -const outDir: string = resolve(join(__dirname, '../src')); - -const options: PgProtoParserOptions = { - outDir, - types: { - enabled: true, - wrappedNodeTypeExport: true - }, - enums: { - enabled: true, - enumsAsTypeUnion: true - } -}; -const parser = new PgProtoParser(inFile, options); - -parser.write(); diff --git a/packages/types/src/enums.ts b/packages/types/src/enums.ts deleted file mode 100644 index 8fd249c8..00000000 --- a/packages/types/src/enums.ts +++ /dev/null @@ -1,76 +0,0 @@ -/** -* This file was automatically generated by pg-proto-parser@1.28.1. -* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, -* and run the pg-proto-parser generate command to regenerate this file. -*/ -export type QuerySource = "QSRC_ORIGINAL" | "QSRC_PARSER" | "QSRC_INSTEAD_RULE" | "QSRC_QUAL_INSTEAD_RULE" | "QSRC_NON_INSTEAD_RULE"; -export type SortByDir = "SORTBY_DEFAULT" | "SORTBY_ASC" | "SORTBY_DESC" | "SORTBY_USING"; -export type SortByNulls = "SORTBY_NULLS_DEFAULT" | "SORTBY_NULLS_FIRST" | "SORTBY_NULLS_LAST"; -export type SetQuantifier = "SET_QUANTIFIER_DEFAULT" | "SET_QUANTIFIER_ALL" | "SET_QUANTIFIER_DISTINCT"; -export type A_Expr_Kind = "AEXPR_OP" | "AEXPR_OP_ANY" | "AEXPR_OP_ALL" | "AEXPR_DISTINCT" | "AEXPR_NOT_DISTINCT" | "AEXPR_NULLIF" | "AEXPR_IN" | "AEXPR_LIKE" | "AEXPR_ILIKE" | "AEXPR_SIMILAR" | "AEXPR_BETWEEN" | "AEXPR_NOT_BETWEEN" | "AEXPR_BETWEEN_SYM" | "AEXPR_NOT_BETWEEN_SYM"; -export type RoleSpecType = "ROLESPEC_CSTRING" | "ROLESPEC_CURRENT_ROLE" | "ROLESPEC_CURRENT_USER" | "ROLESPEC_SESSION_USER" | "ROLESPEC_PUBLIC"; -export type TableLikeOption = "CREATE_TABLE_LIKE_COMMENTS" | "CREATE_TABLE_LIKE_COMPRESSION" | "CREATE_TABLE_LIKE_CONSTRAINTS" | "CREATE_TABLE_LIKE_DEFAULTS" | "CREATE_TABLE_LIKE_GENERATED" | "CREATE_TABLE_LIKE_IDENTITY" | "CREATE_TABLE_LIKE_INDEXES" | "CREATE_TABLE_LIKE_STATISTICS" | "CREATE_TABLE_LIKE_STORAGE" | "CREATE_TABLE_LIKE_ALL"; -export type DefElemAction = "DEFELEM_UNSPEC" | "DEFELEM_SET" | "DEFELEM_ADD" | "DEFELEM_DROP"; -export type PartitionStrategy = "PARTITION_STRATEGY_LIST" | "PARTITION_STRATEGY_RANGE" | "PARTITION_STRATEGY_HASH"; -export type PartitionRangeDatumKind = "PARTITION_RANGE_DATUM_MINVALUE" | "PARTITION_RANGE_DATUM_VALUE" | "PARTITION_RANGE_DATUM_MAXVALUE"; -export type RTEKind = "RTE_RELATION" | "RTE_SUBQUERY" | "RTE_JOIN" | "RTE_FUNCTION" | "RTE_TABLEFUNC" | "RTE_VALUES" | "RTE_CTE" | "RTE_NAMEDTUPLESTORE" | "RTE_RESULT"; -export type WCOKind = "WCO_VIEW_CHECK" | "WCO_RLS_INSERT_CHECK" | "WCO_RLS_UPDATE_CHECK" | "WCO_RLS_CONFLICT_CHECK" | "WCO_RLS_MERGE_UPDATE_CHECK" | "WCO_RLS_MERGE_DELETE_CHECK"; -export type GroupingSetKind = "GROUPING_SET_EMPTY" | "GROUPING_SET_SIMPLE" | "GROUPING_SET_ROLLUP" | "GROUPING_SET_CUBE" | "GROUPING_SET_SETS"; -export type CTEMaterialize = "CTEMaterializeDefault" | "CTEMaterializeAlways" | "CTEMaterializeNever"; -export type JsonQuotes = "JS_QUOTES_UNSPEC" | "JS_QUOTES_KEEP" | "JS_QUOTES_OMIT"; -export type JsonTableColumnType = "JTC_FOR_ORDINALITY" | "JTC_REGULAR" | "JTC_EXISTS" | "JTC_FORMATTED" | "JTC_NESTED"; -export type SetOperation = "SETOP_NONE" | "SETOP_UNION" | "SETOP_INTERSECT" | "SETOP_EXCEPT"; -export type ObjectType = "OBJECT_ACCESS_METHOD" | "OBJECT_AGGREGATE" | "OBJECT_AMOP" | "OBJECT_AMPROC" | "OBJECT_ATTRIBUTE" | "OBJECT_CAST" | "OBJECT_COLUMN" | "OBJECT_COLLATION" | "OBJECT_CONVERSION" | "OBJECT_DATABASE" | "OBJECT_DEFAULT" | "OBJECT_DEFACL" | "OBJECT_DOMAIN" | "OBJECT_DOMCONSTRAINT" | "OBJECT_EVENT_TRIGGER" | "OBJECT_EXTENSION" | "OBJECT_FDW" | "OBJECT_FOREIGN_SERVER" | "OBJECT_FOREIGN_TABLE" | "OBJECT_FUNCTION" | "OBJECT_INDEX" | "OBJECT_LANGUAGE" | "OBJECT_LARGEOBJECT" | "OBJECT_MATVIEW" | "OBJECT_OPCLASS" | "OBJECT_OPERATOR" | "OBJECT_OPFAMILY" | "OBJECT_PARAMETER_ACL" | "OBJECT_POLICY" | "OBJECT_PROCEDURE" | "OBJECT_PUBLICATION" | "OBJECT_PUBLICATION_NAMESPACE" | "OBJECT_PUBLICATION_REL" | "OBJECT_ROLE" | "OBJECT_ROUTINE" | "OBJECT_RULE" | "OBJECT_SCHEMA" | "OBJECT_SEQUENCE" | "OBJECT_SUBSCRIPTION" | "OBJECT_STATISTIC_EXT" | "OBJECT_TABCONSTRAINT" | "OBJECT_TABLE" | "OBJECT_TABLESPACE" | "OBJECT_TRANSFORM" | "OBJECT_TRIGGER" | "OBJECT_TSCONFIGURATION" | "OBJECT_TSDICTIONARY" | "OBJECT_TSPARSER" | "OBJECT_TSTEMPLATE" | "OBJECT_TYPE" | "OBJECT_USER_MAPPING" | "OBJECT_VIEW"; -export type DropBehavior = "DROP_RESTRICT" | "DROP_CASCADE"; -export type AlterTableType = "AT_AddColumn" | "AT_AddColumnToView" | "AT_ColumnDefault" | "AT_CookedColumnDefault" | "AT_DropNotNull" | "AT_SetNotNull" | "AT_SetExpression" | "AT_DropExpression" | "AT_CheckNotNull" | "AT_SetStatistics" | "AT_SetOptions" | "AT_ResetOptions" | "AT_SetStorage" | "AT_SetCompression" | "AT_DropColumn" | "AT_AddIndex" | "AT_ReAddIndex" | "AT_AddConstraint" | "AT_ReAddConstraint" | "AT_ReAddDomainConstraint" | "AT_AlterConstraint" | "AT_ValidateConstraint" | "AT_AddIndexConstraint" | "AT_DropConstraint" | "AT_ReAddComment" | "AT_AlterColumnType" | "AT_AlterColumnGenericOptions" | "AT_ChangeOwner" | "AT_ClusterOn" | "AT_DropCluster" | "AT_SetLogged" | "AT_SetUnLogged" | "AT_DropOids" | "AT_SetAccessMethod" | "AT_SetTableSpace" | "AT_SetRelOptions" | "AT_ResetRelOptions" | "AT_ReplaceRelOptions" | "AT_EnableTrig" | "AT_EnableAlwaysTrig" | "AT_EnableReplicaTrig" | "AT_DisableTrig" | "AT_EnableTrigAll" | "AT_DisableTrigAll" | "AT_EnableTrigUser" | "AT_DisableTrigUser" | "AT_EnableRule" | "AT_EnableAlwaysRule" | "AT_EnableReplicaRule" | "AT_DisableRule" | "AT_AddInherit" | "AT_DropInherit" | "AT_AddOf" | "AT_DropOf" | "AT_ReplicaIdentity" | "AT_EnableRowSecurity" | "AT_DisableRowSecurity" | "AT_ForceRowSecurity" | "AT_NoForceRowSecurity" | "AT_GenericOptions" | "AT_AttachPartition" | "AT_DetachPartition" | "AT_DetachPartitionFinalize" | "AT_AddIdentity" | "AT_SetIdentity" | "AT_DropIdentity" | "AT_ReAddStatistics"; -export type GrantTargetType = "ACL_TARGET_OBJECT" | "ACL_TARGET_ALL_IN_SCHEMA" | "ACL_TARGET_DEFAULTS"; -export type VariableSetKind = "VAR_SET_VALUE" | "VAR_SET_DEFAULT" | "VAR_SET_CURRENT" | "VAR_SET_MULTI" | "VAR_RESET" | "VAR_RESET_ALL"; -export type ConstrType = "CONSTR_NULL" | "CONSTR_NOTNULL" | "CONSTR_DEFAULT" | "CONSTR_IDENTITY" | "CONSTR_GENERATED" | "CONSTR_CHECK" | "CONSTR_PRIMARY" | "CONSTR_UNIQUE" | "CONSTR_EXCLUSION" | "CONSTR_FOREIGN" | "CONSTR_ATTR_DEFERRABLE" | "CONSTR_ATTR_NOT_DEFERRABLE" | "CONSTR_ATTR_DEFERRED" | "CONSTR_ATTR_IMMEDIATE"; -export type ImportForeignSchemaType = "FDW_IMPORT_SCHEMA_ALL" | "FDW_IMPORT_SCHEMA_LIMIT_TO" | "FDW_IMPORT_SCHEMA_EXCEPT"; -export type RoleStmtType = "ROLESTMT_ROLE" | "ROLESTMT_USER" | "ROLESTMT_GROUP"; -export type FetchDirection = "FETCH_FORWARD" | "FETCH_BACKWARD" | "FETCH_ABSOLUTE" | "FETCH_RELATIVE"; -export type FunctionParameterMode = "FUNC_PARAM_IN" | "FUNC_PARAM_OUT" | "FUNC_PARAM_INOUT" | "FUNC_PARAM_VARIADIC" | "FUNC_PARAM_TABLE" | "FUNC_PARAM_DEFAULT"; -export type TransactionStmtKind = "TRANS_STMT_BEGIN" | "TRANS_STMT_START" | "TRANS_STMT_COMMIT" | "TRANS_STMT_ROLLBACK" | "TRANS_STMT_SAVEPOINT" | "TRANS_STMT_RELEASE" | "TRANS_STMT_ROLLBACK_TO" | "TRANS_STMT_PREPARE" | "TRANS_STMT_COMMIT_PREPARED" | "TRANS_STMT_ROLLBACK_PREPARED"; -export type ViewCheckOption = "NO_CHECK_OPTION" | "LOCAL_CHECK_OPTION" | "CASCADED_CHECK_OPTION"; -export type DiscardMode = "DISCARD_ALL" | "DISCARD_PLANS" | "DISCARD_SEQUENCES" | "DISCARD_TEMP"; -export type ReindexObjectType = "REINDEX_OBJECT_INDEX" | "REINDEX_OBJECT_TABLE" | "REINDEX_OBJECT_SCHEMA" | "REINDEX_OBJECT_SYSTEM" | "REINDEX_OBJECT_DATABASE"; -export type AlterTSConfigType = "ALTER_TSCONFIG_ADD_MAPPING" | "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN" | "ALTER_TSCONFIG_REPLACE_DICT" | "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN" | "ALTER_TSCONFIG_DROP_MAPPING"; -export type PublicationObjSpecType = "PUBLICATIONOBJ_TABLE" | "PUBLICATIONOBJ_TABLES_IN_SCHEMA" | "PUBLICATIONOBJ_TABLES_IN_CUR_SCHEMA" | "PUBLICATIONOBJ_CONTINUATION"; -export type AlterPublicationAction = "AP_AddObjects" | "AP_DropObjects" | "AP_SetObjects"; -export type AlterSubscriptionType = "ALTER_SUBSCRIPTION_OPTIONS" | "ALTER_SUBSCRIPTION_CONNECTION" | "ALTER_SUBSCRIPTION_SET_PUBLICATION" | "ALTER_SUBSCRIPTION_ADD_PUBLICATION" | "ALTER_SUBSCRIPTION_DROP_PUBLICATION" | "ALTER_SUBSCRIPTION_REFRESH" | "ALTER_SUBSCRIPTION_ENABLED" | "ALTER_SUBSCRIPTION_SKIP"; -export type OverridingKind = "OVERRIDING_NOT_SET" | "OVERRIDING_USER_VALUE" | "OVERRIDING_SYSTEM_VALUE"; -export type OnCommitAction = "ONCOMMIT_NOOP" | "ONCOMMIT_PRESERVE_ROWS" | "ONCOMMIT_DELETE_ROWS" | "ONCOMMIT_DROP"; -export type TableFuncType = "TFT_XMLTABLE" | "TFT_JSON_TABLE"; -export type ParamKind = "PARAM_EXTERN" | "PARAM_EXEC" | "PARAM_SUBLINK" | "PARAM_MULTIEXPR"; -export type CoercionContext = "COERCION_IMPLICIT" | "COERCION_ASSIGNMENT" | "COERCION_PLPGSQL" | "COERCION_EXPLICIT"; -export type CoercionForm = "COERCE_EXPLICIT_CALL" | "COERCE_EXPLICIT_CAST" | "COERCE_IMPLICIT_CAST" | "COERCE_SQL_SYNTAX"; -export type BoolExprType = "AND_EXPR" | "OR_EXPR" | "NOT_EXPR"; -export type SubLinkType = "EXISTS_SUBLINK" | "ALL_SUBLINK" | "ANY_SUBLINK" | "ROWCOMPARE_SUBLINK" | "EXPR_SUBLINK" | "MULTIEXPR_SUBLINK" | "ARRAY_SUBLINK" | "CTE_SUBLINK"; -export type RowCompareType = "ROWCOMPARE_LT" | "ROWCOMPARE_LE" | "ROWCOMPARE_EQ" | "ROWCOMPARE_GE" | "ROWCOMPARE_GT" | "ROWCOMPARE_NE"; -export type MinMaxOp = "IS_GREATEST" | "IS_LEAST"; -export type SQLValueFunctionOp = "SVFOP_CURRENT_DATE" | "SVFOP_CURRENT_TIME" | "SVFOP_CURRENT_TIME_N" | "SVFOP_CURRENT_TIMESTAMP" | "SVFOP_CURRENT_TIMESTAMP_N" | "SVFOP_LOCALTIME" | "SVFOP_LOCALTIME_N" | "SVFOP_LOCALTIMESTAMP" | "SVFOP_LOCALTIMESTAMP_N" | "SVFOP_CURRENT_ROLE" | "SVFOP_CURRENT_USER" | "SVFOP_USER" | "SVFOP_SESSION_USER" | "SVFOP_CURRENT_CATALOG" | "SVFOP_CURRENT_SCHEMA"; -export type XmlExprOp = "IS_XMLCONCAT" | "IS_XMLELEMENT" | "IS_XMLFOREST" | "IS_XMLPARSE" | "IS_XMLPI" | "IS_XMLROOT" | "IS_XMLSERIALIZE" | "IS_DOCUMENT"; -export type XmlOptionType = "XMLOPTION_DOCUMENT" | "XMLOPTION_CONTENT"; -export type JsonEncoding = "JS_ENC_DEFAULT" | "JS_ENC_UTF8" | "JS_ENC_UTF16" | "JS_ENC_UTF32"; -export type JsonFormatType = "JS_FORMAT_DEFAULT" | "JS_FORMAT_JSON" | "JS_FORMAT_JSONB"; -export type JsonConstructorType = "JSCTOR_JSON_OBJECT" | "JSCTOR_JSON_ARRAY" | "JSCTOR_JSON_OBJECTAGG" | "JSCTOR_JSON_ARRAYAGG" | "JSCTOR_JSON_PARSE" | "JSCTOR_JSON_SCALAR" | "JSCTOR_JSON_SERIALIZE"; -export type JsonValueType = "JS_TYPE_ANY" | "JS_TYPE_OBJECT" | "JS_TYPE_ARRAY" | "JS_TYPE_SCALAR"; -export type JsonWrapper = "JSW_UNSPEC" | "JSW_NONE" | "JSW_CONDITIONAL" | "JSW_UNCONDITIONAL"; -export type JsonBehaviorType = "JSON_BEHAVIOR_NULL" | "JSON_BEHAVIOR_ERROR" | "JSON_BEHAVIOR_EMPTY" | "JSON_BEHAVIOR_TRUE" | "JSON_BEHAVIOR_FALSE" | "JSON_BEHAVIOR_UNKNOWN" | "JSON_BEHAVIOR_EMPTY_ARRAY" | "JSON_BEHAVIOR_EMPTY_OBJECT" | "JSON_BEHAVIOR_DEFAULT"; -export type JsonExprOp = "JSON_EXISTS_OP" | "JSON_QUERY_OP" | "JSON_VALUE_OP" | "JSON_TABLE_OP"; -export type NullTestType = "IS_NULL" | "IS_NOT_NULL"; -export type BoolTestType = "IS_TRUE" | "IS_NOT_TRUE" | "IS_FALSE" | "IS_NOT_FALSE" | "IS_UNKNOWN" | "IS_NOT_UNKNOWN"; -export type MergeMatchKind = "MERGE_WHEN_MATCHED" | "MERGE_WHEN_NOT_MATCHED_BY_SOURCE" | "MERGE_WHEN_NOT_MATCHED_BY_TARGET"; -export type CmdType = "CMD_UNKNOWN" | "CMD_SELECT" | "CMD_UPDATE" | "CMD_INSERT" | "CMD_DELETE" | "CMD_MERGE" | "CMD_UTILITY" | "CMD_NOTHING"; -export type JoinType = "JOIN_INNER" | "JOIN_LEFT" | "JOIN_FULL" | "JOIN_RIGHT" | "JOIN_SEMI" | "JOIN_ANTI" | "JOIN_RIGHT_ANTI" | "JOIN_UNIQUE_OUTER" | "JOIN_UNIQUE_INNER"; -export type AggStrategy = "AGG_PLAIN" | "AGG_SORTED" | "AGG_HASHED" | "AGG_MIXED"; -export type AggSplit = "AGGSPLIT_SIMPLE" | "AGGSPLIT_INITIAL_SERIAL" | "AGGSPLIT_FINAL_DESERIAL"; -export type SetOpCmd = "SETOPCMD_INTERSECT" | "SETOPCMD_INTERSECT_ALL" | "SETOPCMD_EXCEPT" | "SETOPCMD_EXCEPT_ALL"; -export type SetOpStrategy = "SETOP_SORTED" | "SETOP_HASHED"; -export type OnConflictAction = "ONCONFLICT_NONE" | "ONCONFLICT_NOTHING" | "ONCONFLICT_UPDATE"; -export type LimitOption = "LIMIT_OPTION_DEFAULT" | "LIMIT_OPTION_COUNT" | "LIMIT_OPTION_WITH_TIES"; -export type LockClauseStrength = "LCS_NONE" | "LCS_FORKEYSHARE" | "LCS_FORSHARE" | "LCS_FORNOKEYUPDATE" | "LCS_FORUPDATE"; -export type LockWaitPolicy = "LockWaitBlock" | "LockWaitSkip" | "LockWaitError"; -export type LockTupleMode = "LockTupleKeyShare" | "LockTupleShare" | "LockTupleNoKeyExclusive" | "LockTupleExclusive"; -export type KeywordKind = "NO_KEYWORD" | "UNRESERVED_KEYWORD" | "COL_NAME_KEYWORD" | "TYPE_FUNC_NAME_KEYWORD" | "RESERVED_KEYWORD"; -export type Token = "NUL" | "ASCII_36" | "ASCII_37" | "ASCII_40" | "ASCII_41" | "ASCII_42" | "ASCII_43" | "ASCII_44" | "ASCII_45" | "ASCII_46" | "ASCII_47" | "ASCII_58" | "ASCII_59" | "ASCII_60" | "ASCII_61" | "ASCII_62" | "ASCII_63" | "ASCII_91" | "ASCII_92" | "ASCII_93" | "ASCII_94" | "IDENT" | "UIDENT" | "FCONST" | "SCONST" | "USCONST" | "BCONST" | "XCONST" | "Op" | "ICONST" | "PARAM" | "TYPECAST" | "DOT_DOT" | "COLON_EQUALS" | "EQUALS_GREATER" | "LESS_EQUALS" | "GREATER_EQUALS" | "NOT_EQUALS" | "SQL_COMMENT" | "C_COMMENT" | "ABORT_P" | "ABSENT" | "ABSOLUTE_P" | "ACCESS" | "ACTION" | "ADD_P" | "ADMIN" | "AFTER" | "AGGREGATE" | "ALL" | "ALSO" | "ALTER" | "ALWAYS" | "ANALYSE" | "ANALYZE" | "AND" | "ANY" | "ARRAY" | "AS" | "ASC" | "ASENSITIVE" | "ASSERTION" | "ASSIGNMENT" | "ASYMMETRIC" | "ATOMIC" | "AT" | "ATTACH" | "ATTRIBUTE" | "AUTHORIZATION" | "BACKWARD" | "BEFORE" | "BEGIN_P" | "BETWEEN" | "BIGINT" | "BINARY" | "BIT" | "BOOLEAN_P" | "BOTH" | "BREADTH" | "BY" | "CACHE" | "CALL" | "CALLED" | "CASCADE" | "CASCADED" | "CASE" | "CAST" | "CATALOG_P" | "CHAIN" | "CHAR_P" | "CHARACTER" | "CHARACTERISTICS" | "CHECK" | "CHECKPOINT" | "CLASS" | "CLOSE" | "CLUSTER" | "COALESCE" | "COLLATE" | "COLLATION" | "COLUMN" | "COLUMNS" | "COMMENT" | "COMMENTS" | "COMMIT" | "COMMITTED" | "COMPRESSION" | "CONCURRENTLY" | "CONDITIONAL" | "CONFIGURATION" | "CONFLICT" | "CONNECTION" | "CONSTRAINT" | "CONSTRAINTS" | "CONTENT_P" | "CONTINUE_P" | "CONVERSION_P" | "COPY" | "COST" | "CREATE" | "CROSS" | "CSV" | "CUBE" | "CURRENT_P" | "CURRENT_CATALOG" | "CURRENT_DATE" | "CURRENT_ROLE" | "CURRENT_SCHEMA" | "CURRENT_TIME" | "CURRENT_TIMESTAMP" | "CURRENT_USER" | "CURSOR" | "CYCLE" | "DATA_P" | "DATABASE" | "DAY_P" | "DEALLOCATE" | "DEC" | "DECIMAL_P" | "DECLARE" | "DEFAULT" | "DEFAULTS" | "DEFERRABLE" | "DEFERRED" | "DEFINER" | "DELETE_P" | "DELIMITER" | "DELIMITERS" | "DEPENDS" | "DEPTH" | "DESC" | "DETACH" | "DICTIONARY" | "DISABLE_P" | "DISCARD" | "DISTINCT" | "DO" | "DOCUMENT_P" | "DOMAIN_P" | "DOUBLE_P" | "DROP" | "EACH" | "ELSE" | "EMPTY_P" | "ENABLE_P" | "ENCODING" | "ENCRYPTED" | "END_P" | "ENUM_P" | "ERROR_P" | "ESCAPE" | "EVENT" | "EXCEPT" | "EXCLUDE" | "EXCLUDING" | "EXCLUSIVE" | "EXECUTE" | "EXISTS" | "EXPLAIN" | "EXPRESSION" | "EXTENSION" | "EXTERNAL" | "EXTRACT" | "FALSE_P" | "FAMILY" | "FETCH" | "FILTER" | "FINALIZE" | "FIRST_P" | "FLOAT_P" | "FOLLOWING" | "FOR" | "FORCE" | "FOREIGN" | "FORMAT" | "FORWARD" | "FREEZE" | "FROM" | "FULL" | "FUNCTION" | "FUNCTIONS" | "GENERATED" | "GLOBAL" | "GRANT" | "GRANTED" | "GREATEST" | "GROUP_P" | "GROUPING" | "GROUPS" | "HANDLER" | "HAVING" | "HEADER_P" | "HOLD" | "HOUR_P" | "IDENTITY_P" | "IF_P" | "ILIKE" | "IMMEDIATE" | "IMMUTABLE" | "IMPLICIT_P" | "IMPORT_P" | "IN_P" | "INCLUDE" | "INCLUDING" | "INCREMENT" | "INDENT" | "INDEX" | "INDEXES" | "INHERIT" | "INHERITS" | "INITIALLY" | "INLINE_P" | "INNER_P" | "INOUT" | "INPUT_P" | "INSENSITIVE" | "INSERT" | "INSTEAD" | "INT_P" | "INTEGER" | "INTERSECT" | "INTERVAL" | "INTO" | "INVOKER" | "IS" | "ISNULL" | "ISOLATION" | "JOIN" | "JSON" | "JSON_ARRAY" | "JSON_ARRAYAGG" | "JSON_EXISTS" | "JSON_OBJECT" | "JSON_OBJECTAGG" | "JSON_QUERY" | "JSON_SCALAR" | "JSON_SERIALIZE" | "JSON_TABLE" | "JSON_VALUE" | "KEEP" | "KEY" | "KEYS" | "LABEL" | "LANGUAGE" | "LARGE_P" | "LAST_P" | "LATERAL_P" | "LEADING" | "LEAKPROOF" | "LEAST" | "LEFT" | "LEVEL" | "LIKE" | "LIMIT" | "LISTEN" | "LOAD" | "LOCAL" | "LOCALTIME" | "LOCALTIMESTAMP" | "LOCATION" | "LOCK_P" | "LOCKED" | "LOGGED" | "MAPPING" | "MATCH" | "MATCHED" | "MATERIALIZED" | "MAXVALUE" | "MERGE" | "MERGE_ACTION" | "METHOD" | "MINUTE_P" | "MINVALUE" | "MODE" | "MONTH_P" | "MOVE" | "NAME_P" | "NAMES" | "NATIONAL" | "NATURAL" | "NCHAR" | "NESTED" | "NEW" | "NEXT" | "NFC" | "NFD" | "NFKC" | "NFKD" | "NO" | "NONE" | "NORMALIZE" | "NORMALIZED" | "NOT" | "NOTHING" | "NOTIFY" | "NOTNULL" | "NOWAIT" | "NULL_P" | "NULLIF" | "NULLS_P" | "NUMERIC" | "OBJECT_P" | "OF" | "OFF" | "OFFSET" | "OIDS" | "OLD" | "OMIT" | "ON" | "ONLY" | "OPERATOR" | "OPTION" | "OPTIONS" | "OR" | "ORDER" | "ORDINALITY" | "OTHERS" | "OUT_P" | "OUTER_P" | "OVER" | "OVERLAPS" | "OVERLAY" | "OVERRIDING" | "OWNED" | "OWNER" | "PARALLEL" | "PARAMETER" | "PARSER" | "PARTIAL" | "PARTITION" | "PASSING" | "PASSWORD" | "PATH" | "PLACING" | "PLAN" | "PLANS" | "POLICY" | "POSITION" | "PRECEDING" | "PRECISION" | "PRESERVE" | "PREPARE" | "PREPARED" | "PRIMARY" | "PRIOR" | "PRIVILEGES" | "PROCEDURAL" | "PROCEDURE" | "PROCEDURES" | "PROGRAM" | "PUBLICATION" | "QUOTE" | "QUOTES" | "RANGE" | "READ" | "REAL" | "REASSIGN" | "RECHECK" | "RECURSIVE" | "REF_P" | "REFERENCES" | "REFERENCING" | "REFRESH" | "REINDEX" | "RELATIVE_P" | "RELEASE" | "RENAME" | "REPEATABLE" | "REPLACE" | "REPLICA" | "RESET" | "RESTART" | "RESTRICT" | "RETURN" | "RETURNING" | "RETURNS" | "REVOKE" | "RIGHT" | "ROLE" | "ROLLBACK" | "ROLLUP" | "ROUTINE" | "ROUTINES" | "ROW" | "ROWS" | "RULE" | "SAVEPOINT" | "SCALAR" | "SCHEMA" | "SCHEMAS" | "SCROLL" | "SEARCH" | "SECOND_P" | "SECURITY" | "SELECT" | "SEQUENCE" | "SEQUENCES" | "SERIALIZABLE" | "SERVER" | "SESSION" | "SESSION_USER" | "SET" | "SETS" | "SETOF" | "SHARE" | "SHOW" | "SIMILAR" | "SIMPLE" | "SKIP" | "SMALLINT" | "SNAPSHOT" | "SOME" | "SOURCE" | "SQL_P" | "STABLE" | "STANDALONE_P" | "START" | "STATEMENT" | "STATISTICS" | "STDIN" | "STDOUT" | "STORAGE" | "STORED" | "STRICT_P" | "STRING_P" | "STRIP_P" | "SUBSCRIPTION" | "SUBSTRING" | "SUPPORT" | "SYMMETRIC" | "SYSID" | "SYSTEM_P" | "SYSTEM_USER" | "TABLE" | "TABLES" | "TABLESAMPLE" | "TABLESPACE" | "TARGET" | "TEMP" | "TEMPLATE" | "TEMPORARY" | "TEXT_P" | "THEN" | "TIES" | "TIME" | "TIMESTAMP" | "TO" | "TRAILING" | "TRANSACTION" | "TRANSFORM" | "TREAT" | "TRIGGER" | "TRIM" | "TRUE_P" | "TRUNCATE" | "TRUSTED" | "TYPE_P" | "TYPES_P" | "UESCAPE" | "UNBOUNDED" | "UNCONDITIONAL" | "UNCOMMITTED" | "UNENCRYPTED" | "UNION" | "UNIQUE" | "UNKNOWN" | "UNLISTEN" | "UNLOGGED" | "UNTIL" | "UPDATE" | "USER" | "USING" | "VACUUM" | "VALID" | "VALIDATE" | "VALIDATOR" | "VALUE_P" | "VALUES" | "VARCHAR" | "VARIADIC" | "VARYING" | "VERBOSE" | "VERSION_P" | "VIEW" | "VIEWS" | "VOLATILE" | "WHEN" | "WHERE" | "WHITESPACE_P" | "WINDOW" | "WITH" | "WITHIN" | "WITHOUT" | "WORK" | "WRAPPER" | "WRITE" | "XML_P" | "XMLATTRIBUTES" | "XMLCONCAT" | "XMLELEMENT" | "XMLEXISTS" | "XMLFOREST" | "XMLNAMESPACES" | "XMLPARSE" | "XMLPI" | "XMLROOT" | "XMLSERIALIZE" | "XMLTABLE" | "YEAR_P" | "YES_P" | "ZONE" | "FORMAT_LA" | "NOT_LA" | "NULLS_LA" | "WITH_LA" | "WITHOUT_LA" | "MODE_TYPE_NAME" | "MODE_PLPGSQL_EXPR" | "MODE_PLPGSQL_ASSIGN1" | "MODE_PLPGSQL_ASSIGN2" | "MODE_PLPGSQL_ASSIGN3" | "UMINUS"; \ No newline at end of file diff --git a/packages/types/src/index.ts b/packages/types/src/index.ts deleted file mode 100644 index dc5ee069..00000000 --- a/packages/types/src/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from './types'; -export * from './enums'; diff --git a/packages/types/tsconfig.esm.json b/packages/types/tsconfig.esm.json deleted file mode 100644 index 800d7506..00000000 --- a/packages/types/tsconfig.esm.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "outDir": "dist/esm", - "module": "es2022", - "rootDir": "src/", - "declaration": false - } -} diff --git a/packages/types/tsconfig.json b/packages/types/tsconfig.json deleted file mode 100644 index 1a9d5696..00000000 --- a/packages/types/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "dist", - "rootDir": "src/" - }, - "include": ["src/**/*.ts"], - "exclude": ["dist", "node_modules", "**/*.spec.*", "**/*.test.*"] -} diff --git a/packages/utils/__test__/__snapshots__/utils.test.ts.snap b/packages/utils/__test__/__snapshots__/utils.test.ts.snap index 45802c9d..c185dcac 100644 --- a/packages/utils/__test__/__snapshots__/utils.test.ts.snap +++ b/packages/utils/__test__/__snapshots__/utils.test.ts.snap @@ -1,25 +1,6 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`dynamic creation of tables 1`] = ` -"CREATE TABLE users ( - id int PRIMARY KEY, - username text, - email text UNIQUE, - created_at timestamp NOT NULL -)" -`; - -exports[`getEnumValue snapshots 1`] = `"AEXPR_OP"`; - -exports[`getEnumValue snapshots 2`] = `"AEXPR_OP_ANY"`; - -exports[`getEnumValue snapshots 3`] = `"AEXPR_OP_ALL"`; - -exports[`getEnumValue snapshots 4`] = `"AEXPR_DISTINCT"`; - -exports[`getEnumValue snapshots 5`] = `"AEXPR_NOT_DISTINCT"`; - -exports[`getEnumValue snapshots 6`] = `"AEXPR_NULLIF"`; +exports[`dynamic creation of tables 1`] = `"CREATE TABLE users (id int PRIMARY KEY, username text, email text UNIQUE, created_at timestamp NOT NULL)"`; exports[`simple SelectStmt 1`] = ` { diff --git a/packages/utils/__test__/utils.test.ts.no.run b/packages/utils/__test__/utils.test.ts similarity index 55% rename from packages/utils/__test__/utils.test.ts.no.run rename to packages/utils/__test__/utils.test.ts index 6db1559e..1957e7d9 100644 --- a/packages/utils/__test__/utils.test.ts.no.run +++ b/packages/utils/__test__/utils.test.ts @@ -1,24 +1,18 @@ -import * as u from '../src'; -import ast, { SelectStmt, RangeVar } from '../src'; +import * as t from '../src'; +import { RangeVar, SelectStmt } from '@pgsql/types'; import { deparse } from 'pgsql-deparser'; -it('getEnumValue snapshots', () => { - for (let i = 0; i <= 5; i++) { - expect(u.getEnumValue('A_Expr_Kind', i)).toMatchSnapshot(); - } -}); - it('simple SelectStmt', () => { - const stmt: SelectStmt = ast.selectStmt({ + const stmt: { SelectStmt: SelectStmt } = t.nodes.selectStmt({ targetList: [ - ast.resTarget({ - val: ast.columnRef({ - fields: [ast.aStar()] + t.nodes.resTarget({ + val: t.nodes.columnRef({ + fields: [t.nodes.aStar()] }) }) ], fromClause: [ - ast.rangeVar({ + t.nodes.rangeVar({ relname: 'some_table', inh: true, relpersistence: 'p' @@ -28,44 +22,43 @@ it('simple SelectStmt', () => { op: 'SETOP_NONE' }); - // @ts-ignore (because of optional args) - stmt.SelectStmt.fromClause[0].RangeVar.relname = 'another_table'; + (stmt.SelectStmt.fromClause[0] as {RangeVar: RangeVar}).RangeVar.relname = 'another_table'; expect(stmt).toMatchSnapshot(); expect(deparse(stmt, {})).toMatchSnapshot(); }); it('SelectStmt with WHERE clause', () => { - const selectStmt: SelectStmt = ast.selectStmt({ + const selectStmt: { SelectStmt: SelectStmt } = t.nodes.selectStmt({ targetList: [ - ast.resTarget({ - val: ast.columnRef({ - fields: [ast.aStar()] + t.nodes.resTarget({ + val: t.nodes.columnRef({ + fields: [t.nodes.aStar()] }) }) ], fromClause: [ - ast.rangeVar({ + t.nodes.rangeVar({ schemaname: 'myschema', relname: 'mytable', inh: true, relpersistence: 'p' }) ], - whereClause: ast.aExpr({ + whereClause: t.nodes.aExpr({ kind: 'AEXPR_OP', - name: [ast.string({ str: '=' })], - lexpr: ast.columnRef({ - fields: [ast.string({ str: 'a' })] + name: [t.nodes.string({ sval: '=' })], + lexpr: t.nodes.columnRef({ + fields: [t.nodes.string({ sval: 'a' })] }), - rexpr: ast.typeCast({ - arg: ast.aConst({ - val: ast.string({ str: 't' }) + rexpr: t.nodes.typeCast({ + arg: t.nodes.aConst({ + sval: t.ast.string({ sval: 't' }) }), - typeName: ast.typeName({ + typeName: t.ast.typeName({ names: [ - ast.string({ str: 'pg_catalog' }), - ast.string({ str: 'bool' }) + t.nodes.string({ sval: 'pg_catalog' }), + t.nodes.string({ sval: 'bool' }) ], typemod: -1 }) @@ -74,7 +67,8 @@ it('SelectStmt with WHERE clause', () => { limitOption: 'LIMIT_OPTION_DEFAULT', op: 'SETOP_NONE' }); - expect(deparse(selectStmt, {})).toEqual('SELECT * FROM myschema.mytable WHERE a = TRUE'); + + expect(deparse(selectStmt, {})).toEqual(`SELECT * FROM myschema.mytable WHERE a = CAST('t' AS boolean)`); }); it('dynamic creation of tables', () => { @@ -90,19 +84,19 @@ it('dynamic creation of tables', () => { }; // Construct the CREATE TABLE statement - const createStmt = ast.createStmt({ - relation: ast.rangeVar({ + const createStmt = t.nodes.createStmt({ + relation: t.ast.rangeVar({ relname: schema.tableName, inh: true, relpersistence: 'p' - }).RangeVar as RangeVar, // special case due to PG AST - tableElts: schema.columns.map(column => ast.columnDef({ + }), + tableElts: schema.columns.map(column => t.nodes.columnDef({ colname: column.name, - typeName: ast.typeName({ - names: [ast.string({ str: column.type })] + typeName: t.ast.typeName({ + names: [t.nodes.string({ sval: column.type })] }), constraints: column.constraints?.map(constraint => - ast.constraint({ + t.nodes.constraint({ contype: constraint === "PRIMARY KEY" ? "CONSTR_PRIMARY" : constraint === "UNIQUE" ? "CONSTR_UNIQUE" : "CONSTR_NOTNULL" }) ) diff --git a/packages/utils/package.json b/packages/utils/package.json index deff8037..9ae42769 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -31,10 +31,11 @@ "test:watch": "jest --watch" }, "devDependencies": { - "pg-proto-parser": "^1.28.2" + "pg-proto-parser": "^1.28.2", + "pgsql-deparser": "^17.6.2" }, "dependencies": { - "@pgsql/types": "^17.5.2", + "@pgsql/types": "^17.5.3", "nested-obj": "0.0.1" }, "keywords": [] diff --git a/packages/utils/scripts/pg-proto-parser.ts b/packages/utils/scripts/pg-proto-parser.ts index d215ea78..6ce8f9d9 100644 --- a/packages/utils/scripts/pg-proto-parser.ts +++ b/packages/utils/scripts/pg-proto-parser.ts @@ -9,11 +9,26 @@ const options: PgProtoParserOptions = { types: { enabled: false }, + enums: { + enabled: false, + }, utils: { + enums: { + enabled: false, + }, astHelpers: { enabled: true, - typesSource: '@pgsql/types' + typesSource: '@pgsql/types', + }, + wrappedAstHelpers: { + enabled: true, + filename: 'wrapped.ts' } + }, + runtimeSchema: { + enabled: true, + filename: 'runtime-schema.ts', + format: 'typescript' } }; const parser = new PgProtoParser(inFile, options); diff --git a/packages/utils/src/asts.ts b/packages/utils/src/asts.ts index b6e01b99..a44ef610 100644 --- a/packages/utils/src/asts.ts +++ b/packages/utils/src/asts.ts @@ -1,136 +1,64 @@ /** -* This file was automatically generated by pg-proto-parser@1.28.1. +* This file was automatically generated by pg-proto-parser@1.28.2. * DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, * and run the pg-proto-parser generate command to regenerate this file. */ import _o from "nested-obj"; import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, WindowFuncRunCondition, MergeSupportFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, JsonBehavior, JsonExpr, JsonTablePath, JsonTablePathScan, JsonTableSiblingJoin, NullTest, BooleanTest, MergeAction, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, SinglePartitionSpec, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, TriggerTransition, JsonOutput, JsonArgument, JsonFuncExpr, JsonTablePathSpec, JsonTable, JsonTableColumn, JsonKeyValue, JsonParseExpr, JsonScalarExpr, JsonSerializeExpr, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "@pgsql/types"; export default { - parseResult(_p?: ParseResult, isNode?: boolean): ParseResult | { - ParseResult: ParseResult; - } { + parseResult(_p?: ParseResult): ParseResult { const _j = {} as ParseResult; _o.set(_j, "version", _p?.version); _o.set(_j, "stmts", _p?.stmts); - if (isNode) { - return { - ParseResult: _j - }; - } return _j; }, - scanResult(_p?: ScanResult, isNode?: boolean): ScanResult | { - ScanResult: ScanResult; - } { + scanResult(_p?: ScanResult): ScanResult { const _j = {} as ScanResult; _o.set(_j, "version", _p?.version); _o.set(_j, "tokens", _p?.tokens); - if (isNode) { - return { - ScanResult: _j - }; - } return _j; }, - integer(_p?: Integer, isNode?: boolean): Integer | { - Integer: Integer; - } { + integer(_p?: Integer): Integer { const _j = {} as Integer; _o.set(_j, "ival", _p?.ival); - if (isNode) { - return { - Integer: _j - }; - } return _j; }, - float(_p?: Float, isNode?: boolean): Float | { - Float: Float; - } { + float(_p?: Float): Float { const _j = {} as Float; _o.set(_j, "fval", _p?.fval); - if (isNode) { - return { - Float: _j - }; - } return _j; }, - boolean(_p?: Boolean, isNode?: boolean): Boolean | { - Boolean: Boolean; - } { + boolean(_p?: Boolean): Boolean { const _j = {} as Boolean; _o.set(_j, "boolval", _p?.boolval); - if (isNode) { - return { - Boolean: _j - }; - } return _j; }, - string(_p?: String, isNode?: boolean): String | { - String: String; - } { + string(_p?: String): String { const _j = {} as String; _o.set(_j, "sval", _p?.sval); - if (isNode) { - return { - String: _j - }; - } return _j; }, - bitString(_p?: BitString, isNode?: boolean): BitString | { - BitString: BitString; - } { + bitString(_p?: BitString): BitString { const _j = {} as BitString; _o.set(_j, "bsval", _p?.bsval); - if (isNode) { - return { - BitString: _j - }; - } return _j; }, - list(_p?: List, isNode?: boolean): List | { - List: List; - } { + list(_p?: List): List { const _j = {} as List; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - List: _j - }; - } return _j; }, - oidList(_p?: OidList, isNode?: boolean): OidList | { - OidList: OidList; - } { + oidList(_p?: OidList): OidList { const _j = {} as OidList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - OidList: _j - }; - } return _j; }, - intList(_p?: IntList, isNode?: boolean): IntList | { - IntList: IntList; - } { + intList(_p?: IntList): IntList { const _j = {} as IntList; _o.set(_j, "items", _p?.items); - if (isNode) { - return { - IntList: _j - }; - } return _j; }, - aConst(_p?: A_Const, isNode?: boolean): A_Const | { - A_Const: A_Const; - } { + aConst(_p?: A_Const): A_Const { const _j = {} as A_Const; _o.set(_j, "ival", _p?.ival); _o.set(_j, "fval", _p?.fval); @@ -139,29 +67,15 @@ export default { _o.set(_j, "bsval", _p?.bsval); _o.set(_j, "isnull", _p?.isnull); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Const: _j - }; - } return _j; }, - alias(_p?: Alias, isNode?: boolean): Alias | { - Alias: Alias; - } { + alias(_p?: Alias): Alias { const _j = {} as Alias; _o.set(_j, "aliasname", _p?.aliasname); _o.set(_j, "colnames", _p?.colnames); - if (isNode) { - return { - Alias: _j - }; - } return _j; }, - rangeVar(_p?: RangeVar, isNode?: boolean): RangeVar | { - RangeVar: RangeVar; - } { + rangeVar(_p?: RangeVar): RangeVar { const _j = {} as RangeVar; _o.set(_j, "catalogname", _p?.catalogname); _o.set(_j, "schemaname", _p?.schemaname); @@ -170,16 +84,9 @@ export default { _o.set(_j, "relpersistence", _p?.relpersistence); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeVar: _j - }; - } return _j; }, - tableFunc(_p?: TableFunc, isNode?: boolean): TableFunc | { - TableFunc: TableFunc; - } { + tableFunc(_p?: TableFunc): TableFunc { const _j = {} as TableFunc; _o.set(_j, "functype", _p?.functype); _o.set(_j, "ns_uris", _p?.ns_uris); @@ -198,16 +105,9 @@ export default { _o.set(_j, "plan", _p?.plan); _o.set(_j, "ordinalitycol", _p?.ordinalitycol); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TableFunc: _j - }; - } return _j; }, - intoClause(_p?: IntoClause, isNode?: boolean): IntoClause | { - IntoClause: IntoClause; - } { + intoClause(_p?: IntoClause): IntoClause { const _j = {} as IntoClause; _o.set(_j, "rel", _p?.rel); _o.set(_j, "colNames", _p?.colNames); @@ -217,16 +117,9 @@ export default { _o.set(_j, "tableSpaceName", _p?.tableSpaceName); _o.set(_j, "viewQuery", _p?.viewQuery); _o.set(_j, "skipData", _p?.skipData); - if (isNode) { - return { - IntoClause: _j - }; - } return _j; }, - var(_p?: Var, isNode?: boolean): Var | { - Var: Var; - } { + var(_p?: Var): Var { const _j = {} as Var; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "varno", _p?.varno); @@ -237,16 +130,9 @@ export default { _o.set(_j, "varnullingrels", _p?.varnullingrels); _o.set(_j, "varlevelsup", _p?.varlevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Var: _j - }; - } return _j; }, - param(_p?: Param, isNode?: boolean): Param | { - Param: Param; - } { + param(_p?: Param): Param { const _j = {} as Param; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "paramkind", _p?.paramkind); @@ -255,16 +141,9 @@ export default { _o.set(_j, "paramtypmod", _p?.paramtypmod); _o.set(_j, "paramcollid", _p?.paramcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Param: _j - }; - } return _j; }, - aggref(_p?: Aggref, isNode?: boolean): Aggref | { - Aggref: Aggref; - } { + aggref(_p?: Aggref): Aggref { const _j = {} as Aggref; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "aggfnoid", _p?.aggfnoid); @@ -285,32 +164,18 @@ export default { _o.set(_j, "aggno", _p?.aggno); _o.set(_j, "aggtransno", _p?.aggtransno); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Aggref: _j - }; - } return _j; }, - groupingFunc(_p?: GroupingFunc, isNode?: boolean): GroupingFunc | { - GroupingFunc: GroupingFunc; - } { + groupingFunc(_p?: GroupingFunc): GroupingFunc { const _j = {} as GroupingFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); _o.set(_j, "refs", _p?.refs); _o.set(_j, "agglevelsup", _p?.agglevelsup); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingFunc: _j - }; - } return _j; }, - windowFunc(_p?: WindowFunc, isNode?: boolean): WindowFunc | { - WindowFunc: WindowFunc; - } { + windowFunc(_p?: WindowFunc): WindowFunc { const _j = {} as WindowFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "winfnoid", _p?.winfnoid); @@ -324,47 +189,26 @@ export default { _o.set(_j, "winstar", _p?.winstar); _o.set(_j, "winagg", _p?.winagg); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowFunc: _j - }; - } return _j; }, - windowFuncRunCondition(_p?: WindowFuncRunCondition, isNode?: boolean): WindowFuncRunCondition | { - WindowFuncRunCondition: WindowFuncRunCondition; - } { + windowFuncRunCondition(_p?: WindowFuncRunCondition): WindowFuncRunCondition { const _j = {} as WindowFuncRunCondition; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "wfunc_left", _p?.wfunc_left); _o.set(_j, "arg", _p?.arg); - if (isNode) { - return { - WindowFuncRunCondition: _j - }; - } return _j; }, - mergeSupportFunc(_p?: MergeSupportFunc, isNode?: boolean): MergeSupportFunc | { - MergeSupportFunc: MergeSupportFunc; - } { + mergeSupportFunc(_p?: MergeSupportFunc): MergeSupportFunc { const _j = {} as MergeSupportFunc; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "msftype", _p?.msftype); _o.set(_j, "msfcollid", _p?.msfcollid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MergeSupportFunc: _j - }; - } return _j; }, - subscriptingRef(_p?: SubscriptingRef, isNode?: boolean): SubscriptingRef | { - SubscriptingRef: SubscriptingRef; - } { + subscriptingRef(_p?: SubscriptingRef): SubscriptingRef { const _j = {} as SubscriptingRef; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "refcontainertype", _p?.refcontainertype); @@ -376,16 +220,9 @@ export default { _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); _o.set(_j, "refexpr", _p?.refexpr); _o.set(_j, "refassgnexpr", _p?.refassgnexpr); - if (isNode) { - return { - SubscriptingRef: _j - }; - } return _j; }, - funcExpr(_p?: FuncExpr, isNode?: boolean): FuncExpr | { - FuncExpr: FuncExpr; - } { + funcExpr(_p?: FuncExpr): FuncExpr { const _j = {} as FuncExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "funcid", _p?.funcid); @@ -397,32 +234,18 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncExpr: _j - }; - } return _j; }, - namedArgExpr(_p?: NamedArgExpr, isNode?: boolean): NamedArgExpr | { - NamedArgExpr: NamedArgExpr; - } { + namedArgExpr(_p?: NamedArgExpr): NamedArgExpr { const _j = {} as NamedArgExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "name", _p?.name); _o.set(_j, "argnumber", _p?.argnumber); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NamedArgExpr: _j - }; - } return _j; }, - opExpr(_p?: OpExpr, isNode?: boolean): OpExpr | { - OpExpr: OpExpr; - } { + opExpr(_p?: OpExpr): OpExpr { const _j = {} as OpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -432,16 +255,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OpExpr: _j - }; - } return _j; }, - distinctExpr(_p?: DistinctExpr, isNode?: boolean): DistinctExpr | { - DistinctExpr: DistinctExpr; - } { + distinctExpr(_p?: DistinctExpr): DistinctExpr { const _j = {} as DistinctExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -451,16 +267,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DistinctExpr: _j - }; - } return _j; }, - nullIfExpr(_p?: NullIfExpr, isNode?: boolean): NullIfExpr | { - NullIfExpr: NullIfExpr; - } { + nullIfExpr(_p?: NullIfExpr): NullIfExpr { const _j = {} as NullIfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -470,16 +279,9 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullIfExpr: _j - }; - } return _j; }, - scalarArrayOpExpr(_p?: ScalarArrayOpExpr, isNode?: boolean): ScalarArrayOpExpr | { - ScalarArrayOpExpr: ScalarArrayOpExpr; - } { + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): ScalarArrayOpExpr { const _j = {} as ScalarArrayOpExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "opno", _p?.opno); @@ -487,31 +289,17 @@ export default { _o.set(_j, "inputcollid", _p?.inputcollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ScalarArrayOpExpr: _j - }; - } return _j; }, - boolExpr(_p?: BoolExpr, isNode?: boolean): BoolExpr | { - BoolExpr: BoolExpr; - } { + boolExpr(_p?: BoolExpr): BoolExpr { const _j = {} as BoolExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "boolop", _p?.boolop); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BoolExpr: _j - }; - } return _j; }, - subLink(_p?: SubLink, isNode?: boolean): SubLink | { - SubLink: SubLink; - } { + subLink(_p?: SubLink): SubLink { const _j = {} as SubLink; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -520,16 +308,9 @@ export default { _o.set(_j, "operName", _p?.operName); _o.set(_j, "subselect", _p?.subselect); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SubLink: _j - }; - } return _j; }, - subPlan(_p?: SubPlan, isNode?: boolean): SubPlan | { - SubPlan: SubPlan; - } { + subPlan(_p?: SubPlan): SubPlan { const _j = {} as SubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subLinkType", _p?.subLinkType); @@ -548,29 +329,15 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "startup_cost", _p?.startup_cost); _o.set(_j, "per_call_cost", _p?.per_call_cost); - if (isNode) { - return { - SubPlan: _j - }; - } return _j; }, - alternativeSubPlan(_p?: AlternativeSubPlan, isNode?: boolean): AlternativeSubPlan | { - AlternativeSubPlan: AlternativeSubPlan; - } { + alternativeSubPlan(_p?: AlternativeSubPlan): AlternativeSubPlan { const _j = {} as AlternativeSubPlan; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "subplans", _p?.subplans); - if (isNode) { - return { - AlternativeSubPlan: _j - }; - } return _j; }, - fieldSelect(_p?: FieldSelect, isNode?: boolean): FieldSelect | { - FieldSelect: FieldSelect; - } { + fieldSelect(_p?: FieldSelect): FieldSelect { const _j = {} as FieldSelect; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -578,32 +345,18 @@ export default { _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "resulttypmod", _p?.resulttypmod); _o.set(_j, "resultcollid", _p?.resultcollid); - if (isNode) { - return { - FieldSelect: _j - }; - } return _j; }, - fieldStore(_p?: FieldStore, isNode?: boolean): FieldStore | { - FieldStore: FieldStore; - } { + fieldStore(_p?: FieldStore): FieldStore { const _j = {} as FieldStore; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "newvals", _p?.newvals); _o.set(_j, "fieldnums", _p?.fieldnums); _o.set(_j, "resulttype", _p?.resulttype); - if (isNode) { - return { - FieldStore: _j - }; - } return _j; }, - relabelType(_p?: RelabelType, isNode?: boolean): RelabelType | { - RelabelType: RelabelType; - } { + relabelType(_p?: RelabelType): RelabelType { const _j = {} as RelabelType; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -612,16 +365,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "relabelformat", _p?.relabelformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RelabelType: _j - }; - } return _j; }, - coerceViaio(_p?: CoerceViaIO, isNode?: boolean): CoerceViaIO | { - CoerceViaIO: CoerceViaIO; - } { + coerceViaio(_p?: CoerceViaIO): CoerceViaIO { const _j = {} as CoerceViaIO; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -629,16 +375,9 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceViaIO: _j - }; - } return _j; }, - arrayCoerceExpr(_p?: ArrayCoerceExpr, isNode?: boolean): ArrayCoerceExpr | { - ArrayCoerceExpr: ArrayCoerceExpr; - } { + arrayCoerceExpr(_p?: ArrayCoerceExpr): ArrayCoerceExpr { const _j = {} as ArrayCoerceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -648,47 +387,26 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coerceformat", _p?.coerceformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayCoerceExpr: _j - }; - } return _j; }, - convertRowtypeExpr(_p?: ConvertRowtypeExpr, isNode?: boolean): ConvertRowtypeExpr | { - ConvertRowtypeExpr: ConvertRowtypeExpr; - } { + convertRowtypeExpr(_p?: ConvertRowtypeExpr): ConvertRowtypeExpr { const _j = {} as ConvertRowtypeExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "resulttype", _p?.resulttype); _o.set(_j, "convertformat", _p?.convertformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ConvertRowtypeExpr: _j - }; - } return _j; }, - collateExpr(_p?: CollateExpr, isNode?: boolean): CollateExpr | { - CollateExpr: CollateExpr; - } { + collateExpr(_p?: CollateExpr): CollateExpr { const _j = {} as CollateExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "collOid", _p?.collOid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateExpr: _j - }; - } return _j; }, - caseExpr(_p?: CaseExpr, isNode?: boolean): CaseExpr | { - CaseExpr: CaseExpr; - } { + caseExpr(_p?: CaseExpr): CaseExpr { const _j = {} as CaseExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "casetype", _p?.casetype); @@ -697,46 +415,25 @@ export default { _o.set(_j, "args", _p?.args); _o.set(_j, "defresult", _p?.defresult); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseExpr: _j - }; - } return _j; }, - caseWhen(_p?: CaseWhen, isNode?: boolean): CaseWhen | { - CaseWhen: CaseWhen; - } { + caseWhen(_p?: CaseWhen): CaseWhen { const _j = {} as CaseWhen; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "result", _p?.result); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CaseWhen: _j - }; - } return _j; }, - caseTestExpr(_p?: CaseTestExpr, isNode?: boolean): CaseTestExpr | { - CaseTestExpr: CaseTestExpr; - } { + caseTestExpr(_p?: CaseTestExpr): CaseTestExpr { const _j = {} as CaseTestExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); - if (isNode) { - return { - CaseTestExpr: _j - }; - } return _j; }, - arrayExpr(_p?: ArrayExpr, isNode?: boolean): ArrayExpr | { - ArrayExpr: ArrayExpr; - } { + arrayExpr(_p?: ArrayExpr): ArrayExpr { const _j = {} as ArrayExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "array_typeid", _p?.array_typeid); @@ -745,16 +442,9 @@ export default { _o.set(_j, "elements", _p?.elements); _o.set(_j, "multidims", _p?.multidims); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ArrayExpr: _j - }; - } return _j; }, - rowExpr(_p?: RowExpr, isNode?: boolean): RowExpr | { - RowExpr: RowExpr; - } { + rowExpr(_p?: RowExpr): RowExpr { const _j = {} as RowExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "args", _p?.args); @@ -762,16 +452,9 @@ export default { _o.set(_j, "row_format", _p?.row_format); _o.set(_j, "colnames", _p?.colnames); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RowExpr: _j - }; - } return _j; }, - rowCompareExpr(_p?: RowCompareExpr, isNode?: boolean): RowCompareExpr | { - RowCompareExpr: RowCompareExpr; - } { + rowCompareExpr(_p?: RowCompareExpr): RowCompareExpr { const _j = {} as RowCompareExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "rctype", _p?.rctype); @@ -780,32 +463,18 @@ export default { _o.set(_j, "inputcollids", _p?.inputcollids); _o.set(_j, "largs", _p?.largs); _o.set(_j, "rargs", _p?.rargs); - if (isNode) { - return { - RowCompareExpr: _j - }; - } return _j; }, - coalesceExpr(_p?: CoalesceExpr, isNode?: boolean): CoalesceExpr | { - CoalesceExpr: CoalesceExpr; - } { + coalesceExpr(_p?: CoalesceExpr): CoalesceExpr { const _j = {} as CoalesceExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "coalescetype", _p?.coalescetype); _o.set(_j, "coalescecollid", _p?.coalescecollid); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoalesceExpr: _j - }; - } return _j; }, - minMaxExpr(_p?: MinMaxExpr, isNode?: boolean): MinMaxExpr | { - MinMaxExpr: MinMaxExpr; - } { + minMaxExpr(_p?: MinMaxExpr): MinMaxExpr { const _j = {} as MinMaxExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "minmaxtype", _p?.minmaxtype); @@ -814,32 +483,18 @@ export default { _o.set(_j, "op", _p?.op); _o.set(_j, "args", _p?.args); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - MinMaxExpr: _j - }; - } return _j; }, - sqlValueFunction(_p?: SQLValueFunction, isNode?: boolean): SQLValueFunction | { - SQLValueFunction: SQLValueFunction; - } { + sqlValueFunction(_p?: SQLValueFunction): SQLValueFunction { const _j = {} as SQLValueFunction; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SQLValueFunction: _j - }; - } return _j; }, - xmlExpr(_p?: XmlExpr, isNode?: boolean): XmlExpr | { - XmlExpr: XmlExpr; - } { + xmlExpr(_p?: XmlExpr): XmlExpr { const _j = {} as XmlExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -852,58 +507,30 @@ export default { _o.set(_j, "type", _p?.type); _o.set(_j, "typmod", _p?.typmod); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlExpr: _j - }; - } return _j; }, - jsonFormat(_p?: JsonFormat, isNode?: boolean): JsonFormat | { - JsonFormat: JsonFormat; - } { + jsonFormat(_p?: JsonFormat): JsonFormat { const _j = {} as JsonFormat; _o.set(_j, "format_type", _p?.format_type); _o.set(_j, "encoding", _p?.encoding); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFormat: _j - }; - } return _j; }, - jsonReturning(_p?: JsonReturning, isNode?: boolean): JsonReturning | { - JsonReturning: JsonReturning; - } { + jsonReturning(_p?: JsonReturning): JsonReturning { const _j = {} as JsonReturning; _o.set(_j, "format", _p?.format); _o.set(_j, "typid", _p?.typid); _o.set(_j, "typmod", _p?.typmod); - if (isNode) { - return { - JsonReturning: _j - }; - } return _j; }, - jsonValueExpr(_p?: JsonValueExpr, isNode?: boolean): JsonValueExpr | { - JsonValueExpr: JsonValueExpr; - } { + jsonValueExpr(_p?: JsonValueExpr): JsonValueExpr { const _j = {} as JsonValueExpr; _o.set(_j, "raw_expr", _p?.raw_expr); _o.set(_j, "formatted_expr", _p?.formatted_expr); _o.set(_j, "format", _p?.format); - if (isNode) { - return { - JsonValueExpr: _j - }; - } return _j; }, - jsonConstructorExpr(_p?: JsonConstructorExpr, isNode?: boolean): JsonConstructorExpr | { - JsonConstructorExpr: JsonConstructorExpr; - } { + jsonConstructorExpr(_p?: JsonConstructorExpr): JsonConstructorExpr { const _j = {} as JsonConstructorExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "type", _p?.type); @@ -914,47 +541,26 @@ export default { _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonConstructorExpr: _j - }; - } return _j; }, - jsonIsPredicate(_p?: JsonIsPredicate, isNode?: boolean): JsonIsPredicate | { - JsonIsPredicate: JsonIsPredicate; - } { + jsonIsPredicate(_p?: JsonIsPredicate): JsonIsPredicate { const _j = {} as JsonIsPredicate; _o.set(_j, "expr", _p?.expr); _o.set(_j, "format", _p?.format); _o.set(_j, "item_type", _p?.item_type); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonIsPredicate: _j - }; - } return _j; }, - jsonBehavior(_p?: JsonBehavior, isNode?: boolean): JsonBehavior | { - JsonBehavior: JsonBehavior; - } { + jsonBehavior(_p?: JsonBehavior): JsonBehavior { const _j = {} as JsonBehavior; _o.set(_j, "btype", _p?.btype); _o.set(_j, "expr", _p?.expr); _o.set(_j, "coerce", _p?.coerce); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonBehavior: _j - }; - } return _j; }, - jsonExpr(_p?: JsonExpr, isNode?: boolean): JsonExpr | { - JsonExpr: JsonExpr; - } { + jsonExpr(_p?: JsonExpr): JsonExpr { const _j = {} as JsonExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "op", _p?.op); @@ -973,28 +579,14 @@ export default { _o.set(_j, "omit_quotes", _p?.omit_quotes); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonExpr: _j - }; - } return _j; }, - jsonTablePath(_p?: JsonTablePath, isNode?: boolean): JsonTablePath | { - JsonTablePath: JsonTablePath; - } { + jsonTablePath(_p?: JsonTablePath): JsonTablePath { const _j = {} as JsonTablePath; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - JsonTablePath: _j - }; - } return _j; }, - jsonTablePathScan(_p?: JsonTablePathScan, isNode?: boolean): JsonTablePathScan | { - JsonTablePathScan: JsonTablePathScan; - } { + jsonTablePathScan(_p?: JsonTablePathScan): JsonTablePathScan { const _j = {} as JsonTablePathScan; _o.set(_j, "plan", _p?.plan); _o.set(_j, "path", _p?.path); @@ -1002,61 +594,33 @@ export default { _o.set(_j, "child", _p?.child); _o.set(_j, "colMin", _p?.colMin); _o.set(_j, "colMax", _p?.colMax); - if (isNode) { - return { - JsonTablePathScan: _j - }; - } return _j; }, - jsonTableSiblingJoin(_p?: JsonTableSiblingJoin, isNode?: boolean): JsonTableSiblingJoin | { - JsonTableSiblingJoin: JsonTableSiblingJoin; - } { + jsonTableSiblingJoin(_p?: JsonTableSiblingJoin): JsonTableSiblingJoin { const _j = {} as JsonTableSiblingJoin; _o.set(_j, "plan", _p?.plan); _o.set(_j, "lplan", _p?.lplan); _o.set(_j, "rplan", _p?.rplan); - if (isNode) { - return { - JsonTableSiblingJoin: _j - }; - } return _j; }, - nullTest(_p?: NullTest, isNode?: boolean): NullTest | { - NullTest: NullTest; - } { + nullTest(_p?: NullTest): NullTest { const _j = {} as NullTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "nulltesttype", _p?.nulltesttype); _o.set(_j, "argisrow", _p?.argisrow); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - NullTest: _j - }; - } return _j; }, - booleanTest(_p?: BooleanTest, isNode?: boolean): BooleanTest | { - BooleanTest: BooleanTest; - } { + booleanTest(_p?: BooleanTest): BooleanTest { const _j = {} as BooleanTest; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); _o.set(_j, "booltesttype", _p?.booltesttype); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - BooleanTest: _j - }; - } return _j; }, - mergeAction(_p?: MergeAction, isNode?: boolean): MergeAction | { - MergeAction: MergeAction; - } { + mergeAction(_p?: MergeAction): MergeAction { const _j = {} as MergeAction; _o.set(_j, "matchKind", _p?.matchKind); _o.set(_j, "commandType", _p?.commandType); @@ -1064,16 +628,9 @@ export default { _o.set(_j, "qual", _p?.qual); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "updateColnos", _p?.updateColnos); - if (isNode) { - return { - MergeAction: _j - }; - } return _j; }, - coerceToDomain(_p?: CoerceToDomain, isNode?: boolean): CoerceToDomain | { - CoerceToDomain: CoerceToDomain; - } { + coerceToDomain(_p?: CoerceToDomain): CoerceToDomain { const _j = {} as CoerceToDomain; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "arg", _p?.arg); @@ -1082,92 +639,50 @@ export default { _o.set(_j, "resultcollid", _p?.resultcollid); _o.set(_j, "coercionformat", _p?.coercionformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomain: _j - }; - } return _j; }, - coerceToDomainValue(_p?: CoerceToDomainValue, isNode?: boolean): CoerceToDomainValue | { - CoerceToDomainValue: CoerceToDomainValue; - } { + coerceToDomainValue(_p?: CoerceToDomainValue): CoerceToDomainValue { const _j = {} as CoerceToDomainValue; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CoerceToDomainValue: _j - }; - } return _j; }, - setToDefault(_p?: SetToDefault, isNode?: boolean): SetToDefault | { - SetToDefault: SetToDefault; - } { + setToDefault(_p?: SetToDefault): SetToDefault { const _j = {} as SetToDefault; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "typeId", _p?.typeId); _o.set(_j, "typeMod", _p?.typeMod); _o.set(_j, "collation", _p?.collation); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SetToDefault: _j - }; - } return _j; }, - currentOfExpr(_p?: CurrentOfExpr, isNode?: boolean): CurrentOfExpr | { - CurrentOfExpr: CurrentOfExpr; - } { + currentOfExpr(_p?: CurrentOfExpr): CurrentOfExpr { const _j = {} as CurrentOfExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "cvarno", _p?.cvarno); _o.set(_j, "cursor_name", _p?.cursor_name); _o.set(_j, "cursor_param", _p?.cursor_param); - if (isNode) { - return { - CurrentOfExpr: _j - }; - } return _j; }, - nextValueExpr(_p?: NextValueExpr, isNode?: boolean): NextValueExpr | { - NextValueExpr: NextValueExpr; - } { + nextValueExpr(_p?: NextValueExpr): NextValueExpr { const _j = {} as NextValueExpr; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "seqid", _p?.seqid); _o.set(_j, "typeId", _p?.typeId); - if (isNode) { - return { - NextValueExpr: _j - }; - } return _j; }, - inferenceElem(_p?: InferenceElem, isNode?: boolean): InferenceElem | { - InferenceElem: InferenceElem; - } { + inferenceElem(_p?: InferenceElem): InferenceElem { const _j = {} as InferenceElem; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); _o.set(_j, "infercollid", _p?.infercollid); _o.set(_j, "inferopclass", _p?.inferopclass); - if (isNode) { - return { - InferenceElem: _j - }; - } return _j; }, - targetEntry(_p?: TargetEntry, isNode?: boolean): TargetEntry | { - TargetEntry: TargetEntry; - } { + targetEntry(_p?: TargetEntry): TargetEntry { const _j = {} as TargetEntry; _o.set(_j, "xpr", _p?.xpr); _o.set(_j, "expr", _p?.expr); @@ -1177,28 +692,14 @@ export default { _o.set(_j, "resorigtbl", _p?.resorigtbl); _o.set(_j, "resorigcol", _p?.resorigcol); _o.set(_j, "resjunk", _p?.resjunk); - if (isNode) { - return { - TargetEntry: _j - }; - } return _j; }, - rangeTblRef(_p?: RangeTblRef, isNode?: boolean): RangeTblRef | { - RangeTblRef: RangeTblRef; - } { + rangeTblRef(_p?: RangeTblRef): RangeTblRef { const _j = {} as RangeTblRef; _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - RangeTblRef: _j - }; - } return _j; }, - joinExpr(_p?: JoinExpr, isNode?: boolean): JoinExpr | { - JoinExpr: JoinExpr; - } { + joinExpr(_p?: JoinExpr): JoinExpr { const _j = {} as JoinExpr; _o.set(_j, "jointype", _p?.jointype); _o.set(_j, "isNatural", _p?.isNatural); @@ -1209,29 +710,15 @@ export default { _o.set(_j, "quals", _p?.quals); _o.set(_j, "alias", _p?.alias); _o.set(_j, "rtindex", _p?.rtindex); - if (isNode) { - return { - JoinExpr: _j - }; - } return _j; }, - fromExpr(_p?: FromExpr, isNode?: boolean): FromExpr | { - FromExpr: FromExpr; - } { + fromExpr(_p?: FromExpr): FromExpr { const _j = {} as FromExpr; _o.set(_j, "fromlist", _p?.fromlist); _o.set(_j, "quals", _p?.quals); - if (isNode) { - return { - FromExpr: _j - }; - } return _j; }, - onConflictExpr(_p?: OnConflictExpr, isNode?: boolean): OnConflictExpr | { - OnConflictExpr: OnConflictExpr; - } { + onConflictExpr(_p?: OnConflictExpr): OnConflictExpr { const _j = {} as OnConflictExpr; _o.set(_j, "action", _p?.action); _o.set(_j, "arbiterElems", _p?.arbiterElems); @@ -1241,16 +728,9 @@ export default { _o.set(_j, "onConflictWhere", _p?.onConflictWhere); _o.set(_j, "exclRelIndex", _p?.exclRelIndex); _o.set(_j, "exclRelTlist", _p?.exclRelTlist); - if (isNode) { - return { - OnConflictExpr: _j - }; - } return _j; }, - query(_p?: Query, isNode?: boolean): Query | { - Query: Query; - } { + query(_p?: Query): Query { const _j = {} as Query; _o.set(_j, "commandType", _p?.commandType); _o.set(_j, "querySource", _p?.querySource); @@ -1294,16 +774,9 @@ export default { _o.set(_j, "withCheckOptions", _p?.withCheckOptions); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - Query: _j - }; - } return _j; }, - typeName(_p?: TypeName, isNode?: boolean): TypeName | { - TypeName: TypeName; - } { + typeName(_p?: TypeName): TypeName { const _j = {} as TypeName; _o.set(_j, "names", _p?.names); _o.set(_j, "typeOid", _p?.typeOid); @@ -1313,100 +786,51 @@ export default { _o.set(_j, "typemod", _p?.typemod); _o.set(_j, "arrayBounds", _p?.arrayBounds); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeName: _j - }; - } return _j; }, - columnRef(_p?: ColumnRef, isNode?: boolean): ColumnRef | { - ColumnRef: ColumnRef; - } { + columnRef(_p?: ColumnRef): ColumnRef { const _j = {} as ColumnRef; _o.set(_j, "fields", _p?.fields); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnRef: _j - }; - } return _j; }, - paramRef(_p?: ParamRef, isNode?: boolean): ParamRef | { - ParamRef: ParamRef; - } { + paramRef(_p?: ParamRef): ParamRef { const _j = {} as ParamRef; _o.set(_j, "number", _p?.number); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ParamRef: _j - }; - } return _j; }, - aExpr(_p?: A_Expr, isNode?: boolean): A_Expr | { - A_Expr: A_Expr; - } { + aExpr(_p?: A_Expr): A_Expr { const _j = {} as A_Expr; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "lexpr", _p?.lexpr); _o.set(_j, "rexpr", _p?.rexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_Expr: _j - }; - } return _j; }, - typeCast(_p?: TypeCast, isNode?: boolean): TypeCast | { - TypeCast: TypeCast; - } { + typeCast(_p?: TypeCast): TypeCast { const _j = {} as TypeCast; _o.set(_j, "arg", _p?.arg); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TypeCast: _j - }; - } return _j; }, - collateClause(_p?: CollateClause, isNode?: boolean): CollateClause | { - CollateClause: CollateClause; - } { + collateClause(_p?: CollateClause): CollateClause { const _j = {} as CollateClause; _o.set(_j, "arg", _p?.arg); _o.set(_j, "collname", _p?.collname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CollateClause: _j - }; - } return _j; }, - roleSpec(_p?: RoleSpec, isNode?: boolean): RoleSpec | { - RoleSpec: RoleSpec; - } { + roleSpec(_p?: RoleSpec): RoleSpec { const _j = {} as RoleSpec; _o.set(_j, "roletype", _p?.roletype); _o.set(_j, "rolename", _p?.rolename); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RoleSpec: _j - }; - } return _j; }, - funcCall(_p?: FuncCall, isNode?: boolean): FuncCall | { - FuncCall: FuncCall; - } { + funcCall(_p?: FuncCall): FuncCall { const _j = {} as FuncCall; _o.set(_j, "funcname", _p?.funcname); _o.set(_j, "args", _p?.args); @@ -1419,112 +843,56 @@ export default { _o.set(_j, "func_variadic", _p?.func_variadic); _o.set(_j, "funcformat", _p?.funcformat); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - FuncCall: _j - }; - } return _j; }, - aStar(_p?: A_Star, isNode?: boolean): A_Star | { - A_Star: A_Star; - } { + aStar(_p?: A_Star): A_Star { const _j = {} as A_Star; - if (isNode) { - return { - A_Star: _j - }; - } return _j; }, - aIndices(_p?: A_Indices, isNode?: boolean): A_Indices | { - A_Indices: A_Indices; - } { + aIndices(_p?: A_Indices): A_Indices { const _j = {} as A_Indices; _o.set(_j, "is_slice", _p?.is_slice); _o.set(_j, "lidx", _p?.lidx); _o.set(_j, "uidx", _p?.uidx); - if (isNode) { - return { - A_Indices: _j - }; - } return _j; }, - aIndirection(_p?: A_Indirection, isNode?: boolean): A_Indirection | { - A_Indirection: A_Indirection; - } { + aIndirection(_p?: A_Indirection): A_Indirection { const _j = {} as A_Indirection; _o.set(_j, "arg", _p?.arg); _o.set(_j, "indirection", _p?.indirection); - if (isNode) { - return { - A_Indirection: _j - }; - } return _j; }, - aArrayExpr(_p?: A_ArrayExpr, isNode?: boolean): A_ArrayExpr | { - A_ArrayExpr: A_ArrayExpr; - } { + aArrayExpr(_p?: A_ArrayExpr): A_ArrayExpr { const _j = {} as A_ArrayExpr; _o.set(_j, "elements", _p?.elements); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - A_ArrayExpr: _j - }; - } return _j; }, - resTarget(_p?: ResTarget, isNode?: boolean): ResTarget | { - ResTarget: ResTarget; - } { + resTarget(_p?: ResTarget): ResTarget { const _j = {} as ResTarget; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ResTarget: _j - }; - } return _j; }, - multiAssignRef(_p?: MultiAssignRef, isNode?: boolean): MultiAssignRef | { - MultiAssignRef: MultiAssignRef; - } { + multiAssignRef(_p?: MultiAssignRef): MultiAssignRef { const _j = {} as MultiAssignRef; _o.set(_j, "source", _p?.source); _o.set(_j, "colno", _p?.colno); _o.set(_j, "ncolumns", _p?.ncolumns); - if (isNode) { - return { - MultiAssignRef: _j - }; - } return _j; }, - sortBy(_p?: SortBy, isNode?: boolean): SortBy | { - SortBy: SortBy; - } { + sortBy(_p?: SortBy): SortBy { const _j = {} as SortBy; _o.set(_j, "node", _p?.node); _o.set(_j, "sortby_dir", _p?.sortby_dir); _o.set(_j, "sortby_nulls", _p?.sortby_nulls); _o.set(_j, "useOp", _p?.useOp); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - SortBy: _j - }; - } return _j; }, - windowDef(_p?: WindowDef, isNode?: boolean): WindowDef | { - WindowDef: WindowDef; - } { + windowDef(_p?: WindowDef): WindowDef { const _j = {} as WindowDef; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1534,30 +902,16 @@ export default { _o.set(_j, "startOffset", _p?.startOffset); _o.set(_j, "endOffset", _p?.endOffset); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WindowDef: _j - }; - } return _j; }, - rangeSubselect(_p?: RangeSubselect, isNode?: boolean): RangeSubselect | { - RangeSubselect: RangeSubselect; - } { + rangeSubselect(_p?: RangeSubselect): RangeSubselect { const _j = {} as RangeSubselect; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "subquery", _p?.subquery); _o.set(_j, "alias", _p?.alias); - if (isNode) { - return { - RangeSubselect: _j - }; - } return _j; }, - rangeFunction(_p?: RangeFunction, isNode?: boolean): RangeFunction | { - RangeFunction: RangeFunction; - } { + rangeFunction(_p?: RangeFunction): RangeFunction { const _j = {} as RangeFunction; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "ordinality", _p?.ordinality); @@ -1565,16 +919,9 @@ export default { _o.set(_j, "functions", _p?.functions); _o.set(_j, "alias", _p?.alias); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - RangeFunction: _j - }; - } return _j; }, - rangeTableFunc(_p?: RangeTableFunc, isNode?: boolean): RangeTableFunc | { - RangeTableFunc: RangeTableFunc; - } { + rangeTableFunc(_p?: RangeTableFunc): RangeTableFunc { const _j = {} as RangeTableFunc; _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "docexpr", _p?.docexpr); @@ -1583,16 +930,9 @@ export default { _o.set(_j, "columns", _p?.columns); _o.set(_j, "alias", _p?.alias); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFunc: _j - }; - } return _j; }, - rangeTableFuncCol(_p?: RangeTableFuncCol, isNode?: boolean): RangeTableFuncCol | { - RangeTableFuncCol: RangeTableFuncCol; - } { + rangeTableFuncCol(_p?: RangeTableFuncCol): RangeTableFuncCol { const _j = {} as RangeTableFuncCol; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1601,32 +941,18 @@ export default { _o.set(_j, "colexpr", _p?.colexpr); _o.set(_j, "coldefexpr", _p?.coldefexpr); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableFuncCol: _j - }; - } return _j; }, - rangeTableSample(_p?: RangeTableSample, isNode?: boolean): RangeTableSample | { - RangeTableSample: RangeTableSample; - } { + rangeTableSample(_p?: RangeTableSample): RangeTableSample { const _j = {} as RangeTableSample; _o.set(_j, "relation", _p?.relation); _o.set(_j, "method", _p?.method); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - RangeTableSample: _j - }; - } return _j; }, - columnDef(_p?: ColumnDef, isNode?: boolean): ColumnDef | { - ColumnDef: ColumnDef; - } { + columnDef(_p?: ColumnDef): ColumnDef { const _j = {} as ColumnDef; _o.set(_j, "colname", _p?.colname); _o.set(_j, "typeName", _p?.typeName); @@ -1647,30 +973,16 @@ export default { _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "fdwoptions", _p?.fdwoptions); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - ColumnDef: _j - }; - } return _j; }, - tableLikeClause(_p?: TableLikeClause, isNode?: boolean): TableLikeClause | { - TableLikeClause: TableLikeClause; - } { + tableLikeClause(_p?: TableLikeClause): TableLikeClause { const _j = {} as TableLikeClause; _o.set(_j, "relation", _p?.relation); _o.set(_j, "options", _p?.options); _o.set(_j, "relationOid", _p?.relationOid); - if (isNode) { - return { - TableLikeClause: _j - }; - } return _j; }, - indexElem(_p?: IndexElem, isNode?: boolean): IndexElem | { - IndexElem: IndexElem; - } { + indexElem(_p?: IndexElem): IndexElem { const _j = {} as IndexElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); @@ -1680,92 +992,50 @@ export default { _o.set(_j, "opclassopts", _p?.opclassopts); _o.set(_j, "ordering", _p?.ordering); _o.set(_j, "nulls_ordering", _p?.nulls_ordering); - if (isNode) { - return { - IndexElem: _j - }; - } return _j; }, - defElem(_p?: DefElem, isNode?: boolean): DefElem | { - DefElem: DefElem; - } { + defElem(_p?: DefElem): DefElem { const _j = {} as DefElem; _o.set(_j, "defnamespace", _p?.defnamespace); _o.set(_j, "defname", _p?.defname); _o.set(_j, "arg", _p?.arg); _o.set(_j, "defaction", _p?.defaction); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DefElem: _j - }; - } return _j; }, - lockingClause(_p?: LockingClause, isNode?: boolean): LockingClause | { - LockingClause: LockingClause; - } { + lockingClause(_p?: LockingClause): LockingClause { const _j = {} as LockingClause; _o.set(_j, "lockedRels", _p?.lockedRels); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); - if (isNode) { - return { - LockingClause: _j - }; - } return _j; }, - xmlSerialize(_p?: XmlSerialize, isNode?: boolean): XmlSerialize | { - XmlSerialize: XmlSerialize; - } { + xmlSerialize(_p?: XmlSerialize): XmlSerialize { const _j = {} as XmlSerialize; _o.set(_j, "xmloption", _p?.xmloption); _o.set(_j, "expr", _p?.expr); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "indent", _p?.indent); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - XmlSerialize: _j - }; - } return _j; }, - partitionElem(_p?: PartitionElem, isNode?: boolean): PartitionElem | { - PartitionElem: PartitionElem; - } { + partitionElem(_p?: PartitionElem): PartitionElem { const _j = {} as PartitionElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); _o.set(_j, "collation", _p?.collation); _o.set(_j, "opclass", _p?.opclass); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionElem: _j - }; - } return _j; }, - partitionSpec(_p?: PartitionSpec, isNode?: boolean): PartitionSpec | { - PartitionSpec: PartitionSpec; - } { + partitionSpec(_p?: PartitionSpec): PartitionSpec { const _j = {} as PartitionSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "partParams", _p?.partParams); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionSpec: _j - }; - } return _j; }, - partitionBoundSpec(_p?: PartitionBoundSpec, isNode?: boolean): PartitionBoundSpec | { - PartitionBoundSpec: PartitionBoundSpec; - } { + partitionBoundSpec(_p?: PartitionBoundSpec): PartitionBoundSpec { const _j = {} as PartitionBoundSpec; _o.set(_j, "strategy", _p?.strategy); _o.set(_j, "is_default", _p?.is_default); @@ -1775,55 +1045,27 @@ export default { _o.set(_j, "lowerdatums", _p?.lowerdatums); _o.set(_j, "upperdatums", _p?.upperdatums); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionBoundSpec: _j - }; - } return _j; }, - partitionRangeDatum(_p?: PartitionRangeDatum, isNode?: boolean): PartitionRangeDatum | { - PartitionRangeDatum: PartitionRangeDatum; - } { + partitionRangeDatum(_p?: PartitionRangeDatum): PartitionRangeDatum { const _j = {} as PartitionRangeDatum; _o.set(_j, "kind", _p?.kind); _o.set(_j, "value", _p?.value); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PartitionRangeDatum: _j - }; - } return _j; }, - singlePartitionSpec(_p?: SinglePartitionSpec, isNode?: boolean): SinglePartitionSpec | { - SinglePartitionSpec: SinglePartitionSpec; - } { + singlePartitionSpec(_p?: SinglePartitionSpec): SinglePartitionSpec { const _j = {} as SinglePartitionSpec; - if (isNode) { - return { - SinglePartitionSpec: _j - }; - } return _j; }, - partitionCmd(_p?: PartitionCmd, isNode?: boolean): PartitionCmd | { - PartitionCmd: PartitionCmd; - } { + partitionCmd(_p?: PartitionCmd): PartitionCmd { const _j = {} as PartitionCmd; _o.set(_j, "name", _p?.name); _o.set(_j, "bound", _p?.bound); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - PartitionCmd: _j - }; - } return _j; }, - rangeTblEntry(_p?: RangeTblEntry, isNode?: boolean): RangeTblEntry | { - RangeTblEntry: RangeTblEntry; - } { + rangeTblEntry(_p?: RangeTblEntry): RangeTblEntry { const _j = {} as RangeTblEntry; _o.set(_j, "alias", _p?.alias); _o.set(_j, "eref", _p?.eref); @@ -1857,16 +1099,9 @@ export default { _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "inFromCl", _p?.inFromCl); _o.set(_j, "securityQuals", _p?.securityQuals); - if (isNode) { - return { - RangeTblEntry: _j - }; - } return _j; }, - rtePermissionInfo(_p?: RTEPermissionInfo, isNode?: boolean): RTEPermissionInfo | { - RTEPermissionInfo: RTEPermissionInfo; - } { + rtePermissionInfo(_p?: RTEPermissionInfo): RTEPermissionInfo { const _j = {} as RTEPermissionInfo; _o.set(_j, "relid", _p?.relid); _o.set(_j, "inh", _p?.inh); @@ -1875,16 +1110,9 @@ export default { _o.set(_j, "selectedCols", _p?.selectedCols); _o.set(_j, "insertedCols", _p?.insertedCols); _o.set(_j, "updatedCols", _p?.updatedCols); - if (isNode) { - return { - RTEPermissionInfo: _j - }; - } return _j; }, - rangeTblFunction(_p?: RangeTblFunction, isNode?: boolean): RangeTblFunction | { - RangeTblFunction: RangeTblFunction; - } { + rangeTblFunction(_p?: RangeTblFunction): RangeTblFunction { const _j = {} as RangeTblFunction; _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "funccolcount", _p?.funccolcount); @@ -1893,76 +1121,41 @@ export default { _o.set(_j, "funccoltypmods", _p?.funccoltypmods); _o.set(_j, "funccolcollations", _p?.funccolcollations); _o.set(_j, "funcparams", _p?.funcparams); - if (isNode) { - return { - RangeTblFunction: _j - }; - } return _j; }, - tableSampleClause(_p?: TableSampleClause, isNode?: boolean): TableSampleClause | { - TableSampleClause: TableSampleClause; - } { + tableSampleClause(_p?: TableSampleClause): TableSampleClause { const _j = {} as TableSampleClause; _o.set(_j, "tsmhandler", _p?.tsmhandler); _o.set(_j, "args", _p?.args); _o.set(_j, "repeatable", _p?.repeatable); - if (isNode) { - return { - TableSampleClause: _j - }; - } return _j; }, - withCheckOption(_p?: WithCheckOption, isNode?: boolean): WithCheckOption | { - WithCheckOption: WithCheckOption; - } { + withCheckOption(_p?: WithCheckOption): WithCheckOption { const _j = {} as WithCheckOption; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relname", _p?.relname); _o.set(_j, "polname", _p?.polname); _o.set(_j, "qual", _p?.qual); _o.set(_j, "cascaded", _p?.cascaded); - if (isNode) { - return { - WithCheckOption: _j - }; - } return _j; }, - sortGroupClause(_p?: SortGroupClause, isNode?: boolean): SortGroupClause | { - SortGroupClause: SortGroupClause; - } { + sortGroupClause(_p?: SortGroupClause): SortGroupClause { const _j = {} as SortGroupClause; _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); _o.set(_j, "eqop", _p?.eqop); _o.set(_j, "sortop", _p?.sortop); _o.set(_j, "nulls_first", _p?.nulls_first); _o.set(_j, "hashable", _p?.hashable); - if (isNode) { - return { - SortGroupClause: _j - }; - } return _j; }, - groupingSet(_p?: GroupingSet, isNode?: boolean): GroupingSet | { - GroupingSet: GroupingSet; - } { + groupingSet(_p?: GroupingSet): GroupingSet { const _j = {} as GroupingSet; _o.set(_j, "kind", _p?.kind); _o.set(_j, "content", _p?.content); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - GroupingSet: _j - }; - } return _j; }, - windowClause(_p?: WindowClause, isNode?: boolean): WindowClause | { - WindowClause: WindowClause; - } { + windowClause(_p?: WindowClause): WindowClause { const _j = {} as WindowClause; _o.set(_j, "name", _p?.name); _o.set(_j, "refname", _p?.refname); @@ -1978,91 +1171,49 @@ export default { _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); _o.set(_j, "winref", _p?.winref); _o.set(_j, "copiedOrder", _p?.copiedOrder); - if (isNode) { - return { - WindowClause: _j - }; - } return _j; }, - rowMarkClause(_p?: RowMarkClause, isNode?: boolean): RowMarkClause | { - RowMarkClause: RowMarkClause; - } { + rowMarkClause(_p?: RowMarkClause): RowMarkClause { const _j = {} as RowMarkClause; _o.set(_j, "rti", _p?.rti); _o.set(_j, "strength", _p?.strength); _o.set(_j, "waitPolicy", _p?.waitPolicy); _o.set(_j, "pushedDown", _p?.pushedDown); - if (isNode) { - return { - RowMarkClause: _j - }; - } return _j; }, - withClause(_p?: WithClause, isNode?: boolean): WithClause | { - WithClause: WithClause; - } { + withClause(_p?: WithClause): WithClause { const _j = {} as WithClause; _o.set(_j, "ctes", _p?.ctes); _o.set(_j, "recursive", _p?.recursive); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - WithClause: _j - }; - } return _j; }, - inferClause(_p?: InferClause, isNode?: boolean): InferClause | { - InferClause: InferClause; - } { + inferClause(_p?: InferClause): InferClause { const _j = {} as InferClause; _o.set(_j, "indexElems", _p?.indexElems); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "conname", _p?.conname); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - InferClause: _j - }; - } return _j; }, - onConflictClause(_p?: OnConflictClause, isNode?: boolean): OnConflictClause | { - OnConflictClause: OnConflictClause; - } { + onConflictClause(_p?: OnConflictClause): OnConflictClause { const _j = {} as OnConflictClause; _o.set(_j, "action", _p?.action); _o.set(_j, "infer", _p?.infer); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - OnConflictClause: _j - }; - } return _j; }, - cteSearchClause(_p?: CTESearchClause, isNode?: boolean): CTESearchClause | { - CTESearchClause: CTESearchClause; - } { + cteSearchClause(_p?: CTESearchClause): CTESearchClause { const _j = {} as CTESearchClause; _o.set(_j, "search_col_list", _p?.search_col_list); _o.set(_j, "search_breadth_first", _p?.search_breadth_first); _o.set(_j, "search_seq_column", _p?.search_seq_column); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - CTESearchClause: _j - }; - } return _j; }, - cteCycleClause(_p?: CTECycleClause, isNode?: boolean): CTECycleClause | { - CTECycleClause: CTECycleClause; - } { + cteCycleClause(_p?: CTECycleClause): CTECycleClause { const _j = {} as CTECycleClause; _o.set(_j, "cycle_col_list", _p?.cycle_col_list); _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); @@ -2074,16 +1225,9 @@ export default { _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); - if (isNode) { - return { - CTECycleClause: _j - }; - } return _j; }, - commonTableExpr(_p?: CommonTableExpr, isNode?: boolean): CommonTableExpr | { - CommonTableExpr: CommonTableExpr; - } { + commonTableExpr(_p?: CommonTableExpr): CommonTableExpr { const _j = {} as CommonTableExpr; _o.set(_j, "ctename", _p?.ctename); _o.set(_j, "aliascolnames", _p?.aliascolnames); @@ -2098,16 +1242,9 @@ export default { _o.set(_j, "ctecoltypes", _p?.ctecoltypes); _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); _o.set(_j, "ctecolcollations", _p?.ctecolcollations); - if (isNode) { - return { - CommonTableExpr: _j - }; - } return _j; }, - mergeWhenClause(_p?: MergeWhenClause, isNode?: boolean): MergeWhenClause | { - MergeWhenClause: MergeWhenClause; - } { + mergeWhenClause(_p?: MergeWhenClause): MergeWhenClause { const _j = {} as MergeWhenClause; _o.set(_j, "matchKind", _p?.matchKind); _o.set(_j, "commandType", _p?.commandType); @@ -2115,56 +1252,28 @@ export default { _o.set(_j, "condition", _p?.condition); _o.set(_j, "targetList", _p?.targetList); _o.set(_j, "values", _p?.values); - if (isNode) { - return { - MergeWhenClause: _j - }; - } return _j; }, - triggerTransition(_p?: TriggerTransition, isNode?: boolean): TriggerTransition | { - TriggerTransition: TriggerTransition; - } { + triggerTransition(_p?: TriggerTransition): TriggerTransition { const _j = {} as TriggerTransition; _o.set(_j, "name", _p?.name); _o.set(_j, "isNew", _p?.isNew); _o.set(_j, "isTable", _p?.isTable); - if (isNode) { - return { - TriggerTransition: _j - }; - } return _j; }, - jsonOutput(_p?: JsonOutput, isNode?: boolean): JsonOutput | { - JsonOutput: JsonOutput; - } { + jsonOutput(_p?: JsonOutput): JsonOutput { const _j = {} as JsonOutput; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "returning", _p?.returning); - if (isNode) { - return { - JsonOutput: _j - }; - } return _j; }, - jsonArgument(_p?: JsonArgument, isNode?: boolean): JsonArgument | { - JsonArgument: JsonArgument; - } { + jsonArgument(_p?: JsonArgument): JsonArgument { const _j = {} as JsonArgument; _o.set(_j, "val", _p?.val); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - JsonArgument: _j - }; - } return _j; }, - jsonFuncExpr(_p?: JsonFuncExpr, isNode?: boolean): JsonFuncExpr | { - JsonFuncExpr: JsonFuncExpr; - } { + jsonFuncExpr(_p?: JsonFuncExpr): JsonFuncExpr { const _j = {} as JsonFuncExpr; _o.set(_j, "op", _p?.op); _o.set(_j, "column_name", _p?.column_name); @@ -2177,31 +1286,17 @@ export default { _o.set(_j, "wrapper", _p?.wrapper); _o.set(_j, "quotes", _p?.quotes); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonFuncExpr: _j - }; - } return _j; }, - jsonTablePathSpec(_p?: JsonTablePathSpec, isNode?: boolean): JsonTablePathSpec | { - JsonTablePathSpec: JsonTablePathSpec; - } { + jsonTablePathSpec(_p?: JsonTablePathSpec): JsonTablePathSpec { const _j = {} as JsonTablePathSpec; _o.set(_j, "string", _p?.string); _o.set(_j, "name", _p?.name); _o.set(_j, "name_location", _p?.name_location); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonTablePathSpec: _j - }; - } return _j; }, - jsonTable(_p?: JsonTable, isNode?: boolean): JsonTable | { - JsonTable: JsonTable; - } { + jsonTable(_p?: JsonTable): JsonTable { const _j = {} as JsonTable; _o.set(_j, "context_item", _p?.context_item); _o.set(_j, "pathspec", _p?.pathspec); @@ -2211,16 +1306,9 @@ export default { _o.set(_j, "alias", _p?.alias); _o.set(_j, "lateral", _p?.lateral); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonTable: _j - }; - } return _j; }, - jsonTableColumn(_p?: JsonTableColumn, isNode?: boolean): JsonTableColumn | { - JsonTableColumn: JsonTableColumn; - } { + jsonTableColumn(_p?: JsonTableColumn): JsonTableColumn { const _j = {} as JsonTableColumn; _o.set(_j, "coltype", _p?.coltype); _o.set(_j, "name", _p?.name); @@ -2233,178 +1321,94 @@ export default { _o.set(_j, "on_empty", _p?.on_empty); _o.set(_j, "on_error", _p?.on_error); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonTableColumn: _j - }; - } return _j; }, - jsonKeyValue(_p?: JsonKeyValue, isNode?: boolean): JsonKeyValue | { - JsonKeyValue: JsonKeyValue; - } { + jsonKeyValue(_p?: JsonKeyValue): JsonKeyValue { const _j = {} as JsonKeyValue; _o.set(_j, "key", _p?.key); _o.set(_j, "value", _p?.value); - if (isNode) { - return { - JsonKeyValue: _j - }; - } return _j; }, - jsonParseExpr(_p?: JsonParseExpr, isNode?: boolean): JsonParseExpr | { - JsonParseExpr: JsonParseExpr; - } { + jsonParseExpr(_p?: JsonParseExpr): JsonParseExpr { const _j = {} as JsonParseExpr; _o.set(_j, "expr", _p?.expr); _o.set(_j, "output", _p?.output); _o.set(_j, "unique_keys", _p?.unique_keys); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonParseExpr: _j - }; - } return _j; }, - jsonScalarExpr(_p?: JsonScalarExpr, isNode?: boolean): JsonScalarExpr | { - JsonScalarExpr: JsonScalarExpr; - } { + jsonScalarExpr(_p?: JsonScalarExpr): JsonScalarExpr { const _j = {} as JsonScalarExpr; _o.set(_j, "expr", _p?.expr); _o.set(_j, "output", _p?.output); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonScalarExpr: _j - }; - } return _j; }, - jsonSerializeExpr(_p?: JsonSerializeExpr, isNode?: boolean): JsonSerializeExpr | { - JsonSerializeExpr: JsonSerializeExpr; - } { + jsonSerializeExpr(_p?: JsonSerializeExpr): JsonSerializeExpr { const _j = {} as JsonSerializeExpr; _o.set(_j, "expr", _p?.expr); _o.set(_j, "output", _p?.output); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonSerializeExpr: _j - }; - } return _j; }, - jsonObjectConstructor(_p?: JsonObjectConstructor, isNode?: boolean): JsonObjectConstructor | { - JsonObjectConstructor: JsonObjectConstructor; - } { + jsonObjectConstructor(_p?: JsonObjectConstructor): JsonObjectConstructor { const _j = {} as JsonObjectConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonObjectConstructor: _j - }; - } return _j; }, - jsonArrayConstructor(_p?: JsonArrayConstructor, isNode?: boolean): JsonArrayConstructor | { - JsonArrayConstructor: JsonArrayConstructor; - } { + jsonArrayConstructor(_p?: JsonArrayConstructor): JsonArrayConstructor { const _j = {} as JsonArrayConstructor; _o.set(_j, "exprs", _p?.exprs); _o.set(_j, "output", _p?.output); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayConstructor: _j - }; - } return _j; }, - jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor, isNode?: boolean): JsonArrayQueryConstructor | { - JsonArrayQueryConstructor: JsonArrayQueryConstructor; - } { + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): JsonArrayQueryConstructor { const _j = {} as JsonArrayQueryConstructor; _o.set(_j, "query", _p?.query); _o.set(_j, "output", _p?.output); _o.set(_j, "format", _p?.format); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonArrayQueryConstructor: _j - }; - } return _j; }, - jsonAggConstructor(_p?: JsonAggConstructor, isNode?: boolean): JsonAggConstructor | { - JsonAggConstructor: JsonAggConstructor; - } { + jsonAggConstructor(_p?: JsonAggConstructor): JsonAggConstructor { const _j = {} as JsonAggConstructor; _o.set(_j, "output", _p?.output); _o.set(_j, "agg_filter", _p?.agg_filter); _o.set(_j, "agg_order", _p?.agg_order); _o.set(_j, "over", _p?.over); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - JsonAggConstructor: _j - }; - } return _j; }, - jsonObjectAgg(_p?: JsonObjectAgg, isNode?: boolean): JsonObjectAgg | { - JsonObjectAgg: JsonObjectAgg; - } { + jsonObjectAgg(_p?: JsonObjectAgg): JsonObjectAgg { const _j = {} as JsonObjectAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); _o.set(_j, "unique", _p?.unique); - if (isNode) { - return { - JsonObjectAgg: _j - }; - } return _j; }, - jsonArrayAgg(_p?: JsonArrayAgg, isNode?: boolean): JsonArrayAgg | { - JsonArrayAgg: JsonArrayAgg; - } { + jsonArrayAgg(_p?: JsonArrayAgg): JsonArrayAgg { const _j = {} as JsonArrayAgg; _o.set(_j, "constructor", _p?.constructor); _o.set(_j, "arg", _p?.arg); _o.set(_j, "absent_on_null", _p?.absent_on_null); - if (isNode) { - return { - JsonArrayAgg: _j - }; - } return _j; }, - rawStmt(_p?: RawStmt, isNode?: boolean): RawStmt | { - RawStmt: RawStmt; - } { + rawStmt(_p?: RawStmt): RawStmt { const _j = {} as RawStmt; _o.set(_j, "stmt", _p?.stmt); _o.set(_j, "stmt_location", _p?.stmt_location); _o.set(_j, "stmt_len", _p?.stmt_len); - if (isNode) { - return { - RawStmt: _j - }; - } return _j; }, - insertStmt(_p?: InsertStmt, isNode?: boolean): InsertStmt | { - InsertStmt: InsertStmt; - } { + insertStmt(_p?: InsertStmt): InsertStmt { const _j = {} as InsertStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cols", _p?.cols); @@ -2413,32 +1417,18 @@ export default { _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); _o.set(_j, "override", _p?.override); - if (isNode) { - return { - InsertStmt: _j - }; - } return _j; }, - deleteStmt(_p?: DeleteStmt, isNode?: boolean): DeleteStmt | { - DeleteStmt: DeleteStmt; - } { + deleteStmt(_p?: DeleteStmt): DeleteStmt { const _j = {} as DeleteStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "usingClause", _p?.usingClause); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - DeleteStmt: _j - }; - } return _j; }, - updateStmt(_p?: UpdateStmt, isNode?: boolean): UpdateStmt | { - UpdateStmt: UpdateStmt; - } { + updateStmt(_p?: UpdateStmt): UpdateStmt { const _j = {} as UpdateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "targetList", _p?.targetList); @@ -2446,16 +1436,9 @@ export default { _o.set(_j, "fromClause", _p?.fromClause); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - UpdateStmt: _j - }; - } return _j; }, - mergeStmt(_p?: MergeStmt, isNode?: boolean): MergeStmt | { - MergeStmt: MergeStmt; - } { + mergeStmt(_p?: MergeStmt): MergeStmt { const _j = {} as MergeStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "sourceRelation", _p?.sourceRelation); @@ -2463,16 +1446,9 @@ export default { _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); _o.set(_j, "returningList", _p?.returningList); _o.set(_j, "withClause", _p?.withClause); - if (isNode) { - return { - MergeStmt: _j - }; - } return _j; }, - selectStmt(_p?: SelectStmt, isNode?: boolean): SelectStmt | { - SelectStmt: SelectStmt; - } { + selectStmt(_p?: SelectStmt): SelectStmt { const _j = {} as SelectStmt; _o.set(_j, "distinctClause", _p?.distinctClause); _o.set(_j, "intoClause", _p?.intoClause); @@ -2494,16 +1470,9 @@ export default { _o.set(_j, "all", _p?.all); _o.set(_j, "larg", _p?.larg); _o.set(_j, "rarg", _p?.rarg); - if (isNode) { - return { - SelectStmt: _j - }; - } return _j; }, - setOperationStmt(_p?: SetOperationStmt, isNode?: boolean): SetOperationStmt | { - SetOperationStmt: SetOperationStmt; - } { + setOperationStmt(_p?: SetOperationStmt): SetOperationStmt { const _j = {} as SetOperationStmt; _o.set(_j, "op", _p?.op); _o.set(_j, "all", _p?.all); @@ -2513,87 +1482,45 @@ export default { _o.set(_j, "colTypmods", _p?.colTypmods); _o.set(_j, "colCollations", _p?.colCollations); _o.set(_j, "groupClauses", _p?.groupClauses); - if (isNode) { - return { - SetOperationStmt: _j - }; - } return _j; }, - returnStmt(_p?: ReturnStmt, isNode?: boolean): ReturnStmt | { - ReturnStmt: ReturnStmt; - } { + returnStmt(_p?: ReturnStmt): ReturnStmt { const _j = {} as ReturnStmt; _o.set(_j, "returnval", _p?.returnval); - if (isNode) { - return { - ReturnStmt: _j - }; - } return _j; }, - plAssignStmt(_p?: PLAssignStmt, isNode?: boolean): PLAssignStmt | { - PLAssignStmt: PLAssignStmt; - } { + plAssignStmt(_p?: PLAssignStmt): PLAssignStmt { const _j = {} as PLAssignStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "indirection", _p?.indirection); _o.set(_j, "nnames", _p?.nnames); _o.set(_j, "val", _p?.val); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PLAssignStmt: _j - }; - } return _j; }, - createSchemaStmt(_p?: CreateSchemaStmt, isNode?: boolean): CreateSchemaStmt | { - CreateSchemaStmt: CreateSchemaStmt; - } { + createSchemaStmt(_p?: CreateSchemaStmt): CreateSchemaStmt { const _j = {} as CreateSchemaStmt; _o.set(_j, "schemaname", _p?.schemaname); _o.set(_j, "authrole", _p?.authrole); _o.set(_j, "schemaElts", _p?.schemaElts); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSchemaStmt: _j - }; - } return _j; }, - alterTableStmt(_p?: AlterTableStmt, isNode?: boolean): AlterTableStmt | { - AlterTableStmt: AlterTableStmt; - } { + alterTableStmt(_p?: AlterTableStmt): AlterTableStmt { const _j = {} as AlterTableStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "cmds", _p?.cmds); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTableStmt: _j - }; - } return _j; }, - replicaIdentityStmt(_p?: ReplicaIdentityStmt, isNode?: boolean): ReplicaIdentityStmt | { - ReplicaIdentityStmt: ReplicaIdentityStmt; - } { + replicaIdentityStmt(_p?: ReplicaIdentityStmt): ReplicaIdentityStmt { const _j = {} as ReplicaIdentityStmt; _o.set(_j, "identity_type", _p?.identity_type); _o.set(_j, "name", _p?.name); - if (isNode) { - return { - ReplicaIdentityStmt: _j - }; - } return _j; }, - alterTableCmd(_p?: AlterTableCmd, isNode?: boolean): AlterTableCmd | { - AlterTableCmd: AlterTableCmd; - } { + alterTableCmd(_p?: AlterTableCmd): AlterTableCmd { const _j = {} as AlterTableCmd; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "name", _p?.name); @@ -2603,28 +1530,14 @@ export default { _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "recurse", _p?.recurse); - if (isNode) { - return { - AlterTableCmd: _j - }; - } return _j; }, - alterCollationStmt(_p?: AlterCollationStmt, isNode?: boolean): AlterCollationStmt | { - AlterCollationStmt: AlterCollationStmt; - } { + alterCollationStmt(_p?: AlterCollationStmt): AlterCollationStmt { const _j = {} as AlterCollationStmt; _o.set(_j, "collname", _p?.collname); - if (isNode) { - return { - AlterCollationStmt: _j - }; - } return _j; }, - alterDomainStmt(_p?: AlterDomainStmt, isNode?: boolean): AlterDomainStmt | { - AlterDomainStmt: AlterDomainStmt; - } { + alterDomainStmt(_p?: AlterDomainStmt): AlterDomainStmt { const _j = {} as AlterDomainStmt; _o.set(_j, "subtype", _p?.subtype); _o.set(_j, "typeName", _p?.typeName); @@ -2632,16 +1545,9 @@ export default { _o.set(_j, "def", _p?.def); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterDomainStmt: _j - }; - } return _j; }, - grantStmt(_p?: GrantStmt, isNode?: boolean): GrantStmt | { - GrantStmt: GrantStmt; - } { + grantStmt(_p?: GrantStmt): GrantStmt { const _j = {} as GrantStmt; _o.set(_j, "is_grant", _p?.is_grant); _o.set(_j, "targtype", _p?.targtype); @@ -2652,44 +1558,23 @@ export default { _o.set(_j, "grant_option", _p?.grant_option); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantStmt: _j - }; - } return _j; }, - objectWithArgs(_p?: ObjectWithArgs, isNode?: boolean): ObjectWithArgs | { - ObjectWithArgs: ObjectWithArgs; - } { + objectWithArgs(_p?: ObjectWithArgs): ObjectWithArgs { const _j = {} as ObjectWithArgs; _o.set(_j, "objname", _p?.objname); _o.set(_j, "objargs", _p?.objargs); _o.set(_j, "objfuncargs", _p?.objfuncargs); _o.set(_j, "args_unspecified", _p?.args_unspecified); - if (isNode) { - return { - ObjectWithArgs: _j - }; - } return _j; }, - accessPriv(_p?: AccessPriv, isNode?: boolean): AccessPriv | { - AccessPriv: AccessPriv; - } { + accessPriv(_p?: AccessPriv): AccessPriv { const _j = {} as AccessPriv; _o.set(_j, "priv_name", _p?.priv_name); _o.set(_j, "cols", _p?.cols); - if (isNode) { - return { - AccessPriv: _j - }; - } return _j; }, - grantRoleStmt(_p?: GrantRoleStmt, isNode?: boolean): GrantRoleStmt | { - GrantRoleStmt: GrantRoleStmt; - } { + grantRoleStmt(_p?: GrantRoleStmt): GrantRoleStmt { const _j = {} as GrantRoleStmt; _o.set(_j, "granted_roles", _p?.granted_roles); _o.set(_j, "grantee_roles", _p?.grantee_roles); @@ -2697,29 +1582,15 @@ export default { _o.set(_j, "opt", _p?.opt); _o.set(_j, "grantor", _p?.grantor); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - GrantRoleStmt: _j - }; - } return _j; }, - alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt, isNode?: boolean): AlterDefaultPrivilegesStmt | { - AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; - } { + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): AlterDefaultPrivilegesStmt { const _j = {} as AlterDefaultPrivilegesStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterDefaultPrivilegesStmt: _j - }; - } return _j; }, - copyStmt(_p?: CopyStmt, isNode?: boolean): CopyStmt | { - CopyStmt: CopyStmt; - } { + copyStmt(_p?: CopyStmt): CopyStmt { const _j = {} as CopyStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "query", _p?.query); @@ -2729,43 +1600,22 @@ export default { _o.set(_j, "filename", _p?.filename); _o.set(_j, "options", _p?.options); _o.set(_j, "whereClause", _p?.whereClause); - if (isNode) { - return { - CopyStmt: _j - }; - } return _j; }, - variableSetStmt(_p?: VariableSetStmt, isNode?: boolean): VariableSetStmt | { - VariableSetStmt: VariableSetStmt; - } { + variableSetStmt(_p?: VariableSetStmt): VariableSetStmt { const _j = {} as VariableSetStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "name", _p?.name); _o.set(_j, "args", _p?.args); _o.set(_j, "is_local", _p?.is_local); - if (isNode) { - return { - VariableSetStmt: _j - }; - } return _j; }, - variableShowStmt(_p?: VariableShowStmt, isNode?: boolean): VariableShowStmt | { - VariableShowStmt: VariableShowStmt; - } { + variableShowStmt(_p?: VariableShowStmt): VariableShowStmt { const _j = {} as VariableShowStmt; _o.set(_j, "name", _p?.name); - if (isNode) { - return { - VariableShowStmt: _j - }; - } return _j; }, - createStmt(_p?: CreateStmt, isNode?: boolean): CreateStmt | { - CreateStmt: CreateStmt; - } { + createStmt(_p?: CreateStmt): CreateStmt { const _j = {} as CreateStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "tableElts", _p?.tableElts); @@ -2779,16 +1629,9 @@ export default { _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "accessMethod", _p?.accessMethod); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStmt: _j - }; - } return _j; }, - constraint(_p?: Constraint, isNode?: boolean): Constraint | { - Constraint: Constraint; - } { + constraint(_p?: Constraint): Constraint { const _j = {} as Constraint; _o.set(_j, "contype", _p?.contype); _o.set(_j, "conname", _p?.conname); @@ -2821,144 +1664,74 @@ export default { _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - Constraint: _j - }; - } return _j; }, - createTableSpaceStmt(_p?: CreateTableSpaceStmt, isNode?: boolean): CreateTableSpaceStmt | { - CreateTableSpaceStmt: CreateTableSpaceStmt; - } { + createTableSpaceStmt(_p?: CreateTableSpaceStmt): CreateTableSpaceStmt { const _j = {} as CreateTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "owner", _p?.owner); _o.set(_j, "location", _p?.location); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateTableSpaceStmt: _j - }; - } return _j; }, - dropTableSpaceStmt(_p?: DropTableSpaceStmt, isNode?: boolean): DropTableSpaceStmt | { - DropTableSpaceStmt: DropTableSpaceStmt; - } { + dropTableSpaceStmt(_p?: DropTableSpaceStmt): DropTableSpaceStmt { const _j = {} as DropTableSpaceStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropTableSpaceStmt: _j - }; - } return _j; }, - alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt, isNode?: boolean): AlterTableSpaceOptionsStmt | { - AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; - } { + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): AlterTableSpaceOptionsStmt { const _j = {} as AlterTableSpaceOptionsStmt; _o.set(_j, "tablespacename", _p?.tablespacename); _o.set(_j, "options", _p?.options); _o.set(_j, "isReset", _p?.isReset); - if (isNode) { - return { - AlterTableSpaceOptionsStmt: _j - }; - } return _j; }, - alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt, isNode?: boolean): AlterTableMoveAllStmt | { - AlterTableMoveAllStmt: AlterTableMoveAllStmt; - } { + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): AlterTableMoveAllStmt { const _j = {} as AlterTableMoveAllStmt; _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "roles", _p?.roles); _o.set(_j, "new_tablespacename", _p?.new_tablespacename); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - AlterTableMoveAllStmt: _j - }; - } return _j; }, - createExtensionStmt(_p?: CreateExtensionStmt, isNode?: boolean): CreateExtensionStmt | { - CreateExtensionStmt: CreateExtensionStmt; - } { + createExtensionStmt(_p?: CreateExtensionStmt): CreateExtensionStmt { const _j = {} as CreateExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateExtensionStmt: _j - }; - } return _j; }, - alterExtensionStmt(_p?: AlterExtensionStmt, isNode?: boolean): AlterExtensionStmt | { - AlterExtensionStmt: AlterExtensionStmt; - } { + alterExtensionStmt(_p?: AlterExtensionStmt): AlterExtensionStmt { const _j = {} as AlterExtensionStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterExtensionStmt: _j - }; - } return _j; }, - alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt, isNode?: boolean): AlterExtensionContentsStmt | { - AlterExtensionContentsStmt: AlterExtensionContentsStmt; - } { + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): AlterExtensionContentsStmt { const _j = {} as AlterExtensionContentsStmt; _o.set(_j, "extname", _p?.extname); _o.set(_j, "action", _p?.action); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); - if (isNode) { - return { - AlterExtensionContentsStmt: _j - }; - } return _j; }, - createFdwStmt(_p?: CreateFdwStmt, isNode?: boolean): CreateFdwStmt | { - CreateFdwStmt: CreateFdwStmt; - } { + createFdwStmt(_p?: CreateFdwStmt): CreateFdwStmt { const _j = {} as CreateFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateFdwStmt: _j - }; - } return _j; }, - alterFdwStmt(_p?: AlterFdwStmt, isNode?: boolean): AlterFdwStmt | { - AlterFdwStmt: AlterFdwStmt; - } { + alterFdwStmt(_p?: AlterFdwStmt): AlterFdwStmt { const _j = {} as AlterFdwStmt; _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "func_options", _p?.func_options); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterFdwStmt: _j - }; - } return _j; }, - createForeignServerStmt(_p?: CreateForeignServerStmt, isNode?: boolean): CreateForeignServerStmt | { - CreateForeignServerStmt: CreateForeignServerStmt; - } { + createForeignServerStmt(_p?: CreateForeignServerStmt): CreateForeignServerStmt { const _j = {} as CreateForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "servertype", _p?.servertype); @@ -2966,88 +1739,46 @@ export default { _o.set(_j, "fdwname", _p?.fdwname); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignServerStmt: _j - }; - } return _j; }, - alterForeignServerStmt(_p?: AlterForeignServerStmt, isNode?: boolean): AlterForeignServerStmt | { - AlterForeignServerStmt: AlterForeignServerStmt; - } { + alterForeignServerStmt(_p?: AlterForeignServerStmt): AlterForeignServerStmt { const _j = {} as AlterForeignServerStmt; _o.set(_j, "servername", _p?.servername); _o.set(_j, "version", _p?.version); _o.set(_j, "options", _p?.options); _o.set(_j, "has_version", _p?.has_version); - if (isNode) { - return { - AlterForeignServerStmt: _j - }; - } return _j; }, - createForeignTableStmt(_p?: CreateForeignTableStmt, isNode?: boolean): CreateForeignTableStmt | { - CreateForeignTableStmt: CreateForeignTableStmt; - } { + createForeignTableStmt(_p?: CreateForeignTableStmt): CreateForeignTableStmt { const _j = {} as CreateForeignTableStmt; _o.set(_j, "base", _p?.base); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateForeignTableStmt: _j - }; - } return _j; }, - createUserMappingStmt(_p?: CreateUserMappingStmt, isNode?: boolean): CreateUserMappingStmt | { - CreateUserMappingStmt: CreateUserMappingStmt; - } { + createUserMappingStmt(_p?: CreateUserMappingStmt): CreateUserMappingStmt { const _j = {} as CreateUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateUserMappingStmt: _j - }; - } return _j; }, - alterUserMappingStmt(_p?: AlterUserMappingStmt, isNode?: boolean): AlterUserMappingStmt | { - AlterUserMappingStmt: AlterUserMappingStmt; - } { + alterUserMappingStmt(_p?: AlterUserMappingStmt): AlterUserMappingStmt { const _j = {} as AlterUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterUserMappingStmt: _j - }; - } return _j; }, - dropUserMappingStmt(_p?: DropUserMappingStmt, isNode?: boolean): DropUserMappingStmt | { - DropUserMappingStmt: DropUserMappingStmt; - } { + dropUserMappingStmt(_p?: DropUserMappingStmt): DropUserMappingStmt { const _j = {} as DropUserMappingStmt; _o.set(_j, "user", _p?.user); _o.set(_j, "servername", _p?.servername); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropUserMappingStmt: _j - }; - } return _j; }, - importForeignSchemaStmt(_p?: ImportForeignSchemaStmt, isNode?: boolean): ImportForeignSchemaStmt | { - ImportForeignSchemaStmt: ImportForeignSchemaStmt; - } { + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): ImportForeignSchemaStmt { const _j = {} as ImportForeignSchemaStmt; _o.set(_j, "server_name", _p?.server_name); _o.set(_j, "remote_schema", _p?.remote_schema); @@ -3055,16 +1786,9 @@ export default { _o.set(_j, "list_type", _p?.list_type); _o.set(_j, "table_list", _p?.table_list); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ImportForeignSchemaStmt: _j - }; - } return _j; }, - createPolicyStmt(_p?: CreatePolicyStmt, isNode?: boolean): CreatePolicyStmt | { - CreatePolicyStmt: CreatePolicyStmt; - } { + createPolicyStmt(_p?: CreatePolicyStmt): CreatePolicyStmt { const _j = {} as CreatePolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); @@ -3073,46 +1797,25 @@ export default { _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - CreatePolicyStmt: _j - }; - } return _j; }, - alterPolicyStmt(_p?: AlterPolicyStmt, isNode?: boolean): AlterPolicyStmt | { - AlterPolicyStmt: AlterPolicyStmt; - } { + alterPolicyStmt(_p?: AlterPolicyStmt): AlterPolicyStmt { const _j = {} as AlterPolicyStmt; _o.set(_j, "policy_name", _p?.policy_name); _o.set(_j, "table", _p?.table); _o.set(_j, "roles", _p?.roles); _o.set(_j, "qual", _p?.qual); _o.set(_j, "with_check", _p?.with_check); - if (isNode) { - return { - AlterPolicyStmt: _j - }; - } return _j; }, - createAmStmt(_p?: CreateAmStmt, isNode?: boolean): CreateAmStmt | { - CreateAmStmt: CreateAmStmt; - } { + createAmStmt(_p?: CreateAmStmt): CreateAmStmt { const _j = {} as CreateAmStmt; _o.set(_j, "amname", _p?.amname); _o.set(_j, "handler_name", _p?.handler_name); _o.set(_j, "amtype", _p?.amtype); - if (isNode) { - return { - CreateAmStmt: _j - }; - } return _j; }, - createTrigStmt(_p?: CreateTrigStmt, isNode?: boolean): CreateTrigStmt | { - CreateTrigStmt: CreateTrigStmt; - } { + createTrigStmt(_p?: CreateTrigStmt): CreateTrigStmt { const _j = {} as CreateTrigStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "isconstraint", _p?.isconstraint); @@ -3129,44 +1832,23 @@ export default { _o.set(_j, "deferrable", _p?.deferrable); _o.set(_j, "initdeferred", _p?.initdeferred); _o.set(_j, "constrrel", _p?.constrrel); - if (isNode) { - return { - CreateTrigStmt: _j - }; - } return _j; }, - createEventTrigStmt(_p?: CreateEventTrigStmt, isNode?: boolean): CreateEventTrigStmt | { - CreateEventTrigStmt: CreateEventTrigStmt; - } { + createEventTrigStmt(_p?: CreateEventTrigStmt): CreateEventTrigStmt { const _j = {} as CreateEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "eventname", _p?.eventname); _o.set(_j, "whenclause", _p?.whenclause); _o.set(_j, "funcname", _p?.funcname); - if (isNode) { - return { - CreateEventTrigStmt: _j - }; - } return _j; }, - alterEventTrigStmt(_p?: AlterEventTrigStmt, isNode?: boolean): AlterEventTrigStmt | { - AlterEventTrigStmt: AlterEventTrigStmt; - } { + alterEventTrigStmt(_p?: AlterEventTrigStmt): AlterEventTrigStmt { const _j = {} as AlterEventTrigStmt; _o.set(_j, "trigname", _p?.trigname); _o.set(_j, "tgenabled", _p?.tgenabled); - if (isNode) { - return { - AlterEventTrigStmt: _j - }; - } return _j; }, - createpLangStmt(_p?: CreatePLangStmt, isNode?: boolean): CreatePLangStmt | { - CreatePLangStmt: CreatePLangStmt; - } { + createpLangStmt(_p?: CreatePLangStmt): CreatePLangStmt { const _j = {} as CreatePLangStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "plname", _p?.plname); @@ -3174,102 +1856,53 @@ export default { _o.set(_j, "plinline", _p?.plinline); _o.set(_j, "plvalidator", _p?.plvalidator); _o.set(_j, "pltrusted", _p?.pltrusted); - if (isNode) { - return { - CreatePLangStmt: _j - }; - } return _j; }, - createRoleStmt(_p?: CreateRoleStmt, isNode?: boolean): CreateRoleStmt | { - CreateRoleStmt: CreateRoleStmt; - } { + createRoleStmt(_p?: CreateRoleStmt): CreateRoleStmt { const _j = {} as CreateRoleStmt; _o.set(_j, "stmt_type", _p?.stmt_type); _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateRoleStmt: _j - }; - } return _j; }, - alterRoleStmt(_p?: AlterRoleStmt, isNode?: boolean): AlterRoleStmt | { - AlterRoleStmt: AlterRoleStmt; - } { + alterRoleStmt(_p?: AlterRoleStmt): AlterRoleStmt { const _j = {} as AlterRoleStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "options", _p?.options); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterRoleStmt: _j - }; - } return _j; }, - alterRoleSetStmt(_p?: AlterRoleSetStmt, isNode?: boolean): AlterRoleSetStmt | { - AlterRoleSetStmt: AlterRoleSetStmt; - } { + alterRoleSetStmt(_p?: AlterRoleSetStmt): AlterRoleSetStmt { const _j = {} as AlterRoleSetStmt; _o.set(_j, "role", _p?.role); _o.set(_j, "database", _p?.database); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterRoleSetStmt: _j - }; - } return _j; }, - dropRoleStmt(_p?: DropRoleStmt, isNode?: boolean): DropRoleStmt | { - DropRoleStmt: DropRoleStmt; - } { + dropRoleStmt(_p?: DropRoleStmt): DropRoleStmt { const _j = {} as DropRoleStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - DropRoleStmt: _j - }; - } return _j; }, - createSeqStmt(_p?: CreateSeqStmt, isNode?: boolean): CreateSeqStmt | { - CreateSeqStmt: CreateSeqStmt; - } { + createSeqStmt(_p?: CreateSeqStmt): CreateSeqStmt { const _j = {} as CreateSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "ownerId", _p?.ownerId); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateSeqStmt: _j - }; - } return _j; }, - alterSeqStmt(_p?: AlterSeqStmt, isNode?: boolean): AlterSeqStmt | { - AlterSeqStmt: AlterSeqStmt; - } { + alterSeqStmt(_p?: AlterSeqStmt): AlterSeqStmt { const _j = {} as AlterSeqStmt; _o.set(_j, "sequence", _p?.sequence); _o.set(_j, "options", _p?.options); _o.set(_j, "for_identity", _p?.for_identity); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterSeqStmt: _j - }; - } return _j; }, - defineStmt(_p?: DefineStmt, isNode?: boolean): DefineStmt | { - DefineStmt: DefineStmt; - } { + defineStmt(_p?: DefineStmt): DefineStmt { const _j = {} as DefineStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "oldstyle", _p?.oldstyle); @@ -3278,31 +1911,17 @@ export default { _o.set(_j, "definition", _p?.definition); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - DefineStmt: _j - }; - } return _j; }, - createDomainStmt(_p?: CreateDomainStmt, isNode?: boolean): CreateDomainStmt | { - CreateDomainStmt: CreateDomainStmt; - } { + createDomainStmt(_p?: CreateDomainStmt): CreateDomainStmt { const _j = {} as CreateDomainStmt; _o.set(_j, "domainname", _p?.domainname); _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "collClause", _p?.collClause); _o.set(_j, "constraints", _p?.constraints); - if (isNode) { - return { - CreateDomainStmt: _j - }; - } return _j; }, - createOpClassStmt(_p?: CreateOpClassStmt, isNode?: boolean): CreateOpClassStmt | { - CreateOpClassStmt: CreateOpClassStmt; - } { + createOpClassStmt(_p?: CreateOpClassStmt): CreateOpClassStmt { const _j = {} as CreateOpClassStmt; _o.set(_j, "opclassname", _p?.opclassname); _o.set(_j, "opfamilyname", _p?.opfamilyname); @@ -3310,16 +1929,9 @@ export default { _o.set(_j, "datatype", _p?.datatype); _o.set(_j, "items", _p?.items); _o.set(_j, "isDefault", _p?.isDefault); - if (isNode) { - return { - CreateOpClassStmt: _j - }; - } return _j; }, - createOpClassItem(_p?: CreateOpClassItem, isNode?: boolean): CreateOpClassItem | { - CreateOpClassItem: CreateOpClassItem; - } { + createOpClassItem(_p?: CreateOpClassItem): CreateOpClassItem { const _j = {} as CreateOpClassItem; _o.set(_j, "itemtype", _p?.itemtype); _o.set(_j, "name", _p?.name); @@ -3327,144 +1939,74 @@ export default { _o.set(_j, "order_family", _p?.order_family); _o.set(_j, "class_args", _p?.class_args); _o.set(_j, "storedtype", _p?.storedtype); - if (isNode) { - return { - CreateOpClassItem: _j - }; - } return _j; }, - createOpFamilyStmt(_p?: CreateOpFamilyStmt, isNode?: boolean): CreateOpFamilyStmt | { - CreateOpFamilyStmt: CreateOpFamilyStmt; - } { + createOpFamilyStmt(_p?: CreateOpFamilyStmt): CreateOpFamilyStmt { const _j = {} as CreateOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); - if (isNode) { - return { - CreateOpFamilyStmt: _j - }; - } return _j; }, - alterOpFamilyStmt(_p?: AlterOpFamilyStmt, isNode?: boolean): AlterOpFamilyStmt | { - AlterOpFamilyStmt: AlterOpFamilyStmt; - } { + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): AlterOpFamilyStmt { const _j = {} as AlterOpFamilyStmt; _o.set(_j, "opfamilyname", _p?.opfamilyname); _o.set(_j, "amname", _p?.amname); _o.set(_j, "isDrop", _p?.isDrop); _o.set(_j, "items", _p?.items); - if (isNode) { - return { - AlterOpFamilyStmt: _j - }; - } return _j; }, - dropStmt(_p?: DropStmt, isNode?: boolean): DropStmt | { - DropStmt: DropStmt; - } { + dropStmt(_p?: DropStmt): DropStmt { const _j = {} as DropStmt; _o.set(_j, "objects", _p?.objects); _o.set(_j, "removeType", _p?.removeType); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "concurrent", _p?.concurrent); - if (isNode) { - return { - DropStmt: _j - }; - } return _j; }, - truncateStmt(_p?: TruncateStmt, isNode?: boolean): TruncateStmt | { - TruncateStmt: TruncateStmt; - } { + truncateStmt(_p?: TruncateStmt): TruncateStmt { const _j = {} as TruncateStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "restart_seqs", _p?.restart_seqs); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - TruncateStmt: _j - }; - } return _j; }, - commentStmt(_p?: CommentStmt, isNode?: boolean): CommentStmt | { - CommentStmt: CommentStmt; - } { + commentStmt(_p?: CommentStmt): CommentStmt { const _j = {} as CommentStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "comment", _p?.comment); - if (isNode) { - return { - CommentStmt: _j - }; - } return _j; }, - secLabelStmt(_p?: SecLabelStmt, isNode?: boolean): SecLabelStmt | { - SecLabelStmt: SecLabelStmt; - } { + secLabelStmt(_p?: SecLabelStmt): SecLabelStmt { const _j = {} as SecLabelStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "object", _p?.object); _o.set(_j, "provider", _p?.provider); _o.set(_j, "label", _p?.label); - if (isNode) { - return { - SecLabelStmt: _j - }; - } return _j; }, - declareCursorStmt(_p?: DeclareCursorStmt, isNode?: boolean): DeclareCursorStmt | { - DeclareCursorStmt: DeclareCursorStmt; - } { + declareCursorStmt(_p?: DeclareCursorStmt): DeclareCursorStmt { const _j = {} as DeclareCursorStmt; _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "options", _p?.options); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - DeclareCursorStmt: _j - }; - } return _j; }, - closePortalStmt(_p?: ClosePortalStmt, isNode?: boolean): ClosePortalStmt | { - ClosePortalStmt: ClosePortalStmt; - } { + closePortalStmt(_p?: ClosePortalStmt): ClosePortalStmt { const _j = {} as ClosePortalStmt; _o.set(_j, "portalname", _p?.portalname); - if (isNode) { - return { - ClosePortalStmt: _j - }; - } return _j; }, - fetchStmt(_p?: FetchStmt, isNode?: boolean): FetchStmt | { - FetchStmt: FetchStmt; - } { + fetchStmt(_p?: FetchStmt): FetchStmt { const _j = {} as FetchStmt; _o.set(_j, "direction", _p?.direction); _o.set(_j, "howMany", _p?.howMany); _o.set(_j, "portalname", _p?.portalname); _o.set(_j, "ismove", _p?.ismove); - if (isNode) { - return { - FetchStmt: _j - }; - } return _j; }, - indexStmt(_p?: IndexStmt, isNode?: boolean): IndexStmt | { - IndexStmt: IndexStmt; - } { + indexStmt(_p?: IndexStmt): IndexStmt { const _j = {} as IndexStmt; _o.set(_j, "idxname", _p?.idxname); _o.set(_j, "relation", _p?.relation); @@ -3490,16 +2032,9 @@ export default { _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "if_not_exists", _p?.if_not_exists); _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); - if (isNode) { - return { - IndexStmt: _j - }; - } return _j; }, - createStatsStmt(_p?: CreateStatsStmt, isNode?: boolean): CreateStatsStmt | { - CreateStatsStmt: CreateStatsStmt; - } { + createStatsStmt(_p?: CreateStatsStmt): CreateStatsStmt { const _j = {} as CreateStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stat_types", _p?.stat_types); @@ -3508,43 +2043,22 @@ export default { _o.set(_j, "stxcomment", _p?.stxcomment); _o.set(_j, "transformed", _p?.transformed); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateStatsStmt: _j - }; - } return _j; }, - statsElem(_p?: StatsElem, isNode?: boolean): StatsElem | { - StatsElem: StatsElem; - } { + statsElem(_p?: StatsElem): StatsElem { const _j = {} as StatsElem; _o.set(_j, "name", _p?.name); _o.set(_j, "expr", _p?.expr); - if (isNode) { - return { - StatsElem: _j - }; - } return _j; }, - alterStatsStmt(_p?: AlterStatsStmt, isNode?: boolean): AlterStatsStmt | { - AlterStatsStmt: AlterStatsStmt; - } { + alterStatsStmt(_p?: AlterStatsStmt): AlterStatsStmt { const _j = {} as AlterStatsStmt; _o.set(_j, "defnames", _p?.defnames); _o.set(_j, "stxstattarget", _p?.stxstattarget); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterStatsStmt: _j - }; - } return _j; }, - createFunctionStmt(_p?: CreateFunctionStmt, isNode?: boolean): CreateFunctionStmt | { - CreateFunctionStmt: CreateFunctionStmt; - } { + createFunctionStmt(_p?: CreateFunctionStmt): CreateFunctionStmt { const _j = {} as CreateFunctionStmt; _o.set(_j, "is_procedure", _p?.is_procedure); _o.set(_j, "replace", _p?.replace); @@ -3553,98 +2067,49 @@ export default { _o.set(_j, "returnType", _p?.returnType); _o.set(_j, "options", _p?.options); _o.set(_j, "sql_body", _p?.sql_body); - if (isNode) { - return { - CreateFunctionStmt: _j - }; - } return _j; }, - functionParameter(_p?: FunctionParameter, isNode?: boolean): FunctionParameter | { - FunctionParameter: FunctionParameter; - } { + functionParameter(_p?: FunctionParameter): FunctionParameter { const _j = {} as FunctionParameter; _o.set(_j, "name", _p?.name); _o.set(_j, "argType", _p?.argType); _o.set(_j, "mode", _p?.mode); _o.set(_j, "defexpr", _p?.defexpr); - if (isNode) { - return { - FunctionParameter: _j - }; - } return _j; }, - alterFunctionStmt(_p?: AlterFunctionStmt, isNode?: boolean): AlterFunctionStmt | { - AlterFunctionStmt: AlterFunctionStmt; - } { + alterFunctionStmt(_p?: AlterFunctionStmt): AlterFunctionStmt { const _j = {} as AlterFunctionStmt; _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "func", _p?.func); _o.set(_j, "actions", _p?.actions); - if (isNode) { - return { - AlterFunctionStmt: _j - }; - } return _j; }, - doStmt(_p?: DoStmt, isNode?: boolean): DoStmt | { - DoStmt: DoStmt; - } { + doStmt(_p?: DoStmt): DoStmt { const _j = {} as DoStmt; _o.set(_j, "args", _p?.args); - if (isNode) { - return { - DoStmt: _j - }; - } return _j; }, - inlineCodeBlock(_p?: InlineCodeBlock, isNode?: boolean): InlineCodeBlock | { - InlineCodeBlock: InlineCodeBlock; - } { + inlineCodeBlock(_p?: InlineCodeBlock): InlineCodeBlock { const _j = {} as InlineCodeBlock; _o.set(_j, "source_text", _p?.source_text); _o.set(_j, "langOid", _p?.langOid); _o.set(_j, "langIsTrusted", _p?.langIsTrusted); _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - InlineCodeBlock: _j - }; - } return _j; }, - callStmt(_p?: CallStmt, isNode?: boolean): CallStmt | { - CallStmt: CallStmt; - } { + callStmt(_p?: CallStmt): CallStmt { const _j = {} as CallStmt; _o.set(_j, "funccall", _p?.funccall); _o.set(_j, "funcexpr", _p?.funcexpr); _o.set(_j, "outargs", _p?.outargs); - if (isNode) { - return { - CallStmt: _j - }; - } return _j; }, - callContext(_p?: CallContext, isNode?: boolean): CallContext | { - CallContext: CallContext; - } { + callContext(_p?: CallContext): CallContext { const _j = {} as CallContext; _o.set(_j, "atomic", _p?.atomic); - if (isNode) { - return { - CallContext: _j - }; - } return _j; }, - renameStmt(_p?: RenameStmt, isNode?: boolean): RenameStmt | { - RenameStmt: RenameStmt; - } { + renameStmt(_p?: RenameStmt): RenameStmt { const _j = {} as RenameStmt; _o.set(_j, "renameType", _p?.renameType); _o.set(_j, "relationType", _p?.relationType); @@ -3654,89 +2119,47 @@ export default { _o.set(_j, "newname", _p?.newname); _o.set(_j, "behavior", _p?.behavior); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - RenameStmt: _j - }; - } return _j; }, - alterObjectDependsStmt(_p?: AlterObjectDependsStmt, isNode?: boolean): AlterObjectDependsStmt | { - AlterObjectDependsStmt: AlterObjectDependsStmt; - } { + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): AlterObjectDependsStmt { const _j = {} as AlterObjectDependsStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "extname", _p?.extname); _o.set(_j, "remove", _p?.remove); - if (isNode) { - return { - AlterObjectDependsStmt: _j - }; - } return _j; }, - alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt, isNode?: boolean): AlterObjectSchemaStmt | { - AlterObjectSchemaStmt: AlterObjectSchemaStmt; - } { + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): AlterObjectSchemaStmt { const _j = {} as AlterObjectSchemaStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newschema", _p?.newschema); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterObjectSchemaStmt: _j - }; - } return _j; }, - alterOwnerStmt(_p?: AlterOwnerStmt, isNode?: boolean): AlterOwnerStmt | { - AlterOwnerStmt: AlterOwnerStmt; - } { + alterOwnerStmt(_p?: AlterOwnerStmt): AlterOwnerStmt { const _j = {} as AlterOwnerStmt; _o.set(_j, "objectType", _p?.objectType); _o.set(_j, "relation", _p?.relation); _o.set(_j, "object", _p?.object); _o.set(_j, "newowner", _p?.newowner); - if (isNode) { - return { - AlterOwnerStmt: _j - }; - } return _j; }, - alterOperatorStmt(_p?: AlterOperatorStmt, isNode?: boolean): AlterOperatorStmt | { - AlterOperatorStmt: AlterOperatorStmt; - } { + alterOperatorStmt(_p?: AlterOperatorStmt): AlterOperatorStmt { const _j = {} as AlterOperatorStmt; _o.set(_j, "opername", _p?.opername); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterOperatorStmt: _j - }; - } return _j; }, - alterTypeStmt(_p?: AlterTypeStmt, isNode?: boolean): AlterTypeStmt | { - AlterTypeStmt: AlterTypeStmt; - } { + alterTypeStmt(_p?: AlterTypeStmt): AlterTypeStmt { const _j = {} as AlterTypeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTypeStmt: _j - }; - } return _j; }, - ruleStmt(_p?: RuleStmt, isNode?: boolean): RuleStmt | { - RuleStmt: RuleStmt; - } { + ruleStmt(_p?: RuleStmt): RuleStmt { const _j = {} as RuleStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "rulename", _p?.rulename); @@ -3745,53 +2168,25 @@ export default { _o.set(_j, "instead", _p?.instead); _o.set(_j, "actions", _p?.actions); _o.set(_j, "replace", _p?.replace); - if (isNode) { - return { - RuleStmt: _j - }; - } return _j; }, - notifyStmt(_p?: NotifyStmt, isNode?: boolean): NotifyStmt | { - NotifyStmt: NotifyStmt; - } { + notifyStmt(_p?: NotifyStmt): NotifyStmt { const _j = {} as NotifyStmt; _o.set(_j, "conditionname", _p?.conditionname); _o.set(_j, "payload", _p?.payload); - if (isNode) { - return { - NotifyStmt: _j - }; - } return _j; }, - listenStmt(_p?: ListenStmt, isNode?: boolean): ListenStmt | { - ListenStmt: ListenStmt; - } { + listenStmt(_p?: ListenStmt): ListenStmt { const _j = {} as ListenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - ListenStmt: _j - }; - } return _j; }, - unlistenStmt(_p?: UnlistenStmt, isNode?: boolean): UnlistenStmt | { - UnlistenStmt: UnlistenStmt; - } { + unlistenStmt(_p?: UnlistenStmt): UnlistenStmt { const _j = {} as UnlistenStmt; _o.set(_j, "conditionname", _p?.conditionname); - if (isNode) { - return { - UnlistenStmt: _j - }; - } return _j; }, - transactionStmt(_p?: TransactionStmt, isNode?: boolean): TransactionStmt | { - TransactionStmt: TransactionStmt; - } { + transactionStmt(_p?: TransactionStmt): TransactionStmt { const _j = {} as TransactionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "options", _p?.options); @@ -3799,55 +2194,27 @@ export default { _o.set(_j, "gid", _p?.gid); _o.set(_j, "chain", _p?.chain); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - TransactionStmt: _j - }; - } return _j; }, - compositeTypeStmt(_p?: CompositeTypeStmt, isNode?: boolean): CompositeTypeStmt | { - CompositeTypeStmt: CompositeTypeStmt; - } { + compositeTypeStmt(_p?: CompositeTypeStmt): CompositeTypeStmt { const _j = {} as CompositeTypeStmt; _o.set(_j, "typevar", _p?.typevar); _o.set(_j, "coldeflist", _p?.coldeflist); - if (isNode) { - return { - CompositeTypeStmt: _j - }; - } return _j; }, - createEnumStmt(_p?: CreateEnumStmt, isNode?: boolean): CreateEnumStmt | { - CreateEnumStmt: CreateEnumStmt; - } { + createEnumStmt(_p?: CreateEnumStmt): CreateEnumStmt { const _j = {} as CreateEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "vals", _p?.vals); - if (isNode) { - return { - CreateEnumStmt: _j - }; - } return _j; }, - createRangeStmt(_p?: CreateRangeStmt, isNode?: boolean): CreateRangeStmt | { - CreateRangeStmt: CreateRangeStmt; - } { + createRangeStmt(_p?: CreateRangeStmt): CreateRangeStmt { const _j = {} as CreateRangeStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - CreateRangeStmt: _j - }; - } return _j; }, - alterEnumStmt(_p?: AlterEnumStmt, isNode?: boolean): AlterEnumStmt | { - AlterEnumStmt: AlterEnumStmt; - } { + alterEnumStmt(_p?: AlterEnumStmt): AlterEnumStmt { const _j = {} as AlterEnumStmt; _o.set(_j, "typeName", _p?.typeName); _o.set(_j, "oldVal", _p?.oldVal); @@ -3855,16 +2222,9 @@ export default { _o.set(_j, "newValNeighbor", _p?.newValNeighbor); _o.set(_j, "newValIsAfter", _p?.newValIsAfter); _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); - if (isNode) { - return { - AlterEnumStmt: _j - }; - } return _j; }, - viewStmt(_p?: ViewStmt, isNode?: boolean): ViewStmt | { - ViewStmt: ViewStmt; - } { + viewStmt(_p?: ViewStmt): ViewStmt { const _j = {} as ViewStmt; _o.set(_j, "view", _p?.view); _o.set(_j, "aliases", _p?.aliases); @@ -3872,383 +2232,187 @@ export default { _o.set(_j, "replace", _p?.replace); _o.set(_j, "options", _p?.options); _o.set(_j, "withCheckOption", _p?.withCheckOption); - if (isNode) { - return { - ViewStmt: _j - }; - } return _j; }, - loadStmt(_p?: LoadStmt, isNode?: boolean): LoadStmt | { - LoadStmt: LoadStmt; - } { + loadStmt(_p?: LoadStmt): LoadStmt { const _j = {} as LoadStmt; _o.set(_j, "filename", _p?.filename); - if (isNode) { - return { - LoadStmt: _j - }; - } return _j; }, - createdbStmt(_p?: CreatedbStmt, isNode?: boolean): CreatedbStmt | { - CreatedbStmt: CreatedbStmt; - } { + createdbStmt(_p?: CreatedbStmt): CreatedbStmt { const _j = {} as CreatedbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreatedbStmt: _j - }; - } return _j; }, - alterDatabaseStmt(_p?: AlterDatabaseStmt, isNode?: boolean): AlterDatabaseStmt | { - AlterDatabaseStmt: AlterDatabaseStmt; - } { + alterDatabaseStmt(_p?: AlterDatabaseStmt): AlterDatabaseStmt { const _j = {} as AlterDatabaseStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterDatabaseStmt: _j - }; - } return _j; }, - alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt, isNode?: boolean): AlterDatabaseRefreshCollStmt | { - AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; - } { + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): AlterDatabaseRefreshCollStmt { const _j = {} as AlterDatabaseRefreshCollStmt; _o.set(_j, "dbname", _p?.dbname); - if (isNode) { - return { - AlterDatabaseRefreshCollStmt: _j - }; - } return _j; }, - alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt, isNode?: boolean): AlterDatabaseSetStmt | { - AlterDatabaseSetStmt: AlterDatabaseSetStmt; - } { + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): AlterDatabaseSetStmt { const _j = {} as AlterDatabaseSetStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterDatabaseSetStmt: _j - }; - } return _j; }, - dropdbStmt(_p?: DropdbStmt, isNode?: boolean): DropdbStmt | { - DropdbStmt: DropdbStmt; - } { + dropdbStmt(_p?: DropdbStmt): DropdbStmt { const _j = {} as DropdbStmt; _o.set(_j, "dbname", _p?.dbname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - DropdbStmt: _j - }; - } return _j; }, - alterSystemStmt(_p?: AlterSystemStmt, isNode?: boolean): AlterSystemStmt | { - AlterSystemStmt: AlterSystemStmt; - } { + alterSystemStmt(_p?: AlterSystemStmt): AlterSystemStmt { const _j = {} as AlterSystemStmt; _o.set(_j, "setstmt", _p?.setstmt); - if (isNode) { - return { - AlterSystemStmt: _j - }; - } return _j; }, - clusterStmt(_p?: ClusterStmt, isNode?: boolean): ClusterStmt | { - ClusterStmt: ClusterStmt; - } { + clusterStmt(_p?: ClusterStmt): ClusterStmt { const _j = {} as ClusterStmt; _o.set(_j, "relation", _p?.relation); _o.set(_j, "indexname", _p?.indexname); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ClusterStmt: _j - }; - } return _j; }, - vacuumStmt(_p?: VacuumStmt, isNode?: boolean): VacuumStmt | { - VacuumStmt: VacuumStmt; - } { + vacuumStmt(_p?: VacuumStmt): VacuumStmt { const _j = {} as VacuumStmt; _o.set(_j, "options", _p?.options); _o.set(_j, "rels", _p?.rels); _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); - if (isNode) { - return { - VacuumStmt: _j - }; - } return _j; }, - vacuumRelation(_p?: VacuumRelation, isNode?: boolean): VacuumRelation | { - VacuumRelation: VacuumRelation; - } { + vacuumRelation(_p?: VacuumRelation): VacuumRelation { const _j = {} as VacuumRelation; _o.set(_j, "relation", _p?.relation); _o.set(_j, "oid", _p?.oid); _o.set(_j, "va_cols", _p?.va_cols); - if (isNode) { - return { - VacuumRelation: _j - }; - } return _j; }, - explainStmt(_p?: ExplainStmt, isNode?: boolean): ExplainStmt | { - ExplainStmt: ExplainStmt; - } { + explainStmt(_p?: ExplainStmt): ExplainStmt { const _j = {} as ExplainStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - ExplainStmt: _j - }; - } return _j; }, - createTableAsStmt(_p?: CreateTableAsStmt, isNode?: boolean): CreateTableAsStmt | { - CreateTableAsStmt: CreateTableAsStmt; - } { + createTableAsStmt(_p?: CreateTableAsStmt): CreateTableAsStmt { const _j = {} as CreateTableAsStmt; _o.set(_j, "query", _p?.query); _o.set(_j, "into", _p?.into); _o.set(_j, "objtype", _p?.objtype); _o.set(_j, "is_select_into", _p?.is_select_into); _o.set(_j, "if_not_exists", _p?.if_not_exists); - if (isNode) { - return { - CreateTableAsStmt: _j - }; - } return _j; }, - refreshMatViewStmt(_p?: RefreshMatViewStmt, isNode?: boolean): RefreshMatViewStmt | { - RefreshMatViewStmt: RefreshMatViewStmt; - } { + refreshMatViewStmt(_p?: RefreshMatViewStmt): RefreshMatViewStmt { const _j = {} as RefreshMatViewStmt; _o.set(_j, "concurrent", _p?.concurrent); _o.set(_j, "skipData", _p?.skipData); _o.set(_j, "relation", _p?.relation); - if (isNode) { - return { - RefreshMatViewStmt: _j - }; - } return _j; }, - checkPointStmt(_p?: CheckPointStmt, isNode?: boolean): CheckPointStmt | { - CheckPointStmt: CheckPointStmt; - } { + checkPointStmt(_p?: CheckPointStmt): CheckPointStmt { const _j = {} as CheckPointStmt; - if (isNode) { - return { - CheckPointStmt: _j - }; - } return _j; }, - discardStmt(_p?: DiscardStmt, isNode?: boolean): DiscardStmt | { - DiscardStmt: DiscardStmt; - } { + discardStmt(_p?: DiscardStmt): DiscardStmt { const _j = {} as DiscardStmt; _o.set(_j, "target", _p?.target); - if (isNode) { - return { - DiscardStmt: _j - }; - } return _j; }, - lockStmt(_p?: LockStmt, isNode?: boolean): LockStmt | { - LockStmt: LockStmt; - } { + lockStmt(_p?: LockStmt): LockStmt { const _j = {} as LockStmt; _o.set(_j, "relations", _p?.relations); _o.set(_j, "mode", _p?.mode); _o.set(_j, "nowait", _p?.nowait); - if (isNode) { - return { - LockStmt: _j - }; - } return _j; }, - constraintsSetStmt(_p?: ConstraintsSetStmt, isNode?: boolean): ConstraintsSetStmt | { - ConstraintsSetStmt: ConstraintsSetStmt; - } { + constraintsSetStmt(_p?: ConstraintsSetStmt): ConstraintsSetStmt { const _j = {} as ConstraintsSetStmt; _o.set(_j, "constraints", _p?.constraints); _o.set(_j, "deferred", _p?.deferred); - if (isNode) { - return { - ConstraintsSetStmt: _j - }; - } return _j; }, - reindexStmt(_p?: ReindexStmt, isNode?: boolean): ReindexStmt | { - ReindexStmt: ReindexStmt; - } { + reindexStmt(_p?: ReindexStmt): ReindexStmt { const _j = {} as ReindexStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "relation", _p?.relation); _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ReindexStmt: _j - }; - } return _j; }, - createConversionStmt(_p?: CreateConversionStmt, isNode?: boolean): CreateConversionStmt | { - CreateConversionStmt: CreateConversionStmt; - } { + createConversionStmt(_p?: CreateConversionStmt): CreateConversionStmt { const _j = {} as CreateConversionStmt; _o.set(_j, "conversion_name", _p?.conversion_name); _o.set(_j, "for_encoding_name", _p?.for_encoding_name); _o.set(_j, "to_encoding_name", _p?.to_encoding_name); _o.set(_j, "func_name", _p?.func_name); _o.set(_j, "def", _p?.def); - if (isNode) { - return { - CreateConversionStmt: _j - }; - } return _j; }, - createCastStmt(_p?: CreateCastStmt, isNode?: boolean): CreateCastStmt | { - CreateCastStmt: CreateCastStmt; - } { + createCastStmt(_p?: CreateCastStmt): CreateCastStmt { const _j = {} as CreateCastStmt; _o.set(_j, "sourcetype", _p?.sourcetype); _o.set(_j, "targettype", _p?.targettype); _o.set(_j, "func", _p?.func); _o.set(_j, "context", _p?.context); _o.set(_j, "inout", _p?.inout); - if (isNode) { - return { - CreateCastStmt: _j - }; - } return _j; }, - createTransformStmt(_p?: CreateTransformStmt, isNode?: boolean): CreateTransformStmt | { - CreateTransformStmt: CreateTransformStmt; - } { + createTransformStmt(_p?: CreateTransformStmt): CreateTransformStmt { const _j = {} as CreateTransformStmt; _o.set(_j, "replace", _p?.replace); _o.set(_j, "type_name", _p?.type_name); _o.set(_j, "lang", _p?.lang); _o.set(_j, "fromsql", _p?.fromsql); _o.set(_j, "tosql", _p?.tosql); - if (isNode) { - return { - CreateTransformStmt: _j - }; - } return _j; }, - prepareStmt(_p?: PrepareStmt, isNode?: boolean): PrepareStmt | { - PrepareStmt: PrepareStmt; - } { + prepareStmt(_p?: PrepareStmt): PrepareStmt { const _j = {} as PrepareStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "argtypes", _p?.argtypes); _o.set(_j, "query", _p?.query); - if (isNode) { - return { - PrepareStmt: _j - }; - } return _j; }, - executeStmt(_p?: ExecuteStmt, isNode?: boolean): ExecuteStmt | { - ExecuteStmt: ExecuteStmt; - } { + executeStmt(_p?: ExecuteStmt): ExecuteStmt { const _j = {} as ExecuteStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "params", _p?.params); - if (isNode) { - return { - ExecuteStmt: _j - }; - } return _j; }, - deallocateStmt(_p?: DeallocateStmt, isNode?: boolean): DeallocateStmt | { - DeallocateStmt: DeallocateStmt; - } { + deallocateStmt(_p?: DeallocateStmt): DeallocateStmt { const _j = {} as DeallocateStmt; _o.set(_j, "name", _p?.name); _o.set(_j, "isall", _p?.isall); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - DeallocateStmt: _j - }; - } return _j; }, - dropOwnedStmt(_p?: DropOwnedStmt, isNode?: boolean): DropOwnedStmt | { - DropOwnedStmt: DropOwnedStmt; - } { + dropOwnedStmt(_p?: DropOwnedStmt): DropOwnedStmt { const _j = {} as DropOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropOwnedStmt: _j - }; - } return _j; }, - reassignOwnedStmt(_p?: ReassignOwnedStmt, isNode?: boolean): ReassignOwnedStmt | { - ReassignOwnedStmt: ReassignOwnedStmt; - } { + reassignOwnedStmt(_p?: ReassignOwnedStmt): ReassignOwnedStmt { const _j = {} as ReassignOwnedStmt; _o.set(_j, "roles", _p?.roles); _o.set(_j, "newrole", _p?.newrole); - if (isNode) { - return { - ReassignOwnedStmt: _j - }; - } return _j; }, - altertsDictionaryStmt(_p?: AlterTSDictionaryStmt, isNode?: boolean): AlterTSDictionaryStmt | { - AlterTSDictionaryStmt: AlterTSDictionaryStmt; - } { + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): AlterTSDictionaryStmt { const _j = {} as AlterTSDictionaryStmt; _o.set(_j, "dictname", _p?.dictname); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterTSDictionaryStmt: _j - }; - } return _j; }, - altertsConfigurationStmt(_p?: AlterTSConfigurationStmt, isNode?: boolean): AlterTSConfigurationStmt | { - AlterTSConfigurationStmt: AlterTSConfigurationStmt; - } { + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): AlterTSConfigurationStmt { const _j = {} as AlterTSConfigurationStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "cfgname", _p?.cfgname); @@ -4257,131 +2421,70 @@ export default { _o.set(_j, "override", _p?.override); _o.set(_j, "replace", _p?.replace); _o.set(_j, "missing_ok", _p?.missing_ok); - if (isNode) { - return { - AlterTSConfigurationStmt: _j - }; - } return _j; }, - publicationTable(_p?: PublicationTable, isNode?: boolean): PublicationTable | { - PublicationTable: PublicationTable; - } { + publicationTable(_p?: PublicationTable): PublicationTable { const _j = {} as PublicationTable; _o.set(_j, "relation", _p?.relation); _o.set(_j, "whereClause", _p?.whereClause); _o.set(_j, "columns", _p?.columns); - if (isNode) { - return { - PublicationTable: _j - }; - } return _j; }, - publicationObjSpec(_p?: PublicationObjSpec, isNode?: boolean): PublicationObjSpec | { - PublicationObjSpec: PublicationObjSpec; - } { + publicationObjSpec(_p?: PublicationObjSpec): PublicationObjSpec { const _j = {} as PublicationObjSpec; _o.set(_j, "pubobjtype", _p?.pubobjtype); _o.set(_j, "name", _p?.name); _o.set(_j, "pubtable", _p?.pubtable); _o.set(_j, "location", _p?.location); - if (isNode) { - return { - PublicationObjSpec: _j - }; - } return _j; }, - createPublicationStmt(_p?: CreatePublicationStmt, isNode?: boolean): CreatePublicationStmt | { - CreatePublicationStmt: CreatePublicationStmt; - } { + createPublicationStmt(_p?: CreatePublicationStmt): CreatePublicationStmt { const _j = {} as CreatePublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); - if (isNode) { - return { - CreatePublicationStmt: _j - }; - } return _j; }, - alterPublicationStmt(_p?: AlterPublicationStmt, isNode?: boolean): AlterPublicationStmt | { - AlterPublicationStmt: AlterPublicationStmt; - } { + alterPublicationStmt(_p?: AlterPublicationStmt): AlterPublicationStmt { const _j = {} as AlterPublicationStmt; _o.set(_j, "pubname", _p?.pubname); _o.set(_j, "options", _p?.options); _o.set(_j, "pubobjects", _p?.pubobjects); _o.set(_j, "for_all_tables", _p?.for_all_tables); _o.set(_j, "action", _p?.action); - if (isNode) { - return { - AlterPublicationStmt: _j - }; - } return _j; }, - createSubscriptionStmt(_p?: CreateSubscriptionStmt, isNode?: boolean): CreateSubscriptionStmt | { - CreateSubscriptionStmt: CreateSubscriptionStmt; - } { + createSubscriptionStmt(_p?: CreateSubscriptionStmt): CreateSubscriptionStmt { const _j = {} as CreateSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - CreateSubscriptionStmt: _j - }; - } return _j; }, - alterSubscriptionStmt(_p?: AlterSubscriptionStmt, isNode?: boolean): AlterSubscriptionStmt | { - AlterSubscriptionStmt: AlterSubscriptionStmt; - } { + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): AlterSubscriptionStmt { const _j = {} as AlterSubscriptionStmt; _o.set(_j, "kind", _p?.kind); _o.set(_j, "subname", _p?.subname); _o.set(_j, "conninfo", _p?.conninfo); _o.set(_j, "publication", _p?.publication); _o.set(_j, "options", _p?.options); - if (isNode) { - return { - AlterSubscriptionStmt: _j - }; - } return _j; }, - dropSubscriptionStmt(_p?: DropSubscriptionStmt, isNode?: boolean): DropSubscriptionStmt | { - DropSubscriptionStmt: DropSubscriptionStmt; - } { + dropSubscriptionStmt(_p?: DropSubscriptionStmt): DropSubscriptionStmt { const _j = {} as DropSubscriptionStmt; _o.set(_j, "subname", _p?.subname); _o.set(_j, "missing_ok", _p?.missing_ok); _o.set(_j, "behavior", _p?.behavior); - if (isNode) { - return { - DropSubscriptionStmt: _j - }; - } return _j; }, - scanToken(_p?: ScanToken, isNode?: boolean): ScanToken | { - ScanToken: ScanToken; - } { + scanToken(_p?: ScanToken): ScanToken { const _j = {} as ScanToken; _o.set(_j, "start", _p?.start); _o.set(_j, "end", _p?.end); _o.set(_j, "token", _p?.token); _o.set(_j, "keywordKind", _p?.keywordKind); - if (isNode) { - return { - ScanToken: _j - }; - } return _j; } }; \ No newline at end of file diff --git a/packages/utils/src/index.ts b/packages/utils/src/index.ts index 642c4030..379197c3 100644 --- a/packages/utils/src/index.ts +++ b/packages/utils/src/index.ts @@ -1,3 +1,8 @@ -export * from './utils'; -import asts from './asts'; -export default asts; \ No newline at end of file +import ast from './asts'; +import nodes from './wrapped'; +export { nodes }; +export { ast }; +export default { + nodes, + ast +} \ No newline at end of file diff --git a/packages/utils/src/runtime-schema.ts.ts b/packages/utils/src/runtime-schema.ts.ts new file mode 100644 index 00000000..fe30f0b3 --- /dev/null +++ b/packages/utils/src/runtime-schema.ts.ts @@ -0,0 +1,11427 @@ +/** +* This file was automatically generated by pg-proto-parser@1.28.2. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +export interface FieldSpec { + name: string; + type: string; + isNode: boolean; + isArray: boolean; + optional: boolean; +} +export interface NodeSpec { + name: string; + isNode: boolean; + fields: FieldSpec[]; +} +export const runtimeSchema: NodeSpec[] = [ + { + name: 'A_ArrayExpr', + isNode: true, + fields: [ + { + name: 'elements', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'A_Const', + isNode: true, + fields: [ + { + name: 'boolval', + type: 'Boolean', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'bsval', + type: 'BitString', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'fval', + type: 'Float', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'isnull', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ival', + type: 'Integer', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'sval', + type: 'String', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'A_Expr', + isNode: true, + fields: [ + { + name: 'kind', + type: 'A_Expr_Kind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'A_Indices', + isNode: true, + fields: [ + { + name: 'is_slice', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lidx', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'uidx', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'A_Indirection', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'indirection', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'A_Star', + isNode: true, + fields: [ + + ] + }, + { + name: 'AccessPriv', + isNode: true, + fields: [ + { + name: 'cols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'priv_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'Aggref', + isNode: true, + fields: [ + { + name: 'aggargtypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'aggcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggdirectargs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'aggdistinct', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'aggfilter', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'aggfnoid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggkind', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'agglevelsup', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggorder', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'aggsplit', + type: 'AggSplit', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggstar', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggtransno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggtype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'aggvariadic', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Alias', + isNode: true, + fields: [ + { + name: 'aliasname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'colnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterCollationStmt', + isNode: true, + fields: [ + { + name: 'collname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterDatabaseRefreshCollStmt', + isNode: true, + fields: [ + { + name: 'dbname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterDatabaseSetStmt', + isNode: true, + fields: [ + { + name: 'dbname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'setstmt', + type: 'VariableSetStmt', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterDatabaseStmt', + isNode: true, + fields: [ + { + name: 'dbname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterDefaultPrivilegesStmt', + isNode: true, + fields: [ + { + name: 'action', + type: 'GrantStmt', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterDomainStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'def', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subtype', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterEnumStmt', + isNode: true, + fields: [ + { + name: 'newVal', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'newValIsAfter', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'newValNeighbor', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'oldVal', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'skipIfNewValExists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterEventTrigStmt', + isNode: true, + fields: [ + { + name: 'tgenabled', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'trigname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterExtensionContentsStmt', + isNode: true, + fields: [ + { + name: 'action', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'extname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterExtensionStmt', + isNode: true, + fields: [ + { + name: 'extname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterFdwStmt', + isNode: true, + fields: [ + { + name: 'fdwname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'func_options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterForeignServerStmt', + isNode: true, + fields: [ + { + name: 'has_version', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'version', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterFunctionStmt', + isNode: true, + fields: [ + { + name: 'actions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'func', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlternativeSubPlan', + isNode: true, + fields: [ + { + name: 'subplans', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterObjectDependsStmt', + isNode: true, + fields: [ + { + name: 'extname', + type: 'String', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objectType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'remove', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterObjectSchemaStmt', + isNode: true, + fields: [ + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'newschema', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objectType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterOperatorStmt', + isNode: true, + fields: [ + { + name: 'opername', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterOpFamilyStmt', + isNode: true, + fields: [ + { + name: 'amname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'isDrop', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'items', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opfamilyname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterOwnerStmt', + isNode: true, + fields: [ + { + name: 'newowner', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objectType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterPolicyStmt', + isNode: true, + fields: [ + { + name: 'policy_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'qual', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'table', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'with_check', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterPublicationStmt', + isNode: true, + fields: [ + { + name: 'action', + type: 'AlterPublicationAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'for_all_tables', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pubname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'pubobjects', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterRoleSetStmt', + isNode: true, + fields: [ + { + name: 'database', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'role', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'setstmt', + type: 'VariableSetStmt', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterRoleStmt', + isNode: true, + fields: [ + { + name: 'action', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'role', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterSeqStmt', + isNode: true, + fields: [ + { + name: 'for_identity', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'sequence', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterStatsStmt', + isNode: true, + fields: [ + { + name: 'defnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'stxstattarget', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterSubscriptionStmt', + isNode: true, + fields: [ + { + name: 'conninfo', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'kind', + type: 'AlterSubscriptionType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'publication', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'subname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterSystemStmt', + isNode: true, + fields: [ + { + name: 'setstmt', + type: 'VariableSetStmt', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterTableCmd', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'def', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'newowner', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'num', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'recurse', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subtype', + type: 'AlterTableType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterTableMoveAllStmt', + isNode: true, + fields: [ + { + name: 'new_tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nowait', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'orig_tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterTableSpaceOptionsStmt', + isNode: true, + fields: [ + { + name: 'isReset', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterTableStmt', + isNode: true, + fields: [ + { + name: 'cmds', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'AlterTSConfigurationStmt', + isNode: true, + fields: [ + { + name: 'cfgname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'dicts', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'kind', + type: 'AlterTSConfigType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'override', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tokentype', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterTSDictionaryStmt', + isNode: true, + fields: [ + { + name: 'dictname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterTypeStmt', + isNode: true, + fields: [ + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'typeName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'AlterUserMappingStmt', + isNode: true, + fields: [ + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'user', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ArrayCoerceExpr', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'coerceformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'elemexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ArrayExpr', + isNode: true, + fields: [ + { + name: 'array_collid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'array_typeid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'element_typeid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'elements', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'multidims', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'BitString', + isNode: true, + fields: [ + { + name: 'bsval', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'Boolean', + isNode: true, + fields: [ + { + name: 'boolval', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'BooleanTest', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'booltesttype', + type: 'BoolTestType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'BoolExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'boolop', + type: 'BoolExprType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CallContext', + isNode: true, + fields: [ + { + name: 'atomic', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CallStmt', + isNode: true, + fields: [ + { + name: 'funccall', + type: 'FuncCall', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'funcexpr', + type: 'FuncExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'outargs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CaseExpr', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'casecollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'casetype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'defresult', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CaseTestExpr', + isNode: true, + fields: [ + { + name: 'collation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeId', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeMod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CaseWhen', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'result', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CheckPointStmt', + isNode: true, + fields: [ + + ] + }, + { + name: 'ClosePortalStmt', + isNode: true, + fields: [ + { + name: 'portalname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ClusterStmt', + isNode: true, + fields: [ + { + name: 'indexname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'params', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CoalesceExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coalescecollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'coalescetype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CoerceToDomain', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'coercionformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CoerceToDomainValue', + isNode: true, + fields: [ + { + name: 'collation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeId', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeMod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CoerceViaIO', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'coerceformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CollateClause', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'collname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CollateExpr', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'collOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ColumnDef', + isNode: true, + fields: [ + { + name: 'collClause', + type: 'CollateClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'collOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'colname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'compression', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'constraints', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'cooked_default', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'fdwoptions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'generated', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'identity', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'identitySequence', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'inhcount', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_from_type', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_local', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_not_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'raw_default', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'storage', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'storage_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ColumnRef', + isNode: true, + fields: [ + { + name: 'fields', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CommentStmt', + isNode: true, + fields: [ + { + name: 'comment', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CommonTableExpr', + isNode: true, + fields: [ + { + name: 'aliascolnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctecolcollations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctecolnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctecoltypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctecoltypmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctematerialized', + type: 'CTEMaterialize', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ctename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ctequery', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'cterecursive', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cterefcount', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_clause', + type: 'CTECycleClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'search_clause', + type: 'CTESearchClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CompositeTypeStmt', + isNode: true, + fields: [ + { + name: 'coldeflist', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'typevar', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Constraint', + isNode: true, + fields: [ + { + name: 'access_method', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'conname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'contype', + type: 'ConstrType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cooked_expr', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'deferrable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'exclusions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'fk_attrs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'fk_del_action', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'fk_del_set_cols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'fk_matchtype', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'fk_upd_action', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'generated_when', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'including', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'indexname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'indexspace', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inhcount', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'initdeferred', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'initially_valid', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_no_inherit', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'keys', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nulls_not_distinct', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'old_conpfeqop', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'old_pktable_oid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pk_attrs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pktable', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'raw_expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'reset_default_tblspc', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'skip_validation', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'where_clause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ConstraintsSetStmt', + isNode: true, + fields: [ + { + name: 'constraints', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'deferred', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ConvertRowtypeExpr', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'convertformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CopyStmt', + isNode: true, + fields: [ + { + name: 'attlist', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'filename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_from', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_program', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateAmStmt', + isNode: true, + fields: [ + { + name: 'amname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'amtype', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'handler_name', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateCastStmt', + isNode: true, + fields: [ + { + name: 'context', + type: 'CoercionContext', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'func', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'inout', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'sourcetype', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'targettype', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateConversionStmt', + isNode: true, + fields: [ + { + name: 'conversion_name', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'def', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'for_encoding_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'func_name', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'to_encoding_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreatedbStmt', + isNode: true, + fields: [ + { + name: 'dbname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateDomainStmt', + isNode: true, + fields: [ + { + name: 'collClause', + type: 'CollateClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'constraints', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'domainname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateEnumStmt', + isNode: true, + fields: [ + { + name: 'typeName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'vals', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateEventTrigStmt', + isNode: true, + fields: [ + { + name: 'eventname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'trigname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'whenclause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateExtensionStmt', + isNode: true, + fields: [ + { + name: 'extname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateFdwStmt', + isNode: true, + fields: [ + { + name: 'fdwname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'func_options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateForeignServerStmt', + isNode: true, + fields: [ + { + name: 'fdwname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'servertype', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'version', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateForeignTableStmt', + isNode: true, + fields: [ + { + name: 'base', + type: 'CreateStmt', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateFunctionStmt', + isNode: true, + fields: [ + { + name: 'funcname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'is_procedure', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'parameters', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'returnType', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'sql_body', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateOpClassItem', + isNode: true, + fields: [ + { + name: 'class_args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'itemtype', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'number', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'order_family', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'storedtype', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateOpClassStmt', + isNode: true, + fields: [ + { + name: 'amname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'datatype', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'isDefault', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'items', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opclassname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opfamilyname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateOpFamilyStmt', + isNode: true, + fields: [ + { + name: 'amname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opfamilyname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreatePLangStmt', + isNode: true, + fields: [ + { + name: 'plhandler', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'plinline', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'plname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'pltrusted', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'plvalidator', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreatePolicyStmt', + isNode: true, + fields: [ + { + name: 'cmd_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'permissive', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'policy_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'qual', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'table', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'with_check', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreatePublicationStmt', + isNode: true, + fields: [ + { + name: 'for_all_tables', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pubname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'pubobjects', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateRangeStmt', + isNode: true, + fields: [ + { + name: 'params', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'typeName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'CreateRoleStmt', + isNode: true, + fields: [ + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'role', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'stmt_type', + type: 'RoleStmtType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateSchemaStmt', + isNode: true, + fields: [ + { + name: 'authrole', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'schemaElts', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'schemaname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateSeqStmt', + isNode: true, + fields: [ + { + name: 'for_identity', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ownerId', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'sequence', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateStatsStmt', + isNode: true, + fields: [ + { + name: 'defnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'exprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'stat_types', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'stxcomment', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'transformed', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateStmt', + isNode: true, + fields: [ + { + name: 'accessMethod', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'constraints', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inhRelations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ofTypename', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'oncommit', + type: 'OnCommitAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'partbound', + type: 'PartitionBoundSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'partspec', + type: 'PartitionSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'tableElts', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateSubscriptionStmt', + isNode: true, + fields: [ + { + name: 'conninfo', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'publication', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'subname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateTableAsStmt', + isNode: true, + fields: [ + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'into', + type: 'IntoClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'is_select_into', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateTableSpaceStmt', + isNode: true, + fields: [ + { + name: 'location', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'owner', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateTransformStmt', + isNode: true, + fields: [ + { + name: 'fromsql', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'lang', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tosql', + type: 'ObjectWithArgs', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'type_name', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateTrigStmt', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'columns', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'constrrel', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'deferrable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'events', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'initdeferred', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'isconstraint', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'row', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'timing', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'transitionRels', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'trigname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'whenClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CreateUserMappingStmt', + isNode: true, + fields: [ + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'user', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'CTECycleClause', + isNode: true, + fields: [ + { + name: 'cycle_col_list', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'cycle_mark_collation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_column', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_default', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_neop', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_type', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_typmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cycle_mark_value', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'cycle_path_column', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CTESearchClause', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'search_breadth_first', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'search_col_list', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'search_seq_column', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'CurrentOfExpr', + isNode: true, + fields: [ + { + name: 'cursor_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cursor_param', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'cvarno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'DeallocateStmt', + isNode: true, + fields: [ + { + name: 'isall', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DeclareCursorStmt', + isNode: true, + fields: [ + { + name: 'options', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'portalname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'DefElem', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'defaction', + type: 'DefElemAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'defname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'defnamespace', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DefineStmt', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'definition', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'defnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'kind', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'oldstyle', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DeleteStmt', + isNode: true, + fields: [ + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'returningList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'usingClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'withClause', + type: 'WithClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'DiscardStmt', + isNode: true, + fields: [ + { + name: 'target', + type: 'DiscardMode', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DistinctExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opresulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opretset', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'DoStmt', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'DropdbStmt', + isNode: true, + fields: [ + { + name: 'dbname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'DropOwnedStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'DropRoleStmt', + isNode: true, + fields: [ + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'DropStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'concurrent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objects', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'removeType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DropSubscriptionStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DropTableSpaceStmt', + isNode: true, + fields: [ + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tablespacename', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'DropUserMappingStmt', + isNode: true, + fields: [ + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'servername', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'user', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ExecuteStmt', + isNode: true, + fields: [ + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'params', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'ExplainStmt', + isNode: true, + fields: [ + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'FetchStmt', + isNode: true, + fields: [ + { + name: 'direction', + type: 'FetchDirection', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'howMany', + type: 'int64', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ismove', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'portalname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'FieldSelect', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'fieldnum', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'FieldStore', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'fieldnums', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'newvals', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Float', + isNode: true, + fields: [ + { + name: 'fval', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'FromExpr', + isNode: true, + fields: [ + { + name: 'fromlist', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'quals', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'FuncCall', + isNode: true, + fields: [ + { + name: 'agg_distinct', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'agg_filter', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'agg_order', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'agg_star', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'agg_within_group', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'func_variadic', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'over', + type: 'WindowDef', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'FuncExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'funccollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcresulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcretset', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funcvariadic', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'FunctionParameter', + isNode: true, + fields: [ + { + name: 'argType', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'defexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'mode', + type: 'FunctionParameterMode', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'GrantRoleStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'granted_roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'grantee_roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'grantor', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'is_grant', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opt', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'GrantStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'grant_option', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'grantees', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'grantor', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'is_grant', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objects', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'privileges', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'targtype', + type: 'GrantTargetType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'GroupingFunc', + isNode: true, + fields: [ + { + name: 'agglevelsup', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'refs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'GroupingSet', + isNode: true, + fields: [ + { + name: 'content', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'kind', + type: 'GroupingSetKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ImportForeignSchemaStmt', + isNode: true, + fields: [ + { + name: 'list_type', + type: 'ImportForeignSchemaType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'local_schema', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'remote_schema', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'server_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'table_list', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'IndexElem', + isNode: true, + fields: [ + { + name: 'collation', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'indexcolname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nulls_ordering', + type: 'SortByNulls', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opclass', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opclassopts', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ordering', + type: 'SortByDir', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'IndexStmt', + isNode: true, + fields: [ + { + name: 'accessMethod', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'concurrent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'deferrable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'excludeOpNames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'idxcomment', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'idxname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'if_not_exists', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'indexIncludingParams', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'indexOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'indexParams', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'initdeferred', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'isconstraint', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nulls_not_distinct', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'oldCreateSubid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'oldFirstRelfilelocatorSubid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'oldNumber', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'primary', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'reset_default_tblspc', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tableSpace', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'transformed', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'unique', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'InferClause', + isNode: true, + fields: [ + { + name: 'conname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'indexElems', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'InferenceElem', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'infercollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inferopclass', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'InlineCodeBlock', + isNode: true, + fields: [ + { + name: 'atomic', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'langIsTrusted', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'langOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'source_text', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'InsertStmt', + isNode: true, + fields: [ + { + name: 'cols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'onConflictClause', + type: 'OnConflictClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'override', + type: 'OverridingKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'returningList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'selectStmt', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'withClause', + type: 'WithClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Integer', + isNode: true, + fields: [ + { + name: 'ival', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'IntList', + isNode: true, + fields: [ + { + name: 'items', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'IntoClause', + isNode: true, + fields: [ + { + name: 'accessMethod', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'colNames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'onCommit', + type: 'OnCommitAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rel', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'skipData', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tableSpaceName', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'viewQuery', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JoinExpr', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'isNatural', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'join_using_alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'jointype', + type: 'JoinType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'larg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'quals', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'rarg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'rtindex', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'usingClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'JsonAggConstructor', + isNode: true, + fields: [ + { + name: 'agg_filter', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'agg_order', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'over', + type: 'WindowDef', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonArgument', + isNode: true, + fields: [ + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'val', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonArrayAgg', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'arg', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'constructor', + type: 'JsonAggConstructor', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonArrayConstructor', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'exprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonArrayQueryConstructor', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonBehavior', + isNode: true, + fields: [ + { + name: 'btype', + type: 'JsonBehaviorType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'coerce', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonConstructorExpr', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coercion', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'func', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'returning', + type: 'JsonReturning', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'type', + type: 'JsonConstructorType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'unique', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonExpr', + isNode: true, + fields: [ + { + name: 'collation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'column_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'formatted_expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'omit_quotes', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'on_empty', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'on_error', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'op', + type: 'JsonExprOp', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'passing_names', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'passing_values', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'path_spec', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'returning', + type: 'JsonReturning', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'use_io_coercion', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'use_json_coercion', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'wrapper', + type: 'JsonWrapper', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonFormat', + isNode: true, + fields: [ + { + name: 'encoding', + type: 'JsonEncoding', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'format_type', + type: 'JsonFormatType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonFuncExpr', + isNode: true, + fields: [ + { + name: 'column_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'context_item', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'on_empty', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'on_error', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'op', + type: 'JsonExprOp', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'passing', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pathspec', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'quotes', + type: 'JsonQuotes', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'wrapper', + type: 'JsonWrapper', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonIsPredicate', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'item_type', + type: 'JsonValueType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'unique_keys', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonKeyValue', + isNode: true, + fields: [ + { + name: 'key', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'value', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonObjectAgg', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'arg', + type: 'JsonKeyValue', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'constructor', + type: 'JsonAggConstructor', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'unique', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonObjectConstructor', + isNode: true, + fields: [ + { + name: 'absent_on_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'exprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'unique', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonOutput', + isNode: true, + fields: [ + { + name: 'returning', + type: 'JsonReturning', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonParseExpr', + isNode: true, + fields: [ + { + name: 'expr', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'unique_keys', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonReturning', + isNode: true, + fields: [ + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'typid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonScalarExpr', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonSerializeExpr', + isNode: true, + fields: [ + { + name: 'expr', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'output', + type: 'JsonOutput', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTable', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'columns', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'context_item', + type: 'JsonValueExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'lateral', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'on_error', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'passing', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pathspec', + type: 'JsonTablePathSpec', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTableColumn', + isNode: true, + fields: [ + { + name: 'coltype', + type: 'JsonTableColumnType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'columns', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'on_empty', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'on_error', + type: 'JsonBehavior', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'pathspec', + type: 'JsonTablePathSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'quotes', + type: 'JsonQuotes', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'wrapper', + type: 'JsonWrapper', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTablePath', + isNode: true, + fields: [ + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTablePathScan', + isNode: true, + fields: [ + { + name: 'child', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'colMax', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'colMin', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'errorOnError', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'path', + type: 'JsonTablePath', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'plan', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTablePathSpec', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name_location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'string', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonTableSiblingJoin', + isNode: true, + fields: [ + { + name: 'lplan', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'plan', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'rplan', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'JsonValueExpr', + isNode: true, + fields: [ + { + name: 'format', + type: 'JsonFormat', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'formatted_expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'raw_expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'List', + isNode: true, + fields: [ + { + name: 'items', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'ListenStmt', + isNode: true, + fields: [ + { + name: 'conditionname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'LoadStmt', + isNode: true, + fields: [ + { + name: 'filename', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'LockingClause', + isNode: true, + fields: [ + { + name: 'lockedRels', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'strength', + type: 'LockClauseStrength', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'waitPolicy', + type: 'LockWaitPolicy', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'LockStmt', + isNode: true, + fields: [ + { + name: 'mode', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nowait', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'MergeAction', + isNode: true, + fields: [ + { + name: 'commandType', + type: 'CmdType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'matchKind', + type: 'MergeMatchKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'override', + type: 'OverridingKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'qual', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'updateColnos', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'MergeStmt', + isNode: true, + fields: [ + { + name: 'joinCondition', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'mergeWhenClauses', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'returningList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'sourceRelation', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'withClause', + type: 'WithClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'MergeSupportFunc', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'msfcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'msftype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'MergeWhenClause', + isNode: true, + fields: [ + { + name: 'commandType', + type: 'CmdType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'condition', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'matchKind', + type: 'MergeMatchKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'override', + type: 'OverridingKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'values', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'MinMaxExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'minmaxcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'minmaxtype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'op', + type: 'MinMaxOp', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'MultiAssignRef', + isNode: true, + fields: [ + { + name: 'colno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ncolumns', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'source', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'NamedArgExpr', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'argnumber', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'NextValueExpr', + isNode: true, + fields: [ + { + name: 'seqid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeId', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'NotifyStmt', + isNode: true, + fields: [ + { + name: 'conditionname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'payload', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'NullIfExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opresulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opretset', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'NullTest', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'argisrow', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nulltesttype', + type: 'NullTestType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ObjectWithArgs', + isNode: true, + fields: [ + { + name: 'args_unspecified', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'objargs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'objfuncargs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'objname', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'OidList', + isNode: true, + fields: [ + { + name: 'items', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'OnConflictClause', + isNode: true, + fields: [ + { + name: 'action', + type: 'OnConflictAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'infer', + type: 'InferClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'OnConflictExpr', + isNode: true, + fields: [ + { + name: 'action', + type: 'OnConflictAction', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'arbiterElems', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'arbiterWhere', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'constraint', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'exclRelIndex', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'exclRelTlist', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'onConflictSet', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'onConflictWhere', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'OpExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opresulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opretset', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Param', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramid', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramkind', + type: 'ParamKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramtype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramtypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ParamRef', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'number', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ParseResult', + isNode: false, + fields: [ + { + name: 'stmts', + type: 'RawStmt', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'version', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'PartitionBoundSpec', + isNode: true, + fields: [ + { + name: 'is_default', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'listdatums', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lowerdatums', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'modulus', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'remainder', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'strategy', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'upperdatums', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'PartitionCmd', + isNode: true, + fields: [ + { + name: 'bound', + type: 'PartitionBoundSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'concurrent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'PartitionElem', + isNode: true, + fields: [ + { + name: 'collation', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opclass', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'PartitionRangeDatum', + isNode: true, + fields: [ + { + name: 'kind', + type: 'PartitionRangeDatumKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'value', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'PartitionSpec', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'partParams', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'strategy', + type: 'PartitionStrategy', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'PLAssignStmt', + isNode: true, + fields: [ + { + name: 'indirection', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nnames', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'val', + type: 'SelectStmt', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'PrepareStmt', + isNode: true, + fields: [ + { + name: 'argtypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'PublicationObjSpec', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'pubobjtype', + type: 'PublicationObjSpecType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'pubtable', + type: 'PublicationTable', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'PublicationTable', + isNode: true, + fields: [ + { + name: 'columns', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'Query', + isNode: true, + fields: [ + { + name: 'canSetTag', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'commandType', + type: 'CmdType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'constraintDeps', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'cteList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'distinctClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'groupClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'groupDistinct', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'groupingSets', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'hasAggs', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasDistinctOn', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasForUpdate', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasModifyingCTE', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasRecursive', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasRowSecurity', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasSubLinks', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasTargetSRFs', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hasWindowFuncs', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'havingQual', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'isReturn', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'jointree', + type: 'FromExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitCount', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitOption', + type: 'LimitOption', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'mergeActionList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'mergeJoinCondition', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'mergeTargetRelation', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'onConflict', + type: 'OnConflictExpr', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'override', + type: 'OverridingKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'querySource', + type: 'QuerySource', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultRelation', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'returningList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rowMarks', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rtable', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rteperminfos', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'setOperations', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'sortClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'stmt_len', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'stmt_location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'utilityStmt', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'windowClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'withCheckOptions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'RangeFunction', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'coldeflist', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'functions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'is_rowsfrom', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lateral', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ordinality', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeSubselect', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'lateral', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subquery', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeTableFunc', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'columns', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'docexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'lateral', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'namespaces', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rowexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeTableFuncCol', + isNode: true, + fields: [ + { + name: 'coldefexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'colexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'colname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'for_ordinality', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'is_not_null', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeTableSample', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'method', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'repeatable', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeTblEntry', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'colcollations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coltypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coltypmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ctelevelsup', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ctename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'enrname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'enrtuples', + type: 'double', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'eref', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'funcordinality', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'functions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inFromCl', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inh', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'join_using_alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'joinaliasvars', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'joinleftcols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'joinmergedcols', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'joinrightcols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'jointype', + type: 'JoinType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lateral', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'perminfoindex', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relkind', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rellockmode', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rtekind', + type: 'RTEKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'security_barrier', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'securityQuals', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'self_reference', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subquery', + type: 'Query', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'tablefunc', + type: 'TableFunc', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'tablesample', + type: 'TableSampleClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'values_lists', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'RangeTblFunction', + isNode: true, + fields: [ + { + name: 'funccolcollations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'funccolcount', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'funccolnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'funccoltypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'funccoltypmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'funcexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'funcparams', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + } + ] + }, + { + name: 'RangeTblRef', + isNode: true, + fields: [ + { + name: 'rtindex', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'RangeVar', + isNode: true, + fields: [ + { + name: 'alias', + type: 'Alias', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'catalogname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inh', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relpersistence', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'schemaname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'RawStmt', + isNode: true, + fields: [ + { + name: 'stmt', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'stmt_len', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'stmt_location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ReassignOwnedStmt', + isNode: true, + fields: [ + { + name: 'newrole', + type: 'RoleSpec', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'roles', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'RefreshMatViewStmt', + isNode: true, + fields: [ + { + name: 'concurrent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'skipData', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ReindexStmt', + isNode: true, + fields: [ + { + name: 'kind', + type: 'ReindexObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'params', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RelabelType', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relabelformat', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resultcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resulttypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RenameStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'missing_ok', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'newname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relationType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'renameType', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ReplicaIdentityStmt', + isNode: true, + fields: [ + { + name: 'identity_type', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ResTarget', + isNode: true, + fields: [ + { + name: 'indirection', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'val', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ReturnStmt', + isNode: true, + fields: [ + { + name: 'returnval', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RoleSpec', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rolename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'roletype', + type: 'RoleSpecType', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'RowCompareExpr', + isNode: true, + fields: [ + { + name: 'inputcollids', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'largs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opfamilies', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'opnos', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rargs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rctype', + type: 'RowCompareType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RowExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'row_format', + type: 'CoercionForm', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'row_typeid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'RowMarkClause', + isNode: true, + fields: [ + { + name: 'pushedDown', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rti', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'strength', + type: 'LockClauseStrength', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'waitPolicy', + type: 'LockWaitPolicy', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'RTEPermissionInfo', + isNode: true, + fields: [ + { + name: 'checkAsUser', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inh', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'insertedCols', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + }, + { + name: 'relid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'requiredPerms', + type: 'uint64', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'selectedCols', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + }, + { + name: 'updatedCols', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + } + ] + }, + { + name: 'RuleStmt', + isNode: true, + fields: [ + { + name: 'actions', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'event', + type: 'CmdType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'instead', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rulename', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ScalarArrayOpExpr', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'useOr', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'ScanResult', + isNode: false, + fields: [ + { + name: 'tokens', + type: 'ScanToken', + isNode: false, + isArray: true, + optional: true + }, + { + name: 'version', + type: 'int32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ScanToken', + isNode: false, + fields: [ + { + name: 'end', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'keywordKind', + type: 'KeywordKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'start', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'token', + type: 'Token', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'SecLabelStmt', + isNode: true, + fields: [ + { + name: 'label', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'object', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'objtype', + type: 'ObjectType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'provider', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'SelectStmt', + isNode: true, + fields: [ + { + name: 'all', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'distinctClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'fromClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'groupClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'groupDistinct', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'havingClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'intoClause', + type: 'IntoClause', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'larg', + type: 'SelectStmt', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitCount', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'limitOption', + type: 'LimitOption', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'lockingClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'op', + type: 'SetOperation', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rarg', + type: 'SelectStmt', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'sortClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'valuesLists', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'windowClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'withClause', + type: 'WithClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'SetOperationStmt', + isNode: true, + fields: [ + { + name: 'all', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'colCollations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colTypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colTypmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'groupClauses', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'larg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'op', + type: 'SetOperation', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'rarg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'SetToDefault', + isNode: true, + fields: [ + { + name: 'collation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeId', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeMod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'SinglePartitionSpec', + isNode: true, + fields: [ + + ] + }, + { + name: 'SortBy', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'node', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'sortby_dir', + type: 'SortByDir', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'sortby_nulls', + type: 'SortByNulls', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'useOp', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'SortGroupClause', + isNode: true, + fields: [ + { + name: 'eqop', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'hashable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'nulls_first', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'sortop', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'tleSortGroupRef', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'SQLValueFunction', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'op', + type: 'SQLValueFunctionOp', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'type', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'StatsElem', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'String', + isNode: true, + fields: [ + { + name: 'sval', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'SubLink', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'operName', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'subLinkId', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subLinkType', + type: 'SubLinkType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subselect', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'testexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'SubPlan', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'firstColCollation', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'firstColType', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'firstColTypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'parallel_safe', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'paramIds', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'parParam', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'per_call_cost', + type: 'double', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'plan_id', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'plan_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'setParam', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'startup_cost', + type: 'double', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'subLinkType', + type: 'SubLinkType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'testexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'unknownEqFalse', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'useHashTable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'SubscriptingRef', + isNode: true, + fields: [ + { + name: 'refassgnexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'refcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'refcontainertype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'refelemtype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'refexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'reflowerindexpr', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'refrestype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'reftypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'refupperindexpr', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'TableFunc', + isNode: true, + fields: [ + { + name: 'colcollations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coldefexprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colexprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colnames', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coltypes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'coltypmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'colvalexprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'docexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'functype', + type: 'TableFuncType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'notnulls', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + }, + { + name: 'ns_names', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ns_uris', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'ordinalitycol', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'passingvalexprs', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'plan', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'rowexpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'TableLikeClause', + isNode: true, + fields: [ + { + name: 'options', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relationOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'TableSampleClause', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'repeatable', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'tsmhandler', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'TargetEntry', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'resjunk', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resorigcol', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'resorigtbl', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'ressortgroupref', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'TransactionStmt', + isNode: true, + fields: [ + { + name: 'chain', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'gid', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'kind', + type: 'TransactionStmtKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'savepoint_name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'TriggerTransition', + isNode: true, + fields: [ + { + name: 'isNew', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'isTable', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'TruncateStmt', + isNode: true, + fields: [ + { + name: 'behavior', + type: 'DropBehavior', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relations', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'restart_seqs', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'TypeCast', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'TypeName', + isNode: true, + fields: [ + { + name: 'arrayBounds', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'names', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'pct_type', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'setof', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typemod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeOid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typmods', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'UnlistenStmt', + isNode: true, + fields: [ + { + name: 'conditionname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'UpdateStmt', + isNode: true, + fields: [ + { + name: 'fromClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'returningList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'targetList', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'whereClause', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'withClause', + type: 'WithClause', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'VacuumRelation', + isNode: true, + fields: [ + { + name: 'oid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'relation', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'va_cols', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'VacuumStmt', + isNode: true, + fields: [ + { + name: 'is_vacuumcmd', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'rels', + type: 'Node', + isNode: true, + isArray: true, + optional: true + } + ] + }, + { + name: 'Var', + isNode: true, + fields: [ + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'varattno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'varcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'varlevelsup', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'varno', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'varnullingrels', + type: 'uint64', + isNode: false, + isArray: true, + optional: true + }, + { + name: 'vartype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'vartypmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'VariableSetStmt', + isNode: true, + fields: [ + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'is_local', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'kind', + type: 'VariableSetKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'VariableShowStmt', + isNode: true, + fields: [ + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'ViewStmt', + isNode: true, + fields: [ + { + name: 'aliases', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'options', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'query', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'replace', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'view', + type: 'RangeVar', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'withCheckOption', + type: 'ViewCheckOption', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'WindowClause', + isNode: true, + fields: [ + { + name: 'copiedOrder', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'endInRangeFunc', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'endOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'frameOptions', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inRangeAsc', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inRangeColl', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'inRangeNullsFirst', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'orderClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'partitionClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'refname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'startInRangeFunc', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'startOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'winref', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'WindowDef', + isNode: true, + fields: [ + { + name: 'endOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'frameOptions', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'orderClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'partitionClause', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'refname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'startOffset', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'WindowFunc', + isNode: true, + fields: [ + { + name: 'aggfilter', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'runCondition', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'winagg', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'wincollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'winfnoid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'winref', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'winstar', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'wintype', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'WindowFuncRunCondition', + isNode: true, + fields: [ + { + name: 'arg', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'inputcollid', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'opno', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'wfunc_left', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'WithCheckOption', + isNode: true, + fields: [ + { + name: 'cascaded', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'kind', + type: 'WCOKind', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'polname', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'qual', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'relname', + type: 'string', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'WithClause', + isNode: true, + fields: [ + { + name: 'ctes', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'recursive', + type: 'bool', + isNode: false, + isArray: false, + optional: true + } + ] + }, + { + name: 'XmlExpr', + isNode: true, + fields: [ + { + name: 'arg_names', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'indent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'name', + type: 'string', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'named_args', + type: 'Node', + isNode: true, + isArray: true, + optional: true + }, + { + name: 'op', + type: 'XmlExprOp', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'type', + type: 'uint32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typmod', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xmloption', + type: 'XmlOptionType', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'xpr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + } + ] + }, + { + name: 'XmlSerialize', + isNode: true, + fields: [ + { + name: 'expr', + type: 'Node', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'indent', + type: 'bool', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'location', + type: 'int32', + isNode: false, + isArray: false, + optional: true + }, + { + name: 'typeName', + type: 'TypeName', + isNode: true, + isArray: false, + optional: true + }, + { + name: 'xmloption', + type: 'XmlOptionType', + isNode: false, + isArray: false, + optional: true + } + ] + } +]; \ No newline at end of file diff --git a/packages/utils/src/utils.ts b/packages/utils/src/utils.ts deleted file mode 100644 index a5dabd31..00000000 --- a/packages/utils/src/utils.ts +++ /dev/null @@ -1,3923 +0,0 @@ -/** -* This file was automatically generated by pg-proto-parser@1.12.2. -* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, -* and run the pg-proto-parser generate command to regenerate this file. -*/ -export type EnumType = "OverridingKind" | "QuerySource" | "SortByDir" | "SortByNulls" | "A_Expr_Kind" | "RoleSpecType" | "TableLikeOption" | "DefElemAction" | "PartitionRangeDatumKind" | "RTEKind" | "WCOKind" | "GroupingSetKind" | "CTEMaterialize" | "SetOperation" | "ObjectType" | "DropBehavior" | "AlterTableType" | "GrantTargetType" | "VariableSetKind" | "ConstrType" | "ImportForeignSchemaType" | "RoleStmtType" | "FetchDirection" | "FunctionParameterMode" | "TransactionStmtKind" | "ViewCheckOption" | "ClusterOption" | "DiscardMode" | "ReindexObjectType" | "AlterTSConfigType" | "AlterSubscriptionType" | "OnCommitAction" | "ParamKind" | "CoercionContext" | "CoercionForm" | "BoolExprType" | "SubLinkType" | "RowCompareType" | "MinMaxOp" | "SQLValueFunctionOp" | "XmlExprOp" | "XmlOptionType" | "NullTestType" | "BoolTestType" | "CmdType" | "JoinType" | "AggStrategy" | "AggSplit" | "SetOpCmd" | "SetOpStrategy" | "OnConflictAction" | "LimitOption" | "LockClauseStrength" | "LockWaitPolicy" | "LockTupleMode" | "KeywordKind" | "Token"; -export const getEnumValue = (enumType: EnumType, key: string | number) => { - switch (enumType) { - case "OverridingKind": - { - switch (key) { - case "OVERRIDING_NOT_SET": - return 0; - case "OVERRIDING_USER_VALUE": - return 1; - case "OVERRIDING_SYSTEM_VALUE": - return 2; - case 0: - return "OVERRIDING_NOT_SET"; - case 1: - return "OVERRIDING_USER_VALUE"; - case 2: - return "OVERRIDING_SYSTEM_VALUE"; - default: - throw new Error("Key not recognized in enum OverridingKind"); - } - } - case "QuerySource": - { - switch (key) { - case "QSRC_ORIGINAL": - return 0; - case "QSRC_PARSER": - return 1; - case "QSRC_INSTEAD_RULE": - return 2; - case "QSRC_QUAL_INSTEAD_RULE": - return 3; - case "QSRC_NON_INSTEAD_RULE": - return 4; - case 0: - return "QSRC_ORIGINAL"; - case 1: - return "QSRC_PARSER"; - case 2: - return "QSRC_INSTEAD_RULE"; - case 3: - return "QSRC_QUAL_INSTEAD_RULE"; - case 4: - return "QSRC_NON_INSTEAD_RULE"; - default: - throw new Error("Key not recognized in enum QuerySource"); - } - } - case "SortByDir": - { - switch (key) { - case "SORTBY_DEFAULT": - return 0; - case "SORTBY_ASC": - return 1; - case "SORTBY_DESC": - return 2; - case "SORTBY_USING": - return 3; - case 0: - return "SORTBY_DEFAULT"; - case 1: - return "SORTBY_ASC"; - case 2: - return "SORTBY_DESC"; - case 3: - return "SORTBY_USING"; - default: - throw new Error("Key not recognized in enum SortByDir"); - } - } - case "SortByNulls": - { - switch (key) { - case "SORTBY_NULLS_DEFAULT": - return 0; - case "SORTBY_NULLS_FIRST": - return 1; - case "SORTBY_NULLS_LAST": - return 2; - case 0: - return "SORTBY_NULLS_DEFAULT"; - case 1: - return "SORTBY_NULLS_FIRST"; - case 2: - return "SORTBY_NULLS_LAST"; - default: - throw new Error("Key not recognized in enum SortByNulls"); - } - } - case "A_Expr_Kind": - { - switch (key) { - case "AEXPR_OP": - return 0; - case "AEXPR_OP_ANY": - return 1; - case "AEXPR_OP_ALL": - return 2; - case "AEXPR_DISTINCT": - return 3; - case "AEXPR_NOT_DISTINCT": - return 4; - case "AEXPR_NULLIF": - return 5; - case "AEXPR_OF": - return 6; - case "AEXPR_IN": - return 7; - case "AEXPR_LIKE": - return 8; - case "AEXPR_ILIKE": - return 9; - case "AEXPR_SIMILAR": - return 10; - case "AEXPR_BETWEEN": - return 11; - case "AEXPR_NOT_BETWEEN": - return 12; - case "AEXPR_BETWEEN_SYM": - return 13; - case "AEXPR_NOT_BETWEEN_SYM": - return 14; - case "AEXPR_PAREN": - return 15; - case 0: - return "AEXPR_OP"; - case 1: - return "AEXPR_OP_ANY"; - case 2: - return "AEXPR_OP_ALL"; - case 3: - return "AEXPR_DISTINCT"; - case 4: - return "AEXPR_NOT_DISTINCT"; - case 5: - return "AEXPR_NULLIF"; - case 6: - return "AEXPR_OF"; - case 7: - return "AEXPR_IN"; - case 8: - return "AEXPR_LIKE"; - case 9: - return "AEXPR_ILIKE"; - case 10: - return "AEXPR_SIMILAR"; - case 11: - return "AEXPR_BETWEEN"; - case 12: - return "AEXPR_NOT_BETWEEN"; - case 13: - return "AEXPR_BETWEEN_SYM"; - case 14: - return "AEXPR_NOT_BETWEEN_SYM"; - case 15: - return "AEXPR_PAREN"; - default: - throw new Error("Key not recognized in enum A_Expr_Kind"); - } - } - case "RoleSpecType": - { - switch (key) { - case "ROLESPEC_CSTRING": - return 0; - case "ROLESPEC_CURRENT_USER": - return 1; - case "ROLESPEC_SESSION_USER": - return 2; - case "ROLESPEC_PUBLIC": - return 3; - case 0: - return "ROLESPEC_CSTRING"; - case 1: - return "ROLESPEC_CURRENT_USER"; - case 2: - return "ROLESPEC_SESSION_USER"; - case 3: - return "ROLESPEC_PUBLIC"; - default: - throw new Error("Key not recognized in enum RoleSpecType"); - } - } - case "TableLikeOption": - { - switch (key) { - case "CREATE_TABLE_LIKE_COMMENTS": - return 0; - case "CREATE_TABLE_LIKE_CONSTRAINTS": - return 1; - case "CREATE_TABLE_LIKE_DEFAULTS": - return 2; - case "CREATE_TABLE_LIKE_GENERATED": - return 3; - case "CREATE_TABLE_LIKE_IDENTITY": - return 4; - case "CREATE_TABLE_LIKE_INDEXES": - return 5; - case "CREATE_TABLE_LIKE_STATISTICS": - return 6; - case "CREATE_TABLE_LIKE_STORAGE": - return 7; - case "CREATE_TABLE_LIKE_ALL": - return 8; - case 0: - return "CREATE_TABLE_LIKE_COMMENTS"; - case 1: - return "CREATE_TABLE_LIKE_CONSTRAINTS"; - case 2: - return "CREATE_TABLE_LIKE_DEFAULTS"; - case 3: - return "CREATE_TABLE_LIKE_GENERATED"; - case 4: - return "CREATE_TABLE_LIKE_IDENTITY"; - case 5: - return "CREATE_TABLE_LIKE_INDEXES"; - case 6: - return "CREATE_TABLE_LIKE_STATISTICS"; - case 7: - return "CREATE_TABLE_LIKE_STORAGE"; - case 8: - return "CREATE_TABLE_LIKE_ALL"; - default: - throw new Error("Key not recognized in enum TableLikeOption"); - } - } - case "DefElemAction": - { - switch (key) { - case "DEFELEM_UNSPEC": - return 0; - case "DEFELEM_SET": - return 1; - case "DEFELEM_ADD": - return 2; - case "DEFELEM_DROP": - return 3; - case 0: - return "DEFELEM_UNSPEC"; - case 1: - return "DEFELEM_SET"; - case 2: - return "DEFELEM_ADD"; - case 3: - return "DEFELEM_DROP"; - default: - throw new Error("Key not recognized in enum DefElemAction"); - } - } - case "PartitionRangeDatumKind": - { - switch (key) { - case "PARTITION_RANGE_DATUM_MINVALUE": - return 0; - case "PARTITION_RANGE_DATUM_VALUE": - return 1; - case "PARTITION_RANGE_DATUM_MAXVALUE": - return 2; - case 0: - return "PARTITION_RANGE_DATUM_MINVALUE"; - case 1: - return "PARTITION_RANGE_DATUM_VALUE"; - case 2: - return "PARTITION_RANGE_DATUM_MAXVALUE"; - default: - throw new Error("Key not recognized in enum PartitionRangeDatumKind"); - } - } - case "RTEKind": - { - switch (key) { - case "RTE_RELATION": - return 0; - case "RTE_SUBQUERY": - return 1; - case "RTE_JOIN": - return 2; - case "RTE_FUNCTION": - return 3; - case "RTE_TABLEFUNC": - return 4; - case "RTE_VALUES": - return 5; - case "RTE_CTE": - return 6; - case "RTE_NAMEDTUPLESTORE": - return 7; - case "RTE_RESULT": - return 8; - case 0: - return "RTE_RELATION"; - case 1: - return "RTE_SUBQUERY"; - case 2: - return "RTE_JOIN"; - case 3: - return "RTE_FUNCTION"; - case 4: - return "RTE_TABLEFUNC"; - case 5: - return "RTE_VALUES"; - case 6: - return "RTE_CTE"; - case 7: - return "RTE_NAMEDTUPLESTORE"; - case 8: - return "RTE_RESULT"; - default: - throw new Error("Key not recognized in enum RTEKind"); - } - } - case "WCOKind": - { - switch (key) { - case "WCO_VIEW_CHECK": - return 0; - case "WCO_RLS_INSERT_CHECK": - return 1; - case "WCO_RLS_UPDATE_CHECK": - return 2; - case "WCO_RLS_CONFLICT_CHECK": - return 3; - case 0: - return "WCO_VIEW_CHECK"; - case 1: - return "WCO_RLS_INSERT_CHECK"; - case 2: - return "WCO_RLS_UPDATE_CHECK"; - case 3: - return "WCO_RLS_CONFLICT_CHECK"; - default: - throw new Error("Key not recognized in enum WCOKind"); - } - } - case "GroupingSetKind": - { - switch (key) { - case "GROUPING_SET_EMPTY": - return 0; - case "GROUPING_SET_SIMPLE": - return 1; - case "GROUPING_SET_ROLLUP": - return 2; - case "GROUPING_SET_CUBE": - return 3; - case "GROUPING_SET_SETS": - return 4; - case 0: - return "GROUPING_SET_EMPTY"; - case 1: - return "GROUPING_SET_SIMPLE"; - case 2: - return "GROUPING_SET_ROLLUP"; - case 3: - return "GROUPING_SET_CUBE"; - case 4: - return "GROUPING_SET_SETS"; - default: - throw new Error("Key not recognized in enum GroupingSetKind"); - } - } - case "CTEMaterialize": - { - switch (key) { - case "CTEMaterializeDefault": - return 0; - case "CTEMaterializeAlways": - return 1; - case "CTEMaterializeNever": - return 2; - case 0: - return "CTEMaterializeDefault"; - case 1: - return "CTEMaterializeAlways"; - case 2: - return "CTEMaterializeNever"; - default: - throw new Error("Key not recognized in enum CTEMaterialize"); - } - } - case "SetOperation": - { - switch (key) { - case "SETOP_NONE": - return 0; - case "SETOP_UNION": - return 1; - case "SETOP_INTERSECT": - return 2; - case "SETOP_EXCEPT": - return 3; - case 0: - return "SETOP_NONE"; - case 1: - return "SETOP_UNION"; - case 2: - return "SETOP_INTERSECT"; - case 3: - return "SETOP_EXCEPT"; - default: - throw new Error("Key not recognized in enum SetOperation"); - } - } - case "ObjectType": - { - switch (key) { - case "OBJECT_ACCESS_METHOD": - return 0; - case "OBJECT_AGGREGATE": - return 1; - case "OBJECT_AMOP": - return 2; - case "OBJECT_AMPROC": - return 3; - case "OBJECT_ATTRIBUTE": - return 4; - case "OBJECT_CAST": - return 5; - case "OBJECT_COLUMN": - return 6; - case "OBJECT_COLLATION": - return 7; - case "OBJECT_CONVERSION": - return 8; - case "OBJECT_DATABASE": - return 9; - case "OBJECT_DEFAULT": - return 10; - case "OBJECT_DEFACL": - return 11; - case "OBJECT_DOMAIN": - return 12; - case "OBJECT_DOMCONSTRAINT": - return 13; - case "OBJECT_EVENT_TRIGGER": - return 14; - case "OBJECT_EXTENSION": - return 15; - case "OBJECT_FDW": - return 16; - case "OBJECT_FOREIGN_SERVER": - return 17; - case "OBJECT_FOREIGN_TABLE": - return 18; - case "OBJECT_FUNCTION": - return 19; - case "OBJECT_INDEX": - return 20; - case "OBJECT_LANGUAGE": - return 21; - case "OBJECT_LARGEOBJECT": - return 22; - case "OBJECT_MATVIEW": - return 23; - case "OBJECT_OPCLASS": - return 24; - case "OBJECT_OPERATOR": - return 25; - case "OBJECT_OPFAMILY": - return 26; - case "OBJECT_POLICY": - return 27; - case "OBJECT_PROCEDURE": - return 28; - case "OBJECT_PUBLICATION": - return 29; - case "OBJECT_PUBLICATION_REL": - return 30; - case "OBJECT_ROLE": - return 31; - case "OBJECT_ROUTINE": - return 32; - case "OBJECT_RULE": - return 33; - case "OBJECT_SCHEMA": - return 34; - case "OBJECT_SEQUENCE": - return 35; - case "OBJECT_SUBSCRIPTION": - return 36; - case "OBJECT_STATISTIC_EXT": - return 37; - case "OBJECT_TABCONSTRAINT": - return 38; - case "OBJECT_TABLE": - return 39; - case "OBJECT_TABLESPACE": - return 40; - case "OBJECT_TRANSFORM": - return 41; - case "OBJECT_TRIGGER": - return 42; - case "OBJECT_TSCONFIGURATION": - return 43; - case "OBJECT_TSDICTIONARY": - return 44; - case "OBJECT_TSPARSER": - return 45; - case "OBJECT_TSTEMPLATE": - return 46; - case "OBJECT_TYPE": - return 47; - case "OBJECT_USER_MAPPING": - return 48; - case "OBJECT_VIEW": - return 49; - case 0: - return "OBJECT_ACCESS_METHOD"; - case 1: - return "OBJECT_AGGREGATE"; - case 2: - return "OBJECT_AMOP"; - case 3: - return "OBJECT_AMPROC"; - case 4: - return "OBJECT_ATTRIBUTE"; - case 5: - return "OBJECT_CAST"; - case 6: - return "OBJECT_COLUMN"; - case 7: - return "OBJECT_COLLATION"; - case 8: - return "OBJECT_CONVERSION"; - case 9: - return "OBJECT_DATABASE"; - case 10: - return "OBJECT_DEFAULT"; - case 11: - return "OBJECT_DEFACL"; - case 12: - return "OBJECT_DOMAIN"; - case 13: - return "OBJECT_DOMCONSTRAINT"; - case 14: - return "OBJECT_EVENT_TRIGGER"; - case 15: - return "OBJECT_EXTENSION"; - case 16: - return "OBJECT_FDW"; - case 17: - return "OBJECT_FOREIGN_SERVER"; - case 18: - return "OBJECT_FOREIGN_TABLE"; - case 19: - return "OBJECT_FUNCTION"; - case 20: - return "OBJECT_INDEX"; - case 21: - return "OBJECT_LANGUAGE"; - case 22: - return "OBJECT_LARGEOBJECT"; - case 23: - return "OBJECT_MATVIEW"; - case 24: - return "OBJECT_OPCLASS"; - case 25: - return "OBJECT_OPERATOR"; - case 26: - return "OBJECT_OPFAMILY"; - case 27: - return "OBJECT_POLICY"; - case 28: - return "OBJECT_PROCEDURE"; - case 29: - return "OBJECT_PUBLICATION"; - case 30: - return "OBJECT_PUBLICATION_REL"; - case 31: - return "OBJECT_ROLE"; - case 32: - return "OBJECT_ROUTINE"; - case 33: - return "OBJECT_RULE"; - case 34: - return "OBJECT_SCHEMA"; - case 35: - return "OBJECT_SEQUENCE"; - case 36: - return "OBJECT_SUBSCRIPTION"; - case 37: - return "OBJECT_STATISTIC_EXT"; - case 38: - return "OBJECT_TABCONSTRAINT"; - case 39: - return "OBJECT_TABLE"; - case 40: - return "OBJECT_TABLESPACE"; - case 41: - return "OBJECT_TRANSFORM"; - case 42: - return "OBJECT_TRIGGER"; - case 43: - return "OBJECT_TSCONFIGURATION"; - case 44: - return "OBJECT_TSDICTIONARY"; - case 45: - return "OBJECT_TSPARSER"; - case 46: - return "OBJECT_TSTEMPLATE"; - case 47: - return "OBJECT_TYPE"; - case 48: - return "OBJECT_USER_MAPPING"; - case 49: - return "OBJECT_VIEW"; - default: - throw new Error("Key not recognized in enum ObjectType"); - } - } - case "DropBehavior": - { - switch (key) { - case "DROP_RESTRICT": - return 0; - case "DROP_CASCADE": - return 1; - case 0: - return "DROP_RESTRICT"; - case 1: - return "DROP_CASCADE"; - default: - throw new Error("Key not recognized in enum DropBehavior"); - } - } - case "AlterTableType": - { - switch (key) { - case "AT_AddColumn": - return 0; - case "AT_AddColumnRecurse": - return 1; - case "AT_AddColumnToView": - return 2; - case "AT_ColumnDefault": - return 3; - case "AT_CookedColumnDefault": - return 4; - case "AT_DropNotNull": - return 5; - case "AT_SetNotNull": - return 6; - case "AT_DropExpression": - return 7; - case "AT_CheckNotNull": - return 8; - case "AT_SetStatistics": - return 9; - case "AT_SetOptions": - return 10; - case "AT_ResetOptions": - return 11; - case "AT_SetStorage": - return 12; - case "AT_DropColumn": - return 13; - case "AT_DropColumnRecurse": - return 14; - case "AT_AddIndex": - return 15; - case "AT_ReAddIndex": - return 16; - case "AT_AddConstraint": - return 17; - case "AT_AddConstraintRecurse": - return 18; - case "AT_ReAddConstraint": - return 19; - case "AT_ReAddDomainConstraint": - return 20; - case "AT_AlterConstraint": - return 21; - case "AT_ValidateConstraint": - return 22; - case "AT_ValidateConstraintRecurse": - return 23; - case "AT_AddIndexConstraint": - return 24; - case "AT_DropConstraint": - return 25; - case "AT_DropConstraintRecurse": - return 26; - case "AT_ReAddComment": - return 27; - case "AT_AlterColumnType": - return 28; - case "AT_AlterColumnGenericOptions": - return 29; - case "AT_ChangeOwner": - return 30; - case "AT_ClusterOn": - return 31; - case "AT_DropCluster": - return 32; - case "AT_SetLogged": - return 33; - case "AT_SetUnLogged": - return 34; - case "AT_DropOids": - return 35; - case "AT_SetTableSpace": - return 36; - case "AT_SetRelOptions": - return 37; - case "AT_ResetRelOptions": - return 38; - case "AT_ReplaceRelOptions": - return 39; - case "AT_EnableTrig": - return 40; - case "AT_EnableAlwaysTrig": - return 41; - case "AT_EnableReplicaTrig": - return 42; - case "AT_DisableTrig": - return 43; - case "AT_EnableTrigAll": - return 44; - case "AT_DisableTrigAll": - return 45; - case "AT_EnableTrigUser": - return 46; - case "AT_DisableTrigUser": - return 47; - case "AT_EnableRule": - return 48; - case "AT_EnableAlwaysRule": - return 49; - case "AT_EnableReplicaRule": - return 50; - case "AT_DisableRule": - return 51; - case "AT_AddInherit": - return 52; - case "AT_DropInherit": - return 53; - case "AT_AddOf": - return 54; - case "AT_DropOf": - return 55; - case "AT_ReplicaIdentity": - return 56; - case "AT_EnableRowSecurity": - return 57; - case "AT_DisableRowSecurity": - return 58; - case "AT_ForceRowSecurity": - return 59; - case "AT_NoForceRowSecurity": - return 60; - case "AT_GenericOptions": - return 61; - case "AT_AttachPartition": - return 62; - case "AT_DetachPartition": - return 63; - case "AT_AddIdentity": - return 64; - case "AT_SetIdentity": - return 65; - case "AT_DropIdentity": - return 66; - case 0: - return "AT_AddColumn"; - case 1: - return "AT_AddColumnRecurse"; - case 2: - return "AT_AddColumnToView"; - case 3: - return "AT_ColumnDefault"; - case 4: - return "AT_CookedColumnDefault"; - case 5: - return "AT_DropNotNull"; - case 6: - return "AT_SetNotNull"; - case 7: - return "AT_DropExpression"; - case 8: - return "AT_CheckNotNull"; - case 9: - return "AT_SetStatistics"; - case 10: - return "AT_SetOptions"; - case 11: - return "AT_ResetOptions"; - case 12: - return "AT_SetStorage"; - case 13: - return "AT_DropColumn"; - case 14: - return "AT_DropColumnRecurse"; - case 15: - return "AT_AddIndex"; - case 16: - return "AT_ReAddIndex"; - case 17: - return "AT_AddConstraint"; - case 18: - return "AT_AddConstraintRecurse"; - case 19: - return "AT_ReAddConstraint"; - case 20: - return "AT_ReAddDomainConstraint"; - case 21: - return "AT_AlterConstraint"; - case 22: - return "AT_ValidateConstraint"; - case 23: - return "AT_ValidateConstraintRecurse"; - case 24: - return "AT_AddIndexConstraint"; - case 25: - return "AT_DropConstraint"; - case 26: - return "AT_DropConstraintRecurse"; - case 27: - return "AT_ReAddComment"; - case 28: - return "AT_AlterColumnType"; - case 29: - return "AT_AlterColumnGenericOptions"; - case 30: - return "AT_ChangeOwner"; - case 31: - return "AT_ClusterOn"; - case 32: - return "AT_DropCluster"; - case 33: - return "AT_SetLogged"; - case 34: - return "AT_SetUnLogged"; - case 35: - return "AT_DropOids"; - case 36: - return "AT_SetTableSpace"; - case 37: - return "AT_SetRelOptions"; - case 38: - return "AT_ResetRelOptions"; - case 39: - return "AT_ReplaceRelOptions"; - case 40: - return "AT_EnableTrig"; - case 41: - return "AT_EnableAlwaysTrig"; - case 42: - return "AT_EnableReplicaTrig"; - case 43: - return "AT_DisableTrig"; - case 44: - return "AT_EnableTrigAll"; - case 45: - return "AT_DisableTrigAll"; - case 46: - return "AT_EnableTrigUser"; - case 47: - return "AT_DisableTrigUser"; - case 48: - return "AT_EnableRule"; - case 49: - return "AT_EnableAlwaysRule"; - case 50: - return "AT_EnableReplicaRule"; - case 51: - return "AT_DisableRule"; - case 52: - return "AT_AddInherit"; - case 53: - return "AT_DropInherit"; - case 54: - return "AT_AddOf"; - case 55: - return "AT_DropOf"; - case 56: - return "AT_ReplicaIdentity"; - case 57: - return "AT_EnableRowSecurity"; - case 58: - return "AT_DisableRowSecurity"; - case 59: - return "AT_ForceRowSecurity"; - case 60: - return "AT_NoForceRowSecurity"; - case 61: - return "AT_GenericOptions"; - case 62: - return "AT_AttachPartition"; - case 63: - return "AT_DetachPartition"; - case 64: - return "AT_AddIdentity"; - case 65: - return "AT_SetIdentity"; - case 66: - return "AT_DropIdentity"; - default: - throw new Error("Key not recognized in enum AlterTableType"); - } - } - case "GrantTargetType": - { - switch (key) { - case "ACL_TARGET_OBJECT": - return 0; - case "ACL_TARGET_ALL_IN_SCHEMA": - return 1; - case "ACL_TARGET_DEFAULTS": - return 2; - case 0: - return "ACL_TARGET_OBJECT"; - case 1: - return "ACL_TARGET_ALL_IN_SCHEMA"; - case 2: - return "ACL_TARGET_DEFAULTS"; - default: - throw new Error("Key not recognized in enum GrantTargetType"); - } - } - case "VariableSetKind": - { - switch (key) { - case "VAR_SET_VALUE": - return 0; - case "VAR_SET_DEFAULT": - return 1; - case "VAR_SET_CURRENT": - return 2; - case "VAR_SET_MULTI": - return 3; - case "VAR_RESET": - return 4; - case "VAR_RESET_ALL": - return 5; - case 0: - return "VAR_SET_VALUE"; - case 1: - return "VAR_SET_DEFAULT"; - case 2: - return "VAR_SET_CURRENT"; - case 3: - return "VAR_SET_MULTI"; - case 4: - return "VAR_RESET"; - case 5: - return "VAR_RESET_ALL"; - default: - throw new Error("Key not recognized in enum VariableSetKind"); - } - } - case "ConstrType": - { - switch (key) { - case "CONSTR_NULL": - return 0; - case "CONSTR_NOTNULL": - return 1; - case "CONSTR_DEFAULT": - return 2; - case "CONSTR_IDENTITY": - return 3; - case "CONSTR_GENERATED": - return 4; - case "CONSTR_CHECK": - return 5; - case "CONSTR_PRIMARY": - return 6; - case "CONSTR_UNIQUE": - return 7; - case "CONSTR_EXCLUSION": - return 8; - case "CONSTR_FOREIGN": - return 9; - case "CONSTR_ATTR_DEFERRABLE": - return 10; - case "CONSTR_ATTR_NOT_DEFERRABLE": - return 11; - case "CONSTR_ATTR_DEFERRED": - return 12; - case "CONSTR_ATTR_IMMEDIATE": - return 13; - case 0: - return "CONSTR_NULL"; - case 1: - return "CONSTR_NOTNULL"; - case 2: - return "CONSTR_DEFAULT"; - case 3: - return "CONSTR_IDENTITY"; - case 4: - return "CONSTR_GENERATED"; - case 5: - return "CONSTR_CHECK"; - case 6: - return "CONSTR_PRIMARY"; - case 7: - return "CONSTR_UNIQUE"; - case 8: - return "CONSTR_EXCLUSION"; - case 9: - return "CONSTR_FOREIGN"; - case 10: - return "CONSTR_ATTR_DEFERRABLE"; - case 11: - return "CONSTR_ATTR_NOT_DEFERRABLE"; - case 12: - return "CONSTR_ATTR_DEFERRED"; - case 13: - return "CONSTR_ATTR_IMMEDIATE"; - default: - throw new Error("Key not recognized in enum ConstrType"); - } - } - case "ImportForeignSchemaType": - { - switch (key) { - case "FDW_IMPORT_SCHEMA_ALL": - return 0; - case "FDW_IMPORT_SCHEMA_LIMIT_TO": - return 1; - case "FDW_IMPORT_SCHEMA_EXCEPT": - return 2; - case 0: - return "FDW_IMPORT_SCHEMA_ALL"; - case 1: - return "FDW_IMPORT_SCHEMA_LIMIT_TO"; - case 2: - return "FDW_IMPORT_SCHEMA_EXCEPT"; - default: - throw new Error("Key not recognized in enum ImportForeignSchemaType"); - } - } - case "RoleStmtType": - { - switch (key) { - case "ROLESTMT_ROLE": - return 0; - case "ROLESTMT_USER": - return 1; - case "ROLESTMT_GROUP": - return 2; - case 0: - return "ROLESTMT_ROLE"; - case 1: - return "ROLESTMT_USER"; - case 2: - return "ROLESTMT_GROUP"; - default: - throw new Error("Key not recognized in enum RoleStmtType"); - } - } - case "FetchDirection": - { - switch (key) { - case "FETCH_FORWARD": - return 0; - case "FETCH_BACKWARD": - return 1; - case "FETCH_ABSOLUTE": - return 2; - case "FETCH_RELATIVE": - return 3; - case 0: - return "FETCH_FORWARD"; - case 1: - return "FETCH_BACKWARD"; - case 2: - return "FETCH_ABSOLUTE"; - case 3: - return "FETCH_RELATIVE"; - default: - throw new Error("Key not recognized in enum FetchDirection"); - } - } - case "FunctionParameterMode": - { - switch (key) { - case "FUNC_PARAM_IN": - return 0; - case "FUNC_PARAM_OUT": - return 1; - case "FUNC_PARAM_INOUT": - return 2; - case "FUNC_PARAM_VARIADIC": - return 3; - case "FUNC_PARAM_TABLE": - return 4; - case 0: - return "FUNC_PARAM_IN"; - case 1: - return "FUNC_PARAM_OUT"; - case 2: - return "FUNC_PARAM_INOUT"; - case 3: - return "FUNC_PARAM_VARIADIC"; - case 4: - return "FUNC_PARAM_TABLE"; - default: - throw new Error("Key not recognized in enum FunctionParameterMode"); - } - } - case "TransactionStmtKind": - { - switch (key) { - case "TRANS_STMT_BEGIN": - return 0; - case "TRANS_STMT_START": - return 1; - case "TRANS_STMT_COMMIT": - return 2; - case "TRANS_STMT_ROLLBACK": - return 3; - case "TRANS_STMT_SAVEPOINT": - return 4; - case "TRANS_STMT_RELEASE": - return 5; - case "TRANS_STMT_ROLLBACK_TO": - return 6; - case "TRANS_STMT_PREPARE": - return 7; - case "TRANS_STMT_COMMIT_PREPARED": - return 8; - case "TRANS_STMT_ROLLBACK_PREPARED": - return 9; - case 0: - return "TRANS_STMT_BEGIN"; - case 1: - return "TRANS_STMT_START"; - case 2: - return "TRANS_STMT_COMMIT"; - case 3: - return "TRANS_STMT_ROLLBACK"; - case 4: - return "TRANS_STMT_SAVEPOINT"; - case 5: - return "TRANS_STMT_RELEASE"; - case 6: - return "TRANS_STMT_ROLLBACK_TO"; - case 7: - return "TRANS_STMT_PREPARE"; - case 8: - return "TRANS_STMT_COMMIT_PREPARED"; - case 9: - return "TRANS_STMT_ROLLBACK_PREPARED"; - default: - throw new Error("Key not recognized in enum TransactionStmtKind"); - } - } - case "ViewCheckOption": - { - switch (key) { - case "NO_CHECK_OPTION": - return 0; - case "LOCAL_CHECK_OPTION": - return 1; - case "CASCADED_CHECK_OPTION": - return 2; - case 0: - return "NO_CHECK_OPTION"; - case 1: - return "LOCAL_CHECK_OPTION"; - case 2: - return "CASCADED_CHECK_OPTION"; - default: - throw new Error("Key not recognized in enum ViewCheckOption"); - } - } - case "ClusterOption": - { - switch (key) { - case "CLUOPT_RECHECK": - return 0; - case "CLUOPT_VERBOSE": - return 1; - case 0: - return "CLUOPT_RECHECK"; - case 1: - return "CLUOPT_VERBOSE"; - default: - throw new Error("Key not recognized in enum ClusterOption"); - } - } - case "DiscardMode": - { - switch (key) { - case "DISCARD_ALL": - return 0; - case "DISCARD_PLANS": - return 1; - case "DISCARD_SEQUENCES": - return 2; - case "DISCARD_TEMP": - return 3; - case 0: - return "DISCARD_ALL"; - case 1: - return "DISCARD_PLANS"; - case 2: - return "DISCARD_SEQUENCES"; - case 3: - return "DISCARD_TEMP"; - default: - throw new Error("Key not recognized in enum DiscardMode"); - } - } - case "ReindexObjectType": - { - switch (key) { - case "REINDEX_OBJECT_INDEX": - return 0; - case "REINDEX_OBJECT_TABLE": - return 1; - case "REINDEX_OBJECT_SCHEMA": - return 2; - case "REINDEX_OBJECT_SYSTEM": - return 3; - case "REINDEX_OBJECT_DATABASE": - return 4; - case 0: - return "REINDEX_OBJECT_INDEX"; - case 1: - return "REINDEX_OBJECT_TABLE"; - case 2: - return "REINDEX_OBJECT_SCHEMA"; - case 3: - return "REINDEX_OBJECT_SYSTEM"; - case 4: - return "REINDEX_OBJECT_DATABASE"; - default: - throw new Error("Key not recognized in enum ReindexObjectType"); - } - } - case "AlterTSConfigType": - { - switch (key) { - case "ALTER_TSCONFIG_ADD_MAPPING": - return 0; - case "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN": - return 1; - case "ALTER_TSCONFIG_REPLACE_DICT": - return 2; - case "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN": - return 3; - case "ALTER_TSCONFIG_DROP_MAPPING": - return 4; - case 0: - return "ALTER_TSCONFIG_ADD_MAPPING"; - case 1: - return "ALTER_TSCONFIG_ALTER_MAPPING_FOR_TOKEN"; - case 2: - return "ALTER_TSCONFIG_REPLACE_DICT"; - case 3: - return "ALTER_TSCONFIG_REPLACE_DICT_FOR_TOKEN"; - case 4: - return "ALTER_TSCONFIG_DROP_MAPPING"; - default: - throw new Error("Key not recognized in enum AlterTSConfigType"); - } - } - case "AlterSubscriptionType": - { - switch (key) { - case "ALTER_SUBSCRIPTION_OPTIONS": - return 0; - case "ALTER_SUBSCRIPTION_CONNECTION": - return 1; - case "ALTER_SUBSCRIPTION_PUBLICATION": - return 2; - case "ALTER_SUBSCRIPTION_REFRESH": - return 3; - case "ALTER_SUBSCRIPTION_ENABLED": - return 4; - case 0: - return "ALTER_SUBSCRIPTION_OPTIONS"; - case 1: - return "ALTER_SUBSCRIPTION_CONNECTION"; - case 2: - return "ALTER_SUBSCRIPTION_PUBLICATION"; - case 3: - return "ALTER_SUBSCRIPTION_REFRESH"; - case 4: - return "ALTER_SUBSCRIPTION_ENABLED"; - default: - throw new Error("Key not recognized in enum AlterSubscriptionType"); - } - } - case "OnCommitAction": - { - switch (key) { - case "ONCOMMIT_NOOP": - return 0; - case "ONCOMMIT_PRESERVE_ROWS": - return 1; - case "ONCOMMIT_DELETE_ROWS": - return 2; - case "ONCOMMIT_DROP": - return 3; - case 0: - return "ONCOMMIT_NOOP"; - case 1: - return "ONCOMMIT_PRESERVE_ROWS"; - case 2: - return "ONCOMMIT_DELETE_ROWS"; - case 3: - return "ONCOMMIT_DROP"; - default: - throw new Error("Key not recognized in enum OnCommitAction"); - } - } - case "ParamKind": - { - switch (key) { - case "PARAM_EXTERN": - return 0; - case "PARAM_EXEC": - return 1; - case "PARAM_SUBLINK": - return 2; - case "PARAM_MULTIEXPR": - return 3; - case 0: - return "PARAM_EXTERN"; - case 1: - return "PARAM_EXEC"; - case 2: - return "PARAM_SUBLINK"; - case 3: - return "PARAM_MULTIEXPR"; - default: - throw new Error("Key not recognized in enum ParamKind"); - } - } - case "CoercionContext": - { - switch (key) { - case "COERCION_IMPLICIT": - return 0; - case "COERCION_ASSIGNMENT": - return 1; - case "COERCION_EXPLICIT": - return 2; - case 0: - return "COERCION_IMPLICIT"; - case 1: - return "COERCION_ASSIGNMENT"; - case 2: - return "COERCION_EXPLICIT"; - default: - throw new Error("Key not recognized in enum CoercionContext"); - } - } - case "CoercionForm": - { - switch (key) { - case "COERCE_EXPLICIT_CALL": - return 0; - case "COERCE_EXPLICIT_CAST": - return 1; - case "COERCE_IMPLICIT_CAST": - return 2; - case 0: - return "COERCE_EXPLICIT_CALL"; - case 1: - return "COERCE_EXPLICIT_CAST"; - case 2: - return "COERCE_IMPLICIT_CAST"; - default: - throw new Error("Key not recognized in enum CoercionForm"); - } - } - case "BoolExprType": - { - switch (key) { - case "AND_EXPR": - return 0; - case "OR_EXPR": - return 1; - case "NOT_EXPR": - return 2; - case 0: - return "AND_EXPR"; - case 1: - return "OR_EXPR"; - case 2: - return "NOT_EXPR"; - default: - throw new Error("Key not recognized in enum BoolExprType"); - } - } - case "SubLinkType": - { - switch (key) { - case "EXISTS_SUBLINK": - return 0; - case "ALL_SUBLINK": - return 1; - case "ANY_SUBLINK": - return 2; - case "ROWCOMPARE_SUBLINK": - return 3; - case "EXPR_SUBLINK": - return 4; - case "MULTIEXPR_SUBLINK": - return 5; - case "ARRAY_SUBLINK": - return 6; - case "CTE_SUBLINK": - return 7; - case 0: - return "EXISTS_SUBLINK"; - case 1: - return "ALL_SUBLINK"; - case 2: - return "ANY_SUBLINK"; - case 3: - return "ROWCOMPARE_SUBLINK"; - case 4: - return "EXPR_SUBLINK"; - case 5: - return "MULTIEXPR_SUBLINK"; - case 6: - return "ARRAY_SUBLINK"; - case 7: - return "CTE_SUBLINK"; - default: - throw new Error("Key not recognized in enum SubLinkType"); - } - } - case "RowCompareType": - { - switch (key) { - case "ROWCOMPARE_LT": - return 0; - case "ROWCOMPARE_LE": - return 1; - case "ROWCOMPARE_EQ": - return 2; - case "ROWCOMPARE_GE": - return 3; - case "ROWCOMPARE_GT": - return 4; - case "ROWCOMPARE_NE": - return 5; - case 0: - return "ROWCOMPARE_LT"; - case 1: - return "ROWCOMPARE_LE"; - case 2: - return "ROWCOMPARE_EQ"; - case 3: - return "ROWCOMPARE_GE"; - case 4: - return "ROWCOMPARE_GT"; - case 5: - return "ROWCOMPARE_NE"; - default: - throw new Error("Key not recognized in enum RowCompareType"); - } - } - case "MinMaxOp": - { - switch (key) { - case "IS_GREATEST": - return 0; - case "IS_LEAST": - return 1; - case 0: - return "IS_GREATEST"; - case 1: - return "IS_LEAST"; - default: - throw new Error("Key not recognized in enum MinMaxOp"); - } - } - case "SQLValueFunctionOp": - { - switch (key) { - case "SVFOP_CURRENT_DATE": - return 0; - case "SVFOP_CURRENT_TIME": - return 1; - case "SVFOP_CURRENT_TIME_N": - return 2; - case "SVFOP_CURRENT_TIMESTAMP": - return 3; - case "SVFOP_CURRENT_TIMESTAMP_N": - return 4; - case "SVFOP_LOCALTIME": - return 5; - case "SVFOP_LOCALTIME_N": - return 6; - case "SVFOP_LOCALTIMESTAMP": - return 7; - case "SVFOP_LOCALTIMESTAMP_N": - return 8; - case "SVFOP_CURRENT_ROLE": - return 9; - case "SVFOP_CURRENT_USER": - return 10; - case "SVFOP_USER": - return 11; - case "SVFOP_SESSION_USER": - return 12; - case "SVFOP_CURRENT_CATALOG": - return 13; - case "SVFOP_CURRENT_SCHEMA": - return 14; - case 0: - return "SVFOP_CURRENT_DATE"; - case 1: - return "SVFOP_CURRENT_TIME"; - case 2: - return "SVFOP_CURRENT_TIME_N"; - case 3: - return "SVFOP_CURRENT_TIMESTAMP"; - case 4: - return "SVFOP_CURRENT_TIMESTAMP_N"; - case 5: - return "SVFOP_LOCALTIME"; - case 6: - return "SVFOP_LOCALTIME_N"; - case 7: - return "SVFOP_LOCALTIMESTAMP"; - case 8: - return "SVFOP_LOCALTIMESTAMP_N"; - case 9: - return "SVFOP_CURRENT_ROLE"; - case 10: - return "SVFOP_CURRENT_USER"; - case 11: - return "SVFOP_USER"; - case 12: - return "SVFOP_SESSION_USER"; - case 13: - return "SVFOP_CURRENT_CATALOG"; - case 14: - return "SVFOP_CURRENT_SCHEMA"; - default: - throw new Error("Key not recognized in enum SQLValueFunctionOp"); - } - } - case "XmlExprOp": - { - switch (key) { - case "IS_XMLCONCAT": - return 0; - case "IS_XMLELEMENT": - return 1; - case "IS_XMLFOREST": - return 2; - case "IS_XMLPARSE": - return 3; - case "IS_XMLPI": - return 4; - case "IS_XMLROOT": - return 5; - case "IS_XMLSERIALIZE": - return 6; - case "IS_DOCUMENT": - return 7; - case 0: - return "IS_XMLCONCAT"; - case 1: - return "IS_XMLELEMENT"; - case 2: - return "IS_XMLFOREST"; - case 3: - return "IS_XMLPARSE"; - case 4: - return "IS_XMLPI"; - case 5: - return "IS_XMLROOT"; - case 6: - return "IS_XMLSERIALIZE"; - case 7: - return "IS_DOCUMENT"; - default: - throw new Error("Key not recognized in enum XmlExprOp"); - } - } - case "XmlOptionType": - { - switch (key) { - case "XMLOPTION_DOCUMENT": - return 0; - case "XMLOPTION_CONTENT": - return 1; - case 0: - return "XMLOPTION_DOCUMENT"; - case 1: - return "XMLOPTION_CONTENT"; - default: - throw new Error("Key not recognized in enum XmlOptionType"); - } - } - case "NullTestType": - { - switch (key) { - case "IS_NULL": - return 0; - case "IS_NOT_NULL": - return 1; - case 0: - return "IS_NULL"; - case 1: - return "IS_NOT_NULL"; - default: - throw new Error("Key not recognized in enum NullTestType"); - } - } - case "BoolTestType": - { - switch (key) { - case "IS_TRUE": - return 0; - case "IS_NOT_TRUE": - return 1; - case "IS_FALSE": - return 2; - case "IS_NOT_FALSE": - return 3; - case "IS_UNKNOWN": - return 4; - case "IS_NOT_UNKNOWN": - return 5; - case 0: - return "IS_TRUE"; - case 1: - return "IS_NOT_TRUE"; - case 2: - return "IS_FALSE"; - case 3: - return "IS_NOT_FALSE"; - case 4: - return "IS_UNKNOWN"; - case 5: - return "IS_NOT_UNKNOWN"; - default: - throw new Error("Key not recognized in enum BoolTestType"); - } - } - case "CmdType": - { - switch (key) { - case "CMD_UNKNOWN": - return 0; - case "CMD_SELECT": - return 1; - case "CMD_UPDATE": - return 2; - case "CMD_INSERT": - return 3; - case "CMD_DELETE": - return 4; - case "CMD_UTILITY": - return 5; - case "CMD_NOTHING": - return 6; - case 0: - return "CMD_UNKNOWN"; - case 1: - return "CMD_SELECT"; - case 2: - return "CMD_UPDATE"; - case 3: - return "CMD_INSERT"; - case 4: - return "CMD_DELETE"; - case 5: - return "CMD_UTILITY"; - case 6: - return "CMD_NOTHING"; - default: - throw new Error("Key not recognized in enum CmdType"); - } - } - case "JoinType": - { - switch (key) { - case "JOIN_INNER": - return 0; - case "JOIN_LEFT": - return 1; - case "JOIN_FULL": - return 2; - case "JOIN_RIGHT": - return 3; - case "JOIN_SEMI": - return 4; - case "JOIN_ANTI": - return 5; - case "JOIN_UNIQUE_OUTER": - return 6; - case "JOIN_UNIQUE_INNER": - return 7; - case 0: - return "JOIN_INNER"; - case 1: - return "JOIN_LEFT"; - case 2: - return "JOIN_FULL"; - case 3: - return "JOIN_RIGHT"; - case 4: - return "JOIN_SEMI"; - case 5: - return "JOIN_ANTI"; - case 6: - return "JOIN_UNIQUE_OUTER"; - case 7: - return "JOIN_UNIQUE_INNER"; - default: - throw new Error("Key not recognized in enum JoinType"); - } - } - case "AggStrategy": - { - switch (key) { - case "AGG_PLAIN": - return 0; - case "AGG_SORTED": - return 1; - case "AGG_HASHED": - return 2; - case "AGG_MIXED": - return 3; - case 0: - return "AGG_PLAIN"; - case 1: - return "AGG_SORTED"; - case 2: - return "AGG_HASHED"; - case 3: - return "AGG_MIXED"; - default: - throw new Error("Key not recognized in enum AggStrategy"); - } - } - case "AggSplit": - { - switch (key) { - case "AGGSPLIT_SIMPLE": - return 0; - case "AGGSPLIT_INITIAL_SERIAL": - return 1; - case "AGGSPLIT_FINAL_DESERIAL": - return 2; - case 0: - return "AGGSPLIT_SIMPLE"; - case 1: - return "AGGSPLIT_INITIAL_SERIAL"; - case 2: - return "AGGSPLIT_FINAL_DESERIAL"; - default: - throw new Error("Key not recognized in enum AggSplit"); - } - } - case "SetOpCmd": - { - switch (key) { - case "SETOPCMD_INTERSECT": - return 0; - case "SETOPCMD_INTERSECT_ALL": - return 1; - case "SETOPCMD_EXCEPT": - return 2; - case "SETOPCMD_EXCEPT_ALL": - return 3; - case 0: - return "SETOPCMD_INTERSECT"; - case 1: - return "SETOPCMD_INTERSECT_ALL"; - case 2: - return "SETOPCMD_EXCEPT"; - case 3: - return "SETOPCMD_EXCEPT_ALL"; - default: - throw new Error("Key not recognized in enum SetOpCmd"); - } - } - case "SetOpStrategy": - { - switch (key) { - case "SETOP_SORTED": - return 0; - case "SETOP_HASHED": - return 1; - case 0: - return "SETOP_SORTED"; - case 1: - return "SETOP_HASHED"; - default: - throw new Error("Key not recognized in enum SetOpStrategy"); - } - } - case "OnConflictAction": - { - switch (key) { - case "ONCONFLICT_NONE": - return 0; - case "ONCONFLICT_NOTHING": - return 1; - case "ONCONFLICT_UPDATE": - return 2; - case 0: - return "ONCONFLICT_NONE"; - case 1: - return "ONCONFLICT_NOTHING"; - case 2: - return "ONCONFLICT_UPDATE"; - default: - throw new Error("Key not recognized in enum OnConflictAction"); - } - } - case "LimitOption": - { - switch (key) { - case "LIMIT_OPTION_DEFAULT": - return 0; - case "LIMIT_OPTION_COUNT": - return 1; - case "LIMIT_OPTION_WITH_TIES": - return 2; - case 0: - return "LIMIT_OPTION_DEFAULT"; - case 1: - return "LIMIT_OPTION_COUNT"; - case 2: - return "LIMIT_OPTION_WITH_TIES"; - default: - throw new Error("Key not recognized in enum LimitOption"); - } - } - case "LockClauseStrength": - { - switch (key) { - case "LCS_NONE": - return 0; - case "LCS_FORKEYSHARE": - return 1; - case "LCS_FORSHARE": - return 2; - case "LCS_FORNOKEYUPDATE": - return 3; - case "LCS_FORUPDATE": - return 4; - case 0: - return "LCS_NONE"; - case 1: - return "LCS_FORKEYSHARE"; - case 2: - return "LCS_FORSHARE"; - case 3: - return "LCS_FORNOKEYUPDATE"; - case 4: - return "LCS_FORUPDATE"; - default: - throw new Error("Key not recognized in enum LockClauseStrength"); - } - } - case "LockWaitPolicy": - { - switch (key) { - case "LockWaitBlock": - return 0; - case "LockWaitSkip": - return 1; - case "LockWaitError": - return 2; - case 0: - return "LockWaitBlock"; - case 1: - return "LockWaitSkip"; - case 2: - return "LockWaitError"; - default: - throw new Error("Key not recognized in enum LockWaitPolicy"); - } - } - case "LockTupleMode": - { - switch (key) { - case "LockTupleKeyShare": - return 0; - case "LockTupleShare": - return 1; - case "LockTupleNoKeyExclusive": - return 2; - case "LockTupleExclusive": - return 3; - case 0: - return "LockTupleKeyShare"; - case 1: - return "LockTupleShare"; - case 2: - return "LockTupleNoKeyExclusive"; - case 3: - return "LockTupleExclusive"; - default: - throw new Error("Key not recognized in enum LockTupleMode"); - } - } - case "KeywordKind": - { - switch (key) { - case "NO_KEYWORD": - return 0; - case "UNRESERVED_KEYWORD": - return 1; - case "COL_NAME_KEYWORD": - return 2; - case "TYPE_FUNC_NAME_KEYWORD": - return 3; - case "RESERVED_KEYWORD": - return 4; - case 0: - return "NO_KEYWORD"; - case 1: - return "UNRESERVED_KEYWORD"; - case 2: - return "COL_NAME_KEYWORD"; - case 3: - return "TYPE_FUNC_NAME_KEYWORD"; - case 4: - return "RESERVED_KEYWORD"; - default: - throw new Error("Key not recognized in enum KeywordKind"); - } - } - case "Token": - { - switch (key) { - case "NUL": - return 0; - case "ASCII_37": - return 37; - case "ASCII_40": - return 40; - case "ASCII_41": - return 41; - case "ASCII_42": - return 42; - case "ASCII_43": - return 43; - case "ASCII_44": - return 44; - case "ASCII_45": - return 45; - case "ASCII_46": - return 46; - case "ASCII_47": - return 47; - case "ASCII_58": - return 58; - case "ASCII_59": - return 59; - case "ASCII_60": - return 60; - case "ASCII_61": - return 61; - case "ASCII_62": - return 62; - case "ASCII_63": - return 63; - case "ASCII_91": - return 91; - case "ASCII_92": - return 92; - case "ASCII_93": - return 93; - case "ASCII_94": - return 94; - case "IDENT": - return 258; - case "UIDENT": - return 259; - case "FCONST": - return 260; - case "SCONST": - return 261; - case "USCONST": - return 262; - case "BCONST": - return 263; - case "XCONST": - return 264; - case "Op": - return 265; - case "ICONST": - return 266; - case "PARAM": - return 267; - case "TYPECAST": - return 268; - case "DOT_DOT": - return 269; - case "COLON_EQUALS": - return 270; - case "EQUALS_GREATER": - return 271; - case "LESS_EQUALS": - return 272; - case "GREATER_EQUALS": - return 273; - case "NOT_EQUALS": - return 274; - case "SQL_COMMENT": - return 275; - case "C_COMMENT": - return 276; - case "ABORT_P": - return 277; - case "ABSOLUTE_P": - return 278; - case "ACCESS": - return 279; - case "ACTION": - return 280; - case "ADD_P": - return 281; - case "ADMIN": - return 282; - case "AFTER": - return 283; - case "AGGREGATE": - return 284; - case "ALL": - return 285; - case "ALSO": - return 286; - case "ALTER": - return 287; - case "ALWAYS": - return 288; - case "ANALYSE": - return 289; - case "ANALYZE": - return 290; - case "AND": - return 291; - case "ANY": - return 292; - case "ARRAY": - return 293; - case "AS": - return 294; - case "ASC": - return 295; - case "ASSERTION": - return 296; - case "ASSIGNMENT": - return 297; - case "ASYMMETRIC": - return 298; - case "AT": - return 299; - case "ATTACH": - return 300; - case "ATTRIBUTE": - return 301; - case "AUTHORIZATION": - return 302; - case "BACKWARD": - return 303; - case "BEFORE": - return 304; - case "BEGIN_P": - return 305; - case "BETWEEN": - return 306; - case "BIGINT": - return 307; - case "BINARY": - return 308; - case "BIT": - return 309; - case "BOOLEAN_P": - return 310; - case "BOTH": - return 311; - case "BY": - return 312; - case "CACHE": - return 313; - case "CALL": - return 314; - case "CALLED": - return 315; - case "CASCADE": - return 316; - case "CASCADED": - return 317; - case "CASE": - return 318; - case "CAST": - return 319; - case "CATALOG_P": - return 320; - case "CHAIN": - return 321; - case "CHAR_P": - return 322; - case "CHARACTER": - return 323; - case "CHARACTERISTICS": - return 324; - case "CHECK": - return 325; - case "CHECKPOINT": - return 326; - case "CLASS": - return 327; - case "CLOSE": - return 328; - case "CLUSTER": - return 329; - case "COALESCE": - return 330; - case "COLLATE": - return 331; - case "COLLATION": - return 332; - case "COLUMN": - return 333; - case "COLUMNS": - return 334; - case "COMMENT": - return 335; - case "COMMENTS": - return 336; - case "COMMIT": - return 337; - case "COMMITTED": - return 338; - case "CONCURRENTLY": - return 339; - case "CONFIGURATION": - return 340; - case "CONFLICT": - return 341; - case "CONNECTION": - return 342; - case "CONSTRAINT": - return 343; - case "CONSTRAINTS": - return 344; - case "CONTENT_P": - return 345; - case "CONTINUE_P": - return 346; - case "CONVERSION_P": - return 347; - case "COPY": - return 348; - case "COST": - return 349; - case "CREATE": - return 350; - case "CROSS": - return 351; - case "CSV": - return 352; - case "CUBE": - return 353; - case "CURRENT_P": - return 354; - case "CURRENT_CATALOG": - return 355; - case "CURRENT_DATE": - return 356; - case "CURRENT_ROLE": - return 357; - case "CURRENT_SCHEMA": - return 358; - case "CURRENT_TIME": - return 359; - case "CURRENT_TIMESTAMP": - return 360; - case "CURRENT_USER": - return 361; - case "CURSOR": - return 362; - case "CYCLE": - return 363; - case "DATA_P": - return 364; - case "DATABASE": - return 365; - case "DAY_P": - return 366; - case "DEALLOCATE": - return 367; - case "DEC": - return 368; - case "DECIMAL_P": - return 369; - case "DECLARE": - return 370; - case "DEFAULT": - return 371; - case "DEFAULTS": - return 372; - case "DEFERRABLE": - return 373; - case "DEFERRED": - return 374; - case "DEFINER": - return 375; - case "DELETE_P": - return 376; - case "DELIMITER": - return 377; - case "DELIMITERS": - return 378; - case "DEPENDS": - return 379; - case "DESC": - return 380; - case "DETACH": - return 381; - case "DICTIONARY": - return 382; - case "DISABLE_P": - return 383; - case "DISCARD": - return 384; - case "DISTINCT": - return 385; - case "DO": - return 386; - case "DOCUMENT_P": - return 387; - case "DOMAIN_P": - return 388; - case "DOUBLE_P": - return 389; - case "DROP": - return 390; - case "EACH": - return 391; - case "ELSE": - return 392; - case "ENABLE_P": - return 393; - case "ENCODING": - return 394; - case "ENCRYPTED": - return 395; - case "END_P": - return 396; - case "ENUM_P": - return 397; - case "ESCAPE": - return 398; - case "EVENT": - return 399; - case "EXCEPT": - return 400; - case "EXCLUDE": - return 401; - case "EXCLUDING": - return 402; - case "EXCLUSIVE": - return 403; - case "EXECUTE": - return 404; - case "EXISTS": - return 405; - case "EXPLAIN": - return 406; - case "EXPRESSION": - return 407; - case "EXTENSION": - return 408; - case "EXTERNAL": - return 409; - case "EXTRACT": - return 410; - case "FALSE_P": - return 411; - case "FAMILY": - return 412; - case "FETCH": - return 413; - case "FILTER": - return 414; - case "FIRST_P": - return 415; - case "FLOAT_P": - return 416; - case "FOLLOWING": - return 417; - case "FOR": - return 418; - case "FORCE": - return 419; - case "FOREIGN": - return 420; - case "FORWARD": - return 421; - case "FREEZE": - return 422; - case "FROM": - return 423; - case "FULL": - return 424; - case "FUNCTION": - return 425; - case "FUNCTIONS": - return 426; - case "GENERATED": - return 427; - case "GLOBAL": - return 428; - case "GRANT": - return 429; - case "GRANTED": - return 430; - case "GREATEST": - return 431; - case "GROUP_P": - return 432; - case "GROUPING": - return 433; - case "GROUPS": - return 434; - case "HANDLER": - return 435; - case "HAVING": - return 436; - case "HEADER_P": - return 437; - case "HOLD": - return 438; - case "HOUR_P": - return 439; - case "IDENTITY_P": - return 440; - case "IF_P": - return 441; - case "ILIKE": - return 442; - case "IMMEDIATE": - return 443; - case "IMMUTABLE": - return 444; - case "IMPLICIT_P": - return 445; - case "IMPORT_P": - return 446; - case "IN_P": - return 447; - case "INCLUDE": - return 448; - case "INCLUDING": - return 449; - case "INCREMENT": - return 450; - case "INDEX": - return 451; - case "INDEXES": - return 452; - case "INHERIT": - return 453; - case "INHERITS": - return 454; - case "INITIALLY": - return 455; - case "INLINE_P": - return 456; - case "INNER_P": - return 457; - case "INOUT": - return 458; - case "INPUT_P": - return 459; - case "INSENSITIVE": - return 460; - case "INSERT": - return 461; - case "INSTEAD": - return 462; - case "INT_P": - return 463; - case "INTEGER": - return 464; - case "INTERSECT": - return 465; - case "INTERVAL": - return 466; - case "INTO": - return 467; - case "INVOKER": - return 468; - case "IS": - return 469; - case "ISNULL": - return 470; - case "ISOLATION": - return 471; - case "JOIN": - return 472; - case "KEY": - return 473; - case "LABEL": - return 474; - case "LANGUAGE": - return 475; - case "LARGE_P": - return 476; - case "LAST_P": - return 477; - case "LATERAL_P": - return 478; - case "LEADING": - return 479; - case "LEAKPROOF": - return 480; - case "LEAST": - return 481; - case "LEFT": - return 482; - case "LEVEL": - return 483; - case "LIKE": - return 484; - case "LIMIT": - return 485; - case "LISTEN": - return 486; - case "LOAD": - return 487; - case "LOCAL": - return 488; - case "LOCALTIME": - return 489; - case "LOCALTIMESTAMP": - return 490; - case "LOCATION": - return 491; - case "LOCK_P": - return 492; - case "LOCKED": - return 493; - case "LOGGED": - return 494; - case "MAPPING": - return 495; - case "MATCH": - return 496; - case "MATERIALIZED": - return 497; - case "MAXVALUE": - return 498; - case "METHOD": - return 499; - case "MINUTE_P": - return 500; - case "MINVALUE": - return 501; - case "MODE": - return 502; - case "MONTH_P": - return 503; - case "MOVE": - return 504; - case "NAME_P": - return 505; - case "NAMES": - return 506; - case "NATIONAL": - return 507; - case "NATURAL": - return 508; - case "NCHAR": - return 509; - case "NEW": - return 510; - case "NEXT": - return 511; - case "NFC": - return 512; - case "NFD": - return 513; - case "NFKC": - return 514; - case "NFKD": - return 515; - case "NO": - return 516; - case "NONE": - return 517; - case "NORMALIZE": - return 518; - case "NORMALIZED": - return 519; - case "NOT": - return 520; - case "NOTHING": - return 521; - case "NOTIFY": - return 522; - case "NOTNULL": - return 523; - case "NOWAIT": - return 524; - case "NULL_P": - return 525; - case "NULLIF": - return 526; - case "NULLS_P": - return 527; - case "NUMERIC": - return 528; - case "OBJECT_P": - return 529; - case "OF": - return 530; - case "OFF": - return 531; - case "OFFSET": - return 532; - case "OIDS": - return 533; - case "OLD": - return 534; - case "ON": - return 535; - case "ONLY": - return 536; - case "OPERATOR": - return 537; - case "OPTION": - return 538; - case "OPTIONS": - return 539; - case "OR": - return 540; - case "ORDER": - return 541; - case "ORDINALITY": - return 542; - case "OTHERS": - return 543; - case "OUT_P": - return 544; - case "OUTER_P": - return 545; - case "OVER": - return 546; - case "OVERLAPS": - return 547; - case "OVERLAY": - return 548; - case "OVERRIDING": - return 549; - case "OWNED": - return 550; - case "OWNER": - return 551; - case "PARALLEL": - return 552; - case "PARSER": - return 553; - case "PARTIAL": - return 554; - case "PARTITION": - return 555; - case "PASSING": - return 556; - case "PASSWORD": - return 557; - case "PLACING": - return 558; - case "PLANS": - return 559; - case "POLICY": - return 560; - case "POSITION": - return 561; - case "PRECEDING": - return 562; - case "PRECISION": - return 563; - case "PRESERVE": - return 564; - case "PREPARE": - return 565; - case "PREPARED": - return 566; - case "PRIMARY": - return 567; - case "PRIOR": - return 568; - case "PRIVILEGES": - return 569; - case "PROCEDURAL": - return 570; - case "PROCEDURE": - return 571; - case "PROCEDURES": - return 572; - case "PROGRAM": - return 573; - case "PUBLICATION": - return 574; - case "QUOTE": - return 575; - case "RANGE": - return 576; - case "READ": - return 577; - case "REAL": - return 578; - case "REASSIGN": - return 579; - case "RECHECK": - return 580; - case "RECURSIVE": - return 581; - case "REF_P": - return 582; - case "REFERENCES": - return 583; - case "REFERENCING": - return 584; - case "REFRESH": - return 585; - case "REINDEX": - return 586; - case "RELATIVE_P": - return 587; - case "RELEASE": - return 588; - case "RENAME": - return 589; - case "REPEATABLE": - return 590; - case "REPLACE": - return 591; - case "REPLICA": - return 592; - case "RESET": - return 593; - case "RESTART": - return 594; - case "RESTRICT": - return 595; - case "RETURNING": - return 596; - case "RETURNS": - return 597; - case "REVOKE": - return 598; - case "RIGHT": - return 599; - case "ROLE": - return 600; - case "ROLLBACK": - return 601; - case "ROLLUP": - return 602; - case "ROUTINE": - return 603; - case "ROUTINES": - return 604; - case "ROW": - return 605; - case "ROWS": - return 606; - case "RULE": - return 607; - case "SAVEPOINT": - return 608; - case "SCHEMA": - return 609; - case "SCHEMAS": - return 610; - case "SCROLL": - return 611; - case "SEARCH": - return 612; - case "SECOND_P": - return 613; - case "SECURITY": - return 614; - case "SELECT": - return 615; - case "SEQUENCE": - return 616; - case "SEQUENCES": - return 617; - case "SERIALIZABLE": - return 618; - case "SERVER": - return 619; - case "SESSION": - return 620; - case "SESSION_USER": - return 621; - case "SET": - return 622; - case "SETS": - return 623; - case "SETOF": - return 624; - case "SHARE": - return 625; - case "SHOW": - return 626; - case "SIMILAR": - return 627; - case "SIMPLE": - return 628; - case "SKIP": - return 629; - case "SMALLINT": - return 630; - case "SNAPSHOT": - return 631; - case "SOME": - return 632; - case "SQL_P": - return 633; - case "STABLE": - return 634; - case "STANDALONE_P": - return 635; - case "START": - return 636; - case "STATEMENT": - return 637; - case "STATISTICS": - return 638; - case "STDIN": - return 639; - case "STDOUT": - return 640; - case "STORAGE": - return 641; - case "STORED": - return 642; - case "STRICT_P": - return 643; - case "STRIP_P": - return 644; - case "SUBSCRIPTION": - return 645; - case "SUBSTRING": - return 646; - case "SUPPORT": - return 647; - case "SYMMETRIC": - return 648; - case "SYSID": - return 649; - case "SYSTEM_P": - return 650; - case "TABLE": - return 651; - case "TABLES": - return 652; - case "TABLESAMPLE": - return 653; - case "TABLESPACE": - return 654; - case "TEMP": - return 655; - case "TEMPLATE": - return 656; - case "TEMPORARY": - return 657; - case "TEXT_P": - return 658; - case "THEN": - return 659; - case "TIES": - return 660; - case "TIME": - return 661; - case "TIMESTAMP": - return 662; - case "TO": - return 663; - case "TRAILING": - return 664; - case "TRANSACTION": - return 665; - case "TRANSFORM": - return 666; - case "TREAT": - return 667; - case "TRIGGER": - return 668; - case "TRIM": - return 669; - case "TRUE_P": - return 670; - case "TRUNCATE": - return 671; - case "TRUSTED": - return 672; - case "TYPE_P": - return 673; - case "TYPES_P": - return 674; - case "UESCAPE": - return 675; - case "UNBOUNDED": - return 676; - case "UNCOMMITTED": - return 677; - case "UNENCRYPTED": - return 678; - case "UNION": - return 679; - case "UNIQUE": - return 680; - case "UNKNOWN": - return 681; - case "UNLISTEN": - return 682; - case "UNLOGGED": - return 683; - case "UNTIL": - return 684; - case "UPDATE": - return 685; - case "USER": - return 686; - case "USING": - return 687; - case "VACUUM": - return 688; - case "VALID": - return 689; - case "VALIDATE": - return 690; - case "VALIDATOR": - return 691; - case "VALUE_P": - return 692; - case "VALUES": - return 693; - case "VARCHAR": - return 694; - case "VARIADIC": - return 695; - case "VARYING": - return 696; - case "VERBOSE": - return 697; - case "VERSION_P": - return 698; - case "VIEW": - return 699; - case "VIEWS": - return 700; - case "VOLATILE": - return 701; - case "WHEN": - return 702; - case "WHERE": - return 703; - case "WHITESPACE_P": - return 704; - case "WINDOW": - return 705; - case "WITH": - return 706; - case "WITHIN": - return 707; - case "WITHOUT": - return 708; - case "WORK": - return 709; - case "WRAPPER": - return 710; - case "WRITE": - return 711; - case "XML_P": - return 712; - case "XMLATTRIBUTES": - return 713; - case "XMLCONCAT": - return 714; - case "XMLELEMENT": - return 715; - case "XMLEXISTS": - return 716; - case "XMLFOREST": - return 717; - case "XMLNAMESPACES": - return 718; - case "XMLPARSE": - return 719; - case "XMLPI": - return 720; - case "XMLROOT": - return 721; - case "XMLSERIALIZE": - return 722; - case "XMLTABLE": - return 723; - case "YEAR_P": - return 724; - case "YES_P": - return 725; - case "ZONE": - return 726; - case "NOT_LA": - return 727; - case "NULLS_LA": - return 728; - case "WITH_LA": - return 729; - case "POSTFIXOP": - return 730; - case "UMINUS": - return 731; - case 0: - return "NUL"; - case 37: - return "ASCII_37"; - case 40: - return "ASCII_40"; - case 41: - return "ASCII_41"; - case 42: - return "ASCII_42"; - case 43: - return "ASCII_43"; - case 44: - return "ASCII_44"; - case 45: - return "ASCII_45"; - case 46: - return "ASCII_46"; - case 47: - return "ASCII_47"; - case 58: - return "ASCII_58"; - case 59: - return "ASCII_59"; - case 60: - return "ASCII_60"; - case 61: - return "ASCII_61"; - case 62: - return "ASCII_62"; - case 63: - return "ASCII_63"; - case 91: - return "ASCII_91"; - case 92: - return "ASCII_92"; - case 93: - return "ASCII_93"; - case 94: - return "ASCII_94"; - case 258: - return "IDENT"; - case 259: - return "UIDENT"; - case 260: - return "FCONST"; - case 261: - return "SCONST"; - case 262: - return "USCONST"; - case 263: - return "BCONST"; - case 264: - return "XCONST"; - case 265: - return "Op"; - case 266: - return "ICONST"; - case 267: - return "PARAM"; - case 268: - return "TYPECAST"; - case 269: - return "DOT_DOT"; - case 270: - return "COLON_EQUALS"; - case 271: - return "EQUALS_GREATER"; - case 272: - return "LESS_EQUALS"; - case 273: - return "GREATER_EQUALS"; - case 274: - return "NOT_EQUALS"; - case 275: - return "SQL_COMMENT"; - case 276: - return "C_COMMENT"; - case 277: - return "ABORT_P"; - case 278: - return "ABSOLUTE_P"; - case 279: - return "ACCESS"; - case 280: - return "ACTION"; - case 281: - return "ADD_P"; - case 282: - return "ADMIN"; - case 283: - return "AFTER"; - case 284: - return "AGGREGATE"; - case 285: - return "ALL"; - case 286: - return "ALSO"; - case 287: - return "ALTER"; - case 288: - return "ALWAYS"; - case 289: - return "ANALYSE"; - case 290: - return "ANALYZE"; - case 291: - return "AND"; - case 292: - return "ANY"; - case 293: - return "ARRAY"; - case 294: - return "AS"; - case 295: - return "ASC"; - case 296: - return "ASSERTION"; - case 297: - return "ASSIGNMENT"; - case 298: - return "ASYMMETRIC"; - case 299: - return "AT"; - case 300: - return "ATTACH"; - case 301: - return "ATTRIBUTE"; - case 302: - return "AUTHORIZATION"; - case 303: - return "BACKWARD"; - case 304: - return "BEFORE"; - case 305: - return "BEGIN_P"; - case 306: - return "BETWEEN"; - case 307: - return "BIGINT"; - case 308: - return "BINARY"; - case 309: - return "BIT"; - case 310: - return "BOOLEAN_P"; - case 311: - return "BOTH"; - case 312: - return "BY"; - case 313: - return "CACHE"; - case 314: - return "CALL"; - case 315: - return "CALLED"; - case 316: - return "CASCADE"; - case 317: - return "CASCADED"; - case 318: - return "CASE"; - case 319: - return "CAST"; - case 320: - return "CATALOG_P"; - case 321: - return "CHAIN"; - case 322: - return "CHAR_P"; - case 323: - return "CHARACTER"; - case 324: - return "CHARACTERISTICS"; - case 325: - return "CHECK"; - case 326: - return "CHECKPOINT"; - case 327: - return "CLASS"; - case 328: - return "CLOSE"; - case 329: - return "CLUSTER"; - case 330: - return "COALESCE"; - case 331: - return "COLLATE"; - case 332: - return "COLLATION"; - case 333: - return "COLUMN"; - case 334: - return "COLUMNS"; - case 335: - return "COMMENT"; - case 336: - return "COMMENTS"; - case 337: - return "COMMIT"; - case 338: - return "COMMITTED"; - case 339: - return "CONCURRENTLY"; - case 340: - return "CONFIGURATION"; - case 341: - return "CONFLICT"; - case 342: - return "CONNECTION"; - case 343: - return "CONSTRAINT"; - case 344: - return "CONSTRAINTS"; - case 345: - return "CONTENT_P"; - case 346: - return "CONTINUE_P"; - case 347: - return "CONVERSION_P"; - case 348: - return "COPY"; - case 349: - return "COST"; - case 350: - return "CREATE"; - case 351: - return "CROSS"; - case 352: - return "CSV"; - case 353: - return "CUBE"; - case 354: - return "CURRENT_P"; - case 355: - return "CURRENT_CATALOG"; - case 356: - return "CURRENT_DATE"; - case 357: - return "CURRENT_ROLE"; - case 358: - return "CURRENT_SCHEMA"; - case 359: - return "CURRENT_TIME"; - case 360: - return "CURRENT_TIMESTAMP"; - case 361: - return "CURRENT_USER"; - case 362: - return "CURSOR"; - case 363: - return "CYCLE"; - case 364: - return "DATA_P"; - case 365: - return "DATABASE"; - case 366: - return "DAY_P"; - case 367: - return "DEALLOCATE"; - case 368: - return "DEC"; - case 369: - return "DECIMAL_P"; - case 370: - return "DECLARE"; - case 371: - return "DEFAULT"; - case 372: - return "DEFAULTS"; - case 373: - return "DEFERRABLE"; - case 374: - return "DEFERRED"; - case 375: - return "DEFINER"; - case 376: - return "DELETE_P"; - case 377: - return "DELIMITER"; - case 378: - return "DELIMITERS"; - case 379: - return "DEPENDS"; - case 380: - return "DESC"; - case 381: - return "DETACH"; - case 382: - return "DICTIONARY"; - case 383: - return "DISABLE_P"; - case 384: - return "DISCARD"; - case 385: - return "DISTINCT"; - case 386: - return "DO"; - case 387: - return "DOCUMENT_P"; - case 388: - return "DOMAIN_P"; - case 389: - return "DOUBLE_P"; - case 390: - return "DROP"; - case 391: - return "EACH"; - case 392: - return "ELSE"; - case 393: - return "ENABLE_P"; - case 394: - return "ENCODING"; - case 395: - return "ENCRYPTED"; - case 396: - return "END_P"; - case 397: - return "ENUM_P"; - case 398: - return "ESCAPE"; - case 399: - return "EVENT"; - case 400: - return "EXCEPT"; - case 401: - return "EXCLUDE"; - case 402: - return "EXCLUDING"; - case 403: - return "EXCLUSIVE"; - case 404: - return "EXECUTE"; - case 405: - return "EXISTS"; - case 406: - return "EXPLAIN"; - case 407: - return "EXPRESSION"; - case 408: - return "EXTENSION"; - case 409: - return "EXTERNAL"; - case 410: - return "EXTRACT"; - case 411: - return "FALSE_P"; - case 412: - return "FAMILY"; - case 413: - return "FETCH"; - case 414: - return "FILTER"; - case 415: - return "FIRST_P"; - case 416: - return "FLOAT_P"; - case 417: - return "FOLLOWING"; - case 418: - return "FOR"; - case 419: - return "FORCE"; - case 420: - return "FOREIGN"; - case 421: - return "FORWARD"; - case 422: - return "FREEZE"; - case 423: - return "FROM"; - case 424: - return "FULL"; - case 425: - return "FUNCTION"; - case 426: - return "FUNCTIONS"; - case 427: - return "GENERATED"; - case 428: - return "GLOBAL"; - case 429: - return "GRANT"; - case 430: - return "GRANTED"; - case 431: - return "GREATEST"; - case 432: - return "GROUP_P"; - case 433: - return "GROUPING"; - case 434: - return "GROUPS"; - case 435: - return "HANDLER"; - case 436: - return "HAVING"; - case 437: - return "HEADER_P"; - case 438: - return "HOLD"; - case 439: - return "HOUR_P"; - case 440: - return "IDENTITY_P"; - case 441: - return "IF_P"; - case 442: - return "ILIKE"; - case 443: - return "IMMEDIATE"; - case 444: - return "IMMUTABLE"; - case 445: - return "IMPLICIT_P"; - case 446: - return "IMPORT_P"; - case 447: - return "IN_P"; - case 448: - return "INCLUDE"; - case 449: - return "INCLUDING"; - case 450: - return "INCREMENT"; - case 451: - return "INDEX"; - case 452: - return "INDEXES"; - case 453: - return "INHERIT"; - case 454: - return "INHERITS"; - case 455: - return "INITIALLY"; - case 456: - return "INLINE_P"; - case 457: - return "INNER_P"; - case 458: - return "INOUT"; - case 459: - return "INPUT_P"; - case 460: - return "INSENSITIVE"; - case 461: - return "INSERT"; - case 462: - return "INSTEAD"; - case 463: - return "INT_P"; - case 464: - return "INTEGER"; - case 465: - return "INTERSECT"; - case 466: - return "INTERVAL"; - case 467: - return "INTO"; - case 468: - return "INVOKER"; - case 469: - return "IS"; - case 470: - return "ISNULL"; - case 471: - return "ISOLATION"; - case 472: - return "JOIN"; - case 473: - return "KEY"; - case 474: - return "LABEL"; - case 475: - return "LANGUAGE"; - case 476: - return "LARGE_P"; - case 477: - return "LAST_P"; - case 478: - return "LATERAL_P"; - case 479: - return "LEADING"; - case 480: - return "LEAKPROOF"; - case 481: - return "LEAST"; - case 482: - return "LEFT"; - case 483: - return "LEVEL"; - case 484: - return "LIKE"; - case 485: - return "LIMIT"; - case 486: - return "LISTEN"; - case 487: - return "LOAD"; - case 488: - return "LOCAL"; - case 489: - return "LOCALTIME"; - case 490: - return "LOCALTIMESTAMP"; - case 491: - return "LOCATION"; - case 492: - return "LOCK_P"; - case 493: - return "LOCKED"; - case 494: - return "LOGGED"; - case 495: - return "MAPPING"; - case 496: - return "MATCH"; - case 497: - return "MATERIALIZED"; - case 498: - return "MAXVALUE"; - case 499: - return "METHOD"; - case 500: - return "MINUTE_P"; - case 501: - return "MINVALUE"; - case 502: - return "MODE"; - case 503: - return "MONTH_P"; - case 504: - return "MOVE"; - case 505: - return "NAME_P"; - case 506: - return "NAMES"; - case 507: - return "NATIONAL"; - case 508: - return "NATURAL"; - case 509: - return "NCHAR"; - case 510: - return "NEW"; - case 511: - return "NEXT"; - case 512: - return "NFC"; - case 513: - return "NFD"; - case 514: - return "NFKC"; - case 515: - return "NFKD"; - case 516: - return "NO"; - case 517: - return "NONE"; - case 518: - return "NORMALIZE"; - case 519: - return "NORMALIZED"; - case 520: - return "NOT"; - case 521: - return "NOTHING"; - case 522: - return "NOTIFY"; - case 523: - return "NOTNULL"; - case 524: - return "NOWAIT"; - case 525: - return "NULL_P"; - case 526: - return "NULLIF"; - case 527: - return "NULLS_P"; - case 528: - return "NUMERIC"; - case 529: - return "OBJECT_P"; - case 530: - return "OF"; - case 531: - return "OFF"; - case 532: - return "OFFSET"; - case 533: - return "OIDS"; - case 534: - return "OLD"; - case 535: - return "ON"; - case 536: - return "ONLY"; - case 537: - return "OPERATOR"; - case 538: - return "OPTION"; - case 539: - return "OPTIONS"; - case 540: - return "OR"; - case 541: - return "ORDER"; - case 542: - return "ORDINALITY"; - case 543: - return "OTHERS"; - case 544: - return "OUT_P"; - case 545: - return "OUTER_P"; - case 546: - return "OVER"; - case 547: - return "OVERLAPS"; - case 548: - return "OVERLAY"; - case 549: - return "OVERRIDING"; - case 550: - return "OWNED"; - case 551: - return "OWNER"; - case 552: - return "PARALLEL"; - case 553: - return "PARSER"; - case 554: - return "PARTIAL"; - case 555: - return "PARTITION"; - case 556: - return "PASSING"; - case 557: - return "PASSWORD"; - case 558: - return "PLACING"; - case 559: - return "PLANS"; - case 560: - return "POLICY"; - case 561: - return "POSITION"; - case 562: - return "PRECEDING"; - case 563: - return "PRECISION"; - case 564: - return "PRESERVE"; - case 565: - return "PREPARE"; - case 566: - return "PREPARED"; - case 567: - return "PRIMARY"; - case 568: - return "PRIOR"; - case 569: - return "PRIVILEGES"; - case 570: - return "PROCEDURAL"; - case 571: - return "PROCEDURE"; - case 572: - return "PROCEDURES"; - case 573: - return "PROGRAM"; - case 574: - return "PUBLICATION"; - case 575: - return "QUOTE"; - case 576: - return "RANGE"; - case 577: - return "READ"; - case 578: - return "REAL"; - case 579: - return "REASSIGN"; - case 580: - return "RECHECK"; - case 581: - return "RECURSIVE"; - case 582: - return "REF_P"; - case 583: - return "REFERENCES"; - case 584: - return "REFERENCING"; - case 585: - return "REFRESH"; - case 586: - return "REINDEX"; - case 587: - return "RELATIVE_P"; - case 588: - return "RELEASE"; - case 589: - return "RENAME"; - case 590: - return "REPEATABLE"; - case 591: - return "REPLACE"; - case 592: - return "REPLICA"; - case 593: - return "RESET"; - case 594: - return "RESTART"; - case 595: - return "RESTRICT"; - case 596: - return "RETURNING"; - case 597: - return "RETURNS"; - case 598: - return "REVOKE"; - case 599: - return "RIGHT"; - case 600: - return "ROLE"; - case 601: - return "ROLLBACK"; - case 602: - return "ROLLUP"; - case 603: - return "ROUTINE"; - case 604: - return "ROUTINES"; - case 605: - return "ROW"; - case 606: - return "ROWS"; - case 607: - return "RULE"; - case 608: - return "SAVEPOINT"; - case 609: - return "SCHEMA"; - case 610: - return "SCHEMAS"; - case 611: - return "SCROLL"; - case 612: - return "SEARCH"; - case 613: - return "SECOND_P"; - case 614: - return "SECURITY"; - case 615: - return "SELECT"; - case 616: - return "SEQUENCE"; - case 617: - return "SEQUENCES"; - case 618: - return "SERIALIZABLE"; - case 619: - return "SERVER"; - case 620: - return "SESSION"; - case 621: - return "SESSION_USER"; - case 622: - return "SET"; - case 623: - return "SETS"; - case 624: - return "SETOF"; - case 625: - return "SHARE"; - case 626: - return "SHOW"; - case 627: - return "SIMILAR"; - case 628: - return "SIMPLE"; - case 629: - return "SKIP"; - case 630: - return "SMALLINT"; - case 631: - return "SNAPSHOT"; - case 632: - return "SOME"; - case 633: - return "SQL_P"; - case 634: - return "STABLE"; - case 635: - return "STANDALONE_P"; - case 636: - return "START"; - case 637: - return "STATEMENT"; - case 638: - return "STATISTICS"; - case 639: - return "STDIN"; - case 640: - return "STDOUT"; - case 641: - return "STORAGE"; - case 642: - return "STORED"; - case 643: - return "STRICT_P"; - case 644: - return "STRIP_P"; - case 645: - return "SUBSCRIPTION"; - case 646: - return "SUBSTRING"; - case 647: - return "SUPPORT"; - case 648: - return "SYMMETRIC"; - case 649: - return "SYSID"; - case 650: - return "SYSTEM_P"; - case 651: - return "TABLE"; - case 652: - return "TABLES"; - case 653: - return "TABLESAMPLE"; - case 654: - return "TABLESPACE"; - case 655: - return "TEMP"; - case 656: - return "TEMPLATE"; - case 657: - return "TEMPORARY"; - case 658: - return "TEXT_P"; - case 659: - return "THEN"; - case 660: - return "TIES"; - case 661: - return "TIME"; - case 662: - return "TIMESTAMP"; - case 663: - return "TO"; - case 664: - return "TRAILING"; - case 665: - return "TRANSACTION"; - case 666: - return "TRANSFORM"; - case 667: - return "TREAT"; - case 668: - return "TRIGGER"; - case 669: - return "TRIM"; - case 670: - return "TRUE_P"; - case 671: - return "TRUNCATE"; - case 672: - return "TRUSTED"; - case 673: - return "TYPE_P"; - case 674: - return "TYPES_P"; - case 675: - return "UESCAPE"; - case 676: - return "UNBOUNDED"; - case 677: - return "UNCOMMITTED"; - case 678: - return "UNENCRYPTED"; - case 679: - return "UNION"; - case 680: - return "UNIQUE"; - case 681: - return "UNKNOWN"; - case 682: - return "UNLISTEN"; - case 683: - return "UNLOGGED"; - case 684: - return "UNTIL"; - case 685: - return "UPDATE"; - case 686: - return "USER"; - case 687: - return "USING"; - case 688: - return "VACUUM"; - case 689: - return "VALID"; - case 690: - return "VALIDATE"; - case 691: - return "VALIDATOR"; - case 692: - return "VALUE_P"; - case 693: - return "VALUES"; - case 694: - return "VARCHAR"; - case 695: - return "VARIADIC"; - case 696: - return "VARYING"; - case 697: - return "VERBOSE"; - case 698: - return "VERSION_P"; - case 699: - return "VIEW"; - case 700: - return "VIEWS"; - case 701: - return "VOLATILE"; - case 702: - return "WHEN"; - case 703: - return "WHERE"; - case 704: - return "WHITESPACE_P"; - case 705: - return "WINDOW"; - case 706: - return "WITH"; - case 707: - return "WITHIN"; - case 708: - return "WITHOUT"; - case 709: - return "WORK"; - case 710: - return "WRAPPER"; - case 711: - return "WRITE"; - case 712: - return "XML_P"; - case 713: - return "XMLATTRIBUTES"; - case 714: - return "XMLCONCAT"; - case 715: - return "XMLELEMENT"; - case 716: - return "XMLEXISTS"; - case 717: - return "XMLFOREST"; - case 718: - return "XMLNAMESPACES"; - case 719: - return "XMLPARSE"; - case 720: - return "XMLPI"; - case 721: - return "XMLROOT"; - case 722: - return "XMLSERIALIZE"; - case 723: - return "XMLTABLE"; - case 724: - return "YEAR_P"; - case 725: - return "YES_P"; - case 726: - return "ZONE"; - case 727: - return "NOT_LA"; - case 728: - return "NULLS_LA"; - case 729: - return "WITH_LA"; - case 730: - return "POSTFIXOP"; - case 731: - return "UMINUS"; - default: - throw new Error("Key not recognized in enum Token"); - } - } - default: - throw new Error("Enum type not recognized"); - } -}; \ No newline at end of file diff --git a/packages/utils/src/wrapped.ts b/packages/utils/src/wrapped.ts new file mode 100644 index 00000000..a583245f --- /dev/null +++ b/packages/utils/src/wrapped.ts @@ -0,0 +1,3574 @@ +/** +* This file was automatically generated by pg-proto-parser@1.28.2. +* DO NOT MODIFY IT BY HAND. Instead, modify the source proto file, +* and run the pg-proto-parser generate command to regenerate this file. +*/ +import _o from "nested-obj"; +import { ParseResult, ScanResult, Integer, Float, Boolean, String, BitString, List, OidList, IntList, A_Const, Alias, RangeVar, TableFunc, IntoClause, Var, Param, Aggref, GroupingFunc, WindowFunc, WindowFuncRunCondition, MergeSupportFunc, SubscriptingRef, FuncExpr, NamedArgExpr, OpExpr, DistinctExpr, NullIfExpr, ScalarArrayOpExpr, BoolExpr, SubLink, SubPlan, AlternativeSubPlan, FieldSelect, FieldStore, RelabelType, CoerceViaIO, ArrayCoerceExpr, ConvertRowtypeExpr, CollateExpr, CaseExpr, CaseWhen, CaseTestExpr, ArrayExpr, RowExpr, RowCompareExpr, CoalesceExpr, MinMaxExpr, SQLValueFunction, XmlExpr, JsonFormat, JsonReturning, JsonValueExpr, JsonConstructorExpr, JsonIsPredicate, JsonBehavior, JsonExpr, JsonTablePath, JsonTablePathScan, JsonTableSiblingJoin, NullTest, BooleanTest, MergeAction, CoerceToDomain, CoerceToDomainValue, SetToDefault, CurrentOfExpr, NextValueExpr, InferenceElem, TargetEntry, RangeTblRef, JoinExpr, FromExpr, OnConflictExpr, Query, TypeName, ColumnRef, ParamRef, A_Expr, TypeCast, CollateClause, RoleSpec, FuncCall, A_Star, A_Indices, A_Indirection, A_ArrayExpr, ResTarget, MultiAssignRef, SortBy, WindowDef, RangeSubselect, RangeFunction, RangeTableFunc, RangeTableFuncCol, RangeTableSample, ColumnDef, TableLikeClause, IndexElem, DefElem, LockingClause, XmlSerialize, PartitionElem, PartitionSpec, PartitionBoundSpec, PartitionRangeDatum, SinglePartitionSpec, PartitionCmd, RangeTblEntry, RTEPermissionInfo, RangeTblFunction, TableSampleClause, WithCheckOption, SortGroupClause, GroupingSet, WindowClause, RowMarkClause, WithClause, InferClause, OnConflictClause, CTESearchClause, CTECycleClause, CommonTableExpr, MergeWhenClause, TriggerTransition, JsonOutput, JsonArgument, JsonFuncExpr, JsonTablePathSpec, JsonTable, JsonTableColumn, JsonKeyValue, JsonParseExpr, JsonScalarExpr, JsonSerializeExpr, JsonObjectConstructor, JsonArrayConstructor, JsonArrayQueryConstructor, JsonAggConstructor, JsonObjectAgg, JsonArrayAgg, RawStmt, InsertStmt, DeleteStmt, UpdateStmt, MergeStmt, SelectStmt, SetOperationStmt, ReturnStmt, PLAssignStmt, CreateSchemaStmt, AlterTableStmt, ReplicaIdentityStmt, AlterTableCmd, AlterCollationStmt, AlterDomainStmt, GrantStmt, ObjectWithArgs, AccessPriv, GrantRoleStmt, AlterDefaultPrivilegesStmt, CopyStmt, VariableSetStmt, VariableShowStmt, CreateStmt, Constraint, CreateTableSpaceStmt, DropTableSpaceStmt, AlterTableSpaceOptionsStmt, AlterTableMoveAllStmt, CreateExtensionStmt, AlterExtensionStmt, AlterExtensionContentsStmt, CreateFdwStmt, AlterFdwStmt, CreateForeignServerStmt, AlterForeignServerStmt, CreateForeignTableStmt, CreateUserMappingStmt, AlterUserMappingStmt, DropUserMappingStmt, ImportForeignSchemaStmt, CreatePolicyStmt, AlterPolicyStmt, CreateAmStmt, CreateTrigStmt, CreateEventTrigStmt, AlterEventTrigStmt, CreatePLangStmt, CreateRoleStmt, AlterRoleStmt, AlterRoleSetStmt, DropRoleStmt, CreateSeqStmt, AlterSeqStmt, DefineStmt, CreateDomainStmt, CreateOpClassStmt, CreateOpClassItem, CreateOpFamilyStmt, AlterOpFamilyStmt, DropStmt, TruncateStmt, CommentStmt, SecLabelStmt, DeclareCursorStmt, ClosePortalStmt, FetchStmt, IndexStmt, CreateStatsStmt, StatsElem, AlterStatsStmt, CreateFunctionStmt, FunctionParameter, AlterFunctionStmt, DoStmt, InlineCodeBlock, CallStmt, CallContext, RenameStmt, AlterObjectDependsStmt, AlterObjectSchemaStmt, AlterOwnerStmt, AlterOperatorStmt, AlterTypeStmt, RuleStmt, NotifyStmt, ListenStmt, UnlistenStmt, TransactionStmt, CompositeTypeStmt, CreateEnumStmt, CreateRangeStmt, AlterEnumStmt, ViewStmt, LoadStmt, CreatedbStmt, AlterDatabaseStmt, AlterDatabaseRefreshCollStmt, AlterDatabaseSetStmt, DropdbStmt, AlterSystemStmt, ClusterStmt, VacuumStmt, VacuumRelation, ExplainStmt, CreateTableAsStmt, RefreshMatViewStmt, CheckPointStmt, DiscardStmt, LockStmt, ConstraintsSetStmt, ReindexStmt, CreateConversionStmt, CreateCastStmt, CreateTransformStmt, PrepareStmt, ExecuteStmt, DeallocateStmt, DropOwnedStmt, ReassignOwnedStmt, AlterTSDictionaryStmt, AlterTSConfigurationStmt, PublicationTable, PublicationObjSpec, CreatePublicationStmt, AlterPublicationStmt, CreateSubscriptionStmt, AlterSubscriptionStmt, DropSubscriptionStmt, ScanToken } from "@pgsql/types"; +export default { + parseResult(_p?: ParseResult): { + ParseResult: ParseResult; + } { + const _j = {} as ParseResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "stmts", _p?.stmts); + return { + ParseResult: _j + }; + }, + scanResult(_p?: ScanResult): { + ScanResult: ScanResult; + } { + const _j = {} as ScanResult; + _o.set(_j, "version", _p?.version); + _o.set(_j, "tokens", _p?.tokens); + return { + ScanResult: _j + }; + }, + integer(_p?: Integer): { + Integer: Integer; + } { + const _j = {} as Integer; + _o.set(_j, "ival", _p?.ival); + return { + Integer: _j + }; + }, + float(_p?: Float): { + Float: Float; + } { + const _j = {} as Float; + _o.set(_j, "fval", _p?.fval); + return { + Float: _j + }; + }, + boolean(_p?: Boolean): { + Boolean: Boolean; + } { + const _j = {} as Boolean; + _o.set(_j, "boolval", _p?.boolval); + return { + Boolean: _j + }; + }, + string(_p?: String): { + String: String; + } { + const _j = {} as String; + _o.set(_j, "sval", _p?.sval); + return { + String: _j + }; + }, + bitString(_p?: BitString): { + BitString: BitString; + } { + const _j = {} as BitString; + _o.set(_j, "bsval", _p?.bsval); + return { + BitString: _j + }; + }, + list(_p?: List): { + List: List; + } { + const _j = {} as List; + _o.set(_j, "items", _p?.items); + return { + List: _j + }; + }, + oidList(_p?: OidList): { + OidList: OidList; + } { + const _j = {} as OidList; + _o.set(_j, "items", _p?.items); + return { + OidList: _j + }; + }, + intList(_p?: IntList): { + IntList: IntList; + } { + const _j = {} as IntList; + _o.set(_j, "items", _p?.items); + return { + IntList: _j + }; + }, + aConst(_p?: A_Const): { + A_Const: A_Const; + } { + const _j = {} as A_Const; + _o.set(_j, "ival", _p?.ival); + _o.set(_j, "fval", _p?.fval); + _o.set(_j, "boolval", _p?.boolval); + _o.set(_j, "sval", _p?.sval); + _o.set(_j, "bsval", _p?.bsval); + _o.set(_j, "isnull", _p?.isnull); + _o.set(_j, "location", _p?.location); + return { + A_Const: _j + }; + }, + alias(_p?: Alias): { + Alias: Alias; + } { + const _j = {} as Alias; + _o.set(_j, "aliasname", _p?.aliasname); + _o.set(_j, "colnames", _p?.colnames); + return { + Alias: _j + }; + }, + rangeVar(_p?: RangeVar): { + RangeVar: RangeVar; + } { + const _j = {} as RangeVar; + _o.set(_j, "catalogname", _p?.catalogname); + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relpersistence", _p?.relpersistence); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeVar: _j + }; + }, + tableFunc(_p?: TableFunc): { + TableFunc: TableFunc; + } { + const _j = {} as TableFunc; + _o.set(_j, "functype", _p?.functype); + _o.set(_j, "ns_uris", _p?.ns_uris); + _o.set(_j, "ns_names", _p?.ns_names); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "colexprs", _p?.colexprs); + _o.set(_j, "coldefexprs", _p?.coldefexprs); + _o.set(_j, "colvalexprs", _p?.colvalexprs); + _o.set(_j, "passingvalexprs", _p?.passingvalexprs); + _o.set(_j, "notnulls", _p?.notnulls); + _o.set(_j, "plan", _p?.plan); + _o.set(_j, "ordinalitycol", _p?.ordinalitycol); + _o.set(_j, "location", _p?.location); + return { + TableFunc: _j + }; + }, + intoClause(_p?: IntoClause): { + IntoClause: IntoClause; + } { + const _j = {} as IntoClause; + _o.set(_j, "rel", _p?.rel); + _o.set(_j, "colNames", _p?.colNames); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "options", _p?.options); + _o.set(_j, "onCommit", _p?.onCommit); + _o.set(_j, "tableSpaceName", _p?.tableSpaceName); + _o.set(_j, "viewQuery", _p?.viewQuery); + _o.set(_j, "skipData", _p?.skipData); + return { + IntoClause: _j + }; + }, + var(_p?: Var): { + Var: Var; + } { + const _j = {} as Var; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "varno", _p?.varno); + _o.set(_j, "varattno", _p?.varattno); + _o.set(_j, "vartype", _p?.vartype); + _o.set(_j, "vartypmod", _p?.vartypmod); + _o.set(_j, "varcollid", _p?.varcollid); + _o.set(_j, "varnullingrels", _p?.varnullingrels); + _o.set(_j, "varlevelsup", _p?.varlevelsup); + _o.set(_j, "location", _p?.location); + return { + Var: _j + }; + }, + param(_p?: Param): { + Param: Param; + } { + const _j = {} as Param; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "paramkind", _p?.paramkind); + _o.set(_j, "paramid", _p?.paramid); + _o.set(_j, "paramtype", _p?.paramtype); + _o.set(_j, "paramtypmod", _p?.paramtypmod); + _o.set(_j, "paramcollid", _p?.paramcollid); + _o.set(_j, "location", _p?.location); + return { + Param: _j + }; + }, + aggref(_p?: Aggref): { + Aggref: Aggref; + } { + const _j = {} as Aggref; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "aggfnoid", _p?.aggfnoid); + _o.set(_j, "aggtype", _p?.aggtype); + _o.set(_j, "aggcollid", _p?.aggcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "aggargtypes", _p?.aggargtypes); + _o.set(_j, "aggdirectargs", _p?.aggdirectargs); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggorder", _p?.aggorder); + _o.set(_j, "aggdistinct", _p?.aggdistinct); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "aggstar", _p?.aggstar); + _o.set(_j, "aggvariadic", _p?.aggvariadic); + _o.set(_j, "aggkind", _p?.aggkind); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "aggsplit", _p?.aggsplit); + _o.set(_j, "aggno", _p?.aggno); + _o.set(_j, "aggtransno", _p?.aggtransno); + _o.set(_j, "location", _p?.location); + return { + Aggref: _j + }; + }, + groupingFunc(_p?: GroupingFunc): { + GroupingFunc: GroupingFunc; + } { + const _j = {} as GroupingFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "refs", _p?.refs); + _o.set(_j, "agglevelsup", _p?.agglevelsup); + _o.set(_j, "location", _p?.location); + return { + GroupingFunc: _j + }; + }, + windowFunc(_p?: WindowFunc): { + WindowFunc: WindowFunc; + } { + const _j = {} as WindowFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "winfnoid", _p?.winfnoid); + _o.set(_j, "wintype", _p?.wintype); + _o.set(_j, "wincollid", _p?.wincollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "aggfilter", _p?.aggfilter); + _o.set(_j, "runCondition", _p?.runCondition); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "winstar", _p?.winstar); + _o.set(_j, "winagg", _p?.winagg); + _o.set(_j, "location", _p?.location); + return { + WindowFunc: _j + }; + }, + windowFuncRunCondition(_p?: WindowFuncRunCondition): { + WindowFuncRunCondition: WindowFuncRunCondition; + } { + const _j = {} as WindowFuncRunCondition; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "wfunc_left", _p?.wfunc_left); + _o.set(_j, "arg", _p?.arg); + return { + WindowFuncRunCondition: _j + }; + }, + mergeSupportFunc(_p?: MergeSupportFunc): { + MergeSupportFunc: MergeSupportFunc; + } { + const _j = {} as MergeSupportFunc; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "msftype", _p?.msftype); + _o.set(_j, "msfcollid", _p?.msfcollid); + _o.set(_j, "location", _p?.location); + return { + MergeSupportFunc: _j + }; + }, + subscriptingRef(_p?: SubscriptingRef): { + SubscriptingRef: SubscriptingRef; + } { + const _j = {} as SubscriptingRef; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "refcontainertype", _p?.refcontainertype); + _o.set(_j, "refelemtype", _p?.refelemtype); + _o.set(_j, "refrestype", _p?.refrestype); + _o.set(_j, "reftypmod", _p?.reftypmod); + _o.set(_j, "refcollid", _p?.refcollid); + _o.set(_j, "refupperindexpr", _p?.refupperindexpr); + _o.set(_j, "reflowerindexpr", _p?.reflowerindexpr); + _o.set(_j, "refexpr", _p?.refexpr); + _o.set(_j, "refassgnexpr", _p?.refassgnexpr); + return { + SubscriptingRef: _j + }; + }, + funcExpr(_p?: FuncExpr): { + FuncExpr: FuncExpr; + } { + const _j = {} as FuncExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "funcid", _p?.funcid); + _o.set(_j, "funcresulttype", _p?.funcresulttype); + _o.set(_j, "funcretset", _p?.funcretset); + _o.set(_j, "funcvariadic", _p?.funcvariadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "funccollid", _p?.funccollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + FuncExpr: _j + }; + }, + namedArgExpr(_p?: NamedArgExpr): { + NamedArgExpr: NamedArgExpr; + } { + const _j = {} as NamedArgExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "name", _p?.name); + _o.set(_j, "argnumber", _p?.argnumber); + _o.set(_j, "location", _p?.location); + return { + NamedArgExpr: _j + }; + }, + opExpr(_p?: OpExpr): { + OpExpr: OpExpr; + } { + const _j = {} as OpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + OpExpr: _j + }; + }, + distinctExpr(_p?: DistinctExpr): { + DistinctExpr: DistinctExpr; + } { + const _j = {} as DistinctExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + DistinctExpr: _j + }; + }, + nullIfExpr(_p?: NullIfExpr): { + NullIfExpr: NullIfExpr; + } { + const _j = {} as NullIfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "opresulttype", _p?.opresulttype); + _o.set(_j, "opretset", _p?.opretset); + _o.set(_j, "opcollid", _p?.opcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + NullIfExpr: _j + }; + }, + scalarArrayOpExpr(_p?: ScalarArrayOpExpr): { + ScalarArrayOpExpr: ScalarArrayOpExpr; + } { + const _j = {} as ScalarArrayOpExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "opno", _p?.opno); + _o.set(_j, "useOr", _p?.useOr); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + ScalarArrayOpExpr: _j + }; + }, + boolExpr(_p?: BoolExpr): { + BoolExpr: BoolExpr; + } { + const _j = {} as BoolExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "boolop", _p?.boolop); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + BoolExpr: _j + }; + }, + subLink(_p?: SubLink): { + SubLink: SubLink; + } { + const _j = {} as SubLink; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "subLinkId", _p?.subLinkId); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "operName", _p?.operName); + _o.set(_j, "subselect", _p?.subselect); + _o.set(_j, "location", _p?.location); + return { + SubLink: _j + }; + }, + subPlan(_p?: SubPlan): { + SubPlan: SubPlan; + } { + const _j = {} as SubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subLinkType", _p?.subLinkType); + _o.set(_j, "testexpr", _p?.testexpr); + _o.set(_j, "paramIds", _p?.paramIds); + _o.set(_j, "plan_id", _p?.plan_id); + _o.set(_j, "plan_name", _p?.plan_name); + _o.set(_j, "firstColType", _p?.firstColType); + _o.set(_j, "firstColTypmod", _p?.firstColTypmod); + _o.set(_j, "firstColCollation", _p?.firstColCollation); + _o.set(_j, "useHashTable", _p?.useHashTable); + _o.set(_j, "unknownEqFalse", _p?.unknownEqFalse); + _o.set(_j, "parallel_safe", _p?.parallel_safe); + _o.set(_j, "setParam", _p?.setParam); + _o.set(_j, "parParam", _p?.parParam); + _o.set(_j, "args", _p?.args); + _o.set(_j, "startup_cost", _p?.startup_cost); + _o.set(_j, "per_call_cost", _p?.per_call_cost); + return { + SubPlan: _j + }; + }, + alternativeSubPlan(_p?: AlternativeSubPlan): { + AlternativeSubPlan: AlternativeSubPlan; + } { + const _j = {} as AlternativeSubPlan; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "subplans", _p?.subplans); + return { + AlternativeSubPlan: _j + }; + }, + fieldSelect(_p?: FieldSelect): { + FieldSelect: FieldSelect; + } { + const _j = {} as FieldSelect; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "fieldnum", _p?.fieldnum); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + return { + FieldSelect: _j + }; + }, + fieldStore(_p?: FieldStore): { + FieldStore: FieldStore; + } { + const _j = {} as FieldStore; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "newvals", _p?.newvals); + _o.set(_j, "fieldnums", _p?.fieldnums); + _o.set(_j, "resulttype", _p?.resulttype); + return { + FieldStore: _j + }; + }, + relabelType(_p?: RelabelType): { + RelabelType: RelabelType; + } { + const _j = {} as RelabelType; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "relabelformat", _p?.relabelformat); + _o.set(_j, "location", _p?.location); + return { + RelabelType: _j + }; + }, + coerceViaio(_p?: CoerceViaIO): { + CoerceViaIO: CoerceViaIO; + } { + const _j = {} as CoerceViaIO; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + CoerceViaIO: _j + }; + }, + arrayCoerceExpr(_p?: ArrayCoerceExpr): { + ArrayCoerceExpr: ArrayCoerceExpr; + } { + const _j = {} as ArrayCoerceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "elemexpr", _p?.elemexpr); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coerceformat", _p?.coerceformat); + _o.set(_j, "location", _p?.location); + return { + ArrayCoerceExpr: _j + }; + }, + convertRowtypeExpr(_p?: ConvertRowtypeExpr): { + ConvertRowtypeExpr: ConvertRowtypeExpr; + } { + const _j = {} as ConvertRowtypeExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "convertformat", _p?.convertformat); + _o.set(_j, "location", _p?.location); + return { + ConvertRowtypeExpr: _j + }; + }, + collateExpr(_p?: CollateExpr): { + CollateExpr: CollateExpr; + } { + const _j = {} as CollateExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "location", _p?.location); + return { + CollateExpr: _j + }; + }, + caseExpr(_p?: CaseExpr): { + CaseExpr: CaseExpr; + } { + const _j = {} as CaseExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "casetype", _p?.casetype); + _o.set(_j, "casecollid", _p?.casecollid); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "args", _p?.args); + _o.set(_j, "defresult", _p?.defresult); + _o.set(_j, "location", _p?.location); + return { + CaseExpr: _j + }; + }, + caseWhen(_p?: CaseWhen): { + CaseWhen: CaseWhen; + } { + const _j = {} as CaseWhen; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "result", _p?.result); + _o.set(_j, "location", _p?.location); + return { + CaseWhen: _j + }; + }, + caseTestExpr(_p?: CaseTestExpr): { + CaseTestExpr: CaseTestExpr; + } { + const _j = {} as CaseTestExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + return { + CaseTestExpr: _j + }; + }, + arrayExpr(_p?: ArrayExpr): { + ArrayExpr: ArrayExpr; + } { + const _j = {} as ArrayExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "array_typeid", _p?.array_typeid); + _o.set(_j, "array_collid", _p?.array_collid); + _o.set(_j, "element_typeid", _p?.element_typeid); + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "multidims", _p?.multidims); + _o.set(_j, "location", _p?.location); + return { + ArrayExpr: _j + }; + }, + rowExpr(_p?: RowExpr): { + RowExpr: RowExpr; + } { + const _j = {} as RowExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row_typeid", _p?.row_typeid); + _o.set(_j, "row_format", _p?.row_format); + _o.set(_j, "colnames", _p?.colnames); + _o.set(_j, "location", _p?.location); + return { + RowExpr: _j + }; + }, + rowCompareExpr(_p?: RowCompareExpr): { + RowCompareExpr: RowCompareExpr; + } { + const _j = {} as RowCompareExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "rctype", _p?.rctype); + _o.set(_j, "opnos", _p?.opnos); + _o.set(_j, "opfamilies", _p?.opfamilies); + _o.set(_j, "inputcollids", _p?.inputcollids); + _o.set(_j, "largs", _p?.largs); + _o.set(_j, "rargs", _p?.rargs); + return { + RowCompareExpr: _j + }; + }, + coalesceExpr(_p?: CoalesceExpr): { + CoalesceExpr: CoalesceExpr; + } { + const _j = {} as CoalesceExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "coalescetype", _p?.coalescetype); + _o.set(_j, "coalescecollid", _p?.coalescecollid); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + CoalesceExpr: _j + }; + }, + minMaxExpr(_p?: MinMaxExpr): { + MinMaxExpr: MinMaxExpr; + } { + const _j = {} as MinMaxExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "minmaxtype", _p?.minmaxtype); + _o.set(_j, "minmaxcollid", _p?.minmaxcollid); + _o.set(_j, "inputcollid", _p?.inputcollid); + _o.set(_j, "op", _p?.op); + _o.set(_j, "args", _p?.args); + _o.set(_j, "location", _p?.location); + return { + MinMaxExpr: _j + }; + }, + sqlValueFunction(_p?: SQLValueFunction): { + SQLValueFunction: SQLValueFunction; + } { + const _j = {} as SQLValueFunction; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + SQLValueFunction: _j + }; + }, + xmlExpr(_p?: XmlExpr): { + XmlExpr: XmlExpr; + } { + const _j = {} as XmlExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "name", _p?.name); + _o.set(_j, "named_args", _p?.named_args); + _o.set(_j, "arg_names", _p?.arg_names); + _o.set(_j, "args", _p?.args); + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "type", _p?.type); + _o.set(_j, "typmod", _p?.typmod); + _o.set(_j, "location", _p?.location); + return { + XmlExpr: _j + }; + }, + jsonFormat(_p?: JsonFormat): { + JsonFormat: JsonFormat; + } { + const _j = {} as JsonFormat; + _o.set(_j, "format_type", _p?.format_type); + _o.set(_j, "encoding", _p?.encoding); + _o.set(_j, "location", _p?.location); + return { + JsonFormat: _j + }; + }, + jsonReturning(_p?: JsonReturning): { + JsonReturning: JsonReturning; + } { + const _j = {} as JsonReturning; + _o.set(_j, "format", _p?.format); + _o.set(_j, "typid", _p?.typid); + _o.set(_j, "typmod", _p?.typmod); + return { + JsonReturning: _j + }; + }, + jsonValueExpr(_p?: JsonValueExpr): { + JsonValueExpr: JsonValueExpr; + } { + const _j = {} as JsonValueExpr; + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + return { + JsonValueExpr: _j + }; + }, + jsonConstructorExpr(_p?: JsonConstructorExpr): { + JsonConstructorExpr: JsonConstructorExpr; + } { + const _j = {} as JsonConstructorExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "type", _p?.type); + _o.set(_j, "args", _p?.args); + _o.set(_j, "func", _p?.func); + _o.set(_j, "coercion", _p?.coercion); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonConstructorExpr: _j + }; + }, + jsonIsPredicate(_p?: JsonIsPredicate): { + JsonIsPredicate: JsonIsPredicate; + } { + const _j = {} as JsonIsPredicate; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "item_type", _p?.item_type); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonIsPredicate: _j + }; + }, + jsonBehavior(_p?: JsonBehavior): { + JsonBehavior: JsonBehavior; + } { + const _j = {} as JsonBehavior; + _o.set(_j, "btype", _p?.btype); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "coerce", _p?.coerce); + _o.set(_j, "location", _p?.location); + return { + JsonBehavior: _j + }; + }, + jsonExpr(_p?: JsonExpr): { + JsonExpr: JsonExpr; + } { + const _j = {} as JsonExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "op", _p?.op); + _o.set(_j, "column_name", _p?.column_name); + _o.set(_j, "formatted_expr", _p?.formatted_expr); + _o.set(_j, "format", _p?.format); + _o.set(_j, "path_spec", _p?.path_spec); + _o.set(_j, "returning", _p?.returning); + _o.set(_j, "passing_names", _p?.passing_names); + _o.set(_j, "passing_values", _p?.passing_values); + _o.set(_j, "on_empty", _p?.on_empty); + _o.set(_j, "on_error", _p?.on_error); + _o.set(_j, "use_io_coercion", _p?.use_io_coercion); + _o.set(_j, "use_json_coercion", _p?.use_json_coercion); + _o.set(_j, "wrapper", _p?.wrapper); + _o.set(_j, "omit_quotes", _p?.omit_quotes); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + JsonExpr: _j + }; + }, + jsonTablePath(_p?: JsonTablePath): { + JsonTablePath: JsonTablePath; + } { + const _j = {} as JsonTablePath; + _o.set(_j, "name", _p?.name); + return { + JsonTablePath: _j + }; + }, + jsonTablePathScan(_p?: JsonTablePathScan): { + JsonTablePathScan: JsonTablePathScan; + } { + const _j = {} as JsonTablePathScan; + _o.set(_j, "plan", _p?.plan); + _o.set(_j, "path", _p?.path); + _o.set(_j, "errorOnError", _p?.errorOnError); + _o.set(_j, "child", _p?.child); + _o.set(_j, "colMin", _p?.colMin); + _o.set(_j, "colMax", _p?.colMax); + return { + JsonTablePathScan: _j + }; + }, + jsonTableSiblingJoin(_p?: JsonTableSiblingJoin): { + JsonTableSiblingJoin: JsonTableSiblingJoin; + } { + const _j = {} as JsonTableSiblingJoin; + _o.set(_j, "plan", _p?.plan); + _o.set(_j, "lplan", _p?.lplan); + _o.set(_j, "rplan", _p?.rplan); + return { + JsonTableSiblingJoin: _j + }; + }, + nullTest(_p?: NullTest): { + NullTest: NullTest; + } { + const _j = {} as NullTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "nulltesttype", _p?.nulltesttype); + _o.set(_j, "argisrow", _p?.argisrow); + _o.set(_j, "location", _p?.location); + return { + NullTest: _j + }; + }, + booleanTest(_p?: BooleanTest): { + BooleanTest: BooleanTest; + } { + const _j = {} as BooleanTest; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "booltesttype", _p?.booltesttype); + _o.set(_j, "location", _p?.location); + return { + BooleanTest: _j + }; + }, + mergeAction(_p?: MergeAction): { + MergeAction: MergeAction; + } { + const _j = {} as MergeAction; + _o.set(_j, "matchKind", _p?.matchKind); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "updateColnos", _p?.updateColnos); + return { + MergeAction: _j + }; + }, + coerceToDomain(_p?: CoerceToDomain): { + CoerceToDomain: CoerceToDomain; + } { + const _j = {} as CoerceToDomain; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "resulttype", _p?.resulttype); + _o.set(_j, "resulttypmod", _p?.resulttypmod); + _o.set(_j, "resultcollid", _p?.resultcollid); + _o.set(_j, "coercionformat", _p?.coercionformat); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomain: _j + }; + }, + coerceToDomainValue(_p?: CoerceToDomainValue): { + CoerceToDomainValue: CoerceToDomainValue; + } { + const _j = {} as CoerceToDomainValue; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + CoerceToDomainValue: _j + }; + }, + setToDefault(_p?: SetToDefault): { + SetToDefault: SetToDefault; + } { + const _j = {} as SetToDefault; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "typeId", _p?.typeId); + _o.set(_j, "typeMod", _p?.typeMod); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "location", _p?.location); + return { + SetToDefault: _j + }; + }, + currentOfExpr(_p?: CurrentOfExpr): { + CurrentOfExpr: CurrentOfExpr; + } { + const _j = {} as CurrentOfExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "cvarno", _p?.cvarno); + _o.set(_j, "cursor_name", _p?.cursor_name); + _o.set(_j, "cursor_param", _p?.cursor_param); + return { + CurrentOfExpr: _j + }; + }, + nextValueExpr(_p?: NextValueExpr): { + NextValueExpr: NextValueExpr; + } { + const _j = {} as NextValueExpr; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "seqid", _p?.seqid); + _o.set(_j, "typeId", _p?.typeId); + return { + NextValueExpr: _j + }; + }, + inferenceElem(_p?: InferenceElem): { + InferenceElem: InferenceElem; + } { + const _j = {} as InferenceElem; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "infercollid", _p?.infercollid); + _o.set(_j, "inferopclass", _p?.inferopclass); + return { + InferenceElem: _j + }; + }, + targetEntry(_p?: TargetEntry): { + TargetEntry: TargetEntry; + } { + const _j = {} as TargetEntry; + _o.set(_j, "xpr", _p?.xpr); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "resno", _p?.resno); + _o.set(_j, "resname", _p?.resname); + _o.set(_j, "ressortgroupref", _p?.ressortgroupref); + _o.set(_j, "resorigtbl", _p?.resorigtbl); + _o.set(_j, "resorigcol", _p?.resorigcol); + _o.set(_j, "resjunk", _p?.resjunk); + return { + TargetEntry: _j + }; + }, + rangeTblRef(_p?: RangeTblRef): { + RangeTblRef: RangeTblRef; + } { + const _j = {} as RangeTblRef; + _o.set(_j, "rtindex", _p?.rtindex); + return { + RangeTblRef: _j + }; + }, + joinExpr(_p?: JoinExpr): { + JoinExpr: JoinExpr; + } { + const _j = {} as JoinExpr; + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "isNatural", _p?.isNatural); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "quals", _p?.quals); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "rtindex", _p?.rtindex); + return { + JoinExpr: _j + }; + }, + fromExpr(_p?: FromExpr): { + FromExpr: FromExpr; + } { + const _j = {} as FromExpr; + _o.set(_j, "fromlist", _p?.fromlist); + _o.set(_j, "quals", _p?.quals); + return { + FromExpr: _j + }; + }, + onConflictExpr(_p?: OnConflictExpr): { + OnConflictExpr: OnConflictExpr; + } { + const _j = {} as OnConflictExpr; + _o.set(_j, "action", _p?.action); + _o.set(_j, "arbiterElems", _p?.arbiterElems); + _o.set(_j, "arbiterWhere", _p?.arbiterWhere); + _o.set(_j, "constraint", _p?.constraint); + _o.set(_j, "onConflictSet", _p?.onConflictSet); + _o.set(_j, "onConflictWhere", _p?.onConflictWhere); + _o.set(_j, "exclRelIndex", _p?.exclRelIndex); + _o.set(_j, "exclRelTlist", _p?.exclRelTlist); + return { + OnConflictExpr: _j + }; + }, + query(_p?: Query): { + Query: Query; + } { + const _j = {} as Query; + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "querySource", _p?.querySource); + _o.set(_j, "canSetTag", _p?.canSetTag); + _o.set(_j, "utilityStmt", _p?.utilityStmt); + _o.set(_j, "resultRelation", _p?.resultRelation); + _o.set(_j, "hasAggs", _p?.hasAggs); + _o.set(_j, "hasWindowFuncs", _p?.hasWindowFuncs); + _o.set(_j, "hasTargetSRFs", _p?.hasTargetSRFs); + _o.set(_j, "hasSubLinks", _p?.hasSubLinks); + _o.set(_j, "hasDistinctOn", _p?.hasDistinctOn); + _o.set(_j, "hasRecursive", _p?.hasRecursive); + _o.set(_j, "hasModifyingCTE", _p?.hasModifyingCTE); + _o.set(_j, "hasForUpdate", _p?.hasForUpdate); + _o.set(_j, "hasRowSecurity", _p?.hasRowSecurity); + _o.set(_j, "isReturn", _p?.isReturn); + _o.set(_j, "cteList", _p?.cteList); + _o.set(_j, "rtable", _p?.rtable); + _o.set(_j, "rteperminfos", _p?.rteperminfos); + _o.set(_j, "jointree", _p?.jointree); + _o.set(_j, "mergeActionList", _p?.mergeActionList); + _o.set(_j, "mergeTargetRelation", _p?.mergeTargetRelation); + _o.set(_j, "mergeJoinCondition", _p?.mergeJoinCondition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "override", _p?.override); + _o.set(_j, "onConflict", _p?.onConflict); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "groupingSets", _p?.groupingSets); + _o.set(_j, "havingQual", _p?.havingQual); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "rowMarks", _p?.rowMarks); + _o.set(_j, "setOperations", _p?.setOperations); + _o.set(_j, "constraintDeps", _p?.constraintDeps); + _o.set(_j, "withCheckOptions", _p?.withCheckOptions); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + Query: _j + }; + }, + typeName(_p?: TypeName): { + TypeName: TypeName; + } { + const _j = {} as TypeName; + _o.set(_j, "names", _p?.names); + _o.set(_j, "typeOid", _p?.typeOid); + _o.set(_j, "setof", _p?.setof); + _o.set(_j, "pct_type", _p?.pct_type); + _o.set(_j, "typmods", _p?.typmods); + _o.set(_j, "typemod", _p?.typemod); + _o.set(_j, "arrayBounds", _p?.arrayBounds); + _o.set(_j, "location", _p?.location); + return { + TypeName: _j + }; + }, + columnRef(_p?: ColumnRef): { + ColumnRef: ColumnRef; + } { + const _j = {} as ColumnRef; + _o.set(_j, "fields", _p?.fields); + _o.set(_j, "location", _p?.location); + return { + ColumnRef: _j + }; + }, + paramRef(_p?: ParamRef): { + ParamRef: ParamRef; + } { + const _j = {} as ParamRef; + _o.set(_j, "number", _p?.number); + _o.set(_j, "location", _p?.location); + return { + ParamRef: _j + }; + }, + aExpr(_p?: A_Expr): { + A_Expr: A_Expr; + } { + const _j = {} as A_Expr; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "lexpr", _p?.lexpr); + _o.set(_j, "rexpr", _p?.rexpr); + _o.set(_j, "location", _p?.location); + return { + A_Expr: _j + }; + }, + typeCast(_p?: TypeCast): { + TypeCast: TypeCast; + } { + const _j = {} as TypeCast; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "location", _p?.location); + return { + TypeCast: _j + }; + }, + collateClause(_p?: CollateClause): { + CollateClause: CollateClause; + } { + const _j = {} as CollateClause; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "collname", _p?.collname); + _o.set(_j, "location", _p?.location); + return { + CollateClause: _j + }; + }, + roleSpec(_p?: RoleSpec): { + RoleSpec: RoleSpec; + } { + const _j = {} as RoleSpec; + _o.set(_j, "roletype", _p?.roletype); + _o.set(_j, "rolename", _p?.rolename); + _o.set(_j, "location", _p?.location); + return { + RoleSpec: _j + }; + }, + funcCall(_p?: FuncCall): { + FuncCall: FuncCall; + } { + const _j = {} as FuncCall; + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "over", _p?.over); + _o.set(_j, "agg_within_group", _p?.agg_within_group); + _o.set(_j, "agg_star", _p?.agg_star); + _o.set(_j, "agg_distinct", _p?.agg_distinct); + _o.set(_j, "func_variadic", _p?.func_variadic); + _o.set(_j, "funcformat", _p?.funcformat); + _o.set(_j, "location", _p?.location); + return { + FuncCall: _j + }; + }, + aStar(_p?: A_Star): { + A_Star: A_Star; + } { + const _j = {} as A_Star; + return { + A_Star: _j + }; + }, + aIndices(_p?: A_Indices): { + A_Indices: A_Indices; + } { + const _j = {} as A_Indices; + _o.set(_j, "is_slice", _p?.is_slice); + _o.set(_j, "lidx", _p?.lidx); + _o.set(_j, "uidx", _p?.uidx); + return { + A_Indices: _j + }; + }, + aIndirection(_p?: A_Indirection): { + A_Indirection: A_Indirection; + } { + const _j = {} as A_Indirection; + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "indirection", _p?.indirection); + return { + A_Indirection: _j + }; + }, + aArrayExpr(_p?: A_ArrayExpr): { + A_ArrayExpr: A_ArrayExpr; + } { + const _j = {} as A_ArrayExpr; + _o.set(_j, "elements", _p?.elements); + _o.set(_j, "location", _p?.location); + return { + A_ArrayExpr: _j + }; + }, + resTarget(_p?: ResTarget): { + ResTarget: ResTarget; + } { + const _j = {} as ResTarget; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + ResTarget: _j + }; + }, + multiAssignRef(_p?: MultiAssignRef): { + MultiAssignRef: MultiAssignRef; + } { + const _j = {} as MultiAssignRef; + _o.set(_j, "source", _p?.source); + _o.set(_j, "colno", _p?.colno); + _o.set(_j, "ncolumns", _p?.ncolumns); + return { + MultiAssignRef: _j + }; + }, + sortBy(_p?: SortBy): { + SortBy: SortBy; + } { + const _j = {} as SortBy; + _o.set(_j, "node", _p?.node); + _o.set(_j, "sortby_dir", _p?.sortby_dir); + _o.set(_j, "sortby_nulls", _p?.sortby_nulls); + _o.set(_j, "useOp", _p?.useOp); + _o.set(_j, "location", _p?.location); + return { + SortBy: _j + }; + }, + windowDef(_p?: WindowDef): { + WindowDef: WindowDef; + } { + const _j = {} as WindowDef; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "location", _p?.location); + return { + WindowDef: _j + }; + }, + rangeSubselect(_p?: RangeSubselect): { + RangeSubselect: RangeSubselect; + } { + const _j = {} as RangeSubselect; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "alias", _p?.alias); + return { + RangeSubselect: _j + }; + }, + rangeFunction(_p?: RangeFunction): { + RangeFunction: RangeFunction; + } { + const _j = {} as RangeFunction; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "ordinality", _p?.ordinality); + _o.set(_j, "is_rowsfrom", _p?.is_rowsfrom); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + RangeFunction: _j + }; + }, + rangeTableFunc(_p?: RangeTableFunc): { + RangeTableFunc: RangeTableFunc; + } { + const _j = {} as RangeTableFunc; + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "docexpr", _p?.docexpr); + _o.set(_j, "rowexpr", _p?.rowexpr); + _o.set(_j, "namespaces", _p?.namespaces); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "location", _p?.location); + return { + RangeTableFunc: _j + }; + }, + rangeTableFuncCol(_p?: RangeTableFuncCol): { + RangeTableFuncCol: RangeTableFuncCol; + } { + const _j = {} as RangeTableFuncCol; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "for_ordinality", _p?.for_ordinality); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "colexpr", _p?.colexpr); + _o.set(_j, "coldefexpr", _p?.coldefexpr); + _o.set(_j, "location", _p?.location); + return { + RangeTableFuncCol: _j + }; + }, + rangeTableSample(_p?: RangeTableSample): { + RangeTableSample: RangeTableSample; + } { + const _j = {} as RangeTableSample; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "method", _p?.method); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + _o.set(_j, "location", _p?.location); + return { + RangeTableSample: _j + }; + }, + columnDef(_p?: ColumnDef): { + ColumnDef: ColumnDef; + } { + const _j = {} as ColumnDef; + _o.set(_j, "colname", _p?.colname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "compression", _p?.compression); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "is_local", _p?.is_local); + _o.set(_j, "is_not_null", _p?.is_not_null); + _o.set(_j, "is_from_type", _p?.is_from_type); + _o.set(_j, "storage", _p?.storage); + _o.set(_j, "storage_name", _p?.storage_name); + _o.set(_j, "raw_default", _p?.raw_default); + _o.set(_j, "cooked_default", _p?.cooked_default); + _o.set(_j, "identity", _p?.identity); + _o.set(_j, "identitySequence", _p?.identitySequence); + _o.set(_j, "generated", _p?.generated); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "collOid", _p?.collOid); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "fdwoptions", _p?.fdwoptions); + _o.set(_j, "location", _p?.location); + return { + ColumnDef: _j + }; + }, + tableLikeClause(_p?: TableLikeClause): { + TableLikeClause: TableLikeClause; + } { + const _j = {} as TableLikeClause; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "options", _p?.options); + _o.set(_j, "relationOid", _p?.relationOid); + return { + TableLikeClause: _j + }; + }, + indexElem(_p?: IndexElem): { + IndexElem: IndexElem; + } { + const _j = {} as IndexElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "indexcolname", _p?.indexcolname); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "opclassopts", _p?.opclassopts); + _o.set(_j, "ordering", _p?.ordering); + _o.set(_j, "nulls_ordering", _p?.nulls_ordering); + return { + IndexElem: _j + }; + }, + defElem(_p?: DefElem): { + DefElem: DefElem; + } { + const _j = {} as DefElem; + _o.set(_j, "defnamespace", _p?.defnamespace); + _o.set(_j, "defname", _p?.defname); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "defaction", _p?.defaction); + _o.set(_j, "location", _p?.location); + return { + DefElem: _j + }; + }, + lockingClause(_p?: LockingClause): { + LockingClause: LockingClause; + } { + const _j = {} as LockingClause; + _o.set(_j, "lockedRels", _p?.lockedRels); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + return { + LockingClause: _j + }; + }, + xmlSerialize(_p?: XmlSerialize): { + XmlSerialize: XmlSerialize; + } { + const _j = {} as XmlSerialize; + _o.set(_j, "xmloption", _p?.xmloption); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "indent", _p?.indent); + _o.set(_j, "location", _p?.location); + return { + XmlSerialize: _j + }; + }, + partitionElem(_p?: PartitionElem): { + PartitionElem: PartitionElem; + } { + const _j = {} as PartitionElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "collation", _p?.collation); + _o.set(_j, "opclass", _p?.opclass); + _o.set(_j, "location", _p?.location); + return { + PartitionElem: _j + }; + }, + partitionSpec(_p?: PartitionSpec): { + PartitionSpec: PartitionSpec; + } { + const _j = {} as PartitionSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "partParams", _p?.partParams); + _o.set(_j, "location", _p?.location); + return { + PartitionSpec: _j + }; + }, + partitionBoundSpec(_p?: PartitionBoundSpec): { + PartitionBoundSpec: PartitionBoundSpec; + } { + const _j = {} as PartitionBoundSpec; + _o.set(_j, "strategy", _p?.strategy); + _o.set(_j, "is_default", _p?.is_default); + _o.set(_j, "modulus", _p?.modulus); + _o.set(_j, "remainder", _p?.remainder); + _o.set(_j, "listdatums", _p?.listdatums); + _o.set(_j, "lowerdatums", _p?.lowerdatums); + _o.set(_j, "upperdatums", _p?.upperdatums); + _o.set(_j, "location", _p?.location); + return { + PartitionBoundSpec: _j + }; + }, + partitionRangeDatum(_p?: PartitionRangeDatum): { + PartitionRangeDatum: PartitionRangeDatum; + } { + const _j = {} as PartitionRangeDatum; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "value", _p?.value); + _o.set(_j, "location", _p?.location); + return { + PartitionRangeDatum: _j + }; + }, + singlePartitionSpec(_p?: SinglePartitionSpec): { + SinglePartitionSpec: SinglePartitionSpec; + } { + const _j = {} as SinglePartitionSpec; + return { + SinglePartitionSpec: _j + }; + }, + partitionCmd(_p?: PartitionCmd): { + PartitionCmd: PartitionCmd; + } { + const _j = {} as PartitionCmd; + _o.set(_j, "name", _p?.name); + _o.set(_j, "bound", _p?.bound); + _o.set(_j, "concurrent", _p?.concurrent); + return { + PartitionCmd: _j + }; + }, + rangeTblEntry(_p?: RangeTblEntry): { + RangeTblEntry: RangeTblEntry; + } { + const _j = {} as RangeTblEntry; + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "eref", _p?.eref); + _o.set(_j, "rtekind", _p?.rtekind); + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "relkind", _p?.relkind); + _o.set(_j, "rellockmode", _p?.rellockmode); + _o.set(_j, "perminfoindex", _p?.perminfoindex); + _o.set(_j, "tablesample", _p?.tablesample); + _o.set(_j, "subquery", _p?.subquery); + _o.set(_j, "security_barrier", _p?.security_barrier); + _o.set(_j, "jointype", _p?.jointype); + _o.set(_j, "joinmergedcols", _p?.joinmergedcols); + _o.set(_j, "joinaliasvars", _p?.joinaliasvars); + _o.set(_j, "joinleftcols", _p?.joinleftcols); + _o.set(_j, "joinrightcols", _p?.joinrightcols); + _o.set(_j, "join_using_alias", _p?.join_using_alias); + _o.set(_j, "functions", _p?.functions); + _o.set(_j, "funcordinality", _p?.funcordinality); + _o.set(_j, "tablefunc", _p?.tablefunc); + _o.set(_j, "values_lists", _p?.values_lists); + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "ctelevelsup", _p?.ctelevelsup); + _o.set(_j, "self_reference", _p?.self_reference); + _o.set(_j, "coltypes", _p?.coltypes); + _o.set(_j, "coltypmods", _p?.coltypmods); + _o.set(_j, "colcollations", _p?.colcollations); + _o.set(_j, "enrname", _p?.enrname); + _o.set(_j, "enrtuples", _p?.enrtuples); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "inFromCl", _p?.inFromCl); + _o.set(_j, "securityQuals", _p?.securityQuals); + return { + RangeTblEntry: _j + }; + }, + rtePermissionInfo(_p?: RTEPermissionInfo): { + RTEPermissionInfo: RTEPermissionInfo; + } { + const _j = {} as RTEPermissionInfo; + _o.set(_j, "relid", _p?.relid); + _o.set(_j, "inh", _p?.inh); + _o.set(_j, "requiredPerms", _p?.requiredPerms); + _o.set(_j, "checkAsUser", _p?.checkAsUser); + _o.set(_j, "selectedCols", _p?.selectedCols); + _o.set(_j, "insertedCols", _p?.insertedCols); + _o.set(_j, "updatedCols", _p?.updatedCols); + return { + RTEPermissionInfo: _j + }; + }, + rangeTblFunction(_p?: RangeTblFunction): { + RangeTblFunction: RangeTblFunction; + } { + const _j = {} as RangeTblFunction; + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "funccolcount", _p?.funccolcount); + _o.set(_j, "funccolnames", _p?.funccolnames); + _o.set(_j, "funccoltypes", _p?.funccoltypes); + _o.set(_j, "funccoltypmods", _p?.funccoltypmods); + _o.set(_j, "funccolcollations", _p?.funccolcollations); + _o.set(_j, "funcparams", _p?.funcparams); + return { + RangeTblFunction: _j + }; + }, + tableSampleClause(_p?: TableSampleClause): { + TableSampleClause: TableSampleClause; + } { + const _j = {} as TableSampleClause; + _o.set(_j, "tsmhandler", _p?.tsmhandler); + _o.set(_j, "args", _p?.args); + _o.set(_j, "repeatable", _p?.repeatable); + return { + TableSampleClause: _j + }; + }, + withCheckOption(_p?: WithCheckOption): { + WithCheckOption: WithCheckOption; + } { + const _j = {} as WithCheckOption; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relname", _p?.relname); + _o.set(_j, "polname", _p?.polname); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "cascaded", _p?.cascaded); + return { + WithCheckOption: _j + }; + }, + sortGroupClause(_p?: SortGroupClause): { + SortGroupClause: SortGroupClause; + } { + const _j = {} as SortGroupClause; + _o.set(_j, "tleSortGroupRef", _p?.tleSortGroupRef); + _o.set(_j, "eqop", _p?.eqop); + _o.set(_j, "sortop", _p?.sortop); + _o.set(_j, "nulls_first", _p?.nulls_first); + _o.set(_j, "hashable", _p?.hashable); + return { + SortGroupClause: _j + }; + }, + groupingSet(_p?: GroupingSet): { + GroupingSet: GroupingSet; + } { + const _j = {} as GroupingSet; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "content", _p?.content); + _o.set(_j, "location", _p?.location); + return { + GroupingSet: _j + }; + }, + windowClause(_p?: WindowClause): { + WindowClause: WindowClause; + } { + const _j = {} as WindowClause; + _o.set(_j, "name", _p?.name); + _o.set(_j, "refname", _p?.refname); + _o.set(_j, "partitionClause", _p?.partitionClause); + _o.set(_j, "orderClause", _p?.orderClause); + _o.set(_j, "frameOptions", _p?.frameOptions); + _o.set(_j, "startOffset", _p?.startOffset); + _o.set(_j, "endOffset", _p?.endOffset); + _o.set(_j, "startInRangeFunc", _p?.startInRangeFunc); + _o.set(_j, "endInRangeFunc", _p?.endInRangeFunc); + _o.set(_j, "inRangeColl", _p?.inRangeColl); + _o.set(_j, "inRangeAsc", _p?.inRangeAsc); + _o.set(_j, "inRangeNullsFirst", _p?.inRangeNullsFirst); + _o.set(_j, "winref", _p?.winref); + _o.set(_j, "copiedOrder", _p?.copiedOrder); + return { + WindowClause: _j + }; + }, + rowMarkClause(_p?: RowMarkClause): { + RowMarkClause: RowMarkClause; + } { + const _j = {} as RowMarkClause; + _o.set(_j, "rti", _p?.rti); + _o.set(_j, "strength", _p?.strength); + _o.set(_j, "waitPolicy", _p?.waitPolicy); + _o.set(_j, "pushedDown", _p?.pushedDown); + return { + RowMarkClause: _j + }; + }, + withClause(_p?: WithClause): { + WithClause: WithClause; + } { + const _j = {} as WithClause; + _o.set(_j, "ctes", _p?.ctes); + _o.set(_j, "recursive", _p?.recursive); + _o.set(_j, "location", _p?.location); + return { + WithClause: _j + }; + }, + inferClause(_p?: InferClause): { + InferClause: InferClause; + } { + const _j = {} as InferClause; + _o.set(_j, "indexElems", _p?.indexElems); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "location", _p?.location); + return { + InferClause: _j + }; + }, + onConflictClause(_p?: OnConflictClause): { + OnConflictClause: OnConflictClause; + } { + const _j = {} as OnConflictClause; + _o.set(_j, "action", _p?.action); + _o.set(_j, "infer", _p?.infer); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "location", _p?.location); + return { + OnConflictClause: _j + }; + }, + cteSearchClause(_p?: CTESearchClause): { + CTESearchClause: CTESearchClause; + } { + const _j = {} as CTESearchClause; + _o.set(_j, "search_col_list", _p?.search_col_list); + _o.set(_j, "search_breadth_first", _p?.search_breadth_first); + _o.set(_j, "search_seq_column", _p?.search_seq_column); + _o.set(_j, "location", _p?.location); + return { + CTESearchClause: _j + }; + }, + cteCycleClause(_p?: CTECycleClause): { + CTECycleClause: CTECycleClause; + } { + const _j = {} as CTECycleClause; + _o.set(_j, "cycle_col_list", _p?.cycle_col_list); + _o.set(_j, "cycle_mark_column", _p?.cycle_mark_column); + _o.set(_j, "cycle_mark_value", _p?.cycle_mark_value); + _o.set(_j, "cycle_mark_default", _p?.cycle_mark_default); + _o.set(_j, "cycle_path_column", _p?.cycle_path_column); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cycle_mark_type", _p?.cycle_mark_type); + _o.set(_j, "cycle_mark_typmod", _p?.cycle_mark_typmod); + _o.set(_j, "cycle_mark_collation", _p?.cycle_mark_collation); + _o.set(_j, "cycle_mark_neop", _p?.cycle_mark_neop); + return { + CTECycleClause: _j + }; + }, + commonTableExpr(_p?: CommonTableExpr): { + CommonTableExpr: CommonTableExpr; + } { + const _j = {} as CommonTableExpr; + _o.set(_j, "ctename", _p?.ctename); + _o.set(_j, "aliascolnames", _p?.aliascolnames); + _o.set(_j, "ctematerialized", _p?.ctematerialized); + _o.set(_j, "ctequery", _p?.ctequery); + _o.set(_j, "search_clause", _p?.search_clause); + _o.set(_j, "cycle_clause", _p?.cycle_clause); + _o.set(_j, "location", _p?.location); + _o.set(_j, "cterecursive", _p?.cterecursive); + _o.set(_j, "cterefcount", _p?.cterefcount); + _o.set(_j, "ctecolnames", _p?.ctecolnames); + _o.set(_j, "ctecoltypes", _p?.ctecoltypes); + _o.set(_j, "ctecoltypmods", _p?.ctecoltypmods); + _o.set(_j, "ctecolcollations", _p?.ctecolcollations); + return { + CommonTableExpr: _j + }; + }, + mergeWhenClause(_p?: MergeWhenClause): { + MergeWhenClause: MergeWhenClause; + } { + const _j = {} as MergeWhenClause; + _o.set(_j, "matchKind", _p?.matchKind); + _o.set(_j, "commandType", _p?.commandType); + _o.set(_j, "override", _p?.override); + _o.set(_j, "condition", _p?.condition); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "values", _p?.values); + return { + MergeWhenClause: _j + }; + }, + triggerTransition(_p?: TriggerTransition): { + TriggerTransition: TriggerTransition; + } { + const _j = {} as TriggerTransition; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isNew", _p?.isNew); + _o.set(_j, "isTable", _p?.isTable); + return { + TriggerTransition: _j + }; + }, + jsonOutput(_p?: JsonOutput): { + JsonOutput: JsonOutput; + } { + const _j = {} as JsonOutput; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "returning", _p?.returning); + return { + JsonOutput: _j + }; + }, + jsonArgument(_p?: JsonArgument): { + JsonArgument: JsonArgument; + } { + const _j = {} as JsonArgument; + _o.set(_j, "val", _p?.val); + _o.set(_j, "name", _p?.name); + return { + JsonArgument: _j + }; + }, + jsonFuncExpr(_p?: JsonFuncExpr): { + JsonFuncExpr: JsonFuncExpr; + } { + const _j = {} as JsonFuncExpr; + _o.set(_j, "op", _p?.op); + _o.set(_j, "column_name", _p?.column_name); + _o.set(_j, "context_item", _p?.context_item); + _o.set(_j, "pathspec", _p?.pathspec); + _o.set(_j, "passing", _p?.passing); + _o.set(_j, "output", _p?.output); + _o.set(_j, "on_empty", _p?.on_empty); + _o.set(_j, "on_error", _p?.on_error); + _o.set(_j, "wrapper", _p?.wrapper); + _o.set(_j, "quotes", _p?.quotes); + _o.set(_j, "location", _p?.location); + return { + JsonFuncExpr: _j + }; + }, + jsonTablePathSpec(_p?: JsonTablePathSpec): { + JsonTablePathSpec: JsonTablePathSpec; + } { + const _j = {} as JsonTablePathSpec; + _o.set(_j, "string", _p?.string); + _o.set(_j, "name", _p?.name); + _o.set(_j, "name_location", _p?.name_location); + _o.set(_j, "location", _p?.location); + return { + JsonTablePathSpec: _j + }; + }, + jsonTable(_p?: JsonTable): { + JsonTable: JsonTable; + } { + const _j = {} as JsonTable; + _o.set(_j, "context_item", _p?.context_item); + _o.set(_j, "pathspec", _p?.pathspec); + _o.set(_j, "passing", _p?.passing); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "on_error", _p?.on_error); + _o.set(_j, "alias", _p?.alias); + _o.set(_j, "lateral", _p?.lateral); + _o.set(_j, "location", _p?.location); + return { + JsonTable: _j + }; + }, + jsonTableColumn(_p?: JsonTableColumn): { + JsonTableColumn: JsonTableColumn; + } { + const _j = {} as JsonTableColumn; + _o.set(_j, "coltype", _p?.coltype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "pathspec", _p?.pathspec); + _o.set(_j, "format", _p?.format); + _o.set(_j, "wrapper", _p?.wrapper); + _o.set(_j, "quotes", _p?.quotes); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "on_empty", _p?.on_empty); + _o.set(_j, "on_error", _p?.on_error); + _o.set(_j, "location", _p?.location); + return { + JsonTableColumn: _j + }; + }, + jsonKeyValue(_p?: JsonKeyValue): { + JsonKeyValue: JsonKeyValue; + } { + const _j = {} as JsonKeyValue; + _o.set(_j, "key", _p?.key); + _o.set(_j, "value", _p?.value); + return { + JsonKeyValue: _j + }; + }, + jsonParseExpr(_p?: JsonParseExpr): { + JsonParseExpr: JsonParseExpr; + } { + const _j = {} as JsonParseExpr; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "output", _p?.output); + _o.set(_j, "unique_keys", _p?.unique_keys); + _o.set(_j, "location", _p?.location); + return { + JsonParseExpr: _j + }; + }, + jsonScalarExpr(_p?: JsonScalarExpr): { + JsonScalarExpr: JsonScalarExpr; + } { + const _j = {} as JsonScalarExpr; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "output", _p?.output); + _o.set(_j, "location", _p?.location); + return { + JsonScalarExpr: _j + }; + }, + jsonSerializeExpr(_p?: JsonSerializeExpr): { + JsonSerializeExpr: JsonSerializeExpr; + } { + const _j = {} as JsonSerializeExpr; + _o.set(_j, "expr", _p?.expr); + _o.set(_j, "output", _p?.output); + _o.set(_j, "location", _p?.location); + return { + JsonSerializeExpr: _j + }; + }, + jsonObjectConstructor(_p?: JsonObjectConstructor): { + JsonObjectConstructor: JsonObjectConstructor; + } { + const _j = {} as JsonObjectConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "location", _p?.location); + return { + JsonObjectConstructor: _j + }; + }, + jsonArrayConstructor(_p?: JsonArrayConstructor): { + JsonArrayConstructor: JsonArrayConstructor; + } { + const _j = {} as JsonArrayConstructor; + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "output", _p?.output); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayConstructor: _j + }; + }, + jsonArrayQueryConstructor(_p?: JsonArrayQueryConstructor): { + JsonArrayQueryConstructor: JsonArrayQueryConstructor; + } { + const _j = {} as JsonArrayQueryConstructor; + _o.set(_j, "query", _p?.query); + _o.set(_j, "output", _p?.output); + _o.set(_j, "format", _p?.format); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "location", _p?.location); + return { + JsonArrayQueryConstructor: _j + }; + }, + jsonAggConstructor(_p?: JsonAggConstructor): { + JsonAggConstructor: JsonAggConstructor; + } { + const _j = {} as JsonAggConstructor; + _o.set(_j, "output", _p?.output); + _o.set(_j, "agg_filter", _p?.agg_filter); + _o.set(_j, "agg_order", _p?.agg_order); + _o.set(_j, "over", _p?.over); + _o.set(_j, "location", _p?.location); + return { + JsonAggConstructor: _j + }; + }, + jsonObjectAgg(_p?: JsonObjectAgg): { + JsonObjectAgg: JsonObjectAgg; + } { + const _j = {} as JsonObjectAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + _o.set(_j, "unique", _p?.unique); + return { + JsonObjectAgg: _j + }; + }, + jsonArrayAgg(_p?: JsonArrayAgg): { + JsonArrayAgg: JsonArrayAgg; + } { + const _j = {} as JsonArrayAgg; + _o.set(_j, "constructor", _p?.constructor); + _o.set(_j, "arg", _p?.arg); + _o.set(_j, "absent_on_null", _p?.absent_on_null); + return { + JsonArrayAgg: _j + }; + }, + rawStmt(_p?: RawStmt): { + RawStmt: RawStmt; + } { + const _j = {} as RawStmt; + _o.set(_j, "stmt", _p?.stmt); + _o.set(_j, "stmt_location", _p?.stmt_location); + _o.set(_j, "stmt_len", _p?.stmt_len); + return { + RawStmt: _j + }; + }, + insertStmt(_p?: InsertStmt): { + InsertStmt: InsertStmt; + } { + const _j = {} as InsertStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cols", _p?.cols); + _o.set(_j, "selectStmt", _p?.selectStmt); + _o.set(_j, "onConflictClause", _p?.onConflictClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "override", _p?.override); + return { + InsertStmt: _j + }; + }, + deleteStmt(_p?: DeleteStmt): { + DeleteStmt: DeleteStmt; + } { + const _j = {} as DeleteStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "usingClause", _p?.usingClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + DeleteStmt: _j + }; + }, + updateStmt(_p?: UpdateStmt): { + UpdateStmt: UpdateStmt; + } { + const _j = {} as UpdateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + UpdateStmt: _j + }; + }, + mergeStmt(_p?: MergeStmt): { + MergeStmt: MergeStmt; + } { + const _j = {} as MergeStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "sourceRelation", _p?.sourceRelation); + _o.set(_j, "joinCondition", _p?.joinCondition); + _o.set(_j, "mergeWhenClauses", _p?.mergeWhenClauses); + _o.set(_j, "returningList", _p?.returningList); + _o.set(_j, "withClause", _p?.withClause); + return { + MergeStmt: _j + }; + }, + selectStmt(_p?: SelectStmt): { + SelectStmt: SelectStmt; + } { + const _j = {} as SelectStmt; + _o.set(_j, "distinctClause", _p?.distinctClause); + _o.set(_j, "intoClause", _p?.intoClause); + _o.set(_j, "targetList", _p?.targetList); + _o.set(_j, "fromClause", _p?.fromClause); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "groupClause", _p?.groupClause); + _o.set(_j, "groupDistinct", _p?.groupDistinct); + _o.set(_j, "havingClause", _p?.havingClause); + _o.set(_j, "windowClause", _p?.windowClause); + _o.set(_j, "valuesLists", _p?.valuesLists); + _o.set(_j, "sortClause", _p?.sortClause); + _o.set(_j, "limitOffset", _p?.limitOffset); + _o.set(_j, "limitCount", _p?.limitCount); + _o.set(_j, "limitOption", _p?.limitOption); + _o.set(_j, "lockingClause", _p?.lockingClause); + _o.set(_j, "withClause", _p?.withClause); + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + return { + SelectStmt: _j + }; + }, + setOperationStmt(_p?: SetOperationStmt): { + SetOperationStmt: SetOperationStmt; + } { + const _j = {} as SetOperationStmt; + _o.set(_j, "op", _p?.op); + _o.set(_j, "all", _p?.all); + _o.set(_j, "larg", _p?.larg); + _o.set(_j, "rarg", _p?.rarg); + _o.set(_j, "colTypes", _p?.colTypes); + _o.set(_j, "colTypmods", _p?.colTypmods); + _o.set(_j, "colCollations", _p?.colCollations); + _o.set(_j, "groupClauses", _p?.groupClauses); + return { + SetOperationStmt: _j + }; + }, + returnStmt(_p?: ReturnStmt): { + ReturnStmt: ReturnStmt; + } { + const _j = {} as ReturnStmt; + _o.set(_j, "returnval", _p?.returnval); + return { + ReturnStmt: _j + }; + }, + plAssignStmt(_p?: PLAssignStmt): { + PLAssignStmt: PLAssignStmt; + } { + const _j = {} as PLAssignStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "indirection", _p?.indirection); + _o.set(_j, "nnames", _p?.nnames); + _o.set(_j, "val", _p?.val); + _o.set(_j, "location", _p?.location); + return { + PLAssignStmt: _j + }; + }, + createSchemaStmt(_p?: CreateSchemaStmt): { + CreateSchemaStmt: CreateSchemaStmt; + } { + const _j = {} as CreateSchemaStmt; + _o.set(_j, "schemaname", _p?.schemaname); + _o.set(_j, "authrole", _p?.authrole); + _o.set(_j, "schemaElts", _p?.schemaElts); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSchemaStmt: _j + }; + }, + alterTableStmt(_p?: AlterTableStmt): { + AlterTableStmt: AlterTableStmt; + } { + const _j = {} as AlterTableStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "cmds", _p?.cmds); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTableStmt: _j + }; + }, + replicaIdentityStmt(_p?: ReplicaIdentityStmt): { + ReplicaIdentityStmt: ReplicaIdentityStmt; + } { + const _j = {} as ReplicaIdentityStmt; + _o.set(_j, "identity_type", _p?.identity_type); + _o.set(_j, "name", _p?.name); + return { + ReplicaIdentityStmt: _j + }; + }, + alterTableCmd(_p?: AlterTableCmd): { + AlterTableCmd: AlterTableCmd; + } { + const _j = {} as AlterTableCmd; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "num", _p?.num); + _o.set(_j, "newowner", _p?.newowner); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "recurse", _p?.recurse); + return { + AlterTableCmd: _j + }; + }, + alterCollationStmt(_p?: AlterCollationStmt): { + AlterCollationStmt: AlterCollationStmt; + } { + const _j = {} as AlterCollationStmt; + _o.set(_j, "collname", _p?.collname); + return { + AlterCollationStmt: _j + }; + }, + alterDomainStmt(_p?: AlterDomainStmt): { + AlterDomainStmt: AlterDomainStmt; + } { + const _j = {} as AlterDomainStmt; + _o.set(_j, "subtype", _p?.subtype); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "name", _p?.name); + _o.set(_j, "def", _p?.def); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterDomainStmt: _j + }; + }, + grantStmt(_p?: GrantStmt): { + GrantStmt: GrantStmt; + } { + const _j = {} as GrantStmt; + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "targtype", _p?.targtype); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "privileges", _p?.privileges); + _o.set(_j, "grantees", _p?.grantees); + _o.set(_j, "grant_option", _p?.grant_option); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantStmt: _j + }; + }, + objectWithArgs(_p?: ObjectWithArgs): { + ObjectWithArgs: ObjectWithArgs; + } { + const _j = {} as ObjectWithArgs; + _o.set(_j, "objname", _p?.objname); + _o.set(_j, "objargs", _p?.objargs); + _o.set(_j, "objfuncargs", _p?.objfuncargs); + _o.set(_j, "args_unspecified", _p?.args_unspecified); + return { + ObjectWithArgs: _j + }; + }, + accessPriv(_p?: AccessPriv): { + AccessPriv: AccessPriv; + } { + const _j = {} as AccessPriv; + _o.set(_j, "priv_name", _p?.priv_name); + _o.set(_j, "cols", _p?.cols); + return { + AccessPriv: _j + }; + }, + grantRoleStmt(_p?: GrantRoleStmt): { + GrantRoleStmt: GrantRoleStmt; + } { + const _j = {} as GrantRoleStmt; + _o.set(_j, "granted_roles", _p?.granted_roles); + _o.set(_j, "grantee_roles", _p?.grantee_roles); + _o.set(_j, "is_grant", _p?.is_grant); + _o.set(_j, "opt", _p?.opt); + _o.set(_j, "grantor", _p?.grantor); + _o.set(_j, "behavior", _p?.behavior); + return { + GrantRoleStmt: _j + }; + }, + alterDefaultPrivilegesStmt(_p?: AlterDefaultPrivilegesStmt): { + AlterDefaultPrivilegesStmt: AlterDefaultPrivilegesStmt; + } { + const _j = {} as AlterDefaultPrivilegesStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterDefaultPrivilegesStmt: _j + }; + }, + copyStmt(_p?: CopyStmt): { + CopyStmt: CopyStmt; + } { + const _j = {} as CopyStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "query", _p?.query); + _o.set(_j, "attlist", _p?.attlist); + _o.set(_j, "is_from", _p?.is_from); + _o.set(_j, "is_program", _p?.is_program); + _o.set(_j, "filename", _p?.filename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + return { + CopyStmt: _j + }; + }, + variableSetStmt(_p?: VariableSetStmt): { + VariableSetStmt: VariableSetStmt; + } { + const _j = {} as VariableSetStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "name", _p?.name); + _o.set(_j, "args", _p?.args); + _o.set(_j, "is_local", _p?.is_local); + return { + VariableSetStmt: _j + }; + }, + variableShowStmt(_p?: VariableShowStmt): { + VariableShowStmt: VariableShowStmt; + } { + const _j = {} as VariableShowStmt; + _o.set(_j, "name", _p?.name); + return { + VariableShowStmt: _j + }; + }, + createStmt(_p?: CreateStmt): { + CreateStmt: CreateStmt; + } { + const _j = {} as CreateStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "tableElts", _p?.tableElts); + _o.set(_j, "inhRelations", _p?.inhRelations); + _o.set(_j, "partbound", _p?.partbound); + _o.set(_j, "partspec", _p?.partspec); + _o.set(_j, "ofTypename", _p?.ofTypename); + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "options", _p?.options); + _o.set(_j, "oncommit", _p?.oncommit); + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStmt: _j + }; + }, + constraint(_p?: Constraint): { + Constraint: Constraint; + } { + const _j = {} as Constraint; + _o.set(_j, "contype", _p?.contype); + _o.set(_j, "conname", _p?.conname); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "skip_validation", _p?.skip_validation); + _o.set(_j, "initially_valid", _p?.initially_valid); + _o.set(_j, "is_no_inherit", _p?.is_no_inherit); + _o.set(_j, "raw_expr", _p?.raw_expr); + _o.set(_j, "cooked_expr", _p?.cooked_expr); + _o.set(_j, "generated_when", _p?.generated_when); + _o.set(_j, "inhcount", _p?.inhcount); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "keys", _p?.keys); + _o.set(_j, "including", _p?.including); + _o.set(_j, "exclusions", _p?.exclusions); + _o.set(_j, "options", _p?.options); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "indexspace", _p?.indexspace); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + _o.set(_j, "access_method", _p?.access_method); + _o.set(_j, "where_clause", _p?.where_clause); + _o.set(_j, "pktable", _p?.pktable); + _o.set(_j, "fk_attrs", _p?.fk_attrs); + _o.set(_j, "pk_attrs", _p?.pk_attrs); + _o.set(_j, "fk_matchtype", _p?.fk_matchtype); + _o.set(_j, "fk_upd_action", _p?.fk_upd_action); + _o.set(_j, "fk_del_action", _p?.fk_del_action); + _o.set(_j, "fk_del_set_cols", _p?.fk_del_set_cols); + _o.set(_j, "old_conpfeqop", _p?.old_conpfeqop); + _o.set(_j, "old_pktable_oid", _p?.old_pktable_oid); + _o.set(_j, "location", _p?.location); + return { + Constraint: _j + }; + }, + createTableSpaceStmt(_p?: CreateTableSpaceStmt): { + CreateTableSpaceStmt: CreateTableSpaceStmt; + } { + const _j = {} as CreateTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "owner", _p?.owner); + _o.set(_j, "location", _p?.location); + _o.set(_j, "options", _p?.options); + return { + CreateTableSpaceStmt: _j + }; + }, + dropTableSpaceStmt(_p?: DropTableSpaceStmt): { + DropTableSpaceStmt: DropTableSpaceStmt; + } { + const _j = {} as DropTableSpaceStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropTableSpaceStmt: _j + }; + }, + alterTableSpaceOptionsStmt(_p?: AlterTableSpaceOptionsStmt): { + AlterTableSpaceOptionsStmt: AlterTableSpaceOptionsStmt; + } { + const _j = {} as AlterTableSpaceOptionsStmt; + _o.set(_j, "tablespacename", _p?.tablespacename); + _o.set(_j, "options", _p?.options); + _o.set(_j, "isReset", _p?.isReset); + return { + AlterTableSpaceOptionsStmt: _j + }; + }, + alterTableMoveAllStmt(_p?: AlterTableMoveAllStmt): { + AlterTableMoveAllStmt: AlterTableMoveAllStmt; + } { + const _j = {} as AlterTableMoveAllStmt; + _o.set(_j, "orig_tablespacename", _p?.orig_tablespacename); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "new_tablespacename", _p?.new_tablespacename); + _o.set(_j, "nowait", _p?.nowait); + return { + AlterTableMoveAllStmt: _j + }; + }, + createExtensionStmt(_p?: CreateExtensionStmt): { + CreateExtensionStmt: CreateExtensionStmt; + } { + const _j = {} as CreateExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateExtensionStmt: _j + }; + }, + alterExtensionStmt(_p?: AlterExtensionStmt): { + AlterExtensionStmt: AlterExtensionStmt; + } { + const _j = {} as AlterExtensionStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "options", _p?.options); + return { + AlterExtensionStmt: _j + }; + }, + alterExtensionContentsStmt(_p?: AlterExtensionContentsStmt): { + AlterExtensionContentsStmt: AlterExtensionContentsStmt; + } { + const _j = {} as AlterExtensionContentsStmt; + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "action", _p?.action); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + return { + AlterExtensionContentsStmt: _j + }; + }, + createFdwStmt(_p?: CreateFdwStmt): { + CreateFdwStmt: CreateFdwStmt; + } { + const _j = {} as CreateFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + CreateFdwStmt: _j + }; + }, + alterFdwStmt(_p?: AlterFdwStmt): { + AlterFdwStmt: AlterFdwStmt; + } { + const _j = {} as AlterFdwStmt; + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "func_options", _p?.func_options); + _o.set(_j, "options", _p?.options); + return { + AlterFdwStmt: _j + }; + }, + createForeignServerStmt(_p?: CreateForeignServerStmt): { + CreateForeignServerStmt: CreateForeignServerStmt; + } { + const _j = {} as CreateForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "servertype", _p?.servertype); + _o.set(_j, "version", _p?.version); + _o.set(_j, "fdwname", _p?.fdwname); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateForeignServerStmt: _j + }; + }, + alterForeignServerStmt(_p?: AlterForeignServerStmt): { + AlterForeignServerStmt: AlterForeignServerStmt; + } { + const _j = {} as AlterForeignServerStmt; + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "version", _p?.version); + _o.set(_j, "options", _p?.options); + _o.set(_j, "has_version", _p?.has_version); + return { + AlterForeignServerStmt: _j + }; + }, + createForeignTableStmt(_p?: CreateForeignTableStmt): { + CreateForeignTableStmt: CreateForeignTableStmt; + } { + const _j = {} as CreateForeignTableStmt; + _o.set(_j, "base", _p?.base); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + CreateForeignTableStmt: _j + }; + }, + createUserMappingStmt(_p?: CreateUserMappingStmt): { + CreateUserMappingStmt: CreateUserMappingStmt; + } { + const _j = {} as CreateUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "options", _p?.options); + return { + CreateUserMappingStmt: _j + }; + }, + alterUserMappingStmt(_p?: AlterUserMappingStmt): { + AlterUserMappingStmt: AlterUserMappingStmt; + } { + const _j = {} as AlterUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "options", _p?.options); + return { + AlterUserMappingStmt: _j + }; + }, + dropUserMappingStmt(_p?: DropUserMappingStmt): { + DropUserMappingStmt: DropUserMappingStmt; + } { + const _j = {} as DropUserMappingStmt; + _o.set(_j, "user", _p?.user); + _o.set(_j, "servername", _p?.servername); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropUserMappingStmt: _j + }; + }, + importForeignSchemaStmt(_p?: ImportForeignSchemaStmt): { + ImportForeignSchemaStmt: ImportForeignSchemaStmt; + } { + const _j = {} as ImportForeignSchemaStmt; + _o.set(_j, "server_name", _p?.server_name); + _o.set(_j, "remote_schema", _p?.remote_schema); + _o.set(_j, "local_schema", _p?.local_schema); + _o.set(_j, "list_type", _p?.list_type); + _o.set(_j, "table_list", _p?.table_list); + _o.set(_j, "options", _p?.options); + return { + ImportForeignSchemaStmt: _j + }; + }, + createPolicyStmt(_p?: CreatePolicyStmt): { + CreatePolicyStmt: CreatePolicyStmt; + } { + const _j = {} as CreatePolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "cmd_name", _p?.cmd_name); + _o.set(_j, "permissive", _p?.permissive); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + CreatePolicyStmt: _j + }; + }, + alterPolicyStmt(_p?: AlterPolicyStmt): { + AlterPolicyStmt: AlterPolicyStmt; + } { + const _j = {} as AlterPolicyStmt; + _o.set(_j, "policy_name", _p?.policy_name); + _o.set(_j, "table", _p?.table); + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "qual", _p?.qual); + _o.set(_j, "with_check", _p?.with_check); + return { + AlterPolicyStmt: _j + }; + }, + createAmStmt(_p?: CreateAmStmt): { + CreateAmStmt: CreateAmStmt; + } { + const _j = {} as CreateAmStmt; + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "handler_name", _p?.handler_name); + _o.set(_j, "amtype", _p?.amtype); + return { + CreateAmStmt: _j + }; + }, + createTrigStmt(_p?: CreateTrigStmt): { + CreateTrigStmt: CreateTrigStmt; + } { + const _j = {} as CreateTrigStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "args", _p?.args); + _o.set(_j, "row", _p?.row); + _o.set(_j, "timing", _p?.timing); + _o.set(_j, "events", _p?.events); + _o.set(_j, "columns", _p?.columns); + _o.set(_j, "whenClause", _p?.whenClause); + _o.set(_j, "transitionRels", _p?.transitionRels); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "constrrel", _p?.constrrel); + return { + CreateTrigStmt: _j + }; + }, + createEventTrigStmt(_p?: CreateEventTrigStmt): { + CreateEventTrigStmt: CreateEventTrigStmt; + } { + const _j = {} as CreateEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "eventname", _p?.eventname); + _o.set(_j, "whenclause", _p?.whenclause); + _o.set(_j, "funcname", _p?.funcname); + return { + CreateEventTrigStmt: _j + }; + }, + alterEventTrigStmt(_p?: AlterEventTrigStmt): { + AlterEventTrigStmt: AlterEventTrigStmt; + } { + const _j = {} as AlterEventTrigStmt; + _o.set(_j, "trigname", _p?.trigname); + _o.set(_j, "tgenabled", _p?.tgenabled); + return { + AlterEventTrigStmt: _j + }; + }, + createpLangStmt(_p?: CreatePLangStmt): { + CreatePLangStmt: CreatePLangStmt; + } { + const _j = {} as CreatePLangStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "plname", _p?.plname); + _o.set(_j, "plhandler", _p?.plhandler); + _o.set(_j, "plinline", _p?.plinline); + _o.set(_j, "plvalidator", _p?.plvalidator); + _o.set(_j, "pltrusted", _p?.pltrusted); + return { + CreatePLangStmt: _j + }; + }, + createRoleStmt(_p?: CreateRoleStmt): { + CreateRoleStmt: CreateRoleStmt; + } { + const _j = {} as CreateRoleStmt; + _o.set(_j, "stmt_type", _p?.stmt_type); + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + return { + CreateRoleStmt: _j + }; + }, + alterRoleStmt(_p?: AlterRoleStmt): { + AlterRoleStmt: AlterRoleStmt; + } { + const _j = {} as AlterRoleStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "options", _p?.options); + _o.set(_j, "action", _p?.action); + return { + AlterRoleStmt: _j + }; + }, + alterRoleSetStmt(_p?: AlterRoleSetStmt): { + AlterRoleSetStmt: AlterRoleSetStmt; + } { + const _j = {} as AlterRoleSetStmt; + _o.set(_j, "role", _p?.role); + _o.set(_j, "database", _p?.database); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterRoleSetStmt: _j + }; + }, + dropRoleStmt(_p?: DropRoleStmt): { + DropRoleStmt: DropRoleStmt; + } { + const _j = {} as DropRoleStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + DropRoleStmt: _j + }; + }, + createSeqStmt(_p?: CreateSeqStmt): { + CreateSeqStmt: CreateSeqStmt; + } { + const _j = {} as CreateSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "ownerId", _p?.ownerId); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateSeqStmt: _j + }; + }, + alterSeqStmt(_p?: AlterSeqStmt): { + AlterSeqStmt: AlterSeqStmt; + } { + const _j = {} as AlterSeqStmt; + _o.set(_j, "sequence", _p?.sequence); + _o.set(_j, "options", _p?.options); + _o.set(_j, "for_identity", _p?.for_identity); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterSeqStmt: _j + }; + }, + defineStmt(_p?: DefineStmt): { + DefineStmt: DefineStmt; + } { + const _j = {} as DefineStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "oldstyle", _p?.oldstyle); + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "args", _p?.args); + _o.set(_j, "definition", _p?.definition); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "replace", _p?.replace); + return { + DefineStmt: _j + }; + }, + createDomainStmt(_p?: CreateDomainStmt): { + CreateDomainStmt: CreateDomainStmt; + } { + const _j = {} as CreateDomainStmt; + _o.set(_j, "domainname", _p?.domainname); + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "collClause", _p?.collClause); + _o.set(_j, "constraints", _p?.constraints); + return { + CreateDomainStmt: _j + }; + }, + createOpClassStmt(_p?: CreateOpClassStmt): { + CreateOpClassStmt: CreateOpClassStmt; + } { + const _j = {} as CreateOpClassStmt; + _o.set(_j, "opclassname", _p?.opclassname); + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "datatype", _p?.datatype); + _o.set(_j, "items", _p?.items); + _o.set(_j, "isDefault", _p?.isDefault); + return { + CreateOpClassStmt: _j + }; + }, + createOpClassItem(_p?: CreateOpClassItem): { + CreateOpClassItem: CreateOpClassItem; + } { + const _j = {} as CreateOpClassItem; + _o.set(_j, "itemtype", _p?.itemtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "number", _p?.number); + _o.set(_j, "order_family", _p?.order_family); + _o.set(_j, "class_args", _p?.class_args); + _o.set(_j, "storedtype", _p?.storedtype); + return { + CreateOpClassItem: _j + }; + }, + createOpFamilyStmt(_p?: CreateOpFamilyStmt): { + CreateOpFamilyStmt: CreateOpFamilyStmt; + } { + const _j = {} as CreateOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + return { + CreateOpFamilyStmt: _j + }; + }, + alterOpFamilyStmt(_p?: AlterOpFamilyStmt): { + AlterOpFamilyStmt: AlterOpFamilyStmt; + } { + const _j = {} as AlterOpFamilyStmt; + _o.set(_j, "opfamilyname", _p?.opfamilyname); + _o.set(_j, "amname", _p?.amname); + _o.set(_j, "isDrop", _p?.isDrop); + _o.set(_j, "items", _p?.items); + return { + AlterOpFamilyStmt: _j + }; + }, + dropStmt(_p?: DropStmt): { + DropStmt: DropStmt; + } { + const _j = {} as DropStmt; + _o.set(_j, "objects", _p?.objects); + _o.set(_j, "removeType", _p?.removeType); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "concurrent", _p?.concurrent); + return { + DropStmt: _j + }; + }, + truncateStmt(_p?: TruncateStmt): { + TruncateStmt: TruncateStmt; + } { + const _j = {} as TruncateStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "restart_seqs", _p?.restart_seqs); + _o.set(_j, "behavior", _p?.behavior); + return { + TruncateStmt: _j + }; + }, + commentStmt(_p?: CommentStmt): { + CommentStmt: CommentStmt; + } { + const _j = {} as CommentStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "comment", _p?.comment); + return { + CommentStmt: _j + }; + }, + secLabelStmt(_p?: SecLabelStmt): { + SecLabelStmt: SecLabelStmt; + } { + const _j = {} as SecLabelStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "object", _p?.object); + _o.set(_j, "provider", _p?.provider); + _o.set(_j, "label", _p?.label); + return { + SecLabelStmt: _j + }; + }, + declareCursorStmt(_p?: DeclareCursorStmt): { + DeclareCursorStmt: DeclareCursorStmt; + } { + const _j = {} as DeclareCursorStmt; + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "query", _p?.query); + return { + DeclareCursorStmt: _j + }; + }, + closePortalStmt(_p?: ClosePortalStmt): { + ClosePortalStmt: ClosePortalStmt; + } { + const _j = {} as ClosePortalStmt; + _o.set(_j, "portalname", _p?.portalname); + return { + ClosePortalStmt: _j + }; + }, + fetchStmt(_p?: FetchStmt): { + FetchStmt: FetchStmt; + } { + const _j = {} as FetchStmt; + _o.set(_j, "direction", _p?.direction); + _o.set(_j, "howMany", _p?.howMany); + _o.set(_j, "portalname", _p?.portalname); + _o.set(_j, "ismove", _p?.ismove); + return { + FetchStmt: _j + }; + }, + indexStmt(_p?: IndexStmt): { + IndexStmt: IndexStmt; + } { + const _j = {} as IndexStmt; + _o.set(_j, "idxname", _p?.idxname); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "accessMethod", _p?.accessMethod); + _o.set(_j, "tableSpace", _p?.tableSpace); + _o.set(_j, "indexParams", _p?.indexParams); + _o.set(_j, "indexIncludingParams", _p?.indexIncludingParams); + _o.set(_j, "options", _p?.options); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "excludeOpNames", _p?.excludeOpNames); + _o.set(_j, "idxcomment", _p?.idxcomment); + _o.set(_j, "indexOid", _p?.indexOid); + _o.set(_j, "oldNumber", _p?.oldNumber); + _o.set(_j, "oldCreateSubid", _p?.oldCreateSubid); + _o.set(_j, "oldFirstRelfilelocatorSubid", _p?.oldFirstRelfilelocatorSubid); + _o.set(_j, "unique", _p?.unique); + _o.set(_j, "nulls_not_distinct", _p?.nulls_not_distinct); + _o.set(_j, "primary", _p?.primary); + _o.set(_j, "isconstraint", _p?.isconstraint); + _o.set(_j, "deferrable", _p?.deferrable); + _o.set(_j, "initdeferred", _p?.initdeferred); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + _o.set(_j, "reset_default_tblspc", _p?.reset_default_tblspc); + return { + IndexStmt: _j + }; + }, + createStatsStmt(_p?: CreateStatsStmt): { + CreateStatsStmt: CreateStatsStmt; + } { + const _j = {} as CreateStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stat_types", _p?.stat_types); + _o.set(_j, "exprs", _p?.exprs); + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "stxcomment", _p?.stxcomment); + _o.set(_j, "transformed", _p?.transformed); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateStatsStmt: _j + }; + }, + statsElem(_p?: StatsElem): { + StatsElem: StatsElem; + } { + const _j = {} as StatsElem; + _o.set(_j, "name", _p?.name); + _o.set(_j, "expr", _p?.expr); + return { + StatsElem: _j + }; + }, + alterStatsStmt(_p?: AlterStatsStmt): { + AlterStatsStmt: AlterStatsStmt; + } { + const _j = {} as AlterStatsStmt; + _o.set(_j, "defnames", _p?.defnames); + _o.set(_j, "stxstattarget", _p?.stxstattarget); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterStatsStmt: _j + }; + }, + createFunctionStmt(_p?: CreateFunctionStmt): { + CreateFunctionStmt: CreateFunctionStmt; + } { + const _j = {} as CreateFunctionStmt; + _o.set(_j, "is_procedure", _p?.is_procedure); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "funcname", _p?.funcname); + _o.set(_j, "parameters", _p?.parameters); + _o.set(_j, "returnType", _p?.returnType); + _o.set(_j, "options", _p?.options); + _o.set(_j, "sql_body", _p?.sql_body); + return { + CreateFunctionStmt: _j + }; + }, + functionParameter(_p?: FunctionParameter): { + FunctionParameter: FunctionParameter; + } { + const _j = {} as FunctionParameter; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argType", _p?.argType); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "defexpr", _p?.defexpr); + return { + FunctionParameter: _j + }; + }, + alterFunctionStmt(_p?: AlterFunctionStmt): { + AlterFunctionStmt: AlterFunctionStmt; + } { + const _j = {} as AlterFunctionStmt; + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "actions", _p?.actions); + return { + AlterFunctionStmt: _j + }; + }, + doStmt(_p?: DoStmt): { + DoStmt: DoStmt; + } { + const _j = {} as DoStmt; + _o.set(_j, "args", _p?.args); + return { + DoStmt: _j + }; + }, + inlineCodeBlock(_p?: InlineCodeBlock): { + InlineCodeBlock: InlineCodeBlock; + } { + const _j = {} as InlineCodeBlock; + _o.set(_j, "source_text", _p?.source_text); + _o.set(_j, "langOid", _p?.langOid); + _o.set(_j, "langIsTrusted", _p?.langIsTrusted); + _o.set(_j, "atomic", _p?.atomic); + return { + InlineCodeBlock: _j + }; + }, + callStmt(_p?: CallStmt): { + CallStmt: CallStmt; + } { + const _j = {} as CallStmt; + _o.set(_j, "funccall", _p?.funccall); + _o.set(_j, "funcexpr", _p?.funcexpr); + _o.set(_j, "outargs", _p?.outargs); + return { + CallStmt: _j + }; + }, + callContext(_p?: CallContext): { + CallContext: CallContext; + } { + const _j = {} as CallContext; + _o.set(_j, "atomic", _p?.atomic); + return { + CallContext: _j + }; + }, + renameStmt(_p?: RenameStmt): { + RenameStmt: RenameStmt; + } { + const _j = {} as RenameStmt; + _o.set(_j, "renameType", _p?.renameType); + _o.set(_j, "relationType", _p?.relationType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "newname", _p?.newname); + _o.set(_j, "behavior", _p?.behavior); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + RenameStmt: _j + }; + }, + alterObjectDependsStmt(_p?: AlterObjectDependsStmt): { + AlterObjectDependsStmt: AlterObjectDependsStmt; + } { + const _j = {} as AlterObjectDependsStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "extname", _p?.extname); + _o.set(_j, "remove", _p?.remove); + return { + AlterObjectDependsStmt: _j + }; + }, + alterObjectSchemaStmt(_p?: AlterObjectSchemaStmt): { + AlterObjectSchemaStmt: AlterObjectSchemaStmt; + } { + const _j = {} as AlterObjectSchemaStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newschema", _p?.newschema); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterObjectSchemaStmt: _j + }; + }, + alterOwnerStmt(_p?: AlterOwnerStmt): { + AlterOwnerStmt: AlterOwnerStmt; + } { + const _j = {} as AlterOwnerStmt; + _o.set(_j, "objectType", _p?.objectType); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "object", _p?.object); + _o.set(_j, "newowner", _p?.newowner); + return { + AlterOwnerStmt: _j + }; + }, + alterOperatorStmt(_p?: AlterOperatorStmt): { + AlterOperatorStmt: AlterOperatorStmt; + } { + const _j = {} as AlterOperatorStmt; + _o.set(_j, "opername", _p?.opername); + _o.set(_j, "options", _p?.options); + return { + AlterOperatorStmt: _j + }; + }, + alterTypeStmt(_p?: AlterTypeStmt): { + AlterTypeStmt: AlterTypeStmt; + } { + const _j = {} as AlterTypeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "options", _p?.options); + return { + AlterTypeStmt: _j + }; + }, + ruleStmt(_p?: RuleStmt): { + RuleStmt: RuleStmt; + } { + const _j = {} as RuleStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "rulename", _p?.rulename); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "event", _p?.event); + _o.set(_j, "instead", _p?.instead); + _o.set(_j, "actions", _p?.actions); + _o.set(_j, "replace", _p?.replace); + return { + RuleStmt: _j + }; + }, + notifyStmt(_p?: NotifyStmt): { + NotifyStmt: NotifyStmt; + } { + const _j = {} as NotifyStmt; + _o.set(_j, "conditionname", _p?.conditionname); + _o.set(_j, "payload", _p?.payload); + return { + NotifyStmt: _j + }; + }, + listenStmt(_p?: ListenStmt): { + ListenStmt: ListenStmt; + } { + const _j = {} as ListenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + ListenStmt: _j + }; + }, + unlistenStmt(_p?: UnlistenStmt): { + UnlistenStmt: UnlistenStmt; + } { + const _j = {} as UnlistenStmt; + _o.set(_j, "conditionname", _p?.conditionname); + return { + UnlistenStmt: _j + }; + }, + transactionStmt(_p?: TransactionStmt): { + TransactionStmt: TransactionStmt; + } { + const _j = {} as TransactionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "options", _p?.options); + _o.set(_j, "savepoint_name", _p?.savepoint_name); + _o.set(_j, "gid", _p?.gid); + _o.set(_j, "chain", _p?.chain); + _o.set(_j, "location", _p?.location); + return { + TransactionStmt: _j + }; + }, + compositeTypeStmt(_p?: CompositeTypeStmt): { + CompositeTypeStmt: CompositeTypeStmt; + } { + const _j = {} as CompositeTypeStmt; + _o.set(_j, "typevar", _p?.typevar); + _o.set(_j, "coldeflist", _p?.coldeflist); + return { + CompositeTypeStmt: _j + }; + }, + createEnumStmt(_p?: CreateEnumStmt): { + CreateEnumStmt: CreateEnumStmt; + } { + const _j = {} as CreateEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "vals", _p?.vals); + return { + CreateEnumStmt: _j + }; + }, + createRangeStmt(_p?: CreateRangeStmt): { + CreateRangeStmt: CreateRangeStmt; + } { + const _j = {} as CreateRangeStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "params", _p?.params); + return { + CreateRangeStmt: _j + }; + }, + alterEnumStmt(_p?: AlterEnumStmt): { + AlterEnumStmt: AlterEnumStmt; + } { + const _j = {} as AlterEnumStmt; + _o.set(_j, "typeName", _p?.typeName); + _o.set(_j, "oldVal", _p?.oldVal); + _o.set(_j, "newVal", _p?.newVal); + _o.set(_j, "newValNeighbor", _p?.newValNeighbor); + _o.set(_j, "newValIsAfter", _p?.newValIsAfter); + _o.set(_j, "skipIfNewValExists", _p?.skipIfNewValExists); + return { + AlterEnumStmt: _j + }; + }, + viewStmt(_p?: ViewStmt): { + ViewStmt: ViewStmt; + } { + const _j = {} as ViewStmt; + _o.set(_j, "view", _p?.view); + _o.set(_j, "aliases", _p?.aliases); + _o.set(_j, "query", _p?.query); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "options", _p?.options); + _o.set(_j, "withCheckOption", _p?.withCheckOption); + return { + ViewStmt: _j + }; + }, + loadStmt(_p?: LoadStmt): { + LoadStmt: LoadStmt; + } { + const _j = {} as LoadStmt; + _o.set(_j, "filename", _p?.filename); + return { + LoadStmt: _j + }; + }, + createdbStmt(_p?: CreatedbStmt): { + CreatedbStmt: CreatedbStmt; + } { + const _j = {} as CreatedbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + CreatedbStmt: _j + }; + }, + alterDatabaseStmt(_p?: AlterDatabaseStmt): { + AlterDatabaseStmt: AlterDatabaseStmt; + } { + const _j = {} as AlterDatabaseStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "options", _p?.options); + return { + AlterDatabaseStmt: _j + }; + }, + alterDatabaseRefreshCollStmt(_p?: AlterDatabaseRefreshCollStmt): { + AlterDatabaseRefreshCollStmt: AlterDatabaseRefreshCollStmt; + } { + const _j = {} as AlterDatabaseRefreshCollStmt; + _o.set(_j, "dbname", _p?.dbname); + return { + AlterDatabaseRefreshCollStmt: _j + }; + }, + alterDatabaseSetStmt(_p?: AlterDatabaseSetStmt): { + AlterDatabaseSetStmt: AlterDatabaseSetStmt; + } { + const _j = {} as AlterDatabaseSetStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterDatabaseSetStmt: _j + }; + }, + dropdbStmt(_p?: DropdbStmt): { + DropdbStmt: DropdbStmt; + } { + const _j = {} as DropdbStmt; + _o.set(_j, "dbname", _p?.dbname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "options", _p?.options); + return { + DropdbStmt: _j + }; + }, + alterSystemStmt(_p?: AlterSystemStmt): { + AlterSystemStmt: AlterSystemStmt; + } { + const _j = {} as AlterSystemStmt; + _o.set(_j, "setstmt", _p?.setstmt); + return { + AlterSystemStmt: _j + }; + }, + clusterStmt(_p?: ClusterStmt): { + ClusterStmt: ClusterStmt; + } { + const _j = {} as ClusterStmt; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "indexname", _p?.indexname); + _o.set(_j, "params", _p?.params); + return { + ClusterStmt: _j + }; + }, + vacuumStmt(_p?: VacuumStmt): { + VacuumStmt: VacuumStmt; + } { + const _j = {} as VacuumStmt; + _o.set(_j, "options", _p?.options); + _o.set(_j, "rels", _p?.rels); + _o.set(_j, "is_vacuumcmd", _p?.is_vacuumcmd); + return { + VacuumStmt: _j + }; + }, + vacuumRelation(_p?: VacuumRelation): { + VacuumRelation: VacuumRelation; + } { + const _j = {} as VacuumRelation; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "oid", _p?.oid); + _o.set(_j, "va_cols", _p?.va_cols); + return { + VacuumRelation: _j + }; + }, + explainStmt(_p?: ExplainStmt): { + ExplainStmt: ExplainStmt; + } { + const _j = {} as ExplainStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "options", _p?.options); + return { + ExplainStmt: _j + }; + }, + createTableAsStmt(_p?: CreateTableAsStmt): { + CreateTableAsStmt: CreateTableAsStmt; + } { + const _j = {} as CreateTableAsStmt; + _o.set(_j, "query", _p?.query); + _o.set(_j, "into", _p?.into); + _o.set(_j, "objtype", _p?.objtype); + _o.set(_j, "is_select_into", _p?.is_select_into); + _o.set(_j, "if_not_exists", _p?.if_not_exists); + return { + CreateTableAsStmt: _j + }; + }, + refreshMatViewStmt(_p?: RefreshMatViewStmt): { + RefreshMatViewStmt: RefreshMatViewStmt; + } { + const _j = {} as RefreshMatViewStmt; + _o.set(_j, "concurrent", _p?.concurrent); + _o.set(_j, "skipData", _p?.skipData); + _o.set(_j, "relation", _p?.relation); + return { + RefreshMatViewStmt: _j + }; + }, + checkPointStmt(_p?: CheckPointStmt): { + CheckPointStmt: CheckPointStmt; + } { + const _j = {} as CheckPointStmt; + return { + CheckPointStmt: _j + }; + }, + discardStmt(_p?: DiscardStmt): { + DiscardStmt: DiscardStmt; + } { + const _j = {} as DiscardStmt; + _o.set(_j, "target", _p?.target); + return { + DiscardStmt: _j + }; + }, + lockStmt(_p?: LockStmt): { + LockStmt: LockStmt; + } { + const _j = {} as LockStmt; + _o.set(_j, "relations", _p?.relations); + _o.set(_j, "mode", _p?.mode); + _o.set(_j, "nowait", _p?.nowait); + return { + LockStmt: _j + }; + }, + constraintsSetStmt(_p?: ConstraintsSetStmt): { + ConstraintsSetStmt: ConstraintsSetStmt; + } { + const _j = {} as ConstraintsSetStmt; + _o.set(_j, "constraints", _p?.constraints); + _o.set(_j, "deferred", _p?.deferred); + return { + ConstraintsSetStmt: _j + }; + }, + reindexStmt(_p?: ReindexStmt): { + ReindexStmt: ReindexStmt; + } { + const _j = {} as ReindexStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ReindexStmt: _j + }; + }, + createConversionStmt(_p?: CreateConversionStmt): { + CreateConversionStmt: CreateConversionStmt; + } { + const _j = {} as CreateConversionStmt; + _o.set(_j, "conversion_name", _p?.conversion_name); + _o.set(_j, "for_encoding_name", _p?.for_encoding_name); + _o.set(_j, "to_encoding_name", _p?.to_encoding_name); + _o.set(_j, "func_name", _p?.func_name); + _o.set(_j, "def", _p?.def); + return { + CreateConversionStmt: _j + }; + }, + createCastStmt(_p?: CreateCastStmt): { + CreateCastStmt: CreateCastStmt; + } { + const _j = {} as CreateCastStmt; + _o.set(_j, "sourcetype", _p?.sourcetype); + _o.set(_j, "targettype", _p?.targettype); + _o.set(_j, "func", _p?.func); + _o.set(_j, "context", _p?.context); + _o.set(_j, "inout", _p?.inout); + return { + CreateCastStmt: _j + }; + }, + createTransformStmt(_p?: CreateTransformStmt): { + CreateTransformStmt: CreateTransformStmt; + } { + const _j = {} as CreateTransformStmt; + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "type_name", _p?.type_name); + _o.set(_j, "lang", _p?.lang); + _o.set(_j, "fromsql", _p?.fromsql); + _o.set(_j, "tosql", _p?.tosql); + return { + CreateTransformStmt: _j + }; + }, + prepareStmt(_p?: PrepareStmt): { + PrepareStmt: PrepareStmt; + } { + const _j = {} as PrepareStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "argtypes", _p?.argtypes); + _o.set(_j, "query", _p?.query); + return { + PrepareStmt: _j + }; + }, + executeStmt(_p?: ExecuteStmt): { + ExecuteStmt: ExecuteStmt; + } { + const _j = {} as ExecuteStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "params", _p?.params); + return { + ExecuteStmt: _j + }; + }, + deallocateStmt(_p?: DeallocateStmt): { + DeallocateStmt: DeallocateStmt; + } { + const _j = {} as DeallocateStmt; + _o.set(_j, "name", _p?.name); + _o.set(_j, "isall", _p?.isall); + _o.set(_j, "location", _p?.location); + return { + DeallocateStmt: _j + }; + }, + dropOwnedStmt(_p?: DropOwnedStmt): { + DropOwnedStmt: DropOwnedStmt; + } { + const _j = {} as DropOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "behavior", _p?.behavior); + return { + DropOwnedStmt: _j + }; + }, + reassignOwnedStmt(_p?: ReassignOwnedStmt): { + ReassignOwnedStmt: ReassignOwnedStmt; + } { + const _j = {} as ReassignOwnedStmt; + _o.set(_j, "roles", _p?.roles); + _o.set(_j, "newrole", _p?.newrole); + return { + ReassignOwnedStmt: _j + }; + }, + altertsDictionaryStmt(_p?: AlterTSDictionaryStmt): { + AlterTSDictionaryStmt: AlterTSDictionaryStmt; + } { + const _j = {} as AlterTSDictionaryStmt; + _o.set(_j, "dictname", _p?.dictname); + _o.set(_j, "options", _p?.options); + return { + AlterTSDictionaryStmt: _j + }; + }, + altertsConfigurationStmt(_p?: AlterTSConfigurationStmt): { + AlterTSConfigurationStmt: AlterTSConfigurationStmt; + } { + const _j = {} as AlterTSConfigurationStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "cfgname", _p?.cfgname); + _o.set(_j, "tokentype", _p?.tokentype); + _o.set(_j, "dicts", _p?.dicts); + _o.set(_j, "override", _p?.override); + _o.set(_j, "replace", _p?.replace); + _o.set(_j, "missing_ok", _p?.missing_ok); + return { + AlterTSConfigurationStmt: _j + }; + }, + publicationTable(_p?: PublicationTable): { + PublicationTable: PublicationTable; + } { + const _j = {} as PublicationTable; + _o.set(_j, "relation", _p?.relation); + _o.set(_j, "whereClause", _p?.whereClause); + _o.set(_j, "columns", _p?.columns); + return { + PublicationTable: _j + }; + }, + publicationObjSpec(_p?: PublicationObjSpec): { + PublicationObjSpec: PublicationObjSpec; + } { + const _j = {} as PublicationObjSpec; + _o.set(_j, "pubobjtype", _p?.pubobjtype); + _o.set(_j, "name", _p?.name); + _o.set(_j, "pubtable", _p?.pubtable); + _o.set(_j, "location", _p?.location); + return { + PublicationObjSpec: _j + }; + }, + createPublicationStmt(_p?: CreatePublicationStmt): { + CreatePublicationStmt: CreatePublicationStmt; + } { + const _j = {} as CreatePublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + return { + CreatePublicationStmt: _j + }; + }, + alterPublicationStmt(_p?: AlterPublicationStmt): { + AlterPublicationStmt: AlterPublicationStmt; + } { + const _j = {} as AlterPublicationStmt; + _o.set(_j, "pubname", _p?.pubname); + _o.set(_j, "options", _p?.options); + _o.set(_j, "pubobjects", _p?.pubobjects); + _o.set(_j, "for_all_tables", _p?.for_all_tables); + _o.set(_j, "action", _p?.action); + return { + AlterPublicationStmt: _j + }; + }, + createSubscriptionStmt(_p?: CreateSubscriptionStmt): { + CreateSubscriptionStmt: CreateSubscriptionStmt; + } { + const _j = {} as CreateSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + CreateSubscriptionStmt: _j + }; + }, + alterSubscriptionStmt(_p?: AlterSubscriptionStmt): { + AlterSubscriptionStmt: AlterSubscriptionStmt; + } { + const _j = {} as AlterSubscriptionStmt; + _o.set(_j, "kind", _p?.kind); + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "conninfo", _p?.conninfo); + _o.set(_j, "publication", _p?.publication); + _o.set(_j, "options", _p?.options); + return { + AlterSubscriptionStmt: _j + }; + }, + dropSubscriptionStmt(_p?: DropSubscriptionStmt): { + DropSubscriptionStmt: DropSubscriptionStmt; + } { + const _j = {} as DropSubscriptionStmt; + _o.set(_j, "subname", _p?.subname); + _o.set(_j, "missing_ok", _p?.missing_ok); + _o.set(_j, "behavior", _p?.behavior); + return { + DropSubscriptionStmt: _j + }; + }, + scanToken(_p?: ScanToken): { + ScanToken: ScanToken; + } { + const _j = {} as ScanToken; + _o.set(_j, "start", _p?.start); + _o.set(_j, "end", _p?.end); + _o.set(_j, "token", _p?.token); + _o.set(_j, "keywordKind", _p?.keywordKind); + return { + ScanToken: _j + }; + } +}; \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index bc3a2509..6963969a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1227,6 +1227,11 @@ node-addon-api "^3.2.1" node-gyp-build "^4.3.0" +"@pgsql/types@^17.0.0", "@pgsql/types@^17.5.3": + version "17.5.3" + resolved "https://registry.yarnpkg.com/@pgsql/types/-/types-17.5.3.tgz#b4a53ba71a1bf111de744d01fc49a4e1576f3e31" + integrity sha512-lRPdKcipoKLoovXw6tVwg9gdqV1fIvfjzqFDY1UFsJa8I+/yaVrGWCtmE+CeWU5e+imXd7X3fTWs8N8bK3R+AQ== + "@pkgjs/parseargs@^0.11.0": version "0.11.0" resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33"