Browse Source

EAGLESIX-812: Fix docs

Chris Sexton 11 năm trước cách đây
mục cha
commit
736fef3d4b
1 tập tin đã thay đổi với 14 bổ sung1 xóa
  1. 14 1
      lib/pipeline/documentSources/GroupDocumentSource.js

+ 14 - 1
lib/pipeline/documentSources/GroupDocumentSource.js

@@ -415,6 +415,10 @@ proto.makeDocument = function makeDocument(id, accums, mergeableOutput) {
 
 /**
  * Computes the internal representation of the group key.
+ *
+ * @method computeId
+ * @param vars a VariablesParseState
+ * @return vals
  */
 proto.computeId = function computeId(vars) {
 	var self = this;
@@ -434,6 +438,10 @@ proto.computeId = function computeId(vars) {
 /**
  * Converts the internal representation of the group key to the _id shape specified by the
  * user.
+ *
+ * @method expandId
+ * @param val
+ * @return document representing an id
  */
 proto.expandId = function expandId(val) {
 	var self = this;
@@ -457,6 +465,12 @@ proto.expandId = function expandId(val) {
 	return doc;
 };
 
+/**
+ * Parses the raw id expression into _idExpressions and possibly _idFieldNames.
+ *
+ * @method parseIdExpression
+ * @param groupField {Object} The object with the spec
+ */
 proto.parseIdExpression = function parseIdExpression(groupField, vps) {
 	var self = this;
 	if (self._getTypeStr(groupField) === 'Object' && Object.keys(groupField).length !== 0) {
@@ -487,7 +501,6 @@ proto.parseIdExpression = function parseIdExpression(groupField, vps) {
  * @method _getTypeStr
  * @param obj {Object} The object to get the type of
  * @return {String} The type of the object as a string
- * @async
  **/
 proto._getTypeStr = function _getTypeStr(obj) {
 	var typeofStr = typeof obj,