docs: function (num, arrRepeatNum) {
        var param = this.param;
        var ds = this.ds;
        num = isNaN(num) ? 3 : num <= 0 ? 3 : num;
        var datatype = ds.find(function (dt) {
          return dt.id === param.type;
        });
        if (!datatype.params || datatype.format !== 0) {
          return 'NEI.loop 方法只适用于有循环引用的情形';
        }
        var genMock = function () {
          var params = datatype.params;
          var loopParams = params.filter(function (p) {
            return p.type === param.type;
          });
          datatype.params = params.filter(function (p) {
            return p.type !== param.type;
          });
          var json = mockData._getMockOfDatatypeId(param.type, param.name);
          loopParams.forEach(function (p) {
            var pointer = json;
            var i = num - 1;
            while (i) {
              if (p.isArray) {
                pointer[p.name] = [];
                for (var j = 0; j< arrRepeatNum; j++) {
                  var result = mockData._getMockOfDatatypeId(param.type, param.name);
                  var pointer2 = result;
                  // 减去2，不是1，要减去前面遍历的一层
                  var k = num - 2;
                  while (k) {
                    pointer2[p.name] = [mockData._getMockOfDatatypeId(param.type, param.name)];
                    pointer2 = pointer2[p.name][0];
                    k--;
                  }
                  pointer2[p.name] = null;
                  pointer[p.name].push(result);
                }
              } else {
                pointer[p.name] = mockData._getMockOfDatatypeId(param.type, param.name);
              }
              pointer = pointer[p.name];
              i--;
            }
            // 最后一层置为 null
            pointer[p.name] = null;
          });
          // 还原 params, 不然第二次循环就丢失了 params
          datatype.params = params;
          return json;
        };
        var result = null;
        if (param._isArray) {
          arrRepeatNum = isNaN(arrRepeatNum) ? 3 : (arrRepeatNum <= 0 ? 3 : arrRepeatNum);
          result = [];
          for (var i = 0; i < arrRepeatNum; i++) {
            result.push(genMock());
          }
        } else {
          result = genMock();
        }
        return result;
      }