You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

@alipay/faas-db-builder

Package Overview
Dependencies
Maintainers
3
Versions
125
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.1.19-alpha.1 to 1.1.19-alpha.3

56

esm/command/aggregate.d.ts

@@ -1,2 +0,2 @@

import { AggregateArrayExpression, AggregateDateFromStringParam, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateFilterParam, AggregateIndexOfParam, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateRangeParam, AggregateReduceParam, AggregateStrcasecmpParam, AggregateStringExpression, AggregateStringExpressionPair, AggregateZipParam, AggregateSubstrCPParam, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam } from '../typing';
import { AggregateArrayExpression, AggregateArrayExpressionPair, AggregateDateFromStringParam, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateFilterParam, AggregateIndexOfParam, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateRangeParam, AggregateReduceParam, AggregateStrcasecmpParam, AggregateStringExpression, AggregateStringExpressionPair, AggregateZipParam, AggregateSubstrCPParam, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, AggregatedateFromPartsParam, AggregateLiteralParam } from '../typing';
import { AggregateCommand } from './AbstractCommand';

@@ -178,2 +178,26 @@ export declare class AggregateCommandImpl<T> extends AggregateCommand {

}
export declare class AllElementsTrueAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression> {
constructor(value: AggregateArrayExpression);
}
export declare class AnyElementTrueAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression> {
constructor(value: AggregateArrayExpression);
}
export declare class SetDifferenceAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetEqualsAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetIntersectionAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetIsSubsetAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetUnionAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class LiteralAggregateCommand extends AggregateCommandImpl<AggregateLiteralParam> {
constructor(value: AggregateLiteralParam);
}
export declare class ArrayToObjectAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression[]> {

@@ -230,1 +254,31 @@ constructor(value: AggregateArrayExpression[]);

}
export declare class DateFromPartsAggregateCommand extends AggregateCommandImpl<AggregatedateFromPartsParam> {
constructor(value: AggregatedateFromPartsParam);
}
export declare class DayOfMonthAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class DayOfWeekAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class DayOfYearAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class HourAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class ISODayOfWeekAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class ISOWeekYearAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class MillisecondAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class MinuteAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class SecondAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}

2

esm/command/aggregate.js

@@ -1,1 +0,1 @@

