incubator-accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bil...@apache.org
Subject svn commit: r1204761 - /incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java
Date Tue, 22 Nov 2011 00:24:57 GMT
Author: billie
Date: Tue Nov 22 00:24:46 2011
New Revision: 1204761

URL: http://svn.apache.org/viewvc?rev=1204761&view=rev
Log:
ACCUMULO-129 merge to trunk

Modified:
    incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java

Modified: incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java?rev=1204761&r1=1204760&r2=1204761&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java
(original)
+++ incubator/accumulo/trunk/src/core/src/main/java/org/apache/accumulo/core/util/shell/commands/SetIterCommand.java
Tue Nov 22 00:24:46 2011
@@ -120,7 +120,7 @@ public class SetIterCommand extends Comm
     shellState.getConnector().tableOperations().attachIterator(tableName, setting);
   }
   
-  private static String setUpOptions(ConsoleReader reader, String className, Map<String,String>
options) throws IOException {
+  private static String setUpOptions(ConsoleReader reader, String className, Map<String,String>
options) throws IOException, ShellCommandException {
     String input;
     OptionDescriber skvi;
     Class<? extends OptionDescriber> clazz;
@@ -133,6 +133,9 @@ public class SetIterCommand extends Comm
       throw new IllegalArgumentException(e.getMessage());
     } catch (IllegalAccessException e) {
       throw new IllegalArgumentException(e.getMessage());
+    } catch (ClassCastException e) {
+      throw new ShellCommandException(ErrorCode.INITIALIZATION_FAILURE, "Unable to load "
+ className + " as type " + OptionDescriber.class.getName()
+          + "; configure with 'config' instead");
     }
     
     IteratorOptions itopts = skvi.describeOptions();



Mime
View raw message