From 1734229125e7bad5f85dfe11d076eeda206236a9 Mon Sep 17 00:00:00 2001
From: Ludovic Poitou <ludovic.poitou@forgerock.com>
Date: Mon, 18 Oct 2010 19:41:47 +0000
Subject: [PATCH] Update from OpenDS sdk by Bo Li: Added unmodifiable and copyOf request factories. Added authrate performance utility.
---
sdk/src/com/sun/opends/sdk/tools/LDAPSearch.java | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/sdk/src/com/sun/opends/sdk/tools/LDAPSearch.java b/sdk/src/com/sun/opends/sdk/tools/LDAPSearch.java
index d8a8316..5c5daa5 100644
--- a/sdk/src/com/sun/opends/sdk/tools/LDAPSearch.java
+++ b/sdk/src/com/sun/opends/sdk/tools/LDAPSearch.java
@@ -22,7 +22,7 @@
* CDDL HEADER END
*
*
- * Copyright 2009-2010 Sun Microsystems, Inc.
+ * Copyright 2010 Sun Microsystems, Inc.
*/
package com.sun.opends.sdk.tools;
@@ -400,7 +400,8 @@
final ArgumentParser argParser = new ArgumentParser(LDAPSearch.class
.getName(), toolDescription, false, true, 0, 0,
"[filter] [attributes ...]");
- ArgumentParserConnectionFactory connectionFactory;
+ ConnectionFactoryProvider connectionFactoryProvider;
+ ConnectionFactory connectionFactory;
BooleanArgument countEntries;
BooleanArgument dontWrap;
@@ -425,7 +426,8 @@
IntegerArgument sizeLimit;
try
{
- connectionFactory = new ArgumentParserConnectionFactory(argParser, this);
+ connectionFactoryProvider =
+ new ConnectionFactoryProvider(argParser, this);
final StringArgument propertiesFileArgument = new StringArgument(
"propertiesFilePath", null, OPTION_LONG_PROP_FILE_PATH, false, false,
true, INFO_PROP_FILE_PATH_PLACEHOLDER.get(), null, null,
@@ -607,7 +609,8 @@
try
{
argParser.parseArguments(args);
- connectionFactory.validate();
+ connectionFactory =
+ connectionFactoryProvider.getAuthenticatedConnectionFactory();
}
catch (final ArgumentException ae)
{
--
Gitblit v1.10.0