var e=function(){var n=function(t,r){n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,g){o.__proto__=g}||function(o,g){for(var i in g)if(Object.prototype.hasOwnProperty.call(g,i))o[i]=g[i]};return n(t,r)};return function(t,r){if(typeof r!=="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");n(t,r);function o(){this.constructor=t}t.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}}();import{AggregateCommand as m}from"./AbstractCommand";import{AggregateRequest as c}from"./AggregateRequest";var a=function(n){e(t,n);function t(r,o){return n.call(this,r,new c(o).toJSON())||this}return t}(m);export{a as AggregateCommandImpl};var u=function(n){e(t,n);function t(r){return n.call(this,"abs",r)||this}return t}(a);export{u as AbsAggregateCommand};var d=function(n){e(t,n);function t(r){return n.call(this,"add",r)||this}return t}(a);export{d as AddAggregateCommand};var l=function(n){e(t,n);function t(r){return n.call(this,"addToSet",r)||this}return t}(a);export{l as AddToSetAggregateCommand};var A=function(n){e(t,n);function t(r){return n.call(this,"and",r)||this}return t}(a);export{A as AndAggregateCommand};var f=function(n){e(t,n);function t(r){return n.call(this,"arrayElemAt",r)||this}return t}(a);export{f as ArrayElemAtAggregateCommand};var C=function(n){e(t,n);function t(r){return n.call(this,"avg",r)||this}return t}(a);export{C as AvgAggregateCommand};var h=function(n){e(t,n);function t(r){return n.call(this,"ceil",r)||this}return t}(a);export{h as CeilAggregateCommand};var s=function(n){e(t,n);function t(r){return n.call(this,"cmp",r)||this}return t}(a);export{s as CMPAggregateCommand};var x=function(n){e(t,n);function t(r){return n.call(this,"concat",r)||this}return t}(a);export{x as ConcatAggregateCommand};var v=function(n){e(t,n);function t(r){var o=Array.isArray(r)?{if:r[0],then:r[1],else:r[2]}:r;return n.call(this,"cond",o)||this}return t}(a);export{v as CondAggregateCommand};var p=function(n){e(t,n);function t(){return n.call(this,"count",{})||this}t.prototype.stringify=function(){return{$sum:1}};return t}(a);export{p as CountAggregateCommand};var y=function(n){e(t,n);function t(r){return n.call(this,"dateToString",r)||this}return t}(a);export{y as DateToStringAggregateCommand};var S=function(n){e(t,n);function t(r){return n.call(this,"divide",r)||this}return t}(a);export{S as DivideAggregateCommand};var O=function(n){e(t,n);function t(r){return n.call(this,"eq",r)||this}return t}(a);export{O as EqAggregateCommand};var L=function(n){e(t,n);function t(r){return n.call(this,"exp",r)||this}return t}(a);export{L as ExpAggregateCommand};var P=function(n){e(t,n);function t(r){return n.call(this,"first",r)||this}return t}(a);export{P as FirstAggregateCommand};var T=function(n){e(t,n);function t(r){return n.call(this,"floor",r)||this}return t}(a);export{T as FloorAggregateCommand};var b=function(n){e(t,n);function t(r){return n.call(this,"gt",r)||this}return t}(a);export{b as GtAggregateCommand};var I=function(n){e(t,n);function t(r){return n.call(this,"gte",r)||this}return t}(a);export{I as GteAggregateCommand};var M=function(n){e(t,n);function t(r){return n.call(this,"ifNull",r)||this}return t}(a);export{M as IfNullAggregateCommand};var w=function(n){e(t,n);function t(r){return n.call(this,"in",r)||this}return t}(a);export{w as InAggregateCommand};var j=function(n){e(t,n);function t(r){return n.call(this,"indexOfArray",r)||this}return t}(a);export{j as IndexOfArrayAggregateCommand};var D=function(n){e(t,n);function t(r){return n.call(this,"isArray",r)||this}return t}(a);export{D as IsArrayAggregateCommand};var q=function(n){e(t,n);function t(r){return n.call(this,"isoWeek",r)||this}return t}(a);export{q as ISOWeekAggregateCommand};var B=function(n){e(t,n);function t(r){return n.call(this,"last",r)||this}return t}(a);export{B as LastAggregateCommand};var F=function(n){e(t,n);function t(r){return n.call(this,"let",r)||this}return t}(a);export{F as LetAggregateCommand};var E=function(n){e(t,n);function t(r){return n.call(this,"ln",r)||this}return t}(a);export{E as LnAggregateCommand};var N=function(n){e(t,n);function t(r){return n.call(this,"log",r)||this}return t}(a);export{N as LogAggregateCommand};var R=function(n){e(t,n);function t(r){return n.call(this,"log10",r)||this}return t}(a);export{R as Log10AggregateCommand};var k=function(n){e(t,n);function t(r){return n.call(this,"lt",r)||this}return t}(a);export{k as LtAggregateCommand};var W=function(n){e(t,n);function t(r){return n.call(this,"lte",r)||this}return t}(a);export{W as LteAggregateCommand};var z=function(n){e(t,n);function t(r){return n.call(this,"map",r)||this}return t}(a);export{z as MapAggregateCommand};var G=function(n){e(t,n);function t(r){return n.call(this,"max",r)||this}return t}(a);export{G as MaxAggregateCommand};var U=function(n){e(t,n);function t(r){return n.call(this,"mergeObjects",r)||this}return t}(a);export{U as MergeObjectsAggregateCommand};var Y=function(n){e(t,n);function t(r){return n.call(this,"min",r)||this}return t}(a);export{Y as MinAggregateCommand};var Z=function(n){e(t,n);function t(r){return n.call(this,"mod",r)||this}return t}(a);export{Z as ModAggregateCommand};var J=function(n){e(t,n);function t(r){return n.call(this,"month",r)||this}return t}(a);export{J as MonthAggregateCommand};var $=function(n){e(t,n);function t(r){return n.call(this,"multiply",r)||this}return t}(a);export{$ as MultiplyAggregateCommand};var H=function(n){e(t,n);function t(r){return n.call(this,"ne",r)||this}return t}(a);export{H as NeqAggregateCommand};var K=function(n){e(t,n);function t(r){return n.call(this,"not",[r])||this}return t}(a);export{K as NotAggregateCommand};var Q=function(n){e(t,n);function t(r){return n.call(this,"or",r)||this}return t}(a);export{Q as OrAggregateCommand};var V=function(n){e(t,n);function t(r){return n.call(this,"pow",r)||this}return t}(a);export{V as PowAggregateCommand};var X=function(n){e(t,n);function t(r){return n.call(this,"push",r)||this}return t}(a);export{X as PushAggregateCommand};var _=function(n){e(t,n);function t(r){return n.call(this,"size",r)||this}return t}(a);export{_ as SizeAggregateCommand};var tt=function(n){e(t,n);function t(r){return n.call(this,"slice",r)||this}return t}(a);export{tt as SliceAggregateCommand};var nt=function(n){e(t,n);function t(r){return n.call(this,"split",r)||this}return t}(a);export{nt as SplitAggregateCommand};var rt=function(n){e(t,n);function t(r){return n.call(this,"sqrt",r)||this}return t}(a);export{rt as SqrtAggregateCommand};var et=function(n){e(t,n);function t(r){return n.call(this,"substr",r)||this}return t}(a);export{et as SubstrAggregateCommand};var at=function(n){e(t,n);function t(r){return n.call(this,"substrBytes",r)||this}return t}(a);export{at as SubstrBytesAggregateCommand};var ot=function(n){e(t,n);function t(r){return n.call(this,"subtract",r)||this}return t}(a);export{ot as SubtractAggregateCommand};var gt=function(n){e(t,n);function t(r){return n.call(this,"sum",r)||this}return t}(a);export{gt as SumAggregateCommand};var it=function(n){e(t,n);function t(r){var o=r.branches.map(function(g){if(Array.isArray(g)){return{case:g[0],then:g[1]}}return{case:g.case,then:g.then}});return n.call(this,"switch",{branches:o,default:r.default})||this}return t}(a);export{it as SwitchAggregateCommand};var mt=function(n){e(t,n);function t(r){return n.call(this,"toLower",r)||this}return t}(a);export{mt as ToLowerAggregateCommand};var ct=function(n){e(t,n);function t(r){return n.call(this,"toUpper",r)||this}return t}(a);export{ct as ToUpperAggregateCommand};var ut=function(n){e(t,n);function t(r){return n.call(this,"trunc",r)||this}return t}(a);export{ut as TruncAggregateCommand};var dt=function(n){e(t,n);function t(r){return n.call(this,"week",r)||this}return t}(a);export{dt as WeekAggregateCommand};var lt=function(n){e(t,n);function t(r){return n.call(this,"year",r)||this}return t}(a);export{lt as YearAggregateCommand};var At=function(n){e(t,n);function t(r){return n.call(this,"arrayToObject",r)||this}return t}(a);export{At as ArrayToObjectAggregateCommand};var ft=function(n){e(t,n);function t(r){return n.call(this,"concatArrays",r)||this}return t}(a);export{ft as ConcatArraysAggregateCommand};var Ct=function(n){e(t,n);function t(r){return n.call(this,"filter",r)||this}return t}(a);export{Ct as FilterAggregateCommand};var ht=function(n){e(t,n);function t(r){return n.call(this,"objectToArray",r)||this}return t}(a);export{ht as ObjectToArrayAggregateCommand};var st=function(n){e(t,n);function t(r){return n.call(this,"range",r)||this}return t}(a);export{st as RangeAggregateCommand};var xt=function(n){e(t,n);function t(r){return n.call(this,"reduce",r)||this}return t}(a);export{xt as ReduceAggregateCommand};var vt=function(n){e(t,n);function t(r){return n.call(this,"reverseArray",r)||this}return t}(a);export{vt as ReverseArrayAggregateCommand};var pt=function(n){e(t,n);function t(r){return n.call(this,"zip",r)||this}return t}(a);export{pt as ZipAggregateCommand};var yt=function(n){e(t,n);function t(r){return n.call(this,"dateFromString",r)||this}return t}(a);export{yt as DateFromStringAggregateCommand};var St=function(n){e(t,n);function t(r){return n.call(this,"indexOfBytes",r)||this}return t}(a);export{St as IndexOfBytesAggregateCommand};var Ot=function(n){e(t,n);function t(r){return n.call(this,"indexOfCP",r)||this}return t}(a);export{Ot as IndexOfCPAggregateCommand};var Lt=function(n){e(t,n);function t(r){return n.call(this,"strLenBytes",r)||this}return t}(a);export{Lt as StrLenBytesAggregateCommand};var Pt=function(n){e(t,n);function t(r){return n.call(this,"strLenCP",r)||this}return t}(a);export{Pt as StrLenCPAggregateCommand};var Tt=function(n){e(t,n);function t(r){return n.call(this,"strcasecmp",r)||this}return t}(a);export{Tt as StrcasecmpAggregateCommand};var bt=function(n){e(t,n);function t(r){return n.call(this,"substrCP",r)||this}return t}(a);export{bt as SubstrCPAggregateCommand};var It=function(n){e(t,n);function t(r){return n.call(this,"stdDevPop",r)||this}return t}(a);export{It as StdDevPopAggregateCommand};var Mt=function(n){e(t,n);function t(r){return n.call(this,"stdDevSamp",r)||this}return t}(a);export{Mt as StdDevSampAggregateCommand};
var e=function(){var n=function(t,r){n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,g){o.__proto__=g}||function(o,g){for(var i in g)if(Object.prototype.hasOwnProperty.call(g,i))o[i]=g[i]};return n(t,r)};return function(t,r){if(typeof r!=="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");n(t,r);function o(){this.constructor=t}t.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}}();import{AggregateCommand as m}from"./AbstractCommand";import{AggregateRequest as c}from"./AggregateRequest";var a=function(n){e(t,n);function t(r,o){return n.call(this,r,new c(o).toJSON())||this}return t}(m);export{a as AggregateCommandImpl};var u=function(n){e(t,n);function t(r){return n.call(this,"abs",r)||this}return t}(a);export{u as AbsAggregateCommand};var l=function(n){e(t,n);function t(r){return n.call(this,"add",r)||this}return t}(a);export{l as AddAggregateCommand};var d=function(n){e(t,n);function t(r){return n.call(this,"addToSet",r)||this}return t}(a);export{d as AddToSetAggregateCommand};var f=function(n){e(t,n);function t(r){return n.call(this,"and",r)||this}return t}(a);export{f as AndAggregateCommand};var A=function(n){e(t,n);function t(r){return n.call(this,"arrayElemAt",r)||this}return t}(a);export{A as ArrayElemAtAggregateCommand};var s=function(n){e(t,n);function t(r){return n.call(this,"avg",r)||this}return t}(a);export{s as AvgAggregateCommand};var C=function(n){e(t,n);function t(r){return n.call(this,"ceil",r)||this}return t}(a);export{C as CeilAggregateCommand};var h=function(n){e(t,n);function t(r){return n.call(this,"cmp",r)||this}return t}(a);export{h as CMPAggregateCommand};var x=function(n){e(t,n);function t(r){return n.call(this,"concat",r)||this}return t}(a);export{x as ConcatAggregateCommand};var v=function(n){e(t,n);function t(r){var o=Array.isArray(r)?{if:r[0],then:r[1],else:r[2]}:r;return n.call(this,"cond",o)||this}return t}(a);export{v as CondAggregateCommand};var S=function(n){e(t,n);function t(){return n.call(this,"count",{})||this}t.prototype.stringify=function(){return{$sum:1}};return t}(a);export{S as CountAggregateCommand};var y=function(n){e(t,n);function t(r){return n.call(this,"dateToString",r)||this}return t}(a);export{y as DateToStringAggregateCommand};var p=function(n){e(t,n);function t(r){return n.call(this,"divide",r)||this}return t}(a);export{p as DivideAggregateCommand};var O=function(n){e(t,n);function t(r){return n.call(this,"eq",r)||this}return t}(a);export{O as EqAggregateCommand};var D=function(n){e(t,n);function t(r){return n.call(this,"exp",r)||this}return t}(a);export{D as ExpAggregateCommand};var I=function(n){e(t,n);function t(r){return n.call(this,"first",r)||this}return t}(a);export{I as FirstAggregateCommand};var L=function(n){e(t,n);function t(r){return n.call(this,"floor",r)||this}return t}(a);export{L as FloorAggregateCommand};var T=function(n){e(t,n);function t(r){return n.call(this,"gt",r)||this}return t}(a);export{T as GtAggregateCommand};var M=function(n){e(t,n);function t(r){return n.call(this,"gte",r)||this}return t}(a);export{M as GteAggregateCommand};var P=function(n){e(t,n);function t(r){return n.call(this,"ifNull",r)||this}return t}(a);export{P as IfNullAggregateCommand};var b=function(n){e(t,n);function t(r){return n.call(this,"in",r)||this}return t}(a);export{b as InAggregateCommand};var E=function(n){e(t,n);function t(r){return n.call(this,"indexOfArray",r)||this}return t}(a);export{E as IndexOfArrayAggregateCommand};var k=function(n){e(t,n);function t(r){return n.call(this,"isArray",r)||this}return t}(a);export{k as IsArrayAggregateCommand};var w=function(n){e(t,n);function t(r){return n.call(this,"isoWeek",r)||this}return t}(a);export{w as ISOWeekAggregateCommand};var W=function(n){e(t,n);function t(r){return n.call(this,"last",r)||this}return t}(a);export{W as LastAggregateCommand};var j=function(n){e(t,n);function t(r){return n.call(this,"let",r)||this}return t}(a);export{j as LetAggregateCommand};var q=function(n){e(t,n);function t(r){return n.call(this,"ln",r)||this}return t}(a);export{q as LnAggregateCommand};var F=function(n){e(t,n);function t(r){return n.call(this,"log",r)||this}return t}(a);export{F as LogAggregateCommand};var B=function(n){e(t,n);function t(r){return n.call(this,"log10",r)||this}return t}(a);export{B as Log10AggregateCommand};var N=function(n){e(t,n);function t(r){return n.call(this,"lt",r)||this}return t}(a);export{N as LtAggregateCommand};var Y=function(n){e(t,n);function t(r){return n.call(this,"lte",r)||this}return t}(a);export{Y as LteAggregateCommand};var R=function(n){e(t,n);function t(r){return n.call(this,"map",r)||this}return t}(a);export{R as MapAggregateCommand};var U=function(n){e(t,n);function t(r){return n.call(this,"max",r)||this}return t}(a);export{U as MaxAggregateCommand};var z=function(n){e(t,n);function t(r){return n.call(this,"mergeObjects",r)||this}return t}(a);export{z as MergeObjectsAggregateCommand};var G=function(n){e(t,n);function t(r){return n.call(this,"min",r)||this}return t}(a);export{G as MinAggregateCommand};var H=function(n){e(t,n);function t(r){return n.call(this,"mod",r)||this}return t}(a);export{H as ModAggregateCommand};var Z=function(n){e(t,n);function t(r){return n.call(this,"month",r)||this}return t}(a);export{Z as MonthAggregateCommand};var J=function(n){e(t,n);function t(r){return n.call(this,"multiply",r)||this}return t}(a);export{J as MultiplyAggregateCommand};var $=function(n){e(t,n);function t(r){return n.call(this,"ne",r)||this}return t}(a);export{$ as NeqAggregateCommand};var K=function(n){e(t,n);function t(r){return n.call(this,"not",[r])||this}return t}(a);export{K as NotAggregateCommand};var Q=function(n){e(t,n);function t(r){return n.call(this,"or",r)||this}return t}(a);export{Q as OrAggregateCommand};var V=function(n){e(t,n);function t(r){return n.call(this,"pow",r)||this}return t}(a);export{V as PowAggregateCommand};var X=function(n){e(t,n);function t(r){return n.call(this,"push",r)||this}return t}(a);export{X as PushAggregateCommand};var _=function(n){e(t,n);function t(r){return n.call(this,"size",r)||this}return t}(a);export{_ as SizeAggregateCommand};var tt=function(n){e(t,n);function t(r){return n.call(this,"slice",r)||this}return t}(a);export{tt as SliceAggregateCommand};var nt=function(n){e(t,n);function t(r){return n.call(this,"split",r)||this}return t}(a);export{nt as SplitAggregateCommand};var rt=function(n){e(t,n);function t(r){return n.call(this,"sqrt",r)||this}return t}(a);export{rt as SqrtAggregateCommand};var et=function(n){e(t,n);function t(r){return n.call(this,"substr",r)||this}return t}(a);export{et as SubstrAggregateCommand};var at=function(n){e(t,n);function t(r){return n.call(this,"substrBytes",r)||this}return t}(a);export{at as SubstrBytesAggregateCommand};var ot=function(n){e(t,n);function t(r){return n.call(this,"subtract",r)||this}return t}(a);export{ot as SubtractAggregateCommand};var gt=function(n){e(t,n);function t(r){return n.call(this,"sum",r)||this}return t}(a);export{gt as SumAggregateCommand};var it=function(n){e(t,n);function t(r){var o=r.branches.map(function(g){if(Array.isArray(g)){return{case:g[0],then:g[1]}}return{case:g.case,then:g.then}});return n.call(this,"switch",{branches:o,default:r.default})||this}return t}(a);export{it as SwitchAggregateCommand};var mt=function(n){e(t,n);function t(r){return n.call(this,"toLower",r)||this}return t}(a);export{mt as ToLowerAggregateCommand};var ct=function(n){e(t,n);function t(r){return n.call(this,"toUpper",r)||this}return t}(a);export{ct as ToUpperAggregateCommand};var ut=function(n){e(t,n);function t(r){return n.call(this,"trunc",r)||this}return t}(a);export{ut as TruncAggregateCommand};var lt=function(n){e(t,n);function t(r){return n.call(this,"week",r)||this}return t}(a);export{lt as WeekAggregateCommand};var dt=function(n){e(t,n);function t(r){return n.call(this,"year",r)||this}return t}(a);export{dt as YearAggregateCommand};var ft=function(n){e(t,n);function t(r){return n.call(this,"allElementsTrue",r)||this}return t}(a);export{ft as AllElementsTrueAggregateCommand};var At=function(n){e(t,n);function t(r){return n.call(this,"anyElementTrue",r)||this}return t}(a);export{At as AnyElementTrueAggregateCommand};var st=function(n){e(t,n);function t(r){return n.call(this,"setDifference",r)||this}return t}(a);export{st as SetDifferenceAggregateCommand};var Ct=function(n){e(t,n);function t(r){return n.call(this,"setEquals",r)||this}return t}(a);export{Ct as SetEqualsAggregateCommand};var ht=function(n){e(t,n);function t(r){return n.call(this,"setIntersection",r)||this}return t}(a);export{ht as SetIntersectionAggregateCommand};var xt=function(n){e(t,n);function t(r){return n.call(this,"setIsSubset",r)||this}return t}(a);export{xt as SetIsSubsetAggregateCommand};var vt=function(n){e(t,n);function t(r){return n.call(this,"setUnion",r)||this}return t}(a);export{vt as SetUnionAggregateCommand};var St=function(n){e(t,n);function t(r){return n.call(this,"literal",r)||this}return t}(a);export{St as LiteralAggregateCommand};var yt=function(n){e(t,n);function t(r){return n.call(this,"arrayToObject",r)||this}return t}(a);export{yt as ArrayToObjectAggregateCommand};var pt=function(n){e(t,n);function t(r){return n.call(this,"concatArrays",r)||this}return t}(a);export{pt as ConcatArraysAggregateCommand};var Ot=function(n){e(t,n);function t(r){return n.call(this,"filter",r)||this}return t}(a);export{Ot as FilterAggregateCommand};var Dt=function(n){e(t,n);function t(r){return n.call(this,"objectToArray",r)||this}return t}(a);export{Dt as ObjectToArrayAggregateCommand};var It=function(n){e(t,n);function t(r){return n.call(this,"range",r)||this}return t}(a);export{It as RangeAggregateCommand};var Lt=function(n){e(t,n);function t(r){return n.call(this,"reduce",r)||this}return t}(a);export{Lt as ReduceAggregateCommand};var Tt=function(n){e(t,n);function t(r){return n.call(this,"reverseArray",r)||this}return t}(a);export{Tt as ReverseArrayAggregateCommand};var Mt=function(n){e(t,n);function t(r){return n.call(this,"zip",r)||this}return t}(a);export{Mt as ZipAggregateCommand};var Pt=function(n){e(t,n);function t(r){return n.call(this,"dateFromString",r)||this}return t}(a);export{Pt as DateFromStringAggregateCommand};var bt=function(n){e(t,n);function t(r){return n.call(this,"indexOfBytes",r)||this}return t}(a);export{bt as IndexOfBytesAggregateCommand};var Et=function(n){e(t,n);function t(r){return n.call(this,"indexOfCP",r)||this}return t}(a);export{Et as IndexOfCPAggregateCommand};var kt=function(n){e(t,n);function t(r){return n.call(this,"strLenBytes",r)||this}return t}(a);export{kt as StrLenBytesAggregateCommand};var wt=function(n){e(t,n);function t(r){return n.call(this,"strLenCP",r)||this}return t}(a);export{wt as StrLenCPAggregateCommand};var Wt=function(n){e(t,n);function t(r){return n.call(this,"strcasecmp",r)||this}return t}(a);export{Wt as StrcasecmpAggregateCommand};var jt=function(n){e(t,n);function t(r){return n.call(this,"substrCP",r)||this}return t}(a);export{jt as SubstrCPAggregateCommand};var qt=function(n){e(t,n);function t(r){return n.call(this,"stdDevPop",r)||this}return t}(a);export{qt as StdDevPopAggregateCommand};var Ft=function(n){e(t,n);function t(r){return n.call(this,"stdDevSamp",r)||this}return t}(a);export{Ft as StdDevSampAggregateCommand};var Bt=function(n){e(t,n);function t(r){return n.call(this,"dateFromParts",r)||this}return t}(a);export{Bt as DateFromPartsAggregateCommand};var Nt=function(n){e(t,n);function t(r){return n.call(this,"dayOfMonth",r)||this}return t}(a);export{Nt as DayOfMonthAggregateCommand};var Yt=function(n){e(t,n);function t(r){return n.call(this,"dayOfWeek",r)||this}return t}(a);export{Yt as DayOfWeekAggregateCommand};var Rt=function(n){e(t,n);function t(r){return n.call(this,"dayOfYear",r)||this}return t}(a);export{Rt as DayOfYearAggregateCommand};var Ut=function(n){e(t,n);function t(r){return n.call(this,"hour",r)||this}return t}(a);export{Ut as HourAggregateCommand};var zt=function(n){e(t,n);function t(r){return n.call(this,"isoDayOfWeek",r)||this}return t}(a);export{zt as ISODayOfWeekAggregateCommand};var Gt=function(n){e(t,n);function t(r){return n.call(this,"isoWeekYear",r)||this}return t}(a);export{Gt as ISOWeekYearAggregateCommand};var Ht=function(n){e(t,n);function t(r){return n.call(this,"millisecond",r)||this}return t}(a);export{Ht as MillisecondAggregateCommand};var Zt=function(n){e(t,n);function t(r){return n.call(this,"minute",r)||this}return t}(a);export{Zt as MinuteAggregateCommand};var Jt=function(n){e(t,n);function t(r){return n.call(this,"second",r)||this}return t}(a);export{Jt as SecondAggregateCommand};
import { Sort } from '../common/constant';
import { AggregateArrayExpression, AggregateDateExpression, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateStringExpression, AggregateStringExpressionPair, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, PushCommandParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, GeoWinthinParam, GeoNearParam, GeoIntersectsParam, AggregateRangeParam, AggregateFilterParam, AggregateReduceParam, AggregateZipParam, AggregateDateFromStringParam, AggregateStrcasecmpParam, AggregateSubstrCPParam, AggregateIndexOfParam } from '../typing';
import { AggregateArrayExpression, AggregateDateExpression, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateStringExpression, AggregateStringExpressionPair, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, PushCommandParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, GeoWinthinParam, GeoNearParam, GeoIntersectsParam, AggregateRangeParam, AggregateFilterParam, AggregateReduceParam, AggregateZipParam, AggregateDateFromStringParam, AggregateStrcasecmpParam, AggregateSubstrCPParam, AggregateIndexOfParam, AggregateArrayExpressionPair, AggregatedateFromPartsParam, AggregateLiteralParam } from '../typing';
import { AggregateCommand, QueryChainCommand, QueryCommand } from './AbstractCommand';
import { AbsAggregateCommand, AddAggregateCommand, AddToSetAggregateCommand, AndAggregateCommand, ArrayElemAtAggregateCommand, ArrayToObjectAggregateCommand, AvgAggregateCommand, CeilAggregateCommand, CMPAggregateCommand, ConcatAggregateCommand, ConcatArraysAggregateCommand, CondAggregateCommand, CountAggregateCommand, DateFromStringAggregateCommand, DateToStringAggregateCommand, DivideAggregateCommand, EqAggregateCommand, ExpAggregateCommand, FilterAggregateCommand, FirstAggregateCommand, FloorAggregateCommand, GtAggregateCommand, GteAggregateCommand, IfNullAggregateCommand, InAggregateCommand, IndexOfArrayAggregateCommand, IndexOfBytesAggregateCommand, IndexOfCPAggregateCommand, IsArrayAggregateCommand, ISOWeekAggregateCommand, LastAggregateCommand, LetAggregateCommand, LnAggregateCommand, Log10AggregateCommand, LogAggregateCommand, LtAggregateCommand, LteAggregateCommand, MapAggregateCommand, MaxAggregateCommand, MergeObjectsAggregateCommand, MinAggregateCommand, ModAggregateCommand, MonthAggregateCommand, MultiplyAggregateCommand, NeqAggregateCommand, NotAggregateCommand, ObjectToArrayAggregateCommand, OrAggregateCommand, PowAggregateCommand, PushAggregateCommand, RangeAggregateCommand, ReverseArrayAggregateCommand, ReduceAggregateCommand, SizeAggregateCommand, SliceAggregateCommand, SplitAggregateCommand, SqrtAggregateCommand, StdDevPopAggregateCommand, StdDevSampAggregateCommand, StrcasecmpAggregateCommand, StrLenBytesAggregateCommand, StrLenCPAggregateCommand, SubstrAggregateCommand, SubstrBytesAggregateCommand, SubstrCPAggregateCommand, SubtractAggregateCommand, SumAggregateCommand, SwitchAggregateCommand, ToLowerAggregateCommand, ToUpperAggregateCommand, TruncAggregateCommand, WeekAggregateCommand, YearAggregateCommand, ZipAggregateCommand } from './aggregate';
import { AbsAggregateCommand, AddAggregateCommand, AddToSetAggregateCommand, AllElementsTrueAggregateCommand, AndAggregateCommand, AnyElementTrueAggregateCommand, ArrayElemAtAggregateCommand, ArrayToObjectAggregateCommand, AvgAggregateCommand, CeilAggregateCommand, CMPAggregateCommand, ConcatAggregateCommand, ConcatArraysAggregateCommand, CondAggregateCommand, CountAggregateCommand, DateFromStringAggregateCommand, DateToStringAggregateCommand, DivideAggregateCommand, EqAggregateCommand, ExpAggregateCommand, FilterAggregateCommand, FirstAggregateCommand, FloorAggregateCommand, GtAggregateCommand, GteAggregateCommand, IfNullAggregateCommand, InAggregateCommand, IndexOfArrayAggregateCommand, IndexOfBytesAggregateCommand, IndexOfCPAggregateCommand, IsArrayAggregateCommand, ISOWeekAggregateCommand, LastAggregateCommand, LetAggregateCommand, LiteralAggregateCommand, LnAggregateCommand, Log10AggregateCommand, LogAggregateCommand, LtAggregateCommand, LteAggregateCommand, MapAggregateCommand, MaxAggregateCommand, MergeObjectsAggregateCommand, MinAggregateCommand, ModAggregateCommand, MonthAggregateCommand, MultiplyAggregateCommand, NeqAggregateCommand, NotAggregateCommand, ObjectToArrayAggregateCommand, OrAggregateCommand, PowAggregateCommand, PushAggregateCommand, RangeAggregateCommand, ReverseArrayAggregateCommand, ReduceAggregateCommand, SetDifferenceAggregateCommand, SetEqualsAggregateCommand, SetIntersectionAggregateCommand, SetIsSubsetAggregateCommand, SetUnionAggregateCommand, SizeAggregateCommand, SliceAggregateCommand, SplitAggregateCommand, SqrtAggregateCommand, StdDevPopAggregateCommand, StdDevSampAggregateCommand, StrcasecmpAggregateCommand, StrLenBytesAggregateCommand, StrLenCPAggregateCommand, SubstrAggregateCommand, SubstrBytesAggregateCommand, SubstrCPAggregateCommand, SubtractAggregateCommand, SumAggregateCommand, SwitchAggregateCommand, ToLowerAggregateCommand, ToUpperAggregateCommand, TruncAggregateCommand, WeekAggregateCommand, YearAggregateCommand, ZipAggregateCommand, DateFromPartsAggregateCommand, DayOfMonthAggregateCommand, DayOfWeekAggregateCommand, DayOfYearAggregateCommand, HourAggregateCommand, ISODayOfWeekAggregateCommand, ISOWeekYearAggregateCommand, MillisecondAggregateCommand, MinuteAggregateCommand, SecondAggregateCommand } from './aggregate';
import { AggregatePipeline } from './AggregatePipeline';

@@ -128,2 +128,20 @@ import { ExprCommand } from './query/expr';

