incubator-droids-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject svn commit: r1423339 [3/5] - in /incubator/droids/branches/0.2.x-cleanup: droids-crawler/ droids-crawler/src/main/java/org/apache/droids/crawler/ droids-crawler/src/main/java/org/apache/droids/protocol/http/ droids-crawler/src/test/java/org/apache/droi...
Date Tue, 18 Dec 2012 08:48:00 GMT
Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/NoRobotException.java
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/NoRobotException.java?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/NoRobotException.java (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/NoRobotException.java Tue Dec 18 08:47:39 2012
@@ -27,19 +27,19 @@
 package org.apache.droids.norobots;
 
 /**
- * Application exception for anything that might go wrong 
- * in the checking of a robots.txt file. It does not 
+ * Application exception for anything that might go wrong
+ * in the checking of a robots.txt file. It does not
  * wrap an Exception to maintain support for older JDKs.
  */
 public class NoRobotException extends Exception {
 
-  private static final long serialVersionUID = 7185905140738392746L;
+    private static final long serialVersionUID = 7185905140738392746L;
 
-public NoRobotException(String message) {
-    super(message);
-  }
+    public NoRobotException(String message) {
+        super(message);
+    }
 
-  public NoRobotException(String message, Throwable t) {
-    super(message + " :::: " + t.getMessage());
-  }
+    public NoRobotException(String message, Throwable t) {
+        super(message + " :::: " + t.getMessage());
+    }
 }

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/Rule.java
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/Rule.java?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/Rule.java (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/Rule.java Tue Dec 18 08:47:39 2012
@@ -30,10 +30,10 @@ package org.apache.droids.norobots;
  * A robots.txt rule. Is a particular path allowed?
  */
 public interface Rule {
-  /**
-   * Boolean.TRUE means it is allowed. 
-   * Boolean.FALSE means it is not allowed.
-   * null means that this rule is not applicable.
-   */
-  Boolean isAllowed(String path);
+    /**
+     * Boolean.TRUE means it is allowed.
+     * Boolean.FALSE means it is not allowed.
+     * null means that this rule is not applicable.
+     */
+    Boolean isAllowed(String path);
 }

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/RulesEngine.java
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/RulesEngine.java?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/RulesEngine.java (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/RulesEngine.java Tue Dec 18 08:47:39 2012
@@ -30,51 +30,51 @@ import java.util.ArrayList;
 import java.util.List;
 
 /**
- * Contains a series of Rules. It then runs a path against these 
- * to decide if it is allowed or not. 
+ * Contains a series of Rules. It then runs a path against these
+ * to decide if it is allowed or not.
  */
 class RulesEngine {
 
-  private List<Rule> rules;
+    private List<Rule> rules;
 
-  public RulesEngine() {
-    this.rules = new ArrayList<Rule>();
-  }
-
-  public void allowPath(String path) {
-    add( new AllowedRule(path) );
-  }
-
-  public void disallowPath(String path) {
-    add( new DisallowedRule(path) );
-  }
-
-  public void add(Rule rule) {
-    this.rules.add(rule);
-  }
-
-  /**
-   * Run each Rule in series on the path. 
-   * If a Rule returns a Boolean, return that.
-   * When no more rules are left, return null to indicate there were 
-   * no rules for this path.. 
-   */
-  public Boolean isAllowed(String path) {
-    for( Rule rule : rules ) {
-      Boolean test = rule.isAllowed(path);
-      if(test != null) {
-        return test;
-      }
-    }
-    return null;
-  }
-
-  public boolean isEmpty() {
-    return this.rules.isEmpty();
-  }
-
-  @Override
-  public String toString() {
-    return "RulesEngine: " + this.rules;
-  }
+    public RulesEngine() {
+        this.rules = new ArrayList<Rule>();
+    }
+
+    public void allowPath(String path) {
+        add(new AllowedRule(path));
+    }
+
+    public void disallowPath(String path) {
+        add(new DisallowedRule(path));
+    }
+
+    public void add(Rule rule) {
+        this.rules.add(rule);
+    }
+
+    /**
+     * Run each Rule in series on the path.
+     * If a Rule returns a Boolean, return that.
+     * When no more rules are left, return null to indicate there were
+     * no rules for this path..
+     */
+    public Boolean isAllowed(String path) {
+        for (Rule rule : rules) {
+            Boolean test = rule.isAllowed(path);
+            if (test != null) {
+                return test;
+            }
+        }
+        return null;
+    }
+
+    public boolean isEmpty() {
+        return this.rules.isEmpty();
+    }
+
+    @Override
+    public String toString() {
+        return "RulesEngine: " + this.rules;
+    }
 }

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/SimpleContentLoader.java
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/SimpleContentLoader.java?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/SimpleContentLoader.java (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/SimpleContentLoader.java Tue Dec 18 08:47:39 2012
@@ -35,26 +35,24 @@ import java.net.URLConnection;
 /**
  * A simple implementation of {@link ContentLoader} based on {@link URLConnection}.
  */
-public class SimpleContentLoader implements ContentLoader
-{
+public class SimpleContentLoader implements ContentLoader {
 
-  @Override
-  public boolean exists(URI uri) throws IOException
-  {
-    URL url = uri.toURL();
-    try {
-      URLConnection conn = url.openConnection();
-      return conn != null;
-    } catch (IOException ex) {
-      return false;
+    @Override
+    public boolean exists(URI uri) throws IOException {
+        URL url = uri.toURL();
+        try {
+            URLConnection conn = url.openConnection();
+            return conn != null;
+        } catch (IOException ex) {
+            return false;
+        }
     }
-  }
 
-  @Override
-  public InputStream load(URI uri) throws IOException {
-    URL url = uri.toURL();
-    URLConnection conn = url.openConnection();
-    return conn.getInputStream();
-  }
+    @Override
+    public InputStream load(URI uri) throws IOException {
+        URL url = uri.toURL();
+        URLConnection conn = url.openConnection();
+        return conn.getInputStream();
+    }
 
 }

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/package.html
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/package.html?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/package.html (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/main/java/org/apache/droids/norobots/package.html Tue Dec 18 08:47:39 2012
@@ -17,31 +17,31 @@
 <html>
 <body>
 
-  <h3>Using norobots-rfc</h3>
-   <ol>
-   <li>Import the class
-   <code>
-       import org.apache.http.norobots.NoRobotClient;
-   </code>
-   </li>
-   <li>Create an instance for your user-agent
-   <code>
-       NoRobotClient nrc = NoRobotClient("googlebot");
-   </code>
-   </li>
-   <li>Parse a robots.txt at a site
-   <code>
-       nrc.parse( new URL( "http://www.apache.org/" ) );
-   </code>
-   </li>
-   <li>Ask if a url is allowed
-   <code>
-       boolean test = nrc.isUrlAllowed( new URL( "http://www.apache.org/index.html" ) );
-   </code>
-   </li>
-   </ol>
+<h3>Using norobots-rfc</h3>
+<ol>
+    <li>Import the class
+        <code>
+            import org.apache.http.norobots.NoRobotClient;
+        </code>
+    </li>
+    <li>Create an instance for your user-agent
+        <code>
+            NoRobotClient nrc = NoRobotClient("googlebot");
+        </code>
+    </li>
+    <li>Parse a robots.txt at a site
+        <code>
+            nrc.parse( new URL( "http://www.apache.org/" ) );
+        </code>
+    </li>
+    <li>Ask if a url is allowed
+        <code>
+            boolean test = nrc.isUrlAllowed( new URL( "http://www.apache.org/index.html" ) );
+        </code>
+    </li>
+</ol>
 
- </body>
+</body>
 </document>
 </body>
 </html> 

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/site/site.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/site/site.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/site/site.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/site/site.xml Tue Dec 18 08:47:39 2012
@@ -16,14 +16,14 @@
  limitations under the License.
 -->
 <project xmlns="http://maven.apache.org/DECORATION/1.0.0"
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/DECORATION/1.0.0 http://maven.apache.org/xsd/decoration-1.0.0.xsd">
-  <body>
-    <menu ref="parent" />
-    
-    <menu name="JavaDocs"> 
-      <item name="JavaDocs" href="apidocs/index.html"/>
-      <item name="Test JavaDocs" href="testapidocs/index.html"/>
-    </menu>
-  </body>
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/DECORATION/1.0.0 http://maven.apache.org/xsd/decoration-1.0.0.xsd">
+    <body>
+        <menu ref="parent"/>
+
+        <menu name="JavaDocs">
+            <item name="JavaDocs" href="apidocs/index.html"/>
+            <item name="Test JavaDocs" href="testapidocs/index.html"/>
+        </menu>
+    </body>
 </project>
\ No newline at end of file

Modified: incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/test/java/org/apache/droids/norobots/TestNorobotsClient.java
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/test/java/org/apache/droids/norobots/TestNorobotsClient.java?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/test/java/org/apache/droids/norobots/TestNorobotsClient.java (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-norobots/src/test/java/org/apache/droids/norobots/TestNorobotsClient.java Tue Dec 18 08:47:39 2012
@@ -28,258 +28,257 @@ import junit.framework.Assert;
 import org.junit.BeforeClass;
 import org.junit.Test;
 
-public class TestNorobotsClient
-{
+public class TestNorobotsClient {
+
+    private static URI BASE_URI;
+
+    @BeforeClass
+    public static void setupBaseURL() throws URISyntaxException {
+        ClassLoader cl = TestNorobotsClient.class.getClassLoader();
+        BASE_URI = cl.getResource("data/").toURI();
+    }
+
+    //-----------------------------------------------------------------------
+    // To test:
+    // create -> parse -> isUrlAllowed?
+
+    @Test
+    public void testAllowed() throws Exception {
+        URI target = BASE_URI.resolve("basic/");
+        NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
+        nrc.parse(target);
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("view-cvs/")));
+    }
+
+    // Tests the example given in the RFC
+    @Test
+    public void testRfcExampleUnhipbot() throws Exception {
+        URI target = BASE_URI.resolve("rfc/");
+
+        NoRobotClient nrc = new NoRobotClient("unhipbot");
+        nrc.parse(target);
+
+        // Start of rfc test
+        Assert.assertFalse(nrc.isUrlAllowed(target));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("index.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("server.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("services/fast.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("services/slow.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("orgo.gif")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/about.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/plans.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
+        // End of rfc test
+    }
+
+    @Test
+    public void testRfcExampleWebcrawler() throws Exception {
+        URI target = BASE_URI.resolve("rfc/");
+
+        NoRobotClient nrc = new NoRobotClient("webcrawler");
+        nrc.parse(target);
+        // Start of rfc test
+        Assert.assertTrue(nrc.isUrlAllowed(target));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("orgo.gif")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/plans.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
+        // End of rfc test
+    }
+
+    @Test
+    public void testRfcExampleExcite() throws Exception {
+        URI target = BASE_URI.resolve("rfc/");
+
+        NoRobotClient nrc = new NoRobotClient("excite");
+        nrc.parse(target);
+        // Start of rfc test
+        Assert.assertTrue(nrc.isUrlAllowed(target));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("orgo.gif")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/plans.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
+        // End of rfc test
+    }
+
+    @Test
+    public void testRfcExampleOther() throws Exception {
+        URI target = BASE_URI.resolve("rfc/");
+
+        NoRobotClient nrc = new NoRobotClient("other");
+        nrc.parse(target);
+        // Start of rfc test
+        Assert.assertFalse(nrc.isUrlAllowed(target));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("index.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("orgo.gif")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/plans.html")));
+        Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
+        // End of rfc test
+    }
+
+    @Test
+    public void testRfcBadWebDesigner() throws Exception {
+        URI target = BASE_URI.resolve("bad/");
+
+        NoRobotClient nrc = new NoRobotClient("other");
+        nrc.parse(target);
+
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Etest/%7Efoo.html")));
+    }
+
+    // Tests NRB-3
+    // http://www.osjava.org:8080/jira/secure/ViewIssue.jspa?key=NRB-3
+    @Test
+    public void testNrb3() throws Exception {
+        URI target = BASE_URI.resolve("basic/");
+        NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
+        nrc.parse(target);
+        Assert.assertTrue(nrc.isUrlAllowed(target.resolve("basic")));
+    }
+
+    // Tests NRB-6
+    // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-6
+    @Test
+    public void testNrb6() throws Exception {
+        URI target = BASE_URI.resolve("order/");
+        NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
+        nrc.parse(target);
+        Assert.assertTrue("Specific then Wildcard not working as expected", nrc
+                .isUrlAllowed(target.resolve("order/")));
+
+        target = BASE_URI.resolve("order-reverse/");
+        nrc = new NoRobotClient("Scabies-1.0");
+        nrc.parse(target);
+        Assert.assertTrue("Wildcard then Specific not working as expected", nrc
+                .isUrlAllowed(target.resolve("order/")));
+    }
+
+    // Tests NRB-9
+    // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-9
+    @Test
+    public void testNrb9() throws Exception {
+        URI target = BASE_URI.resolve("disallow-empty/");
+        NoRobotClient nrc = new NoRobotClient("test");
+        nrc.parse(target);
+        Assert.assertTrue("'Disallow: ' should mean to disallow nothing", nrc
+                .isUrlAllowed(target.resolve("index.html")));
+    }
+
+    // Tests NRB-8
+    // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-8
+    @Test
+    public void testNrb8() throws Exception {
+        URI target = BASE_URI.resolve("ua-case-insensitive/");
+        String[] names = new String[]{"test", "TEST", "tEsT"};
+        for (int i = 0; i < names.length; i++) {
+            NoRobotClient nrc = new NoRobotClient(names[i]);
+            nrc.parse(target);
+            Assert.assertFalse("User-Agent names should be case insensitive", nrc
+                    .isUrlAllowed(target.resolve("index.html")));
+        }
+    }
+
+    @Test
+    public void testRobotsParsing() throws Exception {
+        String s =
+                "User-agent: *\r\n" +
+                        "Disallow: /tmp/\r\n" +
+                        "User-agent: BadRobot\r\n" +
+                        "Disallow: /cgi-bin/\r\n" +
+                        "Disallow: /blah/";
+        Map<String, RulesEngine> map = NoRobotClient.parse(
+                new ByteArrayInputStream(s.getBytes("US-ASCII")));
+        Assert.assertNotNull(map);
+        Assert.assertEquals(2, map.size());
+        Assert.assertNotNull(map.get("*"));
+        Assert.assertNotNull(map.get("badrobot"));
+        Assert.assertNull(map.get("BadRobot"));
+        Assert.assertNull(map.get("wnatever"));
+    }
+
+    @Test
+    public void testComplexRobotsParsing() throws Exception {
+        String s =
+                "User-agent: *\r\n" +
+                        "Disallow: /tmp/\r\n" +
+                        "User-agent: BadRobot1\r\n" +
+                        "User-agent: BadRobot2\r\n" +
+                        "User-agent: BadRobot3\r\n" +
+                        "Disallow: /cgi-bin/\r\n" +
+                        "Disallow: /blah/\r\n" +
+                        "User-agent: BadRobot1\r\n" +
+                        "Disallow: /yada/\r\n" +
+                        "User-agent: BadRobot3\r\n" +
+                        "Allow: /haha/";
+        Map<String, RulesEngine> map = NoRobotClient.parse(
+                new ByteArrayInputStream(s.getBytes("US-ASCII")));
+        Assert.assertNotNull(map);
+        Assert.assertEquals(4, map.size());
+        Assert.assertNotNull(map.get("*"));
+        Assert.assertNotNull(map.get("badrobot1"));
+        Assert.assertNotNull(map.get("badrobot2"));
+        Assert.assertNotNull(map.get("badrobot3"));
+        Assert.assertNull(map.get("badrobot4"));
+        Assert.assertNull(map.get("wnatever"));
+
+        RulesEngine e1 = map.get("*");
+        Assert.assertEquals(Boolean.FALSE, e1.isAllowed("/tmp/"));
+        Assert.assertNull(e1.isAllowed("/blah/"));
+        Assert.assertNull(e1.isAllowed("/yada/"));
+        Assert.assertNull(e1.isAllowed("/haha/"));
+
+        RulesEngine e2 = map.get("badrobot1");
+        Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/cgi-bin/"));
+        Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/blah/"));
+        Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/yada/"));
+        Assert.assertNull(e2.isAllowed("/haha/"));
+
+        RulesEngine e3 = map.get("badrobot2");
+        Assert.assertEquals(Boolean.FALSE, e3.isAllowed("/cgi-bin/"));
+        Assert.assertEquals(Boolean.FALSE, e3.isAllowed("/blah/"));
+        Assert.assertNull(e3.isAllowed("/yada/"));
+        Assert.assertNull(e3.isAllowed("/haha/"));
+
+        RulesEngine e4 = map.get("badrobot3");
+        Assert.assertEquals(Boolean.FALSE, e4.isAllowed("/cgi-bin/"));
+        Assert.assertEquals(Boolean.FALSE, e4.isAllowed("/blah/"));
+        Assert.assertNull(e4.isAllowed("/yada/"));
+        Assert.assertEquals(Boolean.TRUE, e4.isAllowed("/haha/"));
+    }
+
+    @Test
+    public void testSimpleRobotsCheck() throws Exception {
+        String s =
+                "User-agent: *\r\n" +
+                        "Disallow: /cgi-bin/\r\n" +
+                        "Disallow: /tmp/\r\n" +
+                        "Disallow: /~mine/";
+        NoRobotClient nrc = new NoRobotClient(new SimpleContentLoader(), "whatever");
+        nrc.parseText(new ByteArrayInputStream(s.getBytes("US-ASCII")));
+        Assert.assertTrue(nrc.isUrlAllowed(new URI("/whatever/")));
+        Assert.assertFalse(nrc.isUrlAllowed(new URI("/~mine/")));
+        Assert.assertFalse(nrc.isUrlAllowed(new URI("/tmp/")));
+    }
 
-  private static URI BASE_URI;
-  
-  @BeforeClass
-  public static void setupBaseURL() throws URISyntaxException {
-    ClassLoader cl = TestNorobotsClient.class.getClassLoader();
-    BASE_URI = cl.getResource("data/").toURI();
-  }
-  
-  //-----------------------------------------------------------------------
-  // To test: 
-  // create -> parse -> isUrlAllowed?
-
-  @Test
-  public void testAllowed() throws Exception {
-    URI target = BASE_URI.resolve("basic/");
-    NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
-    nrc.parse(target);
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("view-cvs/")));
-  }
-
-  // Tests the example given in the RFC
-  @Test
-  public void testRfcExampleUnhipbot() throws Exception {
-    URI target = BASE_URI.resolve("rfc/");
-
-    NoRobotClient nrc = new NoRobotClient("unhipbot");
-    nrc.parse(target);
-
-    // Start of rfc test
-    Assert.assertFalse(nrc.isUrlAllowed(target));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("index.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("server.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("services/fast.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("services/slow.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("orgo.gif")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/about.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/plans.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
-    // End of rfc test
-  }
-
-  @Test
-  public void testRfcExampleWebcrawler() throws Exception {
-    URI target = BASE_URI.resolve("rfc/");
-
-    NoRobotClient nrc = new NoRobotClient("webcrawler");
-    nrc.parse(target);
-    // Start of rfc test
-    Assert.assertTrue(nrc.isUrlAllowed(target));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("orgo.gif")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/plans.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
-    // End of rfc test
-  }
-
-  @Test
-  public void testRfcExampleExcite() throws Exception {
-    URI target = BASE_URI.resolve("rfc/");
-
-    NoRobotClient nrc = new NoRobotClient("excite");
-    nrc.parse(target);
-    // Start of rfc test
-    Assert.assertTrue(nrc.isUrlAllowed(target));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("index.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("orgo.gif")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/plans.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
-    // End of rfc test
-  }
-
-  @Test
-  public void testRfcExampleOther() throws Exception {
-    URI target = BASE_URI.resolve("rfc/");
-
-    NoRobotClient nrc = new NoRobotClient("other");
-    nrc.parse(target);
-    // Start of rfc test
-    Assert.assertFalse(nrc.isUrlAllowed(target));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("index.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("robots.txt")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("server.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/fast.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("services/slow.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("orgo.gif")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("org/about.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("org/plans.html")));
-    Assert.assertFalse(nrc.isUrlAllowed(target.resolve("%7Ejim/jim.html")));
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Emak/mak.html")));
-    // End of rfc test
-  }
-
-  @Test
-  public void testRfcBadWebDesigner() throws Exception {
-    URI target = BASE_URI.resolve("bad/");
-
-    NoRobotClient nrc = new NoRobotClient("other");
-    nrc.parse(target);
-
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("%7Etest/%7Efoo.html")));
-  }
-
-  // Tests NRB-3
-  // http://www.osjava.org:8080/jira/secure/ViewIssue.jspa?key=NRB-3
-  @Test
-  public void testNrb3() throws Exception {
-    URI target = BASE_URI.resolve("basic/");
-    NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
-    nrc.parse(target);
-    Assert.assertTrue(nrc.isUrlAllowed(target.resolve("basic")));
-  }
-
-  // Tests NRB-6
-  // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-6
-  @Test
-  public void testNrb6() throws Exception {
-    URI target = BASE_URI.resolve("order/");
-    NoRobotClient nrc = new NoRobotClient("Scabies-1.0");
-    nrc.parse(target);
-    Assert.assertTrue("Specific then Wildcard not working as expected", nrc
-        .isUrlAllowed(target.resolve("order/")));
-
-    target = BASE_URI.resolve("order-reverse/");
-    nrc = new NoRobotClient("Scabies-1.0");
-    nrc.parse(target);
-    Assert.assertTrue("Wildcard then Specific not working as expected", nrc
-        .isUrlAllowed(target.resolve("order/")));
-  }      
-
-  // Tests NRB-9
-  // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-9
-  @Test
-  public void testNrb9() throws Exception {
-    URI target = BASE_URI.resolve("disallow-empty/");
-    NoRobotClient nrc = new NoRobotClient("test");
-    nrc.parse(target);
-    Assert.assertTrue("'Disallow: ' should mean to disallow nothing", nrc
-        .isUrlAllowed(target.resolve("index.html")));
-  }
-
-  // Tests NRB-8
-  // http://issues.osjava.org/jira/secure/ViewIssue.jspa?key=NRB-8
-  @Test
-  public void testNrb8() throws Exception {
-    URI target = BASE_URI.resolve("ua-case-insensitive/");
-    String[] names = new String[] {"test", "TEST", "tEsT"};
-    for (int i = 0; i < names.length; i++) {
-      NoRobotClient nrc = new NoRobotClient(names[i]);
-      nrc.parse(target);
-      Assert.assertFalse("User-Agent names should be case insensitive", nrc
-          .isUrlAllowed(target.resolve("index.html")));
-    }
-  }
-
-  @Test
-  public void testRobotsParsing() throws Exception {
-    String s = 
-      "User-agent: *\r\n" +
-      "Disallow: /tmp/\r\n" +
-      "User-agent: BadRobot\r\n" +
-      "Disallow: /cgi-bin/\r\n" +
-      "Disallow: /blah/";
-    Map<String, RulesEngine> map = NoRobotClient.parse(
-        new ByteArrayInputStream(s.getBytes("US-ASCII")));
-    Assert.assertNotNull(map);
-    Assert.assertEquals(2, map.size());
-    Assert.assertNotNull(map.get("*"));
-    Assert.assertNotNull(map.get("badrobot"));
-    Assert.assertNull(map.get("BadRobot"));
-    Assert.assertNull(map.get("wnatever"));
-  }
-  
-  @Test
-  public void testComplexRobotsParsing() throws Exception {
-    String s = 
-      "User-agent: *\r\n" +
-      "Disallow: /tmp/\r\n" +
-      "User-agent: BadRobot1\r\n" +
-      "User-agent: BadRobot2\r\n" +
-      "User-agent: BadRobot3\r\n" +
-      "Disallow: /cgi-bin/\r\n" +
-      "Disallow: /blah/\r\n" +
-      "User-agent: BadRobot1\r\n" +
-      "Disallow: /yada/\r\n" +
-      "User-agent: BadRobot3\r\n" +
-      "Allow: /haha/";
-    Map<String, RulesEngine> map = NoRobotClient.parse(
-        new ByteArrayInputStream(s.getBytes("US-ASCII")));
-    Assert.assertNotNull(map);
-    Assert.assertEquals(4, map.size());
-    Assert.assertNotNull(map.get("*"));
-    Assert.assertNotNull(map.get("badrobot1"));
-    Assert.assertNotNull(map.get("badrobot2"));
-    Assert.assertNotNull(map.get("badrobot3"));
-    Assert.assertNull(map.get("badrobot4"));
-    Assert.assertNull(map.get("wnatever"));
-    
-    RulesEngine e1 = map.get("*");
-    Assert.assertEquals(Boolean.FALSE, e1.isAllowed("/tmp/"));
-    Assert.assertNull(e1.isAllowed("/blah/"));
-    Assert.assertNull(e1.isAllowed("/yada/"));
-    Assert.assertNull(e1.isAllowed("/haha/"));
-
-    RulesEngine e2 = map.get("badrobot1");
-    Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/cgi-bin/"));
-    Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/blah/"));
-    Assert.assertEquals(Boolean.FALSE, e2.isAllowed("/yada/"));
-    Assert.assertNull(e2.isAllowed("/haha/"));
-
-    RulesEngine e3 = map.get("badrobot2");
-    Assert.assertEquals(Boolean.FALSE, e3.isAllowed("/cgi-bin/"));
-    Assert.assertEquals(Boolean.FALSE, e3.isAllowed("/blah/"));
-    Assert.assertNull(e3.isAllowed("/yada/"));
-    Assert.assertNull(e3.isAllowed("/haha/"));
-
-    RulesEngine e4 = map.get("badrobot3");
-    Assert.assertEquals(Boolean.FALSE, e4.isAllowed("/cgi-bin/"));
-    Assert.assertEquals(Boolean.FALSE, e4.isAllowed("/blah/"));
-    Assert.assertNull(e4.isAllowed("/yada/"));
-    Assert.assertEquals(Boolean.TRUE, e4.isAllowed("/haha/"));
-  }
-  
-  @Test
-  public void testSimpleRobotsCheck() throws Exception {
-    String s = 
-      "User-agent: *\r\n" +
-      "Disallow: /cgi-bin/\r\n" +
-      "Disallow: /tmp/\r\n" +
-      "Disallow: /~mine/";
-    NoRobotClient nrc = new NoRobotClient(new SimpleContentLoader(), "whatever");
-    nrc.parseText(new ByteArrayInputStream(s.getBytes("US-ASCII")));
-    Assert.assertTrue(nrc.isUrlAllowed(new URI("/whatever/")));
-    Assert.assertFalse(nrc.isUrlAllowed(new URI("/~mine/")));
-    Assert.assertFalse(nrc.isUrlAllowed(new URI("/tmp/")));
-  }
-  
 }

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/schema.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/schema.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/schema.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/schema.xml Tue Dec 18 08:47:39 2012
@@ -17,66 +17,68 @@
 -->
 
 <schema name="example" version="1.1">
-  <types>
-  
-    <fieldType name="string" class="solr.StrField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="boolean" class="solr.BoolField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="integer" class="solr.IntField" omitNorms="true"/>
-    <fieldType name="long" class="solr.LongField" omitNorms="true"/>
-    <fieldType name="float" class="solr.FloatField" omitNorms="true"/>
-    <fieldType name="double" class="solr.DoubleField" omitNorms="true"/>
-    <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="date" class="solr.DateField" sortMissingLast="true" omitNorms="true"/>
-    <fieldType name="random" class="solr.RandomSortField" indexed="true" />
-
-    <fieldType name="text" class="solr.TextField" positionIncrementGap="100">
-      <analyzer type="index">
-        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
-        <filter class="solr.StopFilterFactory"
-                ignoreCase="true"
-                words="stopwords.txt"
-                enablePositionIncrements="true"
-                />
-        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"/>
-        <filter class="solr.LowerCaseFilterFactory"/>
-        <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
-        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
-      </analyzer>
-      <analyzer type="query">
-        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
-        <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
-        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
-        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>
-        <filter class="solr.LowerCaseFilterFactory"/>
-        <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
-        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
-      </analyzer>
-    </fieldType>
-
- </types>
-
- <fields>
-   <field name="id"      type="string" indexed="true" stored="true" required="true" /> 
-   <field name="name"    type="string" indexed="true" stored="true" />
-   <field name="host"    type="string" indexed="true" stored="true" />
-   <field name="mime"    type="string" indexed="true" stored="true" />
-   <field name="content" type="text"   indexed="true" stored="true" />
-   <field name="selector" type="text"   indexed="true" stored="true" />
-
- </fields>
-
- <!-- Field to use to determine and enforce document uniqueness. 
-      Unless this field is marked with required="false", it will be a required field
-   -->
- <uniqueKey>id</uniqueKey>
+    <types>
 
- <!-- field for the QueryParser to use when an explicit fieldname is absent -->
- <defaultSearchField>content</defaultSearchField>
+        <fieldType name="string" class="solr.StrField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="boolean" class="solr.BoolField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="integer" class="solr.IntField" omitNorms="true"/>
+        <fieldType name="long" class="solr.LongField" omitNorms="true"/>
+        <fieldType name="float" class="solr.FloatField" omitNorms="true"/>
+        <fieldType name="double" class="solr.DoubleField" omitNorms="true"/>
+        <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="date" class="solr.DateField" sortMissingLast="true" omitNorms="true"/>
+        <fieldType name="random" class="solr.RandomSortField" indexed="true"/>
+
+        <fieldType name="text" class="solr.TextField" positionIncrementGap="100">
+            <analyzer type="index">
+                <tokenizer class="solr.WhitespaceTokenizerFactory"/>
+                <filter class="solr.StopFilterFactory"
+                        ignoreCase="true"
+                        words="stopwords.txt"
+                        enablePositionIncrements="true"
+                        />
+                <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1"
+                        catenateWords="1" catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"/>
+                <filter class="solr.LowerCaseFilterFactory"/>
+                <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
+                <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
+            </analyzer>
+            <analyzer type="query">
+                <tokenizer class="solr.WhitespaceTokenizerFactory"/>
+                <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
+                <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
+                <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1"
+                        catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>
+                <filter class="solr.LowerCaseFilterFactory"/>
+                <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
+                <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
+            </analyzer>
+        </fieldType>
+
+    </types>
+
+    <fields>
+        <field name="id" type="string" indexed="true" stored="true" required="true"/>
+        <field name="name" type="string" indexed="true" stored="true"/>
+        <field name="host" type="string" indexed="true" stored="true"/>
+        <field name="mime" type="string" indexed="true" stored="true"/>
+        <field name="content" type="text" indexed="true" stored="true"/>
+        <field name="selector" type="text" indexed="true" stored="true"/>
+
+    </fields>
+
+    <!-- Field to use to determine and enforce document uniqueness.
+         Unless this field is marked with required="false", it will be a required field
+      -->
+    <uniqueKey>id</uniqueKey>
 
- <!-- SolrQueryParser configuration: defaultOperator="AND|OR" -->
- <solrQueryParser defaultOperator="OR"/>
+    <!-- field for the QueryParser to use when an explicit fieldname is absent -->
+    <defaultSearchField>content</defaultSearchField>
+
+    <!-- SolrQueryParser configuration: defaultOperator="AND|OR" -->
+    <solrQueryParser defaultOperator="OR"/>
 
 </schema>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/solrconfig.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/solrconfig.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/solrconfig.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/example/conf/solrconfig.xml Tue Dec 18 08:47:39 2012
@@ -17,174 +17,174 @@
 -->
 
 <config>
-  <abortOnConfigurationError>true</abortOnConfigurationError>
+    <abortOnConfigurationError>true</abortOnConfigurationError>
 
-  <!-- must specify a data directory -->
-  <dataDir>${solr.data.dir:target/data}</dataDir>
+    <!-- must specify a data directory -->
+    <dataDir>${solr.data.dir:target/data}</dataDir>
 
 
-  <indexDefaults>
-   <!-- Values here affect all index writers and act as a default unless overridden. -->
-    <useCompoundFile>false</useCompoundFile>
+    <indexDefaults>
+        <!-- Values here affect all index writers and act as a default unless overridden. -->
+        <useCompoundFile>false</useCompoundFile>
 
-    <mergeFactor>10</mergeFactor>
-    <!--
-     If both ramBufferSizeMB and maxBufferedDocs is set, then Lucene will flush based on whichever limit is hit first.
+        <mergeFactor>10</mergeFactor>
+        <!--
+         If both ramBufferSizeMB and maxBufferedDocs is set, then Lucene will flush based on whichever limit is hit first.
 
-     -->
-    <!--<maxBufferedDocs>1000</maxBufferedDocs>-->
-    <!-- Tell Lucene when to flush documents to disk.
-    Giving Lucene more memory for indexing means faster indexing at the cost of more RAM
-
-    If both ramBufferSizeMB and maxBufferedDocs is set, then Lucene will flush based on whichever limit is hit first.
-
-    -->
-    <ramBufferSizeMB>32</ramBufferSizeMB>
-    <maxMergeDocs>2147483647</maxMergeDocs>
-    <maxFieldLength>10000</maxFieldLength>
-    <writeLockTimeout>1000</writeLockTimeout>
-    <commitLockTimeout>10000</commitLockTimeout>
-    <lockType>single</lockType>
-  </indexDefaults>
-
-  <mainIndex>
-    <!-- options specific to the main on-disk lucene index -->
-    <useCompoundFile>false</useCompoundFile>
-    <ramBufferSizeMB>32</ramBufferSizeMB>
-    <mergeFactor>10</mergeFactor>
-    <!-- Deprecated -->
-    <!--<maxBufferedDocs>1000</maxBufferedDocs>-->
-    <maxMergeDocs>2147483647</maxMergeDocs>
-    <maxFieldLength>10000</maxFieldLength>
-
-    <!-- If true, unlock any held write or commit locks on startup. 
-         This defeats the locking mechanism that allows multiple
-         processes to safely access a lucene index, and should be
-         used with care.
-         This is not needed if lock type is 'none' or 'single'
-     -->
-    <unlockOnStartup>true</unlockOnStartup>
+         -->
+        <!--<maxBufferedDocs>1000</maxBufferedDocs>-->
+        <!-- Tell Lucene when to flush documents to disk.
+        Giving Lucene more memory for indexing means faster indexing at the cost of more RAM
 
-    <!--
-        Custom deletion policies can specified here. The class must
-        implement org.apache.lucene.index.IndexDeletionPolicy.
+        If both ramBufferSizeMB and maxBufferedDocs is set, then Lucene will flush based on whichever limit is hit first.
 
-        http://lucene.apache.org/java/2_3_2/api/org/apache/lucene/index/IndexDeletionPolicy.html
+        -->
+        <ramBufferSizeMB>32</ramBufferSizeMB>
+        <maxMergeDocs>2147483647</maxMergeDocs>
+        <maxFieldLength>10000</maxFieldLength>
+        <writeLockTimeout>1000</writeLockTimeout>
+        <commitLockTimeout>10000</commitLockTimeout>
+        <lockType>single</lockType>
+    </indexDefaults>
+
+    <mainIndex>
+        <!-- options specific to the main on-disk lucene index -->
+        <useCompoundFile>false</useCompoundFile>
+        <ramBufferSizeMB>32</ramBufferSizeMB>
+        <mergeFactor>10</mergeFactor>
+        <!-- Deprecated -->
+        <!--<maxBufferedDocs>1000</maxBufferedDocs>-->
+        <maxMergeDocs>2147483647</maxMergeDocs>
+        <maxFieldLength>10000</maxFieldLength>
+
+        <!-- If true, unlock any held write or commit locks on startup.
+             This defeats the locking mechanism that allows multiple
+             processes to safely access a lucene index, and should be
+             used with care.
+             This is not needed if lock type is 'none' or 'single'
+         -->
+        <unlockOnStartup>true</unlockOnStartup>
+
+        <!--
+            Custom deletion policies can specified here. The class must
+            implement org.apache.lucene.index.IndexDeletionPolicy.
+
+            http://lucene.apache.org/java/2_3_2/api/org/apache/lucene/index/IndexDeletionPolicy.html
+
+            The standard Solr IndexDeletionPolicy implementation supports deleting
+            index commit points on number of commits, age of commit point and
+            optimized status.
 
-        The standard Solr IndexDeletionPolicy implementation supports deleting
-        index commit points on number of commits, age of commit point and
-        optimized status.
-
-        The latest commit point should always be preserved regardless
-        of the criteria.
-    -->
-    <deletionPolicy class="solr.SolrDeletionPolicy">
-      <!-- Keep only optimized commit points -->
-      <str name="keepOptimizedOnly">false</str>
-      <!-- The maximum number of commit points to be kept -->
-      <str name="maxCommitsToKeep">1</str>
-      <!--
-          Delete all commit points once they have reached the given age.
-          Supports DateMathParser syntax e.g.
-          
-          <str name="maxCommitAge">30MINUTES</str>
-          <str name="maxCommitAge">1DAY</str>
-      -->
-    </deletionPolicy>
+            The latest commit point should always be preserved regardless
+            of the criteria.
+        -->
+        <deletionPolicy class="solr.SolrDeletionPolicy">
+            <!-- Keep only optimized commit points -->
+            <str name="keepOptimizedOnly">false</str>
+            <!-- The maximum number of commit points to be kept -->
+            <str name="maxCommitsToKeep">1</str>
+            <!--
+                Delete all commit points once they have reached the given age.
+                Supports DateMathParser syntax e.g.
+
+                <str name="maxCommitAge">30MINUTES</str>
+                <str name="maxCommitAge">1DAY</str>
+            -->
+        </deletionPolicy>
+
+    </mainIndex>
+
+    <jmx/>
+
+    <!-- the default high-performance update handler -->
+    <updateHandler class="solr.DirectUpdateHandler2">
+        <!-- Perform a <commit/> automatically under certain conditions:
+        <autoCommit>
+          <maxDocs>10000</maxDocs>
+          <maxTime>1000</maxTime>
+        </autoCommit>
+        -->
+    </updateHandler>
 
-  </mainIndex>
 
-  <jmx />
+    <query>
+        <!-- Maximum number of clauses in a boolean query... can affect
+            range or prefix queries that expand to big boolean
+            queries.  An exception is thrown if exceeded.  -->
+        <maxBooleanClauses>1024</maxBooleanClauses>
+
+        <filterCache
+                class="solr.LRUCache"
+                size="512"
+                initialSize="512"
+                autowarmCount="128"/>
+
+        <queryResultCache
+                class="solr.LRUCache"
+                size="512"
+                initialSize="512"
+                autowarmCount="32"/>
+
+        <documentCache
+                class="solr.LRUCache"
+                size="512"
+                initialSize="512"
+                autowarmCount="0"/>
+
+        <enableLazyFieldLoading>true</enableLazyFieldLoading>
+
+        <!-- An optimization for use with the queryResultCache.  When a search
+              is requested, a superset of the requested number of document ids
+              are collected.  For example, if a search for a particular query
+              requests matching documents 10 through 19, and queryWindowSize is 50,
+              then documents 0 through 49 will be collected and cached.  Any further
+              requests in that range can be satisfied via the cache.  -->
+        <queryResultWindowSize>50</queryResultWindowSize>
+
+        <!-- Maximum number of documents to cache for any entry in the
+             queryResultCache. -->
+        <queryResultMaxDocsCached>200</queryResultMaxDocsCached>
+
+        <!-- This entry enables an int hash representation for filters (DocSets)
+             when the number of items in the set is less than maxSize.  For smaller
+             sets, this representation is more memory efficient, more efficient to
+             iterate over, and faster to take intersections.  -->
+        <HashDocSet maxSize="3000" loadFactor="0.75"/>
+
+        <!-- If a search request comes in and there is no current registered searcher,
+             then immediately register the still warming searcher and use it.  If
+             "false" then all requests will block until the first searcher is done
+             warming. -->
+        <useColdSearcher>false</useColdSearcher>
+
+        <!-- Maximum number of searchers that may be warming in the background
+          concurrently.  An error is returned if this limit is exceeded. Recommend
+          1-2 for read-only slaves, higher for masters w/o cache warming. -->
+        <maxWarmingSearchers>2</maxWarmingSearchers>
 
-  <!-- the default high-performance update handler -->
-  <updateHandler class="solr.DirectUpdateHandler2">
-    <!-- Perform a <commit/> automatically under certain conditions:
-    <autoCommit> 
-      <maxDocs>10000</maxDocs>
-      <maxTime>1000</maxTime> 
-    </autoCommit>
-    -->
-  </updateHandler>
-
-
-  <query>
-    <!-- Maximum number of clauses in a boolean query... can affect
-        range or prefix queries that expand to big boolean
-        queries.  An exception is thrown if exceeded.  -->
-    <maxBooleanClauses>1024</maxBooleanClauses>
-
-    <filterCache
-      class="solr.LRUCache"
-      size="512"
-      initialSize="512"
-      autowarmCount="128"/>
-
-    <queryResultCache
-      class="solr.LRUCache"
-      size="512"
-      initialSize="512"
-      autowarmCount="32"/>
-
-    <documentCache
-      class="solr.LRUCache"
-      size="512"
-      initialSize="512"
-      autowarmCount="0"/>
-
-    <enableLazyFieldLoading>true</enableLazyFieldLoading>
-
-   <!-- An optimization for use with the queryResultCache.  When a search
-         is requested, a superset of the requested number of document ids
-         are collected.  For example, if a search for a particular query
-         requests matching documents 10 through 19, and queryWindowSize is 50,
-         then documents 0 through 49 will be collected and cached.  Any further
-         requests in that range can be satisfied via the cache.  -->
-    <queryResultWindowSize>50</queryResultWindowSize>
-
-    <!-- Maximum number of documents to cache for any entry in the
-         queryResultCache. -->
-    <queryResultMaxDocsCached>200</queryResultMaxDocsCached>
-
-    <!-- This entry enables an int hash representation for filters (DocSets)
-         when the number of items in the set is less than maxSize.  For smaller
-         sets, this representation is more memory efficient, more efficient to
-         iterate over, and faster to take intersections.  -->
-    <HashDocSet maxSize="3000" loadFactor="0.75"/>
-
-    <!-- If a search request comes in and there is no current registered searcher,
-         then immediately register the still warming searcher and use it.  If
-         "false" then all requests will block until the first searcher is done
-         warming. -->
-    <useColdSearcher>false</useColdSearcher>
-
-    <!-- Maximum number of searchers that may be warming in the background
-      concurrently.  An error is returned if this limit is exceeded. Recommend
-      1-2 for read-only slaves, higher for masters w/o cache warming. -->
-    <maxWarmingSearchers>2</maxWarmingSearchers>
-
-  </query>
-
-  <!-- 
-    Let the dispatch filter handler /select?qt=XXX
-    handleSelect=true will use consistent error handling for /select and /update
-    handleSelect=false will use solr1.1 style error formatting
-    -->
-  <requestDispatcher handleSelect="true" />
-  
-  <requestHandler name="standard" class="solr.SearchHandler" default="true">
-    <!-- default values for query parameters -->
-     <lst name="defaults">
-       <str name="echoParams">explicit</str>
-       <!--
-       <int name="rows">10</int>
-       <str name="fl">*</str>
-       <str name="version">2.1</str>
-        -->
-     </lst>
-  </requestHandler>
+    </query>
+
+    <!--
+      Let the dispatch filter handler /select?qt=XXX
+      handleSelect=true will use consistent error handling for /select and /update
+      handleSelect=false will use solr1.1 style error formatting
+      -->
+    <requestDispatcher handleSelect="true"/>
+
+    <requestHandler name="standard" class="solr.SearchHandler" default="true">
+        <!-- default values for query parameters -->
+        <lst name="defaults">
+            <str name="echoParams">explicit</str>
+            <!--
+            <int name="rows">10</int>
+            <str name="fl">*</str>
+            <str name="version">2.1</str>
+             -->
+        </lst>
+    </requestHandler>
 
 
-  <requestHandler name="/update" class="solr.XmlUpdateRequestHandler" />
-  <requestHandler name="/admin/" class="org.apache.solr.handler.admin.AdminHandlers" />
+    <requestHandler name="/update" class="solr.XmlUpdateRequestHandler"/>
+    <requestHandler name="/admin/" class="org.apache.solr.handler.admin.AdminHandlers"/>
 
 </config>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/pom.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/pom.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/pom.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/pom.xml Tue Dec 18 08:47:39 2012
@@ -15,66 +15,67 @@
    See the License for the specific language governing permissions and
    limitations under the License.
 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
-  <modelVersion>4.0.0</modelVersion>
-  <parent>
-    <artifactId>droids</artifactId>
-    <groupId>org.apache.droids</groupId>
-    <version>0.3.0-incubating-SNAPSHOT</version>
-    <relativePath>../pom.xml</relativePath>
-  </parent>
-  <artifactId>droids-solr</artifactId>
-  <name>Apache Droids Solr</name>
-  <inceptionYear>2007</inceptionYear>
-  <description>Apache Droids Solr Integration</description>
-  <packaging>jar</packaging>  
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <artifactId>droids</artifactId>
+        <groupId>org.apache.droids</groupId>
+        <version>0.3.0-incubating-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    <artifactId>droids-solr</artifactId>
+    <name>Apache Droids Solr</name>
+    <inceptionYear>2007</inceptionYear>
+    <description>Apache Droids Solr Integration</description>
+    <packaging>jar</packaging>
 
-  <properties>
-    <solr-release-version>3.6.0</solr-release-version>
-  </properties>
+    <properties>
+        <solr-release-version>3.6.0</solr-release-version>
+    </properties>
 
-  <dependencies>
-    <dependency>
-      <groupId>org.apache.droids</groupId>
-      <artifactId>droids-core</artifactId>
-      <version>${project.version}</version>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.solr</groupId>
-      <artifactId>solr-solrj</artifactId>
-      <version>${solr-release-version}</version>
-      <exclusions>
-      	<exclusion>
-      		<artifactId>commons-logging</artifactId>
-      		<groupId>commons-logging</groupId>
-      	</exclusion>
-      </exclusions>
-    </dependency>
-    <!-- FOR TESTING -->
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <version>${junit.version}</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.solr</groupId>
-      <artifactId>solr-core</artifactId>
-      <version>${solr-release-version}</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>javax.servlet</groupId>
-      <artifactId>servlet-api</artifactId>
-      <version>2.3</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.slf4j</groupId>
-      <artifactId>slf4j-simple</artifactId>
-      <version>1.6.4</version>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.droids</groupId>
+            <artifactId>droids-core</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.solr</groupId>
+            <artifactId>solr-solrj</artifactId>
+            <version>${solr-release-version}</version>
+            <exclusions>
+                <exclusion>
+                    <artifactId>commons-logging</artifactId>
+                    <groupId>commons-logging</groupId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <!-- FOR TESTING -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>${junit.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.solr</groupId>
+            <artifactId>solr-core</artifactId>
+            <version>${solr-release-version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <version>2.3</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-simple</artifactId>
+            <version>1.6.4</version>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
 </project>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/locationmap.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/locationmap.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/locationmap.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/locationmap.xml Tue Dec 18 08:47:39 2012
@@ -16,16 +16,16 @@
   limitations under the License.
 -->
 <locationmap xmlns="http://apache.org/forrest/locationmap/1.0">
-  <components>
-    <matchers default="lm">
-      <matcher 
-        name="lm" 
-        src="org.apache.forrest.locationmap.WildcardLocationMapHintMatcher"/>
-    </matchers>
-    <selectors default="exists">
-      <selector name="exists" logger="sitemap.selector.exists"  
-                    src="org.apache.forrest.sourceexists.SourceExistsSelector" />
-    </selectors>
-  </components>
-  <locator></locator>
+    <components>
+        <matchers default="lm">
+            <matcher
+                    name="lm"
+                    src="org.apache.forrest.locationmap.WildcardLocationMapHintMatcher"/>
+        </matchers>
+        <selectors default="exists">
+            <selector name="exists" logger="sitemap.selector.exists"
+                      src="org.apache.forrest.sourceexists.SourceExistsSelector"/>
+        </selectors>
+    </components>
+    <locator></locator>
 </locationmap>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/index.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/index.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/index.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/index.xml Tue Dec 18 08:47:39 2012
@@ -17,35 +17,39 @@
 -->
 <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
 <document>
-  <header>
-    <title>Welcome to the @plugin-name@ Plugin</title>
-  </header>
-  <body>
-    <section id="overview">
-      <title>Apache Droids - @plugin-name@ Plugin</title>
-      <p>
-        @plugin-desc@
-      </p>
-    </section>
-    <section id="samples">
-      <title>Samples</title>
-      <p>
-        This section includes links to a number of samples using this plugin.
-        The plugin is intended to be self documenting through these samples. If
-        you require further help please ask on the user mailing list.
-      </p>
-      <ul>
-        <li><fixme author="droids-dev">
-            Add a link to a sample here...
-          </fixme></li>
-        <li><fixme author="droids-dev">
-            Add another sample link here...
-          </fixme></li>
-      </ul>
-      <note>
-        The more samples included here the easier it is for users to understand
-        this plugin. If you can provide additional samples please do so.
-      </note>
-    </section>
-  </body>
+    <header>
+        <title>Welcome to the @plugin-name@ Plugin</title>
+    </header>
+    <body>
+        <section id="overview">
+            <title>Apache Droids - @plugin-name@ Plugin</title>
+            <p>
+                @plugin-desc@
+            </p>
+        </section>
+        <section id="samples">
+            <title>Samples</title>
+            <p>
+                This section includes links to a number of samples using this plugin.
+                The plugin is intended to be self documenting through these samples. If
+                you require further help please ask on the user mailing list.
+            </p>
+            <ul>
+                <li>
+                    <fixme author="droids-dev">
+                        Add a link to a sample here...
+                    </fixme>
+                </li>
+                <li>
+                    <fixme author="droids-dev">
+                        Add another sample link here...
+                    </fixme>
+                </li>
+            </ul>
+            <note>
+                The more samples included here the easier it is for users to understand
+                this plugin. If you can provide additional samples please do so.
+            </note>
+        </section>
+    </body>
 </document>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/site.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/site.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/site.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/site.xml Tue Dec 18 08:47:39 2012
@@ -29,20 +29,20 @@ This file contains an outline of the sit
 See http://forrest.apache.org/docs/linking.html for more info
 -->
 <site label="@plugin-name@" href="" xmlns="http://apache.org/forrest/linkmap/1.0" tab="">
-  <about label="About">
-    <index label="Index" href="index.html" description="Welcome to @plugin-name@"/>
-    <changes label="Changes" href="changes.html" description="History of Changes" />
-    <todo label="Todo" href="todo.html" description="Todo List" />
-  </about>
-  
-<!--
-  The href must be wholesite.html/pdf  You can change the labels and node names
-  <all label="All">
-    <whole_site_html label="Whole Site HTML" href="wholesite.html"/>
-    <whole_site_pdf label="Whole Site PDF" href="wholesite.pdf"/>
-  </all>
-  -->
-  <external-refs>
-    <forrest href="http://forrest.apache.org/"/>
-  </external-refs>
+    <about label="About">
+        <index label="Index" href="index.html" description="Welcome to @plugin-name@"/>
+        <changes label="Changes" href="changes.html" description="History of Changes"/>
+        <todo label="Todo" href="todo.html" description="Todo List"/>
+    </about>
+
+    <!--
+      The href must be wholesite.html/pdf  You can change the labels and node names
+      <all label="All">
+        <whole_site_html label="Whole Site HTML" href="wholesite.html"/>
+        <whole_site_pdf label="Whole Site PDF" href="wholesite.pdf"/>
+      </all>
+      -->
+    <external-refs>
+        <forrest href="http://forrest.apache.org/"/>
+    </external-refs>
 </site>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/tabs.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/tabs.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/tabs.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/content/xdocs/tabs.xml Tue Dec 18 08:47:39 2012
@@ -15,24 +15,25 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 -->
-<!DOCTYPE tabs PUBLIC "-//APACHE//DTD Cocoon Documentation Tab V1.1//EN" "http://forrest.apache.org/dtd/tab-cocoon-v11.dtd">
+<!DOCTYPE tabs PUBLIC "-//APACHE//DTD Cocoon Documentation Tab V1.1//EN"
+        "http://forrest.apache.org/dtd/tab-cocoon-v11.dtd">
 <tabs software="MyProj"
-  title="MyProj"
-  copyright="Foo"
-  xmlns:xlink="http://www.w3.org/1999/xlink">
-<!-- The rules for tabs are:
-    @dir will always have '/@indexfile' added.
-    @indexfile gets appended to @dir if the tab is selected. Defaults to 'index.html'
-    @href is not modified unless it is root-relative and obviously specifies a
-    directory (ends in '/'), in which case /index.html will be added
-    If @id's are present, site.xml entries with a matching @tab will be in that tab.
+      title="MyProj"
+      copyright="Foo"
+      xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- The rules for tabs are:
+        @dir will always have '/@indexfile' added.
+        @indexfile gets appended to @dir if the tab is selected. Defaults to 'index.html'
+        @href is not modified unless it is root-relative and obviously specifies a
+        directory (ends in '/'), in which case /index.html will be added
+        If @id's are present, site.xml entries with a matching @tab will be in that tab.
 
-   Tabs can be embedded to a depth of two. The second level of tabs will only 
-    be displayed when their parent tab is selected.    
-  -->
-  <tab id="" label="Plugin Home" dir="" indexfile="index.html"/>
-<!-- Add new tabs here, eg:
-  <tab label="How-Tos" dir="community/howto/"/>
-  <tab label="XML Site" dir="xml-site/"/>
-  -->
+       Tabs can be embedded to a depth of two. The second level of tabs will only
+        be displayed when their parent tab is selected.
+      -->
+    <tab id="" label="Plugin Home" dir="" indexfile="index.html"/>
+    <!-- Add new tabs here, eg:
+      <tab label="How-Tos" dir="community/howto/"/>
+      <tab label="XML Site" dir="xml-site/"/>
+      -->
 </tabs>

Modified: incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/skinconf.xml
URL: http://svn.apache.org/viewvc/incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/skinconf.xml?rev=1423339&r1=1423338&r2=1423339&view=diff
==============================================================================
--- incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/skinconf.xml (original)
+++ incubator/droids/branches/0.2.x-cleanup/droids-solr/src/documentation/skinconf.xml Tue Dec 18 08:47:39 2012
@@ -15,13 +15,14 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 -->
-<!DOCTYPE skinconfig PUBLIC "-//APACHE//DTD Skin Configuration V0.7-1//EN" "http://forrest.apache.org/dtd/skinconfig-v07-1.dtd"
-[
-  <!ENTITY skinconf-common PUBLIC "-//Apache Forrest//ENTITIES Skin Configuration common plugins V0.7-1//EN" "">
-]>
+<!DOCTYPE skinconfig PUBLIC "-//APACHE//DTD Skin Configuration V0.7-1//EN"
+        "http://forrest.apache.org/dtd/skinconfig-v07-1.dtd"
+        [
+                <!ENTITY skinconf-common PUBLIC "-//Apache Forrest//ENTITIES Skin Configuration common plugins V0.7-1//EN" "">
+                ]>
 <skinconfig>
-  &skinconf-common;
+    &skinconf-common;
 
-  <project-name>Plugin: @plugin-name@</project-name>
-  <project-description>@plugin-name@ plugin for Apache Droids</project-description>
+    <project-name>Plugin: @plugin-name@</project-name>
+    <project-description>@plugin-name@ plugin for Apache Droids</project-description>
 </skinconfig>



Mime
View raw message