class PersistentSearchRequestControl extends AbstractControl implements RequestControl {

  @Override
  public byte[] encode()
  {
    int types = 0;
    for (PersistentSearchChangeType type : getChangeTypes()) {
      types |= type.value();
    }

    final ConstructedDEREncoder se = new ConstructedDEREncoder(
      UniversalDERTag.SEQ,
      new IntegerType(types),
      new BooleanType(getChangesOnly()),
      new BooleanType(getReturnEcs()));
    return se.encode();
  }

  public  PersistentSearchRequestControl();
  public  PersistentSearchRequestControl(final EnumSet<PersistentSearchChangeType> types);
  public  PersistentSearchRequestControl(final EnumSet<PersistentSearchChangeType> types, final boolean critical);
  public  PersistentSearchRequestControl(
    final EnumSet<PersistentSearchChangeType> types,
    final boolean co,
    final boolean re);
  public  PersistentSearchRequestControl(
    final EnumSet<PersistentSearchChangeType> types,
    final boolean co,
    final boolean re,
    final boolean critical);

}