stdDevSamp(value: AggregateExpression): StdDevSampAggregateCommand;
allElementsTrue(value: AggregateArrayExpression[]): AllElementsTrueAggregateCommand;
anyElementTrue(value: AggregateArrayExpression[]): AnyElementTrueAggregateCommand;
setDifference(value: AggregateArrayExpressionPair): SetDifferenceAggregateCommand;
setEquals(value: AggregateArrayExpressionPair): SetEqualsAggregateCommand;
setIntersection(value: AggregateArrayExpressionPair): SetIntersectionAggregateCommand;
setIsSubset(value: AggregateArrayExpressionPair): SetIsSubsetAggregateCommand;
setUnion(value: AggregateArrayExpressionPair): SetUnionAggregateCommand;
literal(value: AggregateLiteralParam): LiteralAggregateCommand;
dateFromParts(value: AggregatedateFromPartsParam): DateFromPartsAggregateCommand;
dayOfMonth(value: AggregateDateParam): DayOfMonthAggregateCommand;
dayOfWeek(value: AggregateDateParam): DayOfWeekAggregateCommand;
dayOfYear(value: AggregateDateParam): DayOfYearAggregateCommand;
hour(value: AggregateDateParam): HourAggregateCommand;
isoDayOfWeek(value: AggregateDateParam): ISODayOfWeekAggregateCommand;
isoWeekYear(value: AggregateDateParam): ISOWeekYearAggregateCommand;
millisecond(value: AggregateDateParam): MillisecondAggregateCommand;
minute(value: AggregateDateParam): MinuteAggregateCommand;
second(value: AggregateDateParam): SecondAggregateCommand;
}

@@ -130,0 +148,0 @@ export declare class Command {

@@ -1,1 +0,1 @@

var p=function(t,r,e){if(e||arguments.length===2)for(var n=0,a=r.length,m;n<a;n++){if(m||!(n in r)){if(!m)m=Array.prototype.slice.call(r,0,n);m[n]=r[n]}}return t.concat(m||Array.prototype.slice.call(r))};import{Sort as y}from"../common/constant";import{AbsAggregateCommand as f,AddAggregateCommand as c,AddToSetAggregateCommand as d,AndAggregateCommand as A,ArrayElemAtAggregateCommand as w,ArrayToObjectAggregateCommand as C,AvgAggregateCommand as s,CeilAggregateCommand as l,CMPAggregateCommand as v,ConcatAggregateCommand as h,ConcatArraysAggregateCommand as S,CondAggregateCommand as x,CountAggregateCommand as b,DateFromStringAggregateCommand as P,DateToStringAggregateCommand as L,DivideAggregateCommand as M,EqAggregateCommand as O,ExpAggregateCommand as T,FilterAggregateCommand as I,FirstAggregateCommand as q,FloorAggregateCommand as N,GtAggregateCommand as E,GteAggregateCommand as D,IfNullAggregateCommand as F,InAggregateCommand as G,IndexOfArrayAggregateCommand as j,IndexOfBytesAggregateCommand as B,IndexOfCPAggregateCommand as z,IsArrayAggregateCommand as R,ISOWeekAggregateCommand as W,LastAggregateCommand as k,LetAggregateCommand as U,LnAggregateCommand as Q,Log10AggregateCommand as Y,LogAggregateCommand as H,LtAggregateCommand as J,LteAggregateCommand as K,MapAggregateCommand as V,MaxAggregateCommand as X,MergeObjectsAggregateCommand as Z,MinAggregateCommand as $,ModAggregateCommand as _,MonthAggregateCommand as rr,MultiplyAggregateCommand as tr,NeqAggregateCommand as nr,NotAggregateCommand as er,ObjectToArrayAggregateCommand as or,OrAggregateCommand as ar,PowAggregateCommand as mr,PushAggregateCommand as pr,RangeAggregateCommand as ur,ReverseArrayAggregateCommand as gr,ReduceAggregateCommand as ir,SizeAggregateCommand as yr,SliceAggregateCommand as fr,SplitAggregateCommand as cr,SqrtAggregateCommand as dr,StdDevPopAggregateCommand as Ar,StdDevSampAggregateCommand as wr,StrcasecmpAggregateCommand as Cr,StrLenBytesAggregateCommand as sr,StrLenCPAggregateCommand as lr,SubstrAggregateCommand as vr,SubstrBytesAggregateCommand as hr,SubstrCPAggregateCommand as Sr,SubtractAggregateCommand as xr,SumAggregateCommand as br,SwitchAggregateCommand as Pr,ToLowerAggregateCommand as Lr,ToUpperAggregateCommand as Mr,TruncAggregateCommand as Or,WeekAggregateCommand as Tr,YearAggregateCommand as Ir,ZipAggregateCommand as qr}from"./aggregate";import{AggregatePipeline as Nr}from"./AggregatePipeline";import{AllCommand as Er}from"./query/all";import{AndCommand as Dr,NorCommand as Fr,NotCommand as Gr,OrCommand as jr}from"./query/logic";import{ElemMatchCommand as Br}from"./query/elemMatch";import{EqCommand as zr}from"./query/eq";import{ExistsCommand as Rr}from"./query/exists";import{ExprCommand as Wr}from"./query/expr";import{GtCommand as kr}from"./query/gt";import{GteCommand as Ur}from"./query/gte";import{InCommand as Qr}from"./query/in";import{LtCommand as Yr}from"./query/lt";import{LteCommand as Hr}from"./query/lte";import{ModCommand as Jr}from"./query/mod";import{NeqCommand as Kr}from"./query/neq";import{NinCommand as Vr}from"./query/nin";import{QueryChain as o}from"./query/QueryChain";import{SizeCommand as Xr}from"./query/size";import{AddToSetCommand as Zr}from"./update/addToSet";import{IncCommand as $r}from"./update/inc";import{MaxCommand as _r}from"./update/max";import{MinCommand as rt}from"./update/min";import{MulCommand as tt}from"./update/mul";import{PopCommand as nt}from"./update/pop";import{PullCommand as et}from"./update/pull";import{PullAllCommand as ot}from"./update/pullAll";import{PushCommand as u}from"./update/push";import{RemoveCommand as at}from"./update/remove";import{RenameCommand as mt}from"./update/rename";import{SetCommand as pt}from"./update/set";import{GeoIntersectsCommand as ut,GeoNearCommand as gt,GeoWithinCommand as it}from"./query/geo";import{UnShiftCommand as yt}from"./update/unshift";import{ShiftCommand as ft}from"./update/shift";var g=function(){function t(){}t.prototype.pipeline=function(){return new Nr};t.prototype.avg=function(r){return new s(r)};t.prototype.count=function(){return new b};t.prototype.max=function(r){return new X(r)};t.prototype.min=function(r){return new $(r)};t.prototype.sum=function(r){return new br(r)};t.prototype.and=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}var a=Array.isArray(r)?r:p([r],e,true);return new A(a)};t.prototype.or=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}var a=Array.isArray(r)?r:p([r],e,true);return new ar(a)};t.prototype.not=function(r){return new er(r)};t.prototype.cmp=function(r,e){var n=Array.isArray(r)?r:[r,e];return new v(n)};t.prototype.eq=function(r,e){var n=Array.isArray(r)?r:[r,e];return new O(n)};t.prototype.neq=function(r,e){var n=Array.isArray(r)?r:[r,e];return new nr(n)};t.prototype.lt=function(r,e){var n=Array.isArray(r)?r:[r,e];return new J(n)};t.prototype.lte=function(r,e){var n=Array.isArray(r)?r:[r,e];return new K(n)};t.prototype.gt=function(r,e){var n=Array.isArray(r)?r:[r,e];return new E(n)};t.prototype.gte=function(r,e){var n=Array.isArray(r)?r:[r,e];return new D(n)};t.prototype.addToSet=function(r){return new d(r)};t.prototype.arrayElemAt=function(r,e){var n=Array.isArray(r)?r:[r,e];return new w(n)};t.prototype.indexOfArray=function(r,e,n,a){var m=Array.isArray(r)?r:[r,e,n,a].filter(function(i){return i!==void 0});return new j(m)};t.prototype.isArray=function(r){return new R(r)};t.prototype.size=function(r){return new yr(r)};t.prototype.in=function(r,e){var n=Array.isArray(r)?r:[r,e];return new G(n)};t.prototype.slice=function(r,e,n){var a=Array.isArray(r)?r:[r,e,n].filter(function(m){return m!==void 0});return new fr(a)};t.prototype.map=function(r){return new V(r)};t.prototype.ifNull=function(r,e){var n=Array.isArray(r)?r:[r,e];return new F(n)};t.prototype.cond=function(r){return new x(r)};t.prototype.switch=function(r){return new Pr(r)};t.prototype.concat=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}var a=Array.isArray(r)?r:p([r],e,true);return new h(a)};t.prototype.dateToString=function(r){return new L(r)};t.prototype.toLower=function(r){return new Lr(r)};t.prototype.toUpper=function(r){return new Mr(r)};t.prototype.split=function(r,e){var n=Array.isArray(r)?r:[r,e];return new cr(n)};t.prototype.substr=function(r,e,n){var a=Array.isArray(r)?r:[r,e,n];return new vr(a)};t.prototype.substrBytes=function(r,e,n){var a=Array.isArray(r)?r:[r,e,n];return new hr(a)};t.prototype.first=function(r){return new q(r)};t.prototype.last=function(r){return new k(r)};t.prototype.push=function(r){return new pr(r)};t.prototype.let=function(r){return new U(r)};t.prototype.add=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}var a=Array.isArray(r)?r:p([r],e,true);return new c(a)};t.prototype.subtract=function(r,e){var n=Array.isArray(r)?r:[r,e];return new xr(n)};t.prototype.multiply=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}var a=Array.isArray(r)?r:p([r],e,true);return new tr(a)};t.prototype.divide=function(r,e){var n=Array.isArray(r)?r:[r,e];return new M(n)};t.prototype.abs=function(r){return new f(r)};t.prototype.ceil=function(r){return new l(r)};t.prototype.exp=function(r){return new T(r)};t.prototype.floor=function(r){return new N(r)};t.prototype.ln=function(r){return new Q(r)};t.prototype.log=function(r,e){var n=Array.isArray(r)?r:[r,e];return new H(n)};t.prototype.log10=function(r){return new Y(r)};t.prototype.mod=function(r,e){var n=Array.isArray(r)?r:[r,e];return new _(n)};t.prototype.pow=function(r,e){var n=Array.isArray(r)?r:[r,e];return new mr(n)};t.prototype.sqrt=function(r){return new dr(r)};t.prototype.trunc=function(r){return new Or(r)};t.prototype.mergeObjects=function(r){return new Z(r)};t.prototype.month=function(r){return new rr(r)};t.prototype.year=function(r){return new Ir(r)};t.prototype.week=function(r){return new Tr(r)};t.prototype.isoWeek=function(r){return new W(r)};t.prototype.arrayToObject=function(r){return new C(r)};t.prototype.concatArrays=function(r){return new S(r)};t.prototype.filter=function(r){return new I(r)};t.prototype.objectToArray=function(r){return new or(r)};t.prototype.range=function(r,e,n){var a=Array.isArray(r)?r:typeof n!=="undefined"?[r,e,n]:[r,e];return new ur(a)};t.prototype.reduce=function(r){return new ir(r)};t.prototype.reverseArray=function(r){return new gr(r)};t.prototype.zip=function(r){return new qr(r)};t.prototype.dateFromString=function(r){return new P(r)};t.prototype.indexOfBytes=function(r){return new B(r)};t.prototype.indexOfCP=function(r){return new z(r)};t.prototype.strLenBytes=function(r){return new sr(r)};t.prototype.strLenCP=function(r){return new lr(r)};t.prototype.strcasecmp=function(r){return new Cr(r)};t.prototype.substrCP=function(r){return new Sr(r)};t.prototype.stdDevPop=function(r){return new Ar(r)};t.prototype.stdDevSamp=function(r){return new wr(r)};return t}();export{g as AggregateCommandFactory};var ct=function(){function t(){this.aggregate=new g;this.Sort=y}t.prototype.addToSet=function(r){return new Zr(r)};t.prototype.inc=function(r){return new $r(r)};t.prototype.max=function(r){return new _r(r)};t.prototype.min=function(r){return new rt(r)};t.prototype.mul=function(r){return new tt(r)};t.prototype.pop=function(r){return new nt(r)};t.prototype.pull=function(r){return new et(r)};t.prototype.pullAll=function(r){return new ot(r)};t.prototype.push=function(r){var e=[];for(var n=1;n<arguments.length;n++){e[n-1]=arguments[n]}return new(u.bind.apply(u,p([void 0,r],e,false)))};t.prototype.remove=function(){return new at};t.prototype.rename=function(r){return new mt(r)};t.prototype.set=function(r){return new pt(r)};t.prototype.expr=function(r){return new Wr(r)};t.prototype.geoWithin=function(r){return new it(r)};t.prototype.geoNear=function(r){return new gt(r)};t.prototype.geoIntersects=function(r){return new ut(r)};t.prototype.unshift=function(r){return new yt(r)};t.prototype.shift=function(){return new ft};t.prototype.and=function(){var r=[];for(var e=0;e<arguments.length;e++){r[e]=arguments[e]}r=Array.isArray(r[0])?r[0]:r;var n=new Dr(r.map(o.unchain));return new o(n)};t.prototype.or=function(){var r=[];for(var e=0;e<arguments.length;e++){r[e]=arguments[e]}r=Array.isArray(r[0])?r[0]:r;var n=new jr(r.map(o.unchain));return new o(n)};t.prototype.not=function(r){var e=new Gr(o.unchain(r));return new o(e)};t.prototype.nor=function(){var r=[];for(var e=0;e<arguments.length;e++){r[e]=arguments[e]}r=Array.isArray(r[0])?r[0]:r;var n=new Fr(r.map(o.unchain));return new o(n)};t.prototype.eq=function(r){return new o(new zr(r))};t.prototype.neq=function(r){return new o(new Kr(r))};t.prototype.lt=function(r){return new o(new Yr(r))};t.prototype.lte=function(r){return new o(new Hr(r))};t.prototype.gt=function(r){return new o(new kr(r))};t.prototype.gte=function(r){return new o(new Ur(r))};t.prototype.in=function(r){return new o(new Qr(r))};t.prototype.nin=function(r){return new o(new Vr(r))};t.prototype.exists=function(r){return new o(new Rr(r))};t.prototype.mod=function(r,e){return new o(new Jr(r,e))};t.prototype.all=function(r){return new o(new Er(r))};t.prototype.elemMatch=function(r){return new o(new Br(o.unchain(r)))};t.prototype.size=function(r){return new o(new Xr(r))};return t}();export{ct as Command};
var g=function(e,r,n){if(n||arguments.length===2)for(var t=0,a=r.length,m;t<a;t++){if(m||!(t in r)){if(!m)m=Array.prototype.slice.call(r,0,t);m[t]=r[t]}}return e.concat(m||Array.prototype.slice.call(r))};import{Sort as y}from"../common/constant";import{AbsAggregateCommand as f,AddAggregateCommand as c,AddToSetAggregateCommand as d,AllElementsTrueAggregateCommand as A,AndAggregateCommand as w,AnyElementTrueAggregateCommand as C,ArrayElemAtAggregateCommand as s,ArrayToObjectAggregateCommand as l,AvgAggregateCommand as v,CeilAggregateCommand as S,CMPAggregateCommand as h,ConcatAggregateCommand as O,ConcatArraysAggregateCommand as b,CondAggregateCommand as x,CountAggregateCommand as M,DateFromStringAggregateCommand as P,DateToStringAggregateCommand as I,DivideAggregateCommand as T,EqAggregateCommand as L,ExpAggregateCommand as D,FilterAggregateCommand as E,FirstAggregateCommand as q,FloorAggregateCommand as W,GtAggregateCommand as k,GteAggregateCommand as N,IfNullAggregateCommand as F,InAggregateCommand as G,IndexOfArrayAggregateCommand as j,IndexOfBytesAggregateCommand as B,IndexOfCPAggregateCommand as z,IsArrayAggregateCommand as R,ISOWeekAggregateCommand as U,LastAggregateCommand as Y,LetAggregateCommand as H,LiteralAggregateCommand as Q,LnAggregateCommand as J,Log10AggregateCommand as K,LogAggregateCommand as V,LtAggregateCommand as X,LteAggregateCommand as Z,MapAggregateCommand as $,MaxAggregateCommand as _,MergeObjectsAggregateCommand as rr,MinAggregateCommand as er,ModAggregateCommand as tr,MonthAggregateCommand as nr,MultiplyAggregateCommand as or,NeqAggregateCommand as ar,NotAggregateCommand as mr,ObjectToArrayAggregateCommand as gr,OrAggregateCommand as pr,PowAggregateCommand as ur,PushAggregateCommand as ir,RangeAggregateCommand as yr,ReverseArrayAggregateCommand as fr,ReduceAggregateCommand as cr,SetDifferenceAggregateCommand as dr,SetEqualsAggregateCommand as Ar,SetIntersectionAggregateCommand as wr,SetIsSubsetAggregateCommand as Cr,SetUnionAggregateCommand as sr,SizeAggregateCommand as lr,SliceAggregateCommand as vr,SplitAggregateCommand as Sr,SqrtAggregateCommand as hr,StdDevPopAggregateCommand as Or,StdDevSampAggregateCommand as br,StrcasecmpAggregateCommand as xr,StrLenBytesAggregateCommand as Mr,StrLenCPAggregateCommand as Pr,SubstrAggregateCommand as Ir,SubstrBytesAggregateCommand as Tr,SubstrCPAggregateCommand as Lr,SubtractAggregateCommand as Dr,SumAggregateCommand as Er,SwitchAggregateCommand as qr,ToLowerAggregateCommand as Wr,ToUpperAggregateCommand as kr,TruncAggregateCommand as Nr,WeekAggregateCommand as Fr,YearAggregateCommand as Gr,ZipAggregateCommand as jr,DateFromPartsAggregateCommand as Br,DayOfMonthAggregateCommand as zr,DayOfWeekAggregateCommand as Rr,DayOfYearAggregateCommand as Ur,HourAggregateCommand as Yr,ISODayOfWeekAggregateCommand as Hr,ISOWeekYearAggregateCommand as Qr,MillisecondAggregateCommand as Jr,MinuteAggregateCommand as Kr,SecondAggregateCommand as Vr}from"./aggregate";import{AggregatePipeline as Xr}from"./AggregatePipeline";import{AllCommand as Zr}from"./query/all";import{AndCommand as $r,NorCommand as _r,NotCommand as re,OrCommand as ee}from"./query/logic";import{ElemMatchCommand as te}from"./query/elemMatch";import{EqCommand as ne}from"./query/eq";import{ExistsCommand as oe}from"./query/exists";import{ExprCommand as ae}from"./query/expr";import{GtCommand as me}from"./query/gt";import{GteCommand as ge}from"./query/gte";import{InCommand as pe}from"./query/in";import{LtCommand as ue}from"./query/lt";import{LteCommand as ie}from"./query/lte";import{ModCommand as ye}from"./query/mod";import{NeqCommand as fe}from"./query/neq";import{NinCommand as ce}from"./query/nin";import{QueryChain as o}from"./query/QueryChain";import{SizeCommand as de}from"./query/size";import{AddToSetCommand as Ae}from"./update/addToSet";import{IncCommand as we}from"./update/inc";import{MaxCommand as Ce}from"./update/max";import{MinCommand as se}from"./update/min";import{MulCommand as le}from"./update/mul";import{PopCommand as ve}from"./update/pop";import{PullCommand as Se}from"./update/pull";import{PullAllCommand as he}from"./update/pullAll";import{PushCommand as p}from"./update/push";import{RemoveCommand as Oe}from"./update/remove";import{RenameCommand as be}from"./update/rename";import{SetCommand as xe}from"./update/set";import{GeoIntersectsCommand as Me,GeoNearCommand as Pe,GeoWithinCommand as Ie}from"./query/geo";import{UnShiftCommand as Te}from"./update/unshift";import{ShiftCommand as Le}from"./update/shift";var u=function(){function e(){}e.prototype.pipeline=function(){return new Xr};e.prototype.avg=function(r){return new v(r)};e.prototype.count=function(){return new M};e.prototype.max=function(r){return new _(r)};e.prototype.min=function(r){return new er(r)};e.prototype.sum=function(r){return new Er(r)};e.prototype.and=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}var a=Array.isArray(r)?r:g([r],n,true);return new w(a)};e.prototype.or=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}var a=Array.isArray(r)?r:g([r],n,true);return new pr(a)};e.prototype.not=function(r){return new mr(r)};e.prototype.cmp=function(r,n){var t=Array.isArray(r)?r:[r,n];return new h(t)};e.prototype.eq=function(r,n){var t=Array.isArray(r)?r:[r,n];return new L(t)};e.prototype.neq=function(r,n){var t=Array.isArray(r)?r:[r,n];return new ar(t)};e.prototype.lt=function(r,n){var t=Array.isArray(r)?r:[r,n];return new X(t)};e.prototype.lte=function(r,n){var t=Array.isArray(r)?r:[r,n];return new Z(t)};e.prototype.gt=function(r,n){var t=Array.isArray(r)?r:[r,n];return new k(t)};e.prototype.gte=function(r,n){var t=Array.isArray(r)?r:[r,n];return new N(t)};e.prototype.addToSet=function(r){return new d(r)};e.prototype.arrayElemAt=function(r,n){var t=Array.isArray(r)?r:[r,n];return new s(t)};e.prototype.indexOfArray=function(r,n,t,a){var m=Array.isArray(r)?r:[r,n,t,a].filter(function(i){return i!==void 0});return new j(m)};e.prototype.isArray=function(r){return new R(r)};e.prototype.size=function(r){return new lr(r)};e.prototype.in=function(r,n){var t=Array.isArray(r)?r:[r,n];return new G(t)};e.prototype.slice=function(r,n,t){var a=Array.isArray(r)?r:[r,n,t].filter(function(m){return m!==void 0});return new vr(a)};e.prototype.map=function(r){return new $(r)};e.prototype.ifNull=function(r,n){var t=Array.isArray(r)?r:[r,n];return new F(t)};e.prototype.cond=function(r){return new x(r)};e.prototype.switch=function(r){return new qr(r)};e.prototype.concat=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}var a=Array.isArray(r)?r:g([r],n,true);return new O(a)};e.prototype.dateToString=function(r){return new I(r)};e.prototype.toLower=function(r){return new Wr(r)};e.prototype.toUpper=function(r){return new kr(r)};e.prototype.split=function(r,n){var t=Array.isArray(r)?r:[r,n];return new Sr(t)};e.prototype.substr=function(r,n,t){var a=Array.isArray(r)?r:[r,n,t];return new Ir(a)};e.prototype.substrBytes=function(r,n,t){var a=Array.isArray(r)?r:[r,n,t];return new Tr(a)};e.prototype.first=function(r){return new q(r)};e.prototype.last=function(r){return new Y(r)};e.prototype.push=function(r){return new ir(r)};e.prototype.let=function(r){return new H(r)};e.prototype.add=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}var a=Array.isArray(r)?r:g([r],n,true);return new c(a)};e.prototype.subtract=function(r,n){var t=Array.isArray(r)?r:[r,n];return new Dr(t)};e.prototype.multiply=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}var a=Array.isArray(r)?r:g([r],n,true);return new or(a)};e.prototype.divide=function(r,n){var t=Array.isArray(r)?r:[r,n];return new T(t)};e.prototype.abs=function(r){return new f(r)};e.prototype.ceil=function(r){return new S(r)};e.prototype.exp=function(r){return new D(r)};e.prototype.floor=function(r){return new W(r)};e.prototype.ln=function(r){return new J(r)};e.prototype.log=function(r,n){var t=Array.isArray(r)?r:[r,n];return new V(t)};e.prototype.log10=function(r){return new K(r)};e.prototype.mod=function(r,n){var t=Array.isArray(r)?r:[r,n];return new tr(t)};e.prototype.pow=function(r,n){var t=Array.isArray(r)?r:[r,n];return new ur(t)};e.prototype.sqrt=function(r){return new hr(r)};e.prototype.trunc=function(r){return new Nr(r)};e.prototype.mergeObjects=function(r){return new rr(r)};e.prototype.month=function(r){return new nr(r)};e.prototype.year=function(r){return new Gr(r)};e.prototype.week=function(r){return new Fr(r)};e.prototype.isoWeek=function(r){return new U(r)};e.prototype.arrayToObject=function(r){return new l(r)};e.prototype.concatArrays=function(r){return new b(r)};e.prototype.filter=function(r){return new E(r)};e.prototype.objectToArray=function(r){return new gr(r)};e.prototype.range=function(r,n,t){var a=Array.isArray(r)?r:typeof t!=="undefined"?[r,n,t]:[r,n];return new yr(a)};e.prototype.reduce=function(r){return new cr(r)};e.prototype.reverseArray=function(r){return new fr(r)};e.prototype.zip=function(r){return new jr(r)};e.prototype.dateFromString=function(r){return new P(r)};e.prototype.indexOfBytes=function(r){return new B(r)};e.prototype.indexOfCP=function(r){return new z(r)};e.prototype.strLenBytes=function(r){return new Mr(r)};e.prototype.strLenCP=function(r){return new Pr(r)};e.prototype.strcasecmp=function(r){return new xr(r)};e.prototype.substrCP=function(r){return new Lr(r)};e.prototype.stdDevPop=function(r){return new Or(r)};e.prototype.stdDevSamp=function(r){return new br(r)};e.prototype.allElementsTrue=function(r){return new A(r)};e.prototype.anyElementTrue=function(r){return new C(r)};e.prototype.setDifference=function(r){return new dr(r)};e.prototype.setEquals=function(r){return new Ar(r)};e.prototype.setIntersection=function(r){return new wr(r)};e.prototype.setIsSubset=function(r){return new Cr(r)};e.prototype.setUnion=function(r){return new sr(r)};e.prototype.literal=function(r){return new Q(r)};e.prototype.dateFromParts=function(r){return new Br(r)};e.prototype.dayOfMonth=function(r){return new zr(r)};e.prototype.dayOfWeek=function(r){return new Rr(r)};e.prototype.dayOfYear=function(r){return new Ur(r)};e.prototype.hour=function(r){return new Yr(r)};e.prototype.isoDayOfWeek=function(r){return new Hr(r)};e.prototype.isoWeekYear=function(r){return new Qr(r)};e.prototype.millisecond=function(r){return new Jr(r)};e.prototype.minute=function(r){return new Kr(r)};e.prototype.second=function(r){return new Vr(r)};return e}();export{u as AggregateCommandFactory};var De=function(){function e(){this.aggregate=new u;this.Sort=y}e.prototype.addToSet=function(r){return new Ae(r)};e.prototype.inc=function(r){return new we(r)};e.prototype.max=function(r){return new Ce(r)};e.prototype.min=function(r){return new se(r)};e.prototype.mul=function(r){return new le(r)};e.prototype.pop=function(r){return new ve(r)};e.prototype.pull=function(r){return new Se(r)};e.prototype.pullAll=function(r){return new he(r)};e.prototype.push=function(r){var n=[];for(var t=1;t<arguments.length;t++){n[t-1]=arguments[t]}return new(p.bind.apply(p,g([void 0,r],n,false)))};e.prototype.remove=function(){return new Oe};e.prototype.rename=function(r){return new be(r)};e.prototype.set=function(r){return new xe(r)};e.prototype.expr=function(r){return new ae(r)};e.prototype.geoWithin=function(r){return new Ie(r)};e.prototype.geoNear=function(r){return new Pe(r)};e.prototype.geoIntersects=function(r){return new Me(r)};e.prototype.unshift=function(r){return new Te(r)};e.prototype.shift=function(){return new Le};e.prototype.and=function(){var r=[];for(var n=0;n<arguments.length;n++){r[n]=arguments[n]}r=Array.isArray(r[0])?r[0]:r;var t=new $r(r.map(o.unchain));return new o(t)};e.prototype.or=function(){var r=[];for(var n=0;n<arguments.length;n++){r[n]=arguments[n]}r=Array.isArray(r[0])?r[0]:r;var t=new ee(r.map(o.unchain));return new o(t)};e.prototype.not=function(r){var n=new re(o.unchain(r));return new o(n)};e.prototype.nor=function(){var r=[];for(var n=0;n<arguments.length;n++){r[n]=arguments[n]}r=Array.isArray(r[0])?r[0]:r;var t=new _r(r.map(o.unchain));return new o(t)};e.prototype.eq=function(r){return new o(new ne(r))};e.prototype.neq=function(r){return new o(new fe(r))};e.prototype.lt=function(r){return new o(new ue(r))};e.prototype.lte=function(r){return new o(new ie(r))};e.prototype.gt=function(r){return new o(new me(r))};e.prototype.gte=function(r){return new o(new ge(r))};e.prototype.in=function(r){return new o(new pe(r))};e.prototype.nin=function(r){return new o(new ce(r))};e.prototype.exists=function(r){return new o(new oe(r))};e.prototype.mod=function(r,n){return new o(new ye(r,n))};e.prototype.all=function(r){return new o(new Zr(r))};e.prototype.elemMatch=function(r){return new o(new te(o.unchain(r)))};e.prototype.size=function(r){return new o(new de(r))};return e}();export{De as Command};

