lib/controls/server_side_sorting_request_control.js
function ServerSideSortingRequestControl(options) {
  assert.optionalObject(options);
  options = options || {};
  options.type = ServerSideSortingRequestControl.OID;
  if (options.value) {
    if (Buffer.isBuffer(options.value)) {
      this.parse(options.value);
    } else if (Array.isArray(options.value)) {
      assert.arrayOfObject(options.value, 'options.value must be Objects');
      for (var i = 0; i < options.value.length; i++) {
        if (!options.value[i].hasOwnProperty('attributeType')) {
          throw new Error('Missing required key: attributeType');
        }
      }
      this._value = options.value;
    } else if (typeof (options.value) === 'object') {
      if (!options.value.hasOwnProperty('attributeType')) {
        throw new Error('Missing required key: attributeType');
      }
      this._value = [options.value];
    } else {
      throw new TypeError('options.value must be a Buffer, Array or Object');
    }
    options.value = null;
  }
  Control.call(this, options);
}
function ServerSideSortingRequestControl(options) {
  assert.optionalObject(options);
  options = options || {};
  options.type = ServerSideSortingRequestControl.OID;
  if (options.value) {
    if (Buffer.isBuffer(options.value)) {
      this.parse(options.value);
    } else if (Array.isArray(options.value)) {
      assert.arrayOfObject(options.value, 'options.value must be Objects');
      for (var i = 0; i < options.value.length; i++) {
        if (!options.value[i].hasOwnProperty('attributeType')) {
          throw new Error('Missing required key: attributeType');
        }
      }
      this._value = options.value;
    } else if (typeof (options.value) === 'object') {
      if (!options.value.hasOwnProperty('attributeType')) {
        throw new Error('Missing required key: attributeType');
      }
      this._value = [options.value];
    } else {
      throw new TypeError('options.value must be a Buffer, Array or Object');
    }
    options.value = null;
  }
  Control.call(this, options);
}
/--- API