|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectjavax.naming.ldap.BasicControl
javax.naming.ldap.SortResponseControl
public final class SortResponseControl
指示搜索结果的请求排序是否成功。当结果代码指示成功时,结果已按照请求进行了排序。否则,排序失败,同时服务器可能提供关于错误原因的附加详细信息。
SortControl 中的代码示例展示了使用此类的方式。
此类实现在 RFC 2891 中定义的用于服务器端排序的 LDAPv3 响应控件。 控件值具有以下 ASN.1 定义:
SortResult ::= SEQUENCE {
sortResult ENUMERATED {
success (0), -- results are sorted
operationsError (1), -- server internal failure
timeLimitExceeded (3), -- timelimit reached before
-- sorting was completed
strongAuthRequired (8), -- refused to return sorted
-- results via insecure
-- protocol
adminLimitExceeded (11), -- too many matching entries
-- for the server to sort
noSuchAttribute (16), -- unrecognized attribute
-- type in sort key
inappropriateMatching (18), -- unrecognized or inappro-
-- priate matching rule in
-- sort key
insufficientAccessRights (50), -- refused to return sorted
-- results to this client
busy (51), -- too busy to process
unwillingToPerform (53), -- unable to sort
other (80)
},
attributeType [0] AttributeType OPTIONAL }
SortControl,
序列化表格| 字段摘要 | |
|---|---|
static String |
OID
服务器端排序响应控件的分配对象标识符为 1.2.840.113556.1.4.474。 |
| 从类 javax.naming.ldap.BasicControl 继承的字段 |
|---|
criticality, id, value |
| 从接口 javax.naming.ldap.Control 继承的字段 |
|---|
CRITICAL, NONCRITICAL |
| 构造方法摘要 | |
|---|---|
SortResponseControl(String id,
boolean criticality,
byte[] value)
构造一个控件来指示排序请求的结果。 |
|
| 方法摘要 | |
|---|---|
String |
getAttributeID()
检索导致排序失败的属性的 ID。 |
NamingException |
getException()
检索适合结果代码的 NamingException。 |
int |
getResultCode()
检索排序操作的 LDAP 结果代码。 |
boolean |
isSorted()
确定是否已成功排序搜索结果。 |
| 从类 javax.naming.ldap.BasicControl 继承的方法 |
|---|
getEncodedValue, getID, isCritical |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| 字段详细信息 |
|---|
public static final String OID
| 构造方法详细信息 |
|---|
public SortResponseControl(String id,
boolean criticality,
byte[] value)
throws IOException
id - 此控件的对象标识符字符串。criticality - 控件的关键性。value - 控件的 ASN.1 BER 编码值。它不是副本,对值进行的任何更改都将影响控件的内容。
IOException - 如果在解码控件值时遇到错误。| 方法详细信息 |
|---|
public boolean isSorted()
public int getResultCode()
public String getAttributeID()
public NamingException getException()
|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
版权所有 2007 Sun Microsystems, Inc. 保留所有权利。 请遵守许可证条款。另请参阅文档重新分发政策。