@@ -1,2 +0,2 @@

import { AggregateCommand } from './command/AbstractCommand';
import { AggregateCommand, QueryCommand, UpdateCommand } from './command/AbstractCommand';
import { CollectionAction, DocumentAction, PipelineStageName, Sort, Target } from './common/constant';

@@ -8,2 +8,3 @@ import { GeoPolygon, GeoMultiPolygon, GeoPoint, GeoLineString, GeoMultiPoint, GeoMultiLineString } from './mongo-builder/Geo';

export type AggregateArrayExpression = AggregateExpression<any[]>;
export type AggregateArrayExpressionPair = [AggregateArrayExpression, AggregateArrayExpression];
export type AggregateNumberExpression = AggregateExpression<number>;

@@ -204,1 +205,15 @@ export type AggregateNumberExpressionPair = [AggregateNumberExpression, AggregateNumberExpression];

export type AggregateSubstrCPParam = [AggregateStringExpression, AggregateNumberExpression, AggregateNumberExpression];
export interface AggregatedateFromPartsParam {
year?: AggregateNumberExpression;
month?: AggregateNumberExpression;
day?: AggregateNumberExpression;
hour?: AggregateNumberExpression;
minute?: AggregateNumberExpression;
second?: AggregateNumberExpression;
millisecond?: AggregateNumberExpression;
timezone?: string;
isoWeekYear?: AggregateNumberExpression;
isoWeek?: AggregateNumberExpression;
isoDayOfWeek?: AggregateNumberExpression;
}
export type AggregateLiteralParam = AggregateExpression | QueryCommand | UpdateCommand;

@@ -1,2 +0,2 @@

import { AggregateArrayExpression, AggregateDateFromStringParam, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateFilterParam, AggregateIndexOfParam, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateRangeParam, AggregateReduceParam, AggregateStrcasecmpParam, AggregateStringExpression, AggregateStringExpressionPair, AggregateZipParam, AggregateSubstrCPParam, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam } from '../typing';
import { AggregateArrayExpression, AggregateArrayExpressionPair, AggregateDateFromStringParam, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateFilterParam, AggregateIndexOfParam, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateRangeParam, AggregateReduceParam, AggregateStrcasecmpParam, AggregateStringExpression, AggregateStringExpressionPair, AggregateZipParam, AggregateSubstrCPParam, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, AggregatedateFromPartsParam, AggregateLiteralParam } from '../typing';
import { AggregateCommand } from './AbstractCommand';

@@ -178,2 +178,26 @@ export declare class AggregateCommandImpl<T> extends AggregateCommand {

}
export declare class AllElementsTrueAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression> {
constructor(value: AggregateArrayExpression);
}
export declare class AnyElementTrueAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression> {
constructor(value: AggregateArrayExpression);
}
export declare class SetDifferenceAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetEqualsAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetIntersectionAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetIsSubsetAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class SetUnionAggregateCommand extends AggregateCommandImpl<AggregateArrayExpressionPair> {
constructor(value: AggregateArrayExpressionPair);
}
export declare class LiteralAggregateCommand extends AggregateCommandImpl<AggregateLiteralParam> {
constructor(value: AggregateLiteralParam);
}
export declare class ArrayToObjectAggregateCommand extends AggregateCommandImpl<AggregateArrayExpression[]> {

@@ -230,1 +254,31 @@ constructor(value: AggregateArrayExpression[]);

}
export declare class DateFromPartsAggregateCommand extends AggregateCommandImpl<AggregatedateFromPartsParam> {
constructor(value: AggregatedateFromPartsParam);
}
export declare class DayOfMonthAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class DayOfWeekAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class DayOfYearAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class HourAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class ISODayOfWeekAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class ISOWeekYearAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class MillisecondAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class MinuteAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}
export declare class SecondAggregateCommand extends AggregateCommandImpl<AggregateDateParam> {
constructor(value: AggregateDateParam);
}

@@ -1,1 +0,1 @@

