blob: 857286b15b7a80c6ce2136edcff5c21aa7f468d7 [file] [log] [blame]
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*
*/
package org.apache.directory.api.ldap.extras.controls.ad;
import org.apache.directory.api.ldap.model.message.Control;
/**
* The AdDirSyncResponse control has the following value :
*
* <pre>
* Repl Control ::= SEQUENCE {
* controlType 1.2.840.113556.1.4.841
* controlValue replControlValue
* criticality TRUE
* }
*
* realReplControlValue ::= SEQUENCE {
* flag integer
* maxReturnLength integer
* cookie OCTET STRING
* }
* </pre>
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
*/
public interface AdDirSyncResponse extends Control
{
/** This control OID */
static final String OID = "1.2.840.113556.1.4.841";
/**
* @return The flag returned by the server. One of :
* <ul>
* <li>LDAP_DIRSYNC_OBJECT_SECURITY (0x0001)</li>
* <li>LDAP_DIRSYNC_ANCESTORS_FIRST_ORDER (0x0800)</li>
* <li>LDAP_DIRSYNC_PUBLIC_DATA_ONLY (0x2000)(</li>
* <li>LDAP_DIRSYNC_INCREMENTAL_VALUES (0x7FFFFFFF)</li>
* </ul>
*/
AdDirSyncFlag getFlag();
/**
* @param flag The flag.
*/
void setFlag( AdDirSyncFlag flag );
/**
* @return The maximum length of attributes to be returned
*/
int getMaxReturnLength();
/**
* @param maxReturnLength The maximum length of attributes to be returned
*/
void setMaxReturnLength( int maxReturnLength );
/**
* @return The cookie used while processing the successive DirSync operations
*/
byte[] getCookie();
/**
* @param cookie The cookie to send to the server. It's the value found in the response control. Should be null
* for the first control.
*/
void setCookie( byte[] cookie );
}