Ejemplo n.º 1
0
  private Control[] getControls(final LDAPConstraints c) {
    Control[] controls = null;
    if (c != null) {
      controls = LDAPControl.toControls(c.getServerControls());
    } else if (constraints != null) {
      controls = LDAPControl.toControls(constraints.getServerControls());
    }

    if (controls == null) {
      return new Control[0];
    } else {
      return controls;
    }
  }
Ejemplo n.º 2
0
  private void update(final UpdatableLDAPRequest request, final LDAPConstraints constraints) {
    final LDAPConstraints c = (constraints == null) ? this.constraints : constraints;

    request.setControls(LDAPControl.toControls(c.getServerControls()));
    request.setResponseTimeoutMillis(c.getTimeLimit());
    request.setFollowReferrals(c.getReferrals());
  }