"use strict";var __extends=this&&this.__extends||function(){var e=function(t,r){e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,n){g.__proto__=n}||function(g,n){for(var a in n)if(Object.prototype.hasOwnProperty.call(n,a))g[a]=n[a]};return e(t,r)};return function(t,r){if(typeof r!=="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function g(){this.constructor=t}t.prototype=r===null?Object.create(r):(g.prototype=r.prototype,new g)}}();Object.defineProperty(exports,"__esModule",{value:true});exports.SubstrBytesAggregateCommand=exports.SubstrAggregateCommand=exports.SqrtAggregateCommand=exports.SplitAggregateCommand=exports.SliceAggregateCommand=exports.SizeAggregateCommand=exports.PushAggregateCommand=exports.PowAggregateCommand=exports.OrAggregateCommand=exports.NotAggregateCommand=exports.NeqAggregateCommand=exports.MultiplyAggregateCommand=exports.MonthAggregateCommand=exports.ModAggregateCommand=exports.MinAggregateCommand=exports.MergeObjectsAggregateCommand=exports.MaxAggregateCommand=exports.MapAggregateCommand=exports.LteAggregateCommand=exports.LtAggregateCommand=exports.Log10AggregateCommand=exports.LogAggregateCommand=exports.LnAggregateCommand=exports.LetAggregateCommand=exports.LastAggregateCommand=exports.ISOWeekAggregateCommand=exports.IsArrayAggregateCommand=exports.IndexOfArrayAggregateCommand=exports.InAggregateCommand=exports.IfNullAggregateCommand=exports.GteAggregateCommand=exports.GtAggregateCommand=exports.FloorAggregateCommand=exports.FirstAggregateCommand=exports.ExpAggregateCommand=exports.EqAggregateCommand=exports.DivideAggregateCommand=exports.DateToStringAggregateCommand=exports.CountAggregateCommand=exports.CondAggregateCommand=exports.ConcatAggregateCommand=exports.CMPAggregateCommand=exports.CeilAggregateCommand=exports.AvgAggregateCommand=exports.ArrayElemAtAggregateCommand=exports.AndAggregateCommand=exports.AddToSetAggregateCommand=exports.AddAggregateCommand=exports.AbsAggregateCommand=exports.AggregateCommandImpl=void 0;exports.StdDevSampAggregateCommand=exports.StdDevPopAggregateCommand=exports.SubstrCPAggregateCommand=exports.StrcasecmpAggregateCommand=exports.StrLenCPAggregateCommand=exports.StrLenBytesAggregateCommand=exports.IndexOfCPAggregateCommand=exports.IndexOfBytesAggregateCommand=exports.DateFromStringAggregateCommand=exports.ZipAggregateCommand=exports.ReverseArrayAggregateCommand=exports.ReduceAggregateCommand=exports.RangeAggregateCommand=exports.ObjectToArrayAggregateCommand=exports.FilterAggregateCommand=exports.ConcatArraysAggregateCommand=exports.ArrayToObjectAggregateCommand=exports.YearAggregateCommand=exports.WeekAggregateCommand=exports.TruncAggregateCommand=exports.ToUpperAggregateCommand=exports.ToLowerAggregateCommand=exports.SwitchAggregateCommand=exports.SumAggregateCommand=exports.SubtractAggregateCommand=void 0;var AbstractCommand_1=require("./AbstractCommand");var AggregateRequest_1=require("./AggregateRequest");var AggregateCommandImpl=function(e){__extends(t,e);function t(r,g){return e.call(this,r,new AggregateRequest_1.AggregateRequest(g).toJSON())||this}return t}(AbstractCommand_1.AggregateCommand);exports.AggregateCommandImpl=AggregateCommandImpl;var AbsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"abs",r)||this}return t}(AggregateCommandImpl);exports.AbsAggregateCommand=AbsAggregateCommand;var AddAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"add",r)||this}return t}(AggregateCommandImpl);exports.AddAggregateCommand=AddAggregateCommand;var AddToSetAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"addToSet",r)||this}return t}(AggregateCommandImpl);exports.AddToSetAggregateCommand=AddToSetAggregateCommand;var AndAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"and",r)||this}return t}(AggregateCommandImpl);exports.AndAggregateCommand=AndAggregateCommand;var ArrayElemAtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"arrayElemAt",r)||this}return t}(AggregateCommandImpl);exports.ArrayElemAtAggregateCommand=ArrayElemAtAggregateCommand;var AvgAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"avg",r)||this}return t}(AggregateCommandImpl);exports.AvgAggregateCommand=AvgAggregateCommand;var CeilAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ceil",r)||this}return t}(AggregateCommandImpl);exports.CeilAggregateCommand=CeilAggregateCommand;var CMPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"cmp",r)||this}return t}(AggregateCommandImpl);exports.CMPAggregateCommand=CMPAggregateCommand;var ConcatAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"concat",r)||this}return t}(AggregateCommandImpl);exports.ConcatAggregateCommand=ConcatAggregateCommand;var CondAggregateCommand=function(e){__extends(t,e);function t(r){var g=Array.isArray(r)?{if:r[0],then:r[1],else:r[2]}:r;return e.call(this,"cond",g)||this}return t}(AggregateCommandImpl);exports.CondAggregateCommand=CondAggregateCommand;var CountAggregateCommand=function(e){__extends(t,e);function t(){return e.call(this,"count",{})||this}t.prototype.stringify=function(){return{$sum:1}};return t}(AggregateCommandImpl);exports.CountAggregateCommand=CountAggregateCommand;var DateToStringAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dateToString",r)||this}return t}(AggregateCommandImpl);exports.DateToStringAggregateCommand=DateToStringAggregateCommand;var DivideAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"divide",r)||this}return t}(AggregateCommandImpl);exports.DivideAggregateCommand=DivideAggregateCommand;var EqAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"eq",r)||this}return t}(AggregateCommandImpl);exports.EqAggregateCommand=EqAggregateCommand;var ExpAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"exp",r)||this}return t}(AggregateCommandImpl);exports.ExpAggregateCommand=ExpAggregateCommand;var FirstAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"first",r)||this}return t}(AggregateCommandImpl);exports.FirstAggregateCommand=FirstAggregateCommand;var FloorAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"floor",r)||this}return t}(AggregateCommandImpl);exports.FloorAggregateCommand=FloorAggregateCommand;var GtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"gt",r)||this}return t}(AggregateCommandImpl);exports.GtAggregateCommand=GtAggregateCommand;var GteAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"gte",r)||this}return t}(AggregateCommandImpl);exports.GteAggregateCommand=GteAggregateCommand;var IfNullAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ifNull",r)||this}return t}(AggregateCommandImpl);exports.IfNullAggregateCommand=IfNullAggregateCommand;var InAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"in",r)||this}return t}(AggregateCommandImpl);exports.InAggregateCommand=InAggregateCommand;var IndexOfArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfArray",r)||this}return t}(AggregateCommandImpl);exports.IndexOfArrayAggregateCommand=IndexOfArrayAggregateCommand;var IsArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isArray",r)||this}return t}(AggregateCommandImpl);exports.IsArrayAggregateCommand=IsArrayAggregateCommand;var ISOWeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isoWeek",r)||this}return t}(AggregateCommandImpl);exports.ISOWeekAggregateCommand=ISOWeekAggregateCommand;var LastAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"last",r)||this}return t}(AggregateCommandImpl);exports.LastAggregateCommand=LastAggregateCommand;var LetAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"let",r)||this}return t}(AggregateCommandImpl);exports.LetAggregateCommand=LetAggregateCommand;var LnAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ln",r)||this}return t}(AggregateCommandImpl);exports.LnAggregateCommand=LnAggregateCommand;var LogAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"log",r)||this}return t}(AggregateCommandImpl);exports.LogAggregateCommand=LogAggregateCommand;var Log10AggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"log10",r)||this}return t}(AggregateCommandImpl);exports.Log10AggregateCommand=Log10AggregateCommand;var LtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"lt",r)||this}return t}(AggregateCommandImpl);exports.LtAggregateCommand=LtAggregateCommand;var LteAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"lte",r)||this}return t}(AggregateCommandImpl);exports.LteAggregateCommand=LteAggregateCommand;var MapAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"map",r)||this}return t}(AggregateCommandImpl);exports.MapAggregateCommand=MapAggregateCommand;var MaxAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"max",r)||this}return t}(AggregateCommandImpl);exports.MaxAggregateCommand=MaxAggregateCommand;var MergeObjectsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"mergeObjects",r)||this}return t}(AggregateCommandImpl);exports.MergeObjectsAggregateCommand=MergeObjectsAggregateCommand;var MinAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"min",r)||this}return t}(AggregateCommandImpl);exports.MinAggregateCommand=MinAggregateCommand;var ModAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"mod",r)||this}return t}(AggregateCommandImpl);exports.ModAggregateCommand=ModAggregateCommand;var MonthAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"month",r)||this}return t}(AggregateCommandImpl);exports.MonthAggregateCommand=MonthAggregateCommand;var MultiplyAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"multiply",r)||this}return t}(AggregateCommandImpl);exports.MultiplyAggregateCommand=MultiplyAggregateCommand;var NeqAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ne",r)||this}return t}(AggregateCommandImpl);exports.NeqAggregateCommand=NeqAggregateCommand;var NotAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"not",[r])||this}return t}(AggregateCommandImpl);exports.NotAggregateCommand=NotAggregateCommand;var OrAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"or",r)||this}return t}(AggregateCommandImpl);exports.OrAggregateCommand=OrAggregateCommand;var PowAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"pow",r)||this}return t}(AggregateCommandImpl);exports.PowAggregateCommand=PowAggregateCommand;var PushAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"push",r)||this}return t}(AggregateCommandImpl);exports.PushAggregateCommand=PushAggregateCommand;var SizeAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"size",r)||this}return t}(AggregateCommandImpl);exports.SizeAggregateCommand=SizeAggregateCommand;var SliceAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"slice",r)||this}return t}(AggregateCommandImpl);exports.SliceAggregateCommand=SliceAggregateCommand;var SplitAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"split",r)||this}return t}(AggregateCommandImpl);exports.SplitAggregateCommand=SplitAggregateCommand;var SqrtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"sqrt",r)||this}return t}(AggregateCommandImpl);exports.SqrtAggregateCommand=SqrtAggregateCommand;var SubstrAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substr",r)||this}return t}(AggregateCommandImpl);exports.SubstrAggregateCommand=SubstrAggregateCommand;var SubstrBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substrBytes",r)||this}return t}(AggregateCommandImpl);exports.SubstrBytesAggregateCommand=SubstrBytesAggregateCommand;var SubtractAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"subtract",r)||this}return t}(AggregateCommandImpl);exports.SubtractAggregateCommand=SubtractAggregateCommand;var SumAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"sum",r)||this}return t}(AggregateCommandImpl);exports.SumAggregateCommand=SumAggregateCommand;var SwitchAggregateCommand=function(e){__extends(t,e);function t(r){var g=r.branches.map(function(n){if(Array.isArray(n)){return{case:n[0],then:n[1]}}return{case:n.case,then:n.then}});return e.call(this,"switch",{branches:g,default:r.default})||this}return t}(AggregateCommandImpl);exports.SwitchAggregateCommand=SwitchAggregateCommand;var ToLowerAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"toLower",r)||this}return t}(AggregateCommandImpl);exports.ToLowerAggregateCommand=ToLowerAggregateCommand;var ToUpperAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"toUpper",r)||this}return t}(AggregateCommandImpl);exports.ToUpperAggregateCommand=ToUpperAggregateCommand;var TruncAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"trunc",r)||this}return t}(AggregateCommandImpl);exports.TruncAggregateCommand=TruncAggregateCommand;var WeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"week",r)||this}return t}(AggregateCommandImpl);exports.WeekAggregateCommand=WeekAggregateCommand;var YearAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"year",r)||this}return t}(AggregateCommandImpl);exports.YearAggregateCommand=YearAggregateCommand;var ArrayToObjectAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"arrayToObject",r)||this}return t}(AggregateCommandImpl);exports.ArrayToObjectAggregateCommand=ArrayToObjectAggregateCommand;var ConcatArraysAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"concatArrays",r)||this}return t}(AggregateCommandImpl);exports.ConcatArraysAggregateCommand=ConcatArraysAggregateCommand;var FilterAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"filter",r)||this}return t}(AggregateCommandImpl);exports.FilterAggregateCommand=FilterAggregateCommand;var ObjectToArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"objectToArray",r)||this}return t}(AggregateCommandImpl);exports.ObjectToArrayAggregateCommand=ObjectToArrayAggregateCommand;var RangeAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"range",r)||this}return t}(AggregateCommandImpl);exports.RangeAggregateCommand=RangeAggregateCommand;var ReduceAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"reduce",r)||this}return t}(AggregateCommandImpl);exports.ReduceAggregateCommand=ReduceAggregateCommand;var ReverseArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"reverseArray",r)||this}return t}(AggregateCommandImpl);exports.ReverseArrayAggregateCommand=ReverseArrayAggregateCommand;var ZipAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"zip",r)||this}return t}(AggregateCommandImpl);exports.ZipAggregateCommand=ZipAggregateCommand;var DateFromStringAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dateFromString",r)||this}return t}(AggregateCommandImpl);exports.DateFromStringAggregateCommand=DateFromStringAggregateCommand;var IndexOfBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfBytes",r)||this}return t}(AggregateCommandImpl);exports.IndexOfBytesAggregateCommand=IndexOfBytesAggregateCommand;var IndexOfCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfCP",r)||this}return t}(AggregateCommandImpl);exports.IndexOfCPAggregateCommand=IndexOfCPAggregateCommand;var StrLenBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strLenBytes",r)||this}return t}(AggregateCommandImpl);exports.StrLenBytesAggregateCommand=StrLenBytesAggregateCommand;var StrLenCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strLenCP",r)||this}return t}(AggregateCommandImpl);exports.StrLenCPAggregateCommand=StrLenCPAggregateCommand;var StrcasecmpAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strcasecmp",r)||this}return t}(AggregateCommandImpl);exports.StrcasecmpAggregateCommand=StrcasecmpAggregateCommand;var SubstrCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substrCP",r)||this}return t}(AggregateCommandImpl);exports.SubstrCPAggregateCommand=SubstrCPAggregateCommand;var StdDevPopAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"stdDevPop",r)||this}return t}(AggregateCommandImpl);exports.StdDevPopAggregateCommand=StdDevPopAggregateCommand;var StdDevSampAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"stdDevSamp",r)||this}return t}(AggregateCommandImpl);exports.StdDevSampAggregateCommand=StdDevSampAggregateCommand;
"use strict";var __extends=this&&this.__extends||function(){var e=function(t,r){e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,n){g.__proto__=n}||function(g,n){for(var a in n)if(Object.prototype.hasOwnProperty.call(n,a))g[a]=n[a]};return e(t,r)};return function(t,r){if(typeof r!=="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function g(){this.constructor=t}t.prototype=r===null?Object.create(r):(g.prototype=r.prototype,new g)}}();Object.defineProperty(exports,"__esModule",{value:true});exports.SubstrBytesAggregateCommand=exports.SubstrAggregateCommand=exports.SqrtAggregateCommand=exports.SplitAggregateCommand=exports.SliceAggregateCommand=exports.SizeAggregateCommand=exports.PushAggregateCommand=exports.PowAggregateCommand=exports.OrAggregateCommand=exports.NotAggregateCommand=exports.NeqAggregateCommand=exports.MultiplyAggregateCommand=exports.MonthAggregateCommand=exports.ModAggregateCommand=exports.MinAggregateCommand=exports.MergeObjectsAggregateCommand=exports.MaxAggregateCommand=exports.MapAggregateCommand=exports.LteAggregateCommand=exports.LtAggregateCommand=exports.Log10AggregateCommand=exports.LogAggregateCommand=exports.LnAggregateCommand=exports.LetAggregateCommand=exports.LastAggregateCommand=exports.ISOWeekAggregateCommand=exports.IsArrayAggregateCommand=exports.IndexOfArrayAggregateCommand=exports.InAggregateCommand=exports.IfNullAggregateCommand=exports.GteAggregateCommand=exports.GtAggregateCommand=exports.FloorAggregateCommand=exports.FirstAggregateCommand=exports.ExpAggregateCommand=exports.EqAggregateCommand=exports.DivideAggregateCommand=exports.DateToStringAggregateCommand=exports.CountAggregateCommand=exports.CondAggregateCommand=exports.ConcatAggregateCommand=exports.CMPAggregateCommand=exports.CeilAggregateCommand=exports.AvgAggregateCommand=exports.ArrayElemAtAggregateCommand=exports.AndAggregateCommand=exports.AddToSetAggregateCommand=exports.AddAggregateCommand=exports.AbsAggregateCommand=exports.AggregateCommandImpl=void 0;exports.SecondAggregateCommand=exports.MinuteAggregateCommand=exports.MillisecondAggregateCommand=exports.ISOWeekYearAggregateCommand=exports.ISODayOfWeekAggregateCommand=exports.HourAggregateCommand=exports.DayOfYearAggregateCommand=exports.DayOfWeekAggregateCommand=exports.DayOfMonthAggregateCommand=exports.DateFromPartsAggregateCommand=exports.StdDevSampAggregateCommand=exports.StdDevPopAggregateCommand=exports.SubstrCPAggregateCommand=exports.StrcasecmpAggregateCommand=exports.StrLenCPAggregateCommand=exports.StrLenBytesAggregateCommand=exports.IndexOfCPAggregateCommand=exports.IndexOfBytesAggregateCommand=exports.DateFromStringAggregateCommand=exports.ZipAggregateCommand=exports.ReverseArrayAggregateCommand=exports.ReduceAggregateCommand=exports.RangeAggregateCommand=exports.ObjectToArrayAggregateCommand=exports.FilterAggregateCommand=exports.ConcatArraysAggregateCommand=exports.ArrayToObjectAggregateCommand=exports.LiteralAggregateCommand=exports.SetUnionAggregateCommand=exports.SetIsSubsetAggregateCommand=exports.SetIntersectionAggregateCommand=exports.SetEqualsAggregateCommand=exports.SetDifferenceAggregateCommand=exports.AnyElementTrueAggregateCommand=exports.AllElementsTrueAggregateCommand=exports.YearAggregateCommand=exports.WeekAggregateCommand=exports.TruncAggregateCommand=exports.ToUpperAggregateCommand=exports.ToLowerAggregateCommand=exports.SwitchAggregateCommand=exports.SumAggregateCommand=exports.SubtractAggregateCommand=void 0;var AbstractCommand_1=require("./AbstractCommand");var AggregateRequest_1=require("./AggregateRequest");var AggregateCommandImpl=function(e){__extends(t,e);function t(r,g){return e.call(this,r,new AggregateRequest_1.AggregateRequest(g).toJSON())||this}return t}(AbstractCommand_1.AggregateCommand);exports.AggregateCommandImpl=AggregateCommandImpl;var AbsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"abs",r)||this}return t}(AggregateCommandImpl);exports.AbsAggregateCommand=AbsAggregateCommand;var AddAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"add",r)||this}return t}(AggregateCommandImpl);exports.AddAggregateCommand=AddAggregateCommand;var AddToSetAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"addToSet",r)||this}return t}(AggregateCommandImpl);exports.AddToSetAggregateCommand=AddToSetAggregateCommand;var AndAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"and",r)||this}return t}(AggregateCommandImpl);exports.AndAggregateCommand=AndAggregateCommand;var ArrayElemAtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"arrayElemAt",r)||this}return t}(AggregateCommandImpl);exports.ArrayElemAtAggregateCommand=ArrayElemAtAggregateCommand;var AvgAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"avg",r)||this}return t}(AggregateCommandImpl);exports.AvgAggregateCommand=AvgAggregateCommand;var CeilAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ceil",r)||this}return t}(AggregateCommandImpl);exports.CeilAggregateCommand=CeilAggregateCommand;var CMPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"cmp",r)||this}return t}(AggregateCommandImpl);exports.CMPAggregateCommand=CMPAggregateCommand;var ConcatAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"concat",r)||this}return t}(AggregateCommandImpl);exports.ConcatAggregateCommand=ConcatAggregateCommand;var CondAggregateCommand=function(e){__extends(t,e);function t(r){var g=Array.isArray(r)?{if:r[0],then:r[1],else:r[2]}:r;return e.call(this,"cond",g)||this}return t}(AggregateCommandImpl);exports.CondAggregateCommand=CondAggregateCommand;var CountAggregateCommand=function(e){__extends(t,e);function t(){return e.call(this,"count",{})||this}t.prototype.stringify=function(){return{$sum:1}};return t}(AggregateCommandImpl);exports.CountAggregateCommand=CountAggregateCommand;var DateToStringAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dateToString",r)||this}return t}(AggregateCommandImpl);exports.DateToStringAggregateCommand=DateToStringAggregateCommand;var DivideAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"divide",r)||this}return t}(AggregateCommandImpl);exports.DivideAggregateCommand=DivideAggregateCommand;var EqAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"eq",r)||this}return t}(AggregateCommandImpl);exports.EqAggregateCommand=EqAggregateCommand;var ExpAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"exp",r)||this}return t}(AggregateCommandImpl);exports.ExpAggregateCommand=ExpAggregateCommand;var FirstAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"first",r)||this}return t}(AggregateCommandImpl);exports.FirstAggregateCommand=FirstAggregateCommand;var FloorAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"floor",r)||this}return t}(AggregateCommandImpl);exports.FloorAggregateCommand=FloorAggregateCommand;var GtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"gt",r)||this}return t}(AggregateCommandImpl);exports.GtAggregateCommand=GtAggregateCommand;var GteAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"gte",r)||this}return t}(AggregateCommandImpl);exports.GteAggregateCommand=GteAggregateCommand;var IfNullAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ifNull",r)||this}return t}(AggregateCommandImpl);exports.IfNullAggregateCommand=IfNullAggregateCommand;var InAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"in",r)||this}return t}(AggregateCommandImpl);exports.InAggregateCommand=InAggregateCommand;var IndexOfArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfArray",r)||this}return t}(AggregateCommandImpl);exports.IndexOfArrayAggregateCommand=IndexOfArrayAggregateCommand;var IsArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isArray",r)||this}return t}(AggregateCommandImpl);exports.IsArrayAggregateCommand=IsArrayAggregateCommand;var ISOWeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isoWeek",r)||this}return t}(AggregateCommandImpl);exports.ISOWeekAggregateCommand=ISOWeekAggregateCommand;var LastAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"last",r)||this}return t}(AggregateCommandImpl);exports.LastAggregateCommand=LastAggregateCommand;var LetAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"let",r)||this}return t}(AggregateCommandImpl);exports.LetAggregateCommand=LetAggregateCommand;var LnAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ln",r)||this}return t}(AggregateCommandImpl);exports.LnAggregateCommand=LnAggregateCommand;var LogAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"log",r)||this}return t}(AggregateCommandImpl);exports.LogAggregateCommand=LogAggregateCommand;var Log10AggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"log10",r)||this}return t}(AggregateCommandImpl);exports.Log10AggregateCommand=Log10AggregateCommand;var LtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"lt",r)||this}return t}(AggregateCommandImpl);exports.LtAggregateCommand=LtAggregateCommand;var LteAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"lte",r)||this}return t}(AggregateCommandImpl);exports.LteAggregateCommand=LteAggregateCommand;var MapAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"map",r)||this}return t}(AggregateCommandImpl);exports.MapAggregateCommand=MapAggregateCommand;var MaxAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"max",r)||this}return t}(AggregateCommandImpl);exports.MaxAggregateCommand=MaxAggregateCommand;var MergeObjectsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"mergeObjects",r)||this}return t}(AggregateCommandImpl);exports.MergeObjectsAggregateCommand=MergeObjectsAggregateCommand;var MinAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"min",r)||this}return t}(AggregateCommandImpl);exports.MinAggregateCommand=MinAggregateCommand;var ModAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"mod",r)||this}return t}(AggregateCommandImpl);exports.ModAggregateCommand=ModAggregateCommand;var MonthAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"month",r)||this}return t}(AggregateCommandImpl);exports.MonthAggregateCommand=MonthAggregateCommand;var MultiplyAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"multiply",r)||this}return t}(AggregateCommandImpl);exports.MultiplyAggregateCommand=MultiplyAggregateCommand;var NeqAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"ne",r)||this}return t}(AggregateCommandImpl);exports.NeqAggregateCommand=NeqAggregateCommand;var NotAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"not",[r])||this}return t}(AggregateCommandImpl);exports.NotAggregateCommand=NotAggregateCommand;var OrAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"or",r)||this}return t}(AggregateCommandImpl);exports.OrAggregateCommand=OrAggregateCommand;var PowAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"pow",r)||this}return t}(AggregateCommandImpl);exports.PowAggregateCommand=PowAggregateCommand;var PushAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"push",r)||this}return t}(AggregateCommandImpl);exports.PushAggregateCommand=PushAggregateCommand;var SizeAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"size",r)||this}return t}(AggregateCommandImpl);exports.SizeAggregateCommand=SizeAggregateCommand;var SliceAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"slice",r)||this}return t}(AggregateCommandImpl);exports.SliceAggregateCommand=SliceAggregateCommand;var SplitAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"split",r)||this}return t}(AggregateCommandImpl);exports.SplitAggregateCommand=SplitAggregateCommand;var SqrtAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"sqrt",r)||this}return t}(AggregateCommandImpl);exports.SqrtAggregateCommand=SqrtAggregateCommand;var SubstrAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substr",r)||this}return t}(AggregateCommandImpl);exports.SubstrAggregateCommand=SubstrAggregateCommand;var SubstrBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substrBytes",r)||this}return t}(AggregateCommandImpl);exports.SubstrBytesAggregateCommand=SubstrBytesAggregateCommand;var SubtractAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"subtract",r)||this}return t}(AggregateCommandImpl);exports.SubtractAggregateCommand=SubtractAggregateCommand;var SumAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"sum",r)||this}return t}(AggregateCommandImpl);exports.SumAggregateCommand=SumAggregateCommand;var SwitchAggregateCommand=function(e){__extends(t,e);function t(r){var g=r.branches.map(function(n){if(Array.isArray(n)){return{case:n[0],then:n[1]}}return{case:n.case,then:n.then}});return e.call(this,"switch",{branches:g,default:r.default})||this}return t}(AggregateCommandImpl);exports.SwitchAggregateCommand=SwitchAggregateCommand;var ToLowerAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"toLower",r)||this}return t}(AggregateCommandImpl);exports.ToLowerAggregateCommand=ToLowerAggregateCommand;var ToUpperAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"toUpper",r)||this}return t}(AggregateCommandImpl);exports.ToUpperAggregateCommand=ToUpperAggregateCommand;var TruncAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"trunc",r)||this}return t}(AggregateCommandImpl);exports.TruncAggregateCommand=TruncAggregateCommand;var WeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"week",r)||this}return t}(AggregateCommandImpl);exports.WeekAggregateCommand=WeekAggregateCommand;var YearAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"year",r)||this}return t}(AggregateCommandImpl);exports.YearAggregateCommand=YearAggregateCommand;var AllElementsTrueAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"allElementsTrue",r)||this}return t}(AggregateCommandImpl);exports.AllElementsTrueAggregateCommand=AllElementsTrueAggregateCommand;var AnyElementTrueAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"anyElementTrue",r)||this}return t}(AggregateCommandImpl);exports.AnyElementTrueAggregateCommand=AnyElementTrueAggregateCommand;var SetDifferenceAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"setDifference",r)||this}return t}(AggregateCommandImpl);exports.SetDifferenceAggregateCommand=SetDifferenceAggregateCommand;var SetEqualsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"setEquals",r)||this}return t}(AggregateCommandImpl);exports.SetEqualsAggregateCommand=SetEqualsAggregateCommand;var SetIntersectionAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"setIntersection",r)||this}return t}(AggregateCommandImpl);exports.SetIntersectionAggregateCommand=SetIntersectionAggregateCommand;var SetIsSubsetAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"setIsSubset",r)||this}return t}(AggregateCommandImpl);exports.SetIsSubsetAggregateCommand=SetIsSubsetAggregateCommand;var SetUnionAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"setUnion",r)||this}return t}(AggregateCommandImpl);exports.SetUnionAggregateCommand=SetUnionAggregateCommand;var LiteralAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"literal",r)||this}return t}(AggregateCommandImpl);exports.LiteralAggregateCommand=LiteralAggregateCommand;var ArrayToObjectAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"arrayToObject",r)||this}return t}(AggregateCommandImpl);exports.ArrayToObjectAggregateCommand=ArrayToObjectAggregateCommand;var ConcatArraysAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"concatArrays",r)||this}return t}(AggregateCommandImpl);exports.ConcatArraysAggregateCommand=ConcatArraysAggregateCommand;var FilterAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"filter",r)||this}return t}(AggregateCommandImpl);exports.FilterAggregateCommand=FilterAggregateCommand;var ObjectToArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"objectToArray",r)||this}return t}(AggregateCommandImpl);exports.ObjectToArrayAggregateCommand=ObjectToArrayAggregateCommand;var RangeAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"range",r)||this}return t}(AggregateCommandImpl);exports.RangeAggregateCommand=RangeAggregateCommand;var ReduceAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"reduce",r)||this}return t}(AggregateCommandImpl);exports.ReduceAggregateCommand=ReduceAggregateCommand;var ReverseArrayAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"reverseArray",r)||this}return t}(AggregateCommandImpl);exports.ReverseArrayAggregateCommand=ReverseArrayAggregateCommand;var ZipAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"zip",r)||this}return t}(AggregateCommandImpl);exports.ZipAggregateCommand=ZipAggregateCommand;var DateFromStringAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dateFromString",r)||this}return t}(AggregateCommandImpl);exports.DateFromStringAggregateCommand=DateFromStringAggregateCommand;var IndexOfBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfBytes",r)||this}return t}(AggregateCommandImpl);exports.IndexOfBytesAggregateCommand=IndexOfBytesAggregateCommand;var IndexOfCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"indexOfCP",r)||this}return t}(AggregateCommandImpl);exports.IndexOfCPAggregateCommand=IndexOfCPAggregateCommand;var StrLenBytesAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strLenBytes",r)||this}return t}(AggregateCommandImpl);exports.StrLenBytesAggregateCommand=StrLenBytesAggregateCommand;var StrLenCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strLenCP",r)||this}return t}(AggregateCommandImpl);exports.StrLenCPAggregateCommand=StrLenCPAggregateCommand;var StrcasecmpAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"strcasecmp",r)||this}return t}(AggregateCommandImpl);exports.StrcasecmpAggregateCommand=StrcasecmpAggregateCommand;var SubstrCPAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"substrCP",r)||this}return t}(AggregateCommandImpl);exports.SubstrCPAggregateCommand=SubstrCPAggregateCommand;var StdDevPopAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"stdDevPop",r)||this}return t}(AggregateCommandImpl);exports.StdDevPopAggregateCommand=StdDevPopAggregateCommand;var StdDevSampAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"stdDevSamp",r)||this}return t}(AggregateCommandImpl);exports.StdDevSampAggregateCommand=StdDevSampAggregateCommand;var DateFromPartsAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dateFromParts",r)||this}return t}(AggregateCommandImpl);exports.DateFromPartsAggregateCommand=DateFromPartsAggregateCommand;var DayOfMonthAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dayOfMonth",r)||this}return t}(AggregateCommandImpl);exports.DayOfMonthAggregateCommand=DayOfMonthAggregateCommand;var DayOfWeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dayOfWeek",r)||this}return t}(AggregateCommandImpl);exports.DayOfWeekAggregateCommand=DayOfWeekAggregateCommand;var DayOfYearAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"dayOfYear",r)||this}return t}(AggregateCommandImpl);exports.DayOfYearAggregateCommand=DayOfYearAggregateCommand;var HourAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"hour",r)||this}return t}(AggregateCommandImpl);exports.HourAggregateCommand=HourAggregateCommand;var ISODayOfWeekAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isoDayOfWeek",r)||this}return t}(AggregateCommandImpl);exports.ISODayOfWeekAggregateCommand=ISODayOfWeekAggregateCommand;var ISOWeekYearAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"isoWeekYear",r)||this}return t}(AggregateCommandImpl);exports.ISOWeekYearAggregateCommand=ISOWeekYearAggregateCommand;var MillisecondAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"millisecond",r)||this}return t}(AggregateCommandImpl);exports.MillisecondAggregateCommand=MillisecondAggregateCommand;var MinuteAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"minute",r)||this}return t}(AggregateCommandImpl);exports.MinuteAggregateCommand=MinuteAggregateCommand;var SecondAggregateCommand=function(e){__extends(t,e);function t(r){return e.call(this,"second",r)||this}return t}(AggregateCommandImpl);exports.SecondAggregateCommand=SecondAggregateCommand;
import { Sort } from '../common/constant';
import { AggregateArrayExpression, AggregateDateExpression, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateStringExpression, AggregateStringExpressionPair, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, PushCommandParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, GeoWinthinParam, GeoNearParam, GeoIntersectsParam, AggregateRangeParam, AggregateFilterParam, AggregateReduceParam, AggregateZipParam, AggregateDateFromStringParam, AggregateStrcasecmpParam, AggregateSubstrCPParam, AggregateIndexOfParam } from '../typing';
import { AggregateArrayExpression, AggregateDateExpression, AggregateDateParam, AggregateDocumentExpression, AggregateExpression, AggregateExpressionPair, AggregateExpressionRecord, AggregateNumberExpression, AggregateNumberExpressionPair, AggregateStringExpression, AggregateStringExpressionPair, CondCommandParam, DateToStringCommandParam, IndexOfArrayCommandParam, LetCommandParam, MapParam, PushCommandParam, SliceCommandParam, SubstrBytesCommandParam, SubstrCommandParam, SubtractCommandParam, SwitchCommandParam, GeoWinthinParam, GeoNearParam, GeoIntersectsParam, AggregateRangeParam, AggregateFilterParam, AggregateReduceParam, AggregateZipParam, AggregateDateFromStringParam, AggregateStrcasecmpParam, AggregateSubstrCPParam, AggregateIndexOfParam, AggregateArrayExpressionPair, AggregatedateFromPartsParam, AggregateLiteralParam } from '../typing';
import { AggregateCommand, QueryChainCommand, QueryCommand } from './AbstractCommand';
import { AbsAggregateCommand, AddAggregateCommand, AddToSetAggregateCommand, AndAggregateCommand, ArrayElemAtAggregateCommand, ArrayToObjectAggregateCommand, AvgAggregateCommand, CeilAggregateCommand, CMPAggregateCommand, ConcatAggregateCommand, ConcatArraysAggregateCommand, CondAggregateCommand, CountAggregateCommand, DateFromStringAggregateCommand, DateToStringAggregateCommand, DivideAggregateCommand, EqAggregateCommand, ExpAggregateCommand, FilterAggregateCommand, FirstAggregateCommand, FloorAggregateCommand, GtAggregateCommand, GteAggregateCommand, IfNullAggregateCommand, InAggregateCommand, IndexOfArrayAggregateCommand, IndexOfBytesAggregateCommand, IndexOfCPAggregateCommand, IsArrayAggregateCommand, ISOWeekAggregateCommand, LastAggregateCommand, LetAggregateCommand, LnAggregateCommand, Log10AggregateCommand, LogAggregateCommand, LtAggregateCommand, LteAggregateCommand, MapAggregateCommand, MaxAggregateCommand, MergeObjectsAggregateCommand, MinAggregateCommand, ModAggregateCommand, MonthAggregateCommand, MultiplyAggregateCommand, NeqAggregateCommand, NotAggregateCommand, ObjectToArrayAggregateCommand, OrAggregateCommand, PowAggregateCommand, PushAggregateCommand, RangeAggregateCommand, ReverseArrayAggregateCommand, ReduceAggregateCommand, SizeAggregateCommand, SliceAggregateCommand, SplitAggregateCommand, SqrtAggregateCommand, StdDevPopAggregateCommand, StdDevSampAggregateCommand, StrcasecmpAggregateCommand, StrLenBytesAggregateCommand, StrLenCPAggregateCommand, SubstrAggregateCommand, SubstrBytesAggregateCommand, SubstrCPAggregateCommand, SubtractAggregateCommand, SumAggregateCommand, SwitchAggregateCommand, ToLowerAggregateCommand, ToUpperAggregateCommand, TruncAggregateCommand, WeekAggregateCommand, YearAggregateCommand, ZipAggregateCommand } from './aggregate';
import { AbsAggregateCommand, AddAggregateCommand, AddToSetAggregateCommand, AllElementsTrueAggregateCommand, AndAggregateCommand, AnyElementTrueAggregateCommand, ArrayElemAtAggregateCommand, ArrayToObjectAggregateCommand, AvgAggregateCommand, CeilAggregateCommand, CMPAggregateCommand, ConcatAggregateCommand, ConcatArraysAggregateCommand, CondAggregateCommand, CountAggregateCommand, DateFromStringAggregateCommand, DateToStringAggregateCommand, DivideAggregateCommand, EqAggregateCommand, ExpAggregateCommand, FilterAggregateCommand, FirstAggregateCommand, FloorAggregateCommand, GtAggregateCommand, GteAggregateCommand, IfNullAggregateCommand, InAggregateCommand, IndexOfArrayAggregateCommand, IndexOfBytesAggregateCommand, IndexOfCPAggregateCommand, IsArrayAggregateCommand, ISOWeekAggregateCommand, LastAggregateCommand, LetAggregateCommand, LiteralAggregateCommand, LnAggregateCommand, Log10AggregateCommand, LogAggregateCommand, LtAggregateCommand, LteAggregateCommand, MapAggregateCommand, MaxAggregateCommand, MergeObjectsAggregateCommand, MinAggregateCommand, ModAggregateCommand, MonthAggregateCommand, MultiplyAggregateCommand, NeqAggregateCommand, NotAggregateCommand, ObjectToArrayAggregateCommand, OrAggregateCommand, PowAggregateCommand, PushAggregateCommand, RangeAggregateCommand, ReverseArrayAggregateCommand, ReduceAggregateCommand, SetDifferenceAggregateCommand, SetEqualsAggregateCommand, SetIntersectionAggregateCommand, SetIsSubsetAggregateCommand, SetUnionAggregateCommand, SizeAggregateCommand, SliceAggregateCommand, SplitAggregateCommand, SqrtAggregateCommand, StdDevPopAggregateCommand, StdDevSampAggregateCommand, StrcasecmpAggregateCommand, StrLenBytesAggregateCommand, StrLenCPAggregateCommand, SubstrAggregateCommand, SubstrBytesAggregateCommand, SubstrCPAggregateCommand, SubtractAggregateCommand, SumAggregateCommand, SwitchAggregateCommand, ToLowerAggregateCommand, ToUpperAggregateCommand, TruncAggregateCommand, WeekAggregateCommand, YearAggregateCommand, ZipAggregateCommand, DateFromPartsAggregateCommand, DayOfMonthAggregateCommand, DayOfWeekAggregateCommand, DayOfYearAggregateCommand, HourAggregateCommand, ISODayOfWeekAggregateCommand, ISOWeekYearAggregateCommand, MillisecondAggregateCommand, MinuteAggregateCommand, SecondAggregateCommand } from './aggregate';
import { AggregatePipeline } from './AggregatePipeline';

