EdColeman commented on a change in pull request #1537: Add PrintInfo options to 
dump full keys, apply formatter
URL: https://github.com/apache/accumulo/pull/1537#discussion_r385475020
 
 

 ##########
 File path: 
core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
 ##########
 @@ -119,6 +182,18 @@ public String keyword() {
     return "rfile-info";
   }
 
+  protected Class<? extends Formatter> getFormater(String formatterClazz) {
+    try {
+      if (formatterClazz != null) {
+        return this.getClass().getClassLoader().loadClass(formatterClazz)
+            .asSubclass(Formatter.class);
+      }
+    } catch (ClassNotFoundException e) {
+      System.err.println("Could not find formatter class: " + formatterClazz);
+    }
+    return null;
+  }
+
 
 Review comment:
   This is a general question - would this reflection code need to change for 
jdk-11+ (for when this is merged forward)? Specifically, is this still the 
standard way to use reflection, or has the "standard" changed?  From what I've 
read it looks okay, but thought it warranted checking.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to