lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ehatc...@apache.org
Subject svn commit: r638145 - /lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java
Date Mon, 17 Mar 2008 23:58:02 GMT
Author: ehatcher
Date: Mon Mar 17 16:57:59 2008
New Revision: 638145

URL: http://svn.apache.org/viewvc?rev=638145&view=rev
Log:
Fix issue caused by SOLR-494 with SolrJ unit tests.

Modified:
    lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java

Modified: lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java?rev=638145&r1=638144&r2=638145&view=diff
==============================================================================
--- lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java (original)
+++ lucene/solr/trunk/src/java/org/apache/solr/handler/admin/LukeRequestHandler.java Mon Mar
17 16:57:59 2008
@@ -396,14 +396,15 @@
 	       aninfo.add("tokenizer", tokenizer);
 	       TokenFilterFactory[] filtfacs = tchain.getTokenFilterFactories();
 	       
-	       List<Map<String, Object>> filters = new ArrayList<Map<String, Object>>();
-	       for (TokenFilterFactory filtfac : filtfacs) {
+        SimpleOrderedMap<Map<String, Object>> filters = new SimpleOrderedMap<Map<String,
Object>>();
+        for (TokenFilterFactory filtfac : filtfacs) {
 	    	   Map<String, Object> tok = new HashMap<String, Object>();
-	    	   tok.put("className", filtfac.getClass().getName());
+           String className = filtfac.getClass().getName();
+           tok.put("className", className);
 	    	   tok.put("args", filtfac.getArgs());
-	    	   filters.add(tok);
+	    	   filters.add(className.substring(className.lastIndexOf('.')+1), tok);
 	       }
-	       if (!filters.isEmpty()) {
+	       if (filters.size() > 0) {
 	    	   aninfo.add("filters", filters);
 	       }
 	  }



Mime
View raw message