@@ -128,2 +128,20 @@ import { ExprCommand } from './query/expr';

stdDevSamp(value: AggregateExpression): StdDevSampAggregateCommand;
allElementsTrue(value: AggregateArrayExpression[]): AllElementsTrueAggregateCommand;
anyElementTrue(value: AggregateArrayExpression[]): AnyElementTrueAggregateCommand;
setDifference(value: AggregateArrayExpressionPair): SetDifferenceAggregateCommand;
setEquals(value: AggregateArrayExpressionPair): SetEqualsAggregateCommand;
setIntersection(value: AggregateArrayExpressionPair): SetIntersectionAggregateCommand;
setIsSubset(value: AggregateArrayExpressionPair): SetIsSubsetAggregateCommand;
setUnion(value: AggregateArrayExpressionPair): SetUnionAggregateCommand;
literal(value: AggregateLiteralParam): LiteralAggregateCommand;
dateFromParts(value: AggregatedateFromPartsParam): DateFromPartsAggregateCommand;
dayOfMonth(value: AggregateDateParam): DayOfMonthAggregateCommand;
dayOfWeek(value: AggregateDateParam): DayOfWeekAggregateCommand;
dayOfYear(value: AggregateDateParam): DayOfYearAggregateCommand;
hour(value: AggregateDateParam): HourAggregateCommand;
isoDayOfWeek(value: AggregateDateParam): ISODayOfWeekAggregateCommand;
isoWeekYear(value: AggregateDateParam): ISOWeekYearAggregateCommand;
millisecond(value: AggregateDateParam): MillisecondAggregateCommand;
minute(value: AggregateDateParam): MinuteAggregateCommand;
second(value: AggregateDateParam): SecondAggregateCommand;
}

@@ -130,0 +148,0 @@ export declare class Command {

@@ -1,1 +0,1 @@

"use strict";var __spreadArray=this&&this.__spreadArray||function(r,e,t){if(t||arguments.length===2)for(var n=0,o=e.length,a;n<o;n++){if(a||!(n in e)){if(!a)a=Array.prototype.slice.call(e,0,n);a[n]=e[n]}}return r.concat(a||Array.prototype.slice.call(e))};Object.defineProperty(exports,"__esModule",{value:true});exports.Command=exports.AggregateCommandFactory=void 0;var constant_1=require("../common/constant");var aggregate_1=require("./aggregate");var AggregatePipeline_1=require("./AggregatePipeline");var all_1=require("./query/all");var logic_1=require("./query/logic");var elemMatch_1=require("./query/elemMatch");var eq_1=require("./query/eq");var exists_1=require("./query/exists");var expr_1=require("./query/expr");var gt_1=require("./query/gt");var gte_1=require("./query/gte");var in_1=require("./query/in");var lt_1=require("./query/lt");var lte_1=require("./query/lte");var mod_1=require("./query/mod");var neq_1=require("./query/neq");var nin_1=require("./query/nin");var QueryChain_1=require("./query/QueryChain");var size_1=require("./query/size");var addToSet_1=require("./update/addToSet");var inc_1=require("./update/inc");var max_1=require("./update/max");var min_1=require("./update/min");var mul_1=require("./update/mul");var pop_1=require("./update/pop");var pull_1=require("./update/pull");var pullAll_1=require("./update/pullAll");var push_1=require("./update/push");var remove_1=require("./update/remove");var rename_1=require("./update/rename");var set_1=require("./update/set");var geo_1=require("./query/geo");var unshift_1=require("./update/unshift");var shift_1=require("./update/shift");var AggregateCommandFactory=function(){function r(){}r.prototype.pipeline=function(){return new AggregatePipeline_1.AggregatePipeline};r.prototype.avg=function(e){return new aggregate_1.AvgAggregateCommand(e)};r.prototype.count=function(){return new aggregate_1.CountAggregateCommand};r.prototype.max=function(e){return new aggregate_1.MaxAggregateCommand(e)};r.prototype.min=function(e){return new aggregate_1.MinAggregateCommand(e)};r.prototype.sum=function(e){return new aggregate_1.SumAggregateCommand(e)};r.prototype.and=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.AndAggregateCommand(o)};r.prototype.or=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.OrAggregateCommand(o)};r.prototype.not=function(e){return new aggregate_1.NotAggregateCommand(e)};r.prototype.cmp=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.CMPAggregateCommand(n)};r.prototype.eq=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.EqAggregateCommand(n)};r.prototype.neq=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.NeqAggregateCommand(n)};r.prototype.lt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LtAggregateCommand(n)};r.prototype.lte=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LteAggregateCommand(n)};r.prototype.gt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.GtAggregateCommand(n)};r.prototype.gte=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.GteAggregateCommand(n)};r.prototype.addToSet=function(e){return new aggregate_1.AddToSetAggregateCommand(e)};r.prototype.arrayElemAt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.ArrayElemAtAggregateCommand(n)};r.prototype.indexOfArray=function(e,t,n,o){var a=Array.isArray(e)?e:[e,t,n,o].filter(function(u){return u!==void 0});return new aggregate_1.IndexOfArrayAggregateCommand(a)};r.prototype.isArray=function(e){return new aggregate_1.IsArrayAggregateCommand(e)};r.prototype.size=function(e){return new aggregate_1.SizeAggregateCommand(e)};r.prototype.in=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.InAggregateCommand(n)};r.prototype.slice=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n].filter(function(a){return a!==void 0});return new aggregate_1.SliceAggregateCommand(o)};r.prototype.map=function(e){return new aggregate_1.MapAggregateCommand(e)};r.prototype.ifNull=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.IfNullAggregateCommand(n)};r.prototype.cond=function(e){return new aggregate_1.CondAggregateCommand(e)};r.prototype.switch=function(e){return new aggregate_1.SwitchAggregateCommand(e)};r.prototype.concat=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.ConcatAggregateCommand(o)};r.prototype.dateToString=function(e){return new aggregate_1.DateToStringAggregateCommand(e)};r.prototype.toLower=function(e){return new aggregate_1.ToLowerAggregateCommand(e)};r.prototype.toUpper=function(e){return new aggregate_1.ToUpperAggregateCommand(e)};r.prototype.split=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.SplitAggregateCommand(n)};r.prototype.substr=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n];return new aggregate_1.SubstrAggregateCommand(o)};r.prototype.substrBytes=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n];return new aggregate_1.SubstrBytesAggregateCommand(o)};r.prototype.first=function(e){return new aggregate_1.FirstAggregateCommand(e)};r.prototype.last=function(e){return new aggregate_1.LastAggregateCommand(e)};r.prototype.push=function(e){return new aggregate_1.PushAggregateCommand(e)};r.prototype.let=function(e){return new aggregate_1.LetAggregateCommand(e)};r.prototype.add=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.AddAggregateCommand(o)};r.prototype.subtract=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.SubtractAggregateCommand(n)};r.prototype.multiply=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.MultiplyAggregateCommand(o)};r.prototype.divide=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.DivideAggregateCommand(n)};r.prototype.abs=function(e){return new aggregate_1.AbsAggregateCommand(e)};r.prototype.ceil=function(e){return new aggregate_1.CeilAggregateCommand(e)};r.prototype.exp=function(e){return new aggregate_1.ExpAggregateCommand(e)};r.prototype.floor=function(e){return new aggregate_1.FloorAggregateCommand(e)};r.prototype.ln=function(e){return new aggregate_1.LnAggregateCommand(e)};r.prototype.log=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LogAggregateCommand(n)};r.prototype.log10=function(e){return new aggregate_1.Log10AggregateCommand(e)};r.prototype.mod=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.ModAggregateCommand(n)};r.prototype.pow=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.PowAggregateCommand(n)};r.prototype.sqrt=function(e){return new aggregate_1.SqrtAggregateCommand(e)};r.prototype.trunc=function(e){return new aggregate_1.TruncAggregateCommand(e)};r.prototype.mergeObjects=function(e){return new aggregate_1.MergeObjectsAggregateCommand(e)};r.prototype.month=function(e){return new aggregate_1.MonthAggregateCommand(e)};r.prototype.year=function(e){return new aggregate_1.YearAggregateCommand(e)};r.prototype.week=function(e){return new aggregate_1.WeekAggregateCommand(e)};r.prototype.isoWeek=function(e){return new aggregate_1.ISOWeekAggregateCommand(e)};r.prototype.arrayToObject=function(e){return new aggregate_1.ArrayToObjectAggregateCommand(e)};r.prototype.concatArrays=function(e){return new aggregate_1.ConcatArraysAggregateCommand(e)};r.prototype.filter=function(e){return new aggregate_1.FilterAggregateCommand(e)};r.prototype.objectToArray=function(e){return new aggregate_1.ObjectToArrayAggregateCommand(e)};r.prototype.range=function(e,t,n){var o=Array.isArray(e)?e:typeof n!=="undefined"?[e,t,n]:[e,t];return new aggregate_1.RangeAggregateCommand(o)};r.prototype.reduce=function(e){return new aggregate_1.ReduceAggregateCommand(e)};r.prototype.reverseArray=function(e){return new aggregate_1.ReverseArrayAggregateCommand(e)};r.prototype.zip=function(e){return new aggregate_1.ZipAggregateCommand(e)};r.prototype.dateFromString=function(e){return new aggregate_1.DateFromStringAggregateCommand(e)};r.prototype.indexOfBytes=function(e){return new aggregate_1.IndexOfBytesAggregateCommand(e)};r.prototype.indexOfCP=function(e){return new aggregate_1.IndexOfCPAggregateCommand(e)};r.prototype.strLenBytes=function(e){return new aggregate_1.StrLenBytesAggregateCommand(e)};r.prototype.strLenCP=function(e){return new aggregate_1.StrLenCPAggregateCommand(e)};r.prototype.strcasecmp=function(e){return new aggregate_1.StrcasecmpAggregateCommand(e)};r.prototype.substrCP=function(e){return new aggregate_1.SubstrCPAggregateCommand(e)};r.prototype.stdDevPop=function(e){return new aggregate_1.StdDevPopAggregateCommand(e)};r.prototype.stdDevSamp=function(e){return new aggregate_1.StdDevSampAggregateCommand(e)};return r}();exports.AggregateCommandFactory=AggregateCommandFactory;var Command=function(){function r(){this.aggregate=new AggregateCommandFactory;this.Sort=constant_1.Sort}r.prototype.addToSet=function(e){return new addToSet_1.AddToSetCommand(e)};r.prototype.inc=function(e){return new inc_1.IncCommand(e)};r.prototype.max=function(e){return new max_1.MaxCommand(e)};r.prototype.min=function(e){return new min_1.MinCommand(e)};r.prototype.mul=function(e){return new mul_1.MulCommand(e)};r.prototype.pop=function(e){return new pop_1.PopCommand(e)};r.prototype.pull=function(e){return new pull_1.PullCommand(e)};r.prototype.pullAll=function(e){return new pullAll_1.PullAllCommand(e)};r.prototype.push=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}return new(push_1.PushCommand.bind.apply(push_1.PushCommand,__spreadArray([void 0,e],t,false)))};r.prototype.remove=function(){return new remove_1.RemoveCommand};r.prototype.rename=function(e){return new rename_1.RenameCommand(e)};r.prototype.set=function(e){return new set_1.SetCommand(e)};r.prototype.expr=function(e){return new expr_1.ExprCommand(e)};r.prototype.geoWithin=function(e){return new geo_1.GeoWithinCommand(e)};r.prototype.geoNear=function(e){return new geo_1.GeoNearCommand(e)};r.prototype.geoIntersects=function(e){return new geo_1.GeoIntersectsCommand(e)};r.prototype.unshift=function(e){return new unshift_1.UnShiftCommand(e)};r.prototype.shift=function(){return new shift_1.ShiftCommand};r.prototype.and=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.AndCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.or=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.OrCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.not=function(e){var t=new logic_1.NotCommand(QueryChain_1.QueryChain.unchain(e));return new QueryChain_1.QueryChain(t)};r.prototype.nor=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.NorCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.eq=function(e){return new QueryChain_1.QueryChain(new eq_1.EqCommand(e))};r.prototype.neq=function(e){return new QueryChain_1.QueryChain(new neq_1.NeqCommand(e))};r.prototype.lt=function(e){return new QueryChain_1.QueryChain(new lt_1.LtCommand(e))};r.prototype.lte=function(e){return new QueryChain_1.QueryChain(new lte_1.LteCommand(e))};r.prototype.gt=function(e){return new QueryChain_1.QueryChain(new gt_1.GtCommand(e))};r.prototype.gte=function(e){return new QueryChain_1.QueryChain(new gte_1.GteCommand(e))};r.prototype.in=function(e){return new QueryChain_1.QueryChain(new in_1.InCommand(e))};r.prototype.nin=function(e){return new QueryChain_1.QueryChain(new nin_1.NinCommand(e))};r.prototype.exists=function(e){return new QueryChain_1.QueryChain(new exists_1.ExistsCommand(e))};r.prototype.mod=function(e,t){return new QueryChain_1.QueryChain(new mod_1.ModCommand(e,t))};r.prototype.all=function(e){return new QueryChain_1.QueryChain(new all_1.AllCommand(e))};r.prototype.elemMatch=function(e){return new QueryChain_1.QueryChain(new elemMatch_1.ElemMatchCommand(QueryChain_1.QueryChain.unchain(e)))};r.prototype.size=function(e){return new QueryChain_1.QueryChain(new size_1.SizeCommand(e))};return r}();exports.Command=Command;
"use strict";var __spreadArray=this&&this.__spreadArray||function(r,e,t){if(t||arguments.length===2)for(var n=0,o=e.length,a;n<o;n++){if(a||!(n in e)){if(!a)a=Array.prototype.slice.call(e,0,n);a[n]=e[n]}}return r.concat(a||Array.prototype.slice.call(e))};Object.defineProperty(exports,"__esModule",{value:true});exports.Command=exports.AggregateCommandFactory=void 0;var constant_1=require("../common/constant");var aggregate_1=require("./aggregate");var AggregatePipeline_1=require("./AggregatePipeline");var all_1=require("./query/all");var logic_1=require("./query/logic");var elemMatch_1=require("./query/elemMatch");var eq_1=require("./query/eq");var exists_1=require("./query/exists");var expr_1=require("./query/expr");var gt_1=require("./query/gt");var gte_1=require("./query/gte");var in_1=require("./query/in");var lt_1=require("./query/lt");var lte_1=require("./query/lte");var mod_1=require("./query/mod");var neq_1=require("./query/neq");var nin_1=require("./query/nin");var QueryChain_1=require("./query/QueryChain");var size_1=require("./query/size");var addToSet_1=require("./update/addToSet");var inc_1=require("./update/inc");var max_1=require("./update/max");var min_1=require("./update/min");var mul_1=require("./update/mul");var pop_1=require("./update/pop");var pull_1=require("./update/pull");var pullAll_1=require("./update/pullAll");var push_1=require("./update/push");var remove_1=require("./update/remove");var rename_1=require("./update/rename");var set_1=require("./update/set");var geo_1=require("./query/geo");var unshift_1=require("./update/unshift");var shift_1=require("./update/shift");var AggregateCommandFactory=function(){function r(){}r.prototype.pipeline=function(){return new AggregatePipeline_1.AggregatePipeline};r.prototype.avg=function(e){return new aggregate_1.AvgAggregateCommand(e)};r.prototype.count=function(){return new aggregate_1.CountAggregateCommand};r.prototype.max=function(e){return new aggregate_1.MaxAggregateCommand(e)};r.prototype.min=function(e){return new aggregate_1.MinAggregateCommand(e)};r.prototype.sum=function(e){return new aggregate_1.SumAggregateCommand(e)};r.prototype.and=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.AndAggregateCommand(o)};r.prototype.or=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.OrAggregateCommand(o)};r.prototype.not=function(e){return new aggregate_1.NotAggregateCommand(e)};r.prototype.cmp=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.CMPAggregateCommand(n)};r.prototype.eq=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.EqAggregateCommand(n)};r.prototype.neq=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.NeqAggregateCommand(n)};r.prototype.lt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LtAggregateCommand(n)};r.prototype.lte=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LteAggregateCommand(n)};r.prototype.gt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.GtAggregateCommand(n)};r.prototype.gte=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.GteAggregateCommand(n)};r.prototype.addToSet=function(e){return new aggregate_1.AddToSetAggregateCommand(e)};r.prototype.arrayElemAt=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.ArrayElemAtAggregateCommand(n)};r.prototype.indexOfArray=function(e,t,n,o){var a=Array.isArray(e)?e:[e,t,n,o].filter(function(u){return u!==void 0});return new aggregate_1.IndexOfArrayAggregateCommand(a)};r.prototype.isArray=function(e){return new aggregate_1.IsArrayAggregateCommand(e)};r.prototype.size=function(e){return new aggregate_1.SizeAggregateCommand(e)};r.prototype.in=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.InAggregateCommand(n)};r.prototype.slice=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n].filter(function(a){return a!==void 0});return new aggregate_1.SliceAggregateCommand(o)};r.prototype.map=function(e){return new aggregate_1.MapAggregateCommand(e)};r.prototype.ifNull=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.IfNullAggregateCommand(n)};r.prototype.cond=function(e){return new aggregate_1.CondAggregateCommand(e)};r.prototype.switch=function(e){return new aggregate_1.SwitchAggregateCommand(e)};r.prototype.concat=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.ConcatAggregateCommand(o)};r.prototype.dateToString=function(e){return new aggregate_1.DateToStringAggregateCommand(e)};r.prototype.toLower=function(e){return new aggregate_1.ToLowerAggregateCommand(e)};r.prototype.toUpper=function(e){return new aggregate_1.ToUpperAggregateCommand(e)};r.prototype.split=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.SplitAggregateCommand(n)};r.prototype.substr=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n];return new aggregate_1.SubstrAggregateCommand(o)};r.prototype.substrBytes=function(e,t,n){var o=Array.isArray(e)?e:[e,t,n];return new aggregate_1.SubstrBytesAggregateCommand(o)};r.prototype.first=function(e){return new aggregate_1.FirstAggregateCommand(e)};r.prototype.last=function(e){return new aggregate_1.LastAggregateCommand(e)};r.prototype.push=function(e){return new aggregate_1.PushAggregateCommand(e)};r.prototype.let=function(e){return new aggregate_1.LetAggregateCommand(e)};r.prototype.add=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.AddAggregateCommand(o)};r.prototype.subtract=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.SubtractAggregateCommand(n)};r.prototype.multiply=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}var o=Array.isArray(e)?e:__spreadArray([e],t,true);return new aggregate_1.MultiplyAggregateCommand(o)};r.prototype.divide=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.DivideAggregateCommand(n)};r.prototype.abs=function(e){return new aggregate_1.AbsAggregateCommand(e)};r.prototype.ceil=function(e){return new aggregate_1.CeilAggregateCommand(e)};r.prototype.exp=function(e){return new aggregate_1.ExpAggregateCommand(e)};r.prototype.floor=function(e){return new aggregate_1.FloorAggregateCommand(e)};r.prototype.ln=function(e){return new aggregate_1.LnAggregateCommand(e)};r.prototype.log=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.LogAggregateCommand(n)};r.prototype.log10=function(e){return new aggregate_1.Log10AggregateCommand(e)};r.prototype.mod=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.ModAggregateCommand(n)};r.prototype.pow=function(e,t){var n=Array.isArray(e)?e:[e,t];return new aggregate_1.PowAggregateCommand(n)};r.prototype.sqrt=function(e){return new aggregate_1.SqrtAggregateCommand(e)};r.prototype.trunc=function(e){return new aggregate_1.TruncAggregateCommand(e)};r.prototype.mergeObjects=function(e){return new aggregate_1.MergeObjectsAggregateCommand(e)};r.prototype.month=function(e){return new aggregate_1.MonthAggregateCommand(e)};r.prototype.year=function(e){return new aggregate_1.YearAggregateCommand(e)};r.prototype.week=function(e){return new aggregate_1.WeekAggregateCommand(e)};r.prototype.isoWeek=function(e){return new aggregate_1.ISOWeekAggregateCommand(e)};r.prototype.arrayToObject=function(e){return new aggregate_1.ArrayToObjectAggregateCommand(e)};r.prototype.concatArrays=function(e){return new aggregate_1.ConcatArraysAggregateCommand(e)};r.prototype.filter=function(e){return new aggregate_1.FilterAggregateCommand(e)};r.prototype.objectToArray=function(e){return new aggregate_1.ObjectToArrayAggregateCommand(e)};r.prototype.range=function(e,t,n){var o=Array.isArray(e)?e:typeof n!=="undefined"?[e,t,n]:[e,t];return new aggregate_1.RangeAggregateCommand(o)};r.prototype.reduce=function(e){return new aggregate_1.ReduceAggregateCommand(e)};r.prototype.reverseArray=function(e){return new aggregate_1.ReverseArrayAggregateCommand(e)};r.prototype.zip=function(e){return new aggregate_1.ZipAggregateCommand(e)};r.prototype.dateFromString=function(e){return new aggregate_1.DateFromStringAggregateCommand(e)};r.prototype.indexOfBytes=function(e){return new aggregate_1.IndexOfBytesAggregateCommand(e)};r.prototype.indexOfCP=function(e){return new aggregate_1.IndexOfCPAggregateCommand(e)};r.prototype.strLenBytes=function(e){return new aggregate_1.StrLenBytesAggregateCommand(e)};r.prototype.strLenCP=function(e){return new aggregate_1.StrLenCPAggregateCommand(e)};r.prototype.strcasecmp=function(e){return new aggregate_1.StrcasecmpAggregateCommand(e)};r.prototype.substrCP=function(e){return new aggregate_1.SubstrCPAggregateCommand(e)};r.prototype.stdDevPop=function(e){return new aggregate_1.StdDevPopAggregateCommand(e)};r.prototype.stdDevSamp=function(e){return new aggregate_1.StdDevSampAggregateCommand(e)};r.prototype.allElementsTrue=function(e){return new aggregate_1.AllElementsTrueAggregateCommand(e)};r.prototype.anyElementTrue=function(e){return new aggregate_1.AnyElementTrueAggregateCommand(e)};r.prototype.setDifference=function(e){return new aggregate_1.SetDifferenceAggregateCommand(e)};r.prototype.setEquals=function(e){return new aggregate_1.SetEqualsAggregateCommand(e)};r.prototype.setIntersection=function(e){return new aggregate_1.SetIntersectionAggregateCommand(e)};r.prototype.setIsSubset=function(e){return new aggregate_1.SetIsSubsetAggregateCommand(e)};r.prototype.setUnion=function(e){return new aggregate_1.SetUnionAggregateCommand(e)};r.prototype.literal=function(e){return new aggregate_1.LiteralAggregateCommand(e)};r.prototype.dateFromParts=function(e){return new aggregate_1.DateFromPartsAggregateCommand(e)};r.prototype.dayOfMonth=function(e){return new aggregate_1.DayOfMonthAggregateCommand(e)};r.prototype.dayOfWeek=function(e){return new aggregate_1.DayOfWeekAggregateCommand(e)};r.prototype.dayOfYear=function(e){return new aggregate_1.DayOfYearAggregateCommand(e)};r.prototype.hour=function(e){return new aggregate_1.HourAggregateCommand(e)};r.prototype.isoDayOfWeek=function(e){return new aggregate_1.ISODayOfWeekAggregateCommand(e)};r.prototype.isoWeekYear=function(e){return new aggregate_1.ISOWeekYearAggregateCommand(e)};r.prototype.millisecond=function(e){return new aggregate_1.MillisecondAggregateCommand(e)};r.prototype.minute=function(e){return new aggregate_1.MinuteAggregateCommand(e)};r.prototype.second=function(e){return new aggregate_1.SecondAggregateCommand(e)};return r}();exports.AggregateCommandFactory=AggregateCommandFactory;var Command=function(){function r(){this.aggregate=new AggregateCommandFactory;this.Sort=constant_1.Sort}r.prototype.addToSet=function(e){return new addToSet_1.AddToSetCommand(e)};r.prototype.inc=function(e){return new inc_1.IncCommand(e)};r.prototype.max=function(e){return new max_1.MaxCommand(e)};r.prototype.min=function(e){return new min_1.MinCommand(e)};r.prototype.mul=function(e){return new mul_1.MulCommand(e)};r.prototype.pop=function(e){return new pop_1.PopCommand(e)};r.prototype.pull=function(e){return new pull_1.PullCommand(e)};r.prototype.pullAll=function(e){return new pullAll_1.PullAllCommand(e)};r.prototype.push=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}return new(push_1.PushCommand.bind.apply(push_1.PushCommand,__spreadArray([void 0,e],t,false)))};r.prototype.remove=function(){return new remove_1.RemoveCommand};r.prototype.rename=function(e){return new rename_1.RenameCommand(e)};r.prototype.set=function(e){return new set_1.SetCommand(e)};r.prototype.expr=function(e){return new expr_1.ExprCommand(e)};r.prototype.geoWithin=function(e){return new geo_1.GeoWithinCommand(e)};r.prototype.geoNear=function(e){return new geo_1.GeoNearCommand(e)};r.prototype.geoIntersects=function(e){return new geo_1.GeoIntersectsCommand(e)};r.prototype.unshift=function(e){return new unshift_1.UnShiftCommand(e)};r.prototype.shift=function(){return new shift_1.ShiftCommand};r.prototype.and=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.AndCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.or=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.OrCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.not=function(e){var t=new logic_1.NotCommand(QueryChain_1.QueryChain.unchain(e));return new QueryChain_1.QueryChain(t)};r.prototype.nor=function(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}e=Array.isArray(e[0])?e[0]:e;var n=new logic_1.NorCommand(e.map(QueryChain_1.QueryChain.unchain));return new QueryChain_1.QueryChain(n)};r.prototype.eq=function(e){return new QueryChain_1.QueryChain(new eq_1.EqCommand(e))};r.prototype.neq=function(e){return new QueryChain_1.QueryChain(new neq_1.NeqCommand(e))};r.prototype.lt=function(e){return new QueryChain_1.QueryChain(new lt_1.LtCommand(e))};r.prototype.lte=function(e){return new QueryChain_1.QueryChain(new lte_1.LteCommand(e))};r.prototype.gt=function(e){return new QueryChain_1.QueryChain(new gt_1.GtCommand(e))};r.prototype.gte=function(e){return new QueryChain_1.QueryChain(new gte_1.GteCommand(e))};r.prototype.in=function(e){return new QueryChain_1.QueryChain(new in_1.InCommand(e))};r.prototype.nin=function(e){return new QueryChain_1.QueryChain(new nin_1.NinCommand(e))};r.prototype.exists=function(e){return new QueryChain_1.QueryChain(new exists_1.ExistsCommand(e))};r.prototype.mod=function(e,t){return new QueryChain_1.QueryChain(new mod_1.ModCommand(e,t))};r.prototype.all=function(e){return new QueryChain_1.QueryChain(new all_1.AllCommand(e))};r.prototype.elemMatch=function(e){return new QueryChain_1.QueryChain(new elemMatch_1.ElemMatchCommand(QueryChain_1.QueryChain.unchain(e)))};r.prototype.size=function(e){return new QueryChain_1.QueryChain(new size_1.SizeCommand(e))};return r}();exports.Command=Command;

@@ -1,2 +0,2 @@

import { AggregateCommand } from './command/AbstractCommand';
import { AggregateCommand, QueryCommand, UpdateCommand } from './command/AbstractCommand';
import { CollectionAction, DocumentAction, PipelineStageName, Sort, Target } from './common/constant';

@@ -8,2 +8,3 @@ import { GeoPolygon, GeoMultiPolygon, GeoPoint, GeoLineString, GeoMultiPoint, GeoMultiLineString } from './mongo-builder/Geo';

export type AggregateArrayExpression = AggregateExpression<any[]>;
export type AggregateArrayExpressionPair = [AggregateArrayExpression, AggregateArrayExpression];
export type AggregateNumberExpression = AggregateExpression<number>;

@@ -204,1 +205,15 @@ export type AggregateNumberExpressionPair = [AggregateNumberExpression, AggregateNumberExpression];

export type AggregateSubstrCPParam = [AggregateStringExpression, AggregateNumberExpression, AggregateNumberExpression];
export interface AggregatedateFromPartsParam {
year?: AggregateNumberExpression;
month?: AggregateNumberExpression;
day?: AggregateNumberExpression;
hour?: AggregateNumberExpression;
minute?: AggregateNumberExpression;
second?: AggregateNumberExpression;
millisecond?: AggregateNumberExpression;
timezone?: string;
isoWeekYear?: AggregateNumberExpression;
isoWeek?: AggregateNumberExpression;
isoDayOfWeek?: AggregateNumberExpression;
}
export type AggregateLiteralParam = AggregateExpression | QueryCommand | UpdateCommand;
{
"name": "@alipay/faas-db-builder",
"version": "1.1.19-alpha.1",
"version": "1.1.19-alpha.3",
"description": "db builder",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc