manifoldcf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwri...@apache.org
Subject svn commit: r1220632 [4/9] - in /incubator/lcf/branches/CONNECTORS-314: ./ connectors/activedirectory/connector/src/main/java/org/apache/manifoldcf/authorities/authorities/activedirectory/ connectors/cmis/connector/src/main/java/org/apache/manifoldcf/c...
Date Mon, 19 Dec 2011 07:35:00 GMT
Modified: incubator/lcf/branches/CONNECTORS-314/connectors/webcrawler/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/webcrawler/WebcrawlerConnector.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/connectors/webcrawler/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/webcrawler/WebcrawlerConnector.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/connectors/webcrawler/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/webcrawler/WebcrawlerConnector.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/connectors/webcrawler/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/webcrawler/WebcrawlerConnector.java Mon Dec 19 07:34:58 2011
@@ -18,6 +18,7 @@
 */
 package org.apache.manifoldcf.crawler.connectors.webcrawler;
 
+import org.apache.manifoldcf.core.i18n.*;
 import org.apache.manifoldcf.core.interfaces.*;
 import org.apache.manifoldcf.agents.interfaces.*;
 import org.apache.manifoldcf.crawler.interfaces.*;
@@ -1372,11 +1373,11 @@ public class WebcrawlerConnector extends
   public void outputConfigurationHeader(IThreadContext threadContext, IHTTPOutput out, ConfigParams parameters, List<String> tabsArray)
     throws ManifoldCFException, IOException
   {
-    tabsArray.add("Email");
-    tabsArray.add("Robots");
-    tabsArray.add("Bandwidth");
-    tabsArray.add("Access Credentials");
-    tabsArray.add("Certificates");
+    tabsArray.add(Messages.getString("WebcrawlerConnector.Email"));
+    tabsArray.add(Messages.getString("WebcrawlerConnector.Robots"));
+    tabsArray.add(Messages.getString("WebcrawlerConnector.Bandwidth"));
+    tabsArray.add(Messages.getString("WebcrawlerConnector.AccessCredentials"));
+    tabsArray.add(Messages.getString("WebcrawlerConnector.Certificates"));
     out.print(
 "<script type=\"text/javascript\">\n"+
 "<!--\n"+
@@ -1485,8 +1486,8 @@ public class WebcrawlerConnector extends
 "{\n"+
 "  if (editconnection.email.value == \"\")\n"+
 "  {\n"+
-"    alert(\"Email address required, to be included in all request headers\");\n"+
-"    SelectTab(\"Email\");\n"+
+"    alert(\"" + Messages.getString("WebcrawlerConnector.EmailAaddressRequired") + "\");\n"+
+"    SelectTab(\"" + Messages.getString("WebcrawlerConnector.Email") + "\");\n"+
 "    editconnection.email.focus();\n"+
 "    return false;\n"+
 "  }\n"+
@@ -1510,7 +1511,7 @@ public class WebcrawlerConnector extends
 "{\n"+
 "  if (editconnection.connections_bandwidth.value != \"\" && !isInteger(editconnection.connections_bandwidth.value))\n"+
 "  {\n"+
-"    alert(\"Maximum connections must be an integer\");\n"+
+"    alert(\"" + Messages.getString("WebcrawlerConnector.MaximumConnectionsMustBeAnInteger") + "\");\n"+
 "    editconnection.connections_bandwidth.focus();\n"+
 "    return;\n"+
 "  }\n"+
@@ -1713,13 +1714,13 @@ public class WebcrawlerConnector extends
       robotsUsage = "all";
 
     // Email tab
-    if (tabName.equals("Email"))
+    if (tabName.equals(Messages.getString("WebcrawlerConnector.Email")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Email address to contact:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.EmailAddressToContact") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <input type=\"text\" size=\"32\" name=\"email\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(email)+"\"/>\n"+
 "    </td>\n"+
@@ -1735,18 +1736,18 @@ public class WebcrawlerConnector extends
     }
 
     // Robots tab
-    if (tabName.equals("Robots"))
+    if (tabName.equals(Messages.getString("WebcrawlerConnector.Robots")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Robots.txt usage:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.RobotsTxtUsage") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <select name=\"robotsusage\" size=\"3\">\n"+
-"        <option value=\"none\" "+(robotsUsage.equals("none")?"selected=\"selected\"":"")+">Don't look at robots.txt</option>\n"+
-"        <option value=\"data\" "+(robotsUsage.equals("data")?"selected=\"selected\"":"")+">Obey robots.txt for data fetches only</option>\n"+
-"        <option value=\"all\" "+(robotsUsage.equals("all")?"selected=\"selected\"":"")+">Obey robots.txt for all fetches</option>\n"+
+"        <option value=\"none\" "+(robotsUsage.equals("none")?"selected=\"selected\"":"")+">" + Messages.getString("WebcrawlerConnector.DontLookAtRobotsTxt") + "</option>\n"+
+"        <option value=\"data\" "+(robotsUsage.equals("data")?"selected=\"selected\"":"")+">" + Messages.getString("WebcrawlerConnector.ObeyRobotsTxtForDataFetchesOnly") + "</option>\n"+
+"        <option value=\"all\" "+(robotsUsage.equals("all")?"selected=\"selected\"":"")+">" + Messages.getString("WebcrawlerConnector.ObeyRobotsTxtForAllFetches") + "</option>\n"+
 "      </select>\n"+
 "    </td>\n"+
 "  </tr>\n"+
@@ -1761,22 +1762,22 @@ public class WebcrawlerConnector extends
     }
 
     // Bandwidth tab
-    if (tabName.equals("Bandwidth"))
+    if (tabName.equals(Messages.getString("WebcrawlerConnector.Bandwidth")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Throttles:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.Throttles") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Bin regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Case insensitive?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Max connections</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Max Kbytes/sec</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Max fetches/min</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.BinRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.CaseInsensitive") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.MaxConnections") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.MaxKbytesSec") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.MaxFetchesMin") + "</nobr></td>\n"+
 "        </tr>\n"
       );
       int i = 0;
@@ -1819,7 +1820,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\""+(((binCounter % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+prefix+"\">\n"+
-"              <input type=\"button\" value=\"Delete\" alt=\""+"Delete bin regular expression #"+Integer.toString(binCounter+1)+"\" onclick='javascript:deleteRegexp("+Integer.toString(binCounter)+");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" alt=\""+Messages.getString("WebcrawlerConnector.DeleteBinRegularExpression")+Integer.toString(binCounter+1)+"\" onclick='javascript:deleteRegexp("+Integer.toString(binCounter)+");'/>\n"+
 "              <input type=\"hidden\" name=\""+"op_"+prefix+"\" value=\"Continue\"/>\n"+
 "              <input type=\"hidden\" name=\""+"regexp_"+prefix+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(regexp)+"\"/>\n"+
 "            </a>\n"+
@@ -1855,7 +1856,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\""+(((binCounter % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+prefix+"\">\n"+
-"              <input type=\"button\" value=\"Delete\" alt=\""+"Delete bin regular expression #"+Integer.toString(binCounter+1)+"\" onclick='javascript:deleteRegexp("+Integer.toString(binCounter)+");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" alt=\""+ Messages.getString("WebcrawlerConnector.DeleteBinRegularExpression") +Integer.toString(binCounter+1)+"\" onclick='javascript:deleteRegexp("+Integer.toString(binCounter)+");'/>\n"+
 "              <input type=\"hidden\" name=\""+"op_"+prefix+"\" value=\"Continue\"/>\n"+
 "              <input type=\"hidden\" name=\""+"regexp_"+prefix+"\" value=\"\"/>\n"+
 "            </a>\n"+
@@ -1891,7 +1892,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\"formrow\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\"bandwidth\">\n"+
-"              <input type=\"button\" value=\"Add\" alt=\"Add bin regular expression\" onclick=\"javascript:addRegexp();\"/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" alt=\"" + Messages.getString("WebcrawlerConnector.AddBinRegularExpression") + "\" onclick=\"javascript:addRegexp();\"/>\n"+
 "            </a>\n"+
 "            <input type=\"hidden\" name=\"bandwidth_count\" value=\""+binCounter+"\"/>\n"+
 "            <input type=\"hidden\" name=\"bandwidth_op\" value=\"Continue\"/>\n"+
@@ -1989,22 +1990,22 @@ public class WebcrawlerConnector extends
     }
 
     // Access Credentials tab
-    if (tabName.equals("Access Credentials"))
+    if (tabName.equals(Messages.getString("WebcrawlerConnector.AccessCredentials")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Page access credentials:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.PageAccessCredentials") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Authentication type</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Domain</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>User name</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Password</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.AuthenticationType") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Domain") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.UserName") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Password") + "</nobr></td>\n"+
 "        </tr>\n"
       );
       int i = 0;
@@ -2031,7 +2032,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\""+(((accessCounter % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+prefix+"\">\n"+
-"              <input type=\"button\" value=\"Delete\" alt=\""+"Delete page authentication url regular expression #"+Integer.toString(accessCounter+1)+"\" onclick='javascript:deleteARegexp("+Integer.toString(accessCounter)+");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" alt=\""+Messages.getString("WebcrawlerConnector.DeletePageAuthenticationUrlRegularExpression")+Integer.toString(accessCounter+1)+"\" onclick='javascript:deleteARegexp("+Integer.toString(accessCounter)+");'/>\n"+
 "              <input type=\"hidden\" name=\"op_"+prefix+"\" value=\"Continue\"/>\n"+
 "              <input type=\"hidden\" name=\"regexp_"+prefix+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(regexp)+"\"/>\n"+
 "            </a>\n"+
@@ -2040,8 +2041,8 @@ public class WebcrawlerConnector extends
 "            <nobr>"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(regexp)+"</nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
-"            <nobr><input type=\"radio\" name=\"type_"+prefix+"\" value=\"basic\" "+(type.equals("basic")?"checked=\"\"":"")+" />&nbsp;Basic authentication</nobr><br/>\n"+
-"            <nobr><input type=\"radio\" name=\"type_"+prefix+"\" value=\"ntlm\" "+(type.equals("ntlm")?"checked=\"\"":"")+" />&nbsp;NTLM authentication</nobr>\n"+
+"            <nobr><input type=\"radio\" name=\"type_"+prefix+"\" value=\"basic\" "+(type.equals("basic")?"checked=\"\"":"")+" />&nbsp;" + Messages.getString("WebcrawlerConnector.BasicAuthentication") + "</nobr><br/>\n"+
+"            <nobr><input type=\"radio\" name=\"type_"+prefix+"\" value=\"ntlm\" "+(type.equals("ntlm")?"checked=\"\"":"")+" />&nbsp;" + Messages.getString("WebcrawlerConnector.NTLMAuthentication") + "</nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <nobr><input type=\"text\" size=\"16\" name=\""+"domain_"+prefix+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(domain)+"\"/></nobr>\n"+
@@ -2062,7 +2063,7 @@ public class WebcrawlerConnector extends
       if (accessCounter == 0)
       {
         out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"6\">No page access credentials specified</td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"6\">" + Messages.getString("WebcrawlerConnector.NoPageAccessCredentialsSpecified") + "</td></tr>\n"
         );
       }
       out.print(
@@ -2070,7 +2071,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\"formrow\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\"acredential\">\n"+
-"              <input type=\"button\" value=\"Add\" alt=\"Add page authentication url regular expression\" onclick=\"javascript:addARegexp();\"/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" alt=\"" + Messages.getString("WebcrawlerConnector.AddPageAuthenticationUrlRegularExpression") + "\" onclick=\"javascript:addARegexp();\"/>\n"+
 "            </a>\n"+
 "            <input type=\"hidden\" name=\"acredential_count\" value=\""+accessCounter+"\"/>\n"+
 "            <input type=\"hidden\" name=\"acredential_op\" value=\"Continue\"/>\n"+
@@ -2079,8 +2080,8 @@ public class WebcrawlerConnector extends
 "            <nobr><input type=\"text\" size=\"30\" name=\"regexp_acredential\" value=\"\"/></nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
-"            <nobr><input type=\"radio\" name=\"type_acredential\" value=\"basic\" checked=\"\" />&nbsp;Basic authentication</nobr><br/>\n"+
-"            <nobr><input type=\"radio\" name=\"type_acredential\" value=\"ntlm\" />&nbsp;NTLM authentication</nobr>\n"+
+"            <nobr><input type=\"radio\" name=\"type_acredential\" value=\"basic\" checked=\"\" />&nbsp;" + Messages.getString("WebcrawlerConnector.BasicAuthentication") + "</nobr><br/>\n"+
+"            <nobr><input type=\"radio\" name=\"type_acredential\" value=\"ntlm\" />&nbsp;" + Messages.getString("WebcrawlerConnector.NTLMAuthentication") + "</nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <nobr><input type=\"text\" size=\"16\" name=\"domain_acredential\" value=\"\"/></nobr>\n"+
@@ -2099,13 +2100,13 @@ public class WebcrawlerConnector extends
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Session-based access credentials:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.SessionBasedAccessCredentials") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Login pages</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.LoginPages") + "</nobr></td>\n"+
 "        </tr>\n"
       );
       i = 0;
@@ -2127,7 +2128,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\""+(((accessCounter % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+prefix+"\">\n"+
-"              <input type=\"button\" value=\"Delete\" alt=\""+"Delete session authentication url regular expression #"+Integer.toString(accessCounter+1)+"\" onclick='javascript:deleteSRegexp("+Integer.toString(accessCounter)+");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" alt=\""+Messages.getString("WebcrawlerConnector.DeleteSessionAuthenticationUrlRegularExpression")+Integer.toString(accessCounter+1)+"\" onclick='javascript:deleteSRegexp("+Integer.toString(accessCounter)+");'/>\n"+
 "              <input type=\"hidden\" name=\""+prefix+"_op"+"\" value=\"Continue\"/>\n"+
 "              <input type=\"hidden\" name=\""+prefix+"_regexp"+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(regexp)+"\"/>\n"+
 "            </a>\n"+
@@ -2139,10 +2140,10 @@ public class WebcrawlerConnector extends
 "            <table class=\"formtable\">\n"+
 "              <tr class=\"formheaderrow\">\n"+
 "                <td class=\"formcolumnheader\"></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Login URL regular expression</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Page type</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Form name/link target regular expression</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Override form parameters</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.LoginURLRegularExpression") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.PageType") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.FormNamelinkTargetRegularExpression") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.OverrideFormParameters") + "</nobr></td>\n"+
 "              </tr>\n"
             );
             int q = 0;
@@ -2297,7 +2298,7 @@ public class WebcrawlerConnector extends
       if (accessCounter == 0)
       {
         out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"3\">No session-based access credentials specified</td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"3\">" + Messages.getString("WebcrawlerConnector.NoSessionBasedAccessCredentialsSpecified") + "</td></tr>\n"
         );
       }
       out.print(
@@ -2305,7 +2306,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\"formrow\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\"scredential\">\n"+
-"              <input type=\"button\" value=\"Add\" alt=\"Add session authentication url regular expression\" onclick=\"javascript:addSRegexp();\"/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" alt=\"Add session authentication url regular expression\" onclick=\"javascript:addSRegexp();\"/>\n"+
 "            </a>\n"+
 "            <input type=\"hidden\" name=\"scredential_count\" value=\""+accessCounter+"\"/>\n"+
 "            <input type=\"hidden\" name=\"scredential_op\" value=\"Continue\"/>\n"+
@@ -2447,19 +2448,19 @@ public class WebcrawlerConnector extends
     }
 
     // "Certificates" tab
-    if (tabName.equals("Certificates"))
+    if (tabName.equals(Messages.getString("WebcrawlerConnector.Certificates")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Trust certificates:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.TrustCertificates") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Certificate</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Certificate") + "</nobr></td>\n"+
 "        </tr>\n"
       );
       int i = 0;
@@ -2542,14 +2543,14 @@ public class WebcrawlerConnector extends
       if (trustsCounter == 0)
       {
         out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"3\">No trust certificates specified</td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"3\">" + Messages.getString("WebcrawlerConnector.NoTrustCertificatesSpecified") + "</td></tr>\n"
         );
       }
       out.print(
 "        <tr class=\"formrow\"><td class=\"formseparator\" colspan=\"3\"><hr/></td></tr>\n"+
 "        <tr class=\"formrow\">\n"+
 "          <td class=\"formcolumncell\">\n"+
-"            <a name=\"trust\"><input type=\"button\" value=\"Add\" alt=\"Add url regular expression for truststore\" onclick=\"javascript:addTRegexp();\"/></a>\n"+
+"            <a name=\"trust\"><input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" alt=\"" + Messages.getString("WebcrawlerConnector.AddUrlRegularExpressionForTruststore") + "\" onclick=\"javascript:addTRegexp();\"/></a>\n"+
 "            <input type=\"hidden\" name=\"trust_count\" value=\""+trustsCounter+"\"/>\n"+
 "            <input type=\"hidden\" name=\"trust_op\" value=\"Continue\"/>\n"+
 "          </td>\n"+
@@ -2557,7 +2558,7 @@ public class WebcrawlerConnector extends
 "            <nobr><input type=\"text\" size=\"30\" name=\"regexp_trust\" value=\"\"/></nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
-"            <nobr>Upload certificate: <input name=\"certificate_trust\" size=\"50\" type=\"file\"/>&nbsp;<input name=\"all_trust\" type=\"checkbox\" value=\"true\">Trust everything</input></nobr>\n"+
+"            <nobr>" + Messages.getString("WebcrawlerConnector.UploadCertificate") + " <input name=\"certificate_trust\" size=\"50\" type=\"file\"/>&nbsp;<input name=\"all_trust\" type=\"checkbox\" value=\"true\">" + Messages.getString("WebcrawlerConnector.TrustEverything") + "</input></nobr>\n"+
 "          </td>\n"+
 "        </tr>\n"+
 "      </table>\n"+
@@ -3084,14 +3085,14 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "  \n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Page access credentials:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.PageAccessCredentials") + "</nobr></td>\n"+
 "    <td class=\"boxcell\" colspan=\"3\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Credential type</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Credential domain</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>User name</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.CredentialType") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.CredentialDomain") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.UserName") + "</nobr></td>\n"+
 "        </tr>\n"
     );
     i = 0;
@@ -3126,7 +3127,7 @@ public class WebcrawlerConnector extends
     if (instanceNumber == 0)
     {
       out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"4\"><nobr>No page access credentials</nobr></td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"4\"><nobr>" + Messages.getString("WebcrawlerConnector.NoPageAccessCredentials") + "</nobr></td></tr>\n"
       );
     }
     out.print(
@@ -3135,12 +3136,12 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "\n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Session-based access credentials:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.SessionBasedAccessCredentials") + "</nobr></td>\n"+
 "    <td class=\"boxcell\" colspan=\"3\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Login pages</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.LoginPages") + "</nobr></td>\n"+
 "        </tr>\n"
     );
     i = 0;
@@ -3178,10 +3179,10 @@ public class WebcrawlerConnector extends
                 out.print(
 "            <table class=\"formtable\">\n"+
 "              <tr class=\"formheaderrow\">\n"+
-"                <td class=\"formcolumnheader\"><nobr>Login URL regular expression</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Page type</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Form name/link target regular expression</nobr></td>\n"+
-"                <td class=\"formcolumnheader\"><nobr>Override form parameters</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.LoginURLRegularExpression") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.PageType") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.FormNamelinkTargetRegularExpression") + "</nobr></td>\n"+
+"                <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.OverrideFormParameters") + "</nobr></td>\n"+
 "              </tr>\n"
                 );
               }
@@ -3225,7 +3226,7 @@ public class WebcrawlerConnector extends
           if (authPageInstanceNumber == 0)
           {
             out.print(
-"            <nobr>No login pages specified</nobr>\n"
+"            <nobr>" + Messages.getString("WebcrawlerConnector.NoLoginPagesSpecified") + "</nobr>\n"
             );
           }
           else
@@ -3245,7 +3246,7 @@ public class WebcrawlerConnector extends
     if (instanceNumber == 0)
     {
       out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\"><nobr>No session-based access credentials</nobr></td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\"><nobr>" + Messages.getString("WebcrawlerConnector.NoSessionBasedAccessCredentials") + "</nobr></td></tr>\n"
       );
     }
     out.print(
@@ -3254,12 +3255,12 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "  \n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Trust certificates:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.TrustCertificates") + "</nobr></td>\n"+
 "    <td class=\"boxcell\" colspan=\"3\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Certificate</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Certificate") + "</nobr></td>\n"+
 "        </tr>\n"
     );
     i = 0;
@@ -3278,7 +3279,7 @@ public class WebcrawlerConnector extends
           out.print(
 "        <tr class=\""+(((instanceNumber % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\"><nobr>"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(regexp)+"</nobr></td>\n"+
-"          <td class=\"formcolumncell\"><i>Trust everything</i></td>\n"+
+"          <td class=\"formcolumncell\"><i>" + Messages.getString("WebcrawlerConnector.TrustEverything") + "</i></td>\n"+
 "        </tr>\n"
           );
           instanceNumber++;
@@ -3313,7 +3314,7 @@ public class WebcrawlerConnector extends
     if (instanceNumber == 0)
     {
       out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\">No trust certificates</td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\">" + Messages.getString("WebcrawlerConnector.NoTrustCertificates") + "</td></tr>\n"
       );
     }
     out.print(
@@ -3541,13 +3542,13 @@ public class WebcrawlerConnector extends
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regular expression</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Description</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Reorder?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove JSP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove ASP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove PHP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove BV sessions?</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegularExpression") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Description") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Reorder") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveJSPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveASPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemovePHPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveBVSessions") + "</nobr></td>\n"+
 "        </tr>\n"
       );
       int q = 0;
@@ -3581,7 +3582,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\""+(((l % 2)==0)?"evenformrow":"oddformrow")+"\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+"urlregexp_"+Integer.toString(l)+"\">\n"+
-"              <input type=\"button\" value=\"Delete\" alt=\""+"Delete url regexp "+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(regexpString)+"\" onclick='javascript:URLRegexpDelete("+Integer.toString(l)+",\"urlregexp_"+Integer.toString(l)+"\");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" alt=\""+Messages.getString("WebcrawlerConnector.DeleteUrlRegexp")+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(regexpString)+"\" onclick='javascript:URLRegexpDelete("+Integer.toString(l)+",\"urlregexp_"+Integer.toString(l)+"\");'/>\n"+
 "            </a>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
@@ -3609,7 +3610,7 @@ public class WebcrawlerConnector extends
       if (l == 0)
       {
         out.print(
-"        <tr class=\"formrow\"><td colspan=\"8\" class=\"formcolumnmessage\"><nobr>No canonicalization specified - all URLs will be reordered and have all sessions removed</nobr></td></tr>\n"
+"        <tr class=\"formrow\"><td colspan=\"8\" class=\"formcolumnmessage\"><nobr>" + Messages.getString("WebcrawlerConnector.NoCanonicalizationSpecified") + "</nobr></td></tr>\n"
         );
       }
       out.print(
@@ -3617,7 +3618,7 @@ public class WebcrawlerConnector extends
 "        <tr class=\"formrow\">\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <a name=\""+"urlregexp_"+Integer.toString(l)+"\">\n"+
-"              <input type=\"button\" value=\"Add\" alt=\"Add url regexp\" onclick='javascript:URLRegexpAdd(\"urlregexp_"+Integer.toString(l+1)+"\");'/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" alt=\"" + Messages.getString("WebcrawlerConnector.AddUrlRegexp") + "\" onclick='javascript:URLRegexpAdd(\"urlregexp_"+Integer.toString(l+1)+"\");'/>\n"+
 "              <input type=\"hidden\" name=\"urlregexpcount\" value=\""+Integer.toString(l)+"\"/>\n"+
 "            </a>\n"+
 "          </td>\n"+
@@ -3689,19 +3690,19 @@ public class WebcrawlerConnector extends
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Include in crawl:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeInCrawl") + "</nobr></td>\n"+
 "    <td class=\"value\" colspan=\"1\">\n"+
 "      <textarea rows=\"25\" cols=\"60\" name=\"inclusions\">"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(inclusions)+"</textarea>\n"+
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Include in index:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeInIndex") + "</nobr></td>\n"+
 "    <td class=\"value\" colspan=\"1\">\n"+
 "      <textarea rows=\"10\" cols=\"60\" name=\"inclusionsindex\">"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(inclusionsIndex)+"</textarea>\n"+
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Include only hosts matching seeds?</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeOnlyHostsMatchingSeeds") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <input type=\"checkbox\" name=\"matchinghosts\" value=\"true\""+(includeMatching?" checked=\"yes\"":"")+"/>\n"+
 "      <input type=\"hidden\" name=\"matchinghosts_present\" value=\"true\"/>\n"+
@@ -3727,13 +3728,13 @@ public class WebcrawlerConnector extends
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Exclude from crawl:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.ExcludeFromCrawl") + "</nobr></td>\n"+
 "    <td class=\"value\" colspan=\"1\">\n"+
 "      <textarea rows=\"25\" cols=\"60\" name=\"exclusions\">"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(exclusions)+"</textarea>\n"+
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\" colspan=\"1\"><nobr>Exclude from index:</nobr></td>\n"+
+"    <td class=\"description\" colspan=\"1\"><nobr>" + Messages.getString("WebcrawlerConnector.ExcludeFromIndex") + "</nobr></td>\n"+
 "    <td class=\"value\" colspan=\"1\">\n"+
 "      <textarea rows=\"10\" cols=\"60\" name=\"exclusionsindex\">"+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(exclusionsIndex)+"</textarea>\n"+
 "    </td>\n"+
@@ -3776,7 +3777,7 @@ public class WebcrawlerConnector extends
 "      <input type=\"hidden\" name=\""+accessOpName+"\" value=\"\"/>\n"+
 "      <input type=\"hidden\" name=\""+"spectoken"+accessDescription+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(token)+"\"/>\n"+
 "      <a name=\""+"token_"+Integer.toString(k)+"\">\n"+
-"        <input type=\"button\" value=\"Delete\" onClick='Javascript:SpecOp(\""+accessOpName+"\",\"Delete\",\"token_"+Integer.toString(k)+"\")' alt=\""+"Delete token #"+Integer.toString(k)+"\"/>\n"+
+"        <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" onClick='Javascript:SpecOp(\""+accessOpName+"\",\"Delete\",\"token_"+Integer.toString(k)+"\")' alt=\""+Messages.getString("WebcrawlerConnector.DeleteToken")+Integer.toString(k)+"\"/>\n"+
 "      </a>&nbsp;\n"+
 "    </td>\n"+
 "    <td class=\"value\">\n"+
@@ -3791,7 +3792,7 @@ public class WebcrawlerConnector extends
       {
         out.print(
 "  <tr>\n"+
-"    <td class=\"message\" colspan=\"2\">No access tokens present</td>\n"+
+"    <td class=\"message\" colspan=\"2\">" + Messages.getString("WebcrawlerConnector.NoAccessTokensPresent") + "</td>\n"+
 "  </tr>\n"
         );
       }
@@ -3802,7 +3803,7 @@ public class WebcrawlerConnector extends
 "      <input type=\"hidden\" name=\"tokencount\" value=\""+Integer.toString(k)+"\"/>\n"+
 "      <input type=\"hidden\" name=\"accessop\" value=\"\"/>\n"+
 "      <a name=\""+"token_"+Integer.toString(k)+"\">\n"+
-"        <input type=\"button\" value=\"Add\" onClick='Javascript:SpecAddToken(\"token_"+Integer.toString(k+1)+"\")' alt=\"Add access token\"/>\n"+
+"        <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" onClick='Javascript:SpecAddToken(\"token_"+Integer.toString(k+1)+"\")' alt=\"" + Messages.getString("WebcrawlerConnector.AddAccessToken") + "\"/>\n"+
 "      </a>&nbsp;\n"+
 "    </td>\n"+
 "    <td class=\"value\">\n"+
@@ -3861,7 +3862,7 @@ public class WebcrawlerConnector extends
 "      <input type=\"hidden\" name=\""+"specmetaname"+metadataDescription+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(name)+"\"/>\n"+
 "      <input type=\"hidden\" name=\""+"specmetavalue"+metadataDescription+"\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(value)+"\"/>\n"+
 "      <a name=\""+"metadata_"+Integer.toString(k)+"\">\n"+
-"        <input type=\"button\" value=\"Delete\" onClick='Javascript:SpecOp(\""+metadataOpName+"\",\"Delete\",\"metadata_"+Integer.toString(k)+"\")' alt=\""+"Delete metadata #"+Integer.toString(k)+"\"/>\n"+
+"        <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Delete") + "\" onClick='Javascript:SpecOp(\""+metadataOpName+"\",\"Delete\",\"metadata_"+Integer.toString(k)+"\")' alt=\""+Messages.getString("WebcrawlerConnector.DeleteMetadata")+Integer.toString(k)+"\"/>\n"+
 "      </a>&nbsp;\n"+
 "    </td>\n"+
 "    <td class=\"value\">\n"+
@@ -3881,7 +3882,7 @@ public class WebcrawlerConnector extends
       {
         out.print(
 "  <tr>\n"+
-"    <td class=\"message\" colspan=\"4\">No metadata present</td>\n"+
+"    <td class=\"message\" colspan=\"4\">" + Messages.getString("WebcrawlerConnector.NoMetadataPresent") + "</td>\n"+
 "  </tr>\n"
         );
       }
@@ -3892,7 +3893,7 @@ public class WebcrawlerConnector extends
 "      <input type=\"hidden\" name=\"metadatacount\" value=\""+Integer.toString(k)+"\"/>\n"+
 "      <input type=\"hidden\" name=\"metadataop\" value=\"\"/>\n"+
 "      <a name=\""+"metadata_"+Integer.toString(k)+"\">\n"+
-"        <input type=\"button\" value=\"Add\" onClick='Javascript:SpecAddMetadata(\"metadata_"+Integer.toString(k+1)+"\")' alt=\"Add metadata\"/>\n"+
+"        <input type=\"button\" value=\"" + Messages.getString("WebcrawlerConnector.Add") + "\" onClick='Javascript:SpecAddMetadata(\"metadata_"+Integer.toString(k+1)+"\")' alt=\"" + Messages.getString("WebcrawlerConnector.AddMetadata") + "\"/>\n"+
 "      </a>&nbsp;\n"+
 "    </td>\n"+
 "    <td class=\"value\">\n"+
@@ -4316,7 +4317,7 @@ public class WebcrawlerConnector extends
     out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Seeds:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.Seeds") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
     );
     try
@@ -4370,17 +4371,17 @@ public class WebcrawlerConnector extends
         {
           out.print(
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>URL canonicalization:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.URLCanonicalization") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
-"          <td class=\"formcolumnheader\"><nobr>URL regexp</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Description</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Reorder?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove JSP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove ASP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove PHP sessions?</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Remove BV sessions?</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.URLRegexp") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Description") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.Reorder") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveJSPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveASPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemovePHPSessions") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WebcrawlerConnector.RemoveBVSessions") + "</nobr></td>\n"+
 "        </tr>\n"
           );
         }
@@ -4428,13 +4429,13 @@ public class WebcrawlerConnector extends
     else
     {
       out.print(
-"  <tr><td class=\"message\" colspan=\"2\"><nobr>No url canonicalization specified; will reorder all urls and remove all sessions</nobr></td></tr>\n"
+"  <tr><td class=\"message\" colspan=\"2\"><nobr>" + Messages.getString("WebcrawlerConnector.NoCanonicalizationSpecified") + "</nobr></td></tr>\n"
       );
     }
     out.print(
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Include only hosts mentioned in seeds?</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeOnlyHostsMatchingSeeds") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "    "+(includeMatching?"yes":"no")+"\n"+
 "    </td>\n"+
@@ -4444,7 +4445,7 @@ public class WebcrawlerConnector extends
     out.print(
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Include in crawl:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeInCrawl") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
     );
     try
@@ -4486,7 +4487,7 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Include in index:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.IncludeInIndex") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
     );
     try
@@ -4528,7 +4529,7 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Exclude from crawl:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.ExcludeFromCrawl") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
     );
     try
@@ -4570,7 +4571,7 @@ public class WebcrawlerConnector extends
 "  </tr>\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Exclude from index:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.ExcludeFromIndex") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
     );
     try
@@ -4625,7 +4626,7 @@ public class WebcrawlerConnector extends
         {
           out.print(
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Access tokens:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.AccessTokens") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
           );
           seenAny = true;
@@ -4647,7 +4648,7 @@ public class WebcrawlerConnector extends
     else
     {
       out.print(
-"  <tr><td class=\"message\" colspan=\"2\"><nobr>No access tokens specified</nobr></td></tr>\n"
+"  <tr><td class=\"message\" colspan=\"2\"><nobr>" + Messages.getString("WebcrawlerConnector.NoAccessTokensSpecified") + "</nobr></td></tr>\n"
       );
     }
     out.print(
@@ -4665,7 +4666,7 @@ public class WebcrawlerConnector extends
         {
           out.print(
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Metadata:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WebcrawlerConnector.Metadata") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"
           );
           seenAny = true;
@@ -4688,7 +4689,7 @@ public class WebcrawlerConnector extends
     else
     {
       out.print(
-"  <tr><td class=\"message\" colspan=\"2\"><nobr>No metadata specified</nobr></td></tr>\n"
+"  <tr><td class=\"message\" colspan=\"2\"><nobr>" + Messages.getString("WebcrawlerConnector.NoMetadataSpecified") + "</nobr></td></tr>\n"
       );
     }
     out.print(

Modified: incubator/lcf/branches/CONNECTORS-314/connectors/wiki/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/wiki/WikiConnector.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/connectors/wiki/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/wiki/WikiConnector.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/connectors/wiki/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/wiki/WikiConnector.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/connectors/wiki/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/wiki/WikiConnector.java Mon Dec 19 07:34:58 2011
@@ -18,6 +18,7 @@
 */
 package org.apache.manifoldcf.crawler.connectors.wiki;
 
+import org.apache.manifoldcf.core.i18n.*;
 import org.apache.manifoldcf.core.interfaces.*;
 import org.apache.manifoldcf.agents.interfaces.*;
 import org.apache.manifoldcf.crawler.interfaces.*;
@@ -320,7 +321,7 @@ public class WikiConnector extends org.a
   public void outputConfigurationHeader(IThreadContext threadContext, IHTTPOutput out, ConfigParams parameters, List<String> tabsArray)
     throws ManifoldCFException, IOException
   {
-    tabsArray.add("Server");
+    tabsArray.add(Messages.getString("WikiConnector.Server"));
 
     out.print(
 "<script type=\"text/javascript\">\n"+
@@ -401,12 +402,12 @@ public class WikiConnector extends org.a
     if (path == null)
       path = "/w";
 
-    if (tabName.equals("Server"))
+    if (tabName.equals(Messages.getString("WikiConnector.Server")))
     {
       out.print(
 "<table class=\"displaytable\">\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Protocol:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.Protocol") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <select name=\"serverprotocol\">\n"+
 "        <option value=\"http\""+(protocol.equals("http")?" selected=\"true\"":"")+">http</option>\n"+
@@ -415,19 +416,19 @@ public class WikiConnector extends org.a
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Server name:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.ServerName") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <input name=\"servername\" type=\"text\" size=\"32\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(server)+"\"/>\n"+
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Port:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.Port") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <input name=\"serverport\" type=\"text\" size=\"5\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(port)+"\"/>\n"+
 "    </td>\n"+
 "  </tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Path name:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.PathName") + "</nobr></td>\n"+
 "    <td class=\"value\">\n"+
 "      <input name=\"serverpath\" type=\"text\" size=\"16\" value=\""+org.apache.manifoldcf.ui.util.Encoder.attributeEscape(path)+"\"/>\n"+
 "    </td>\n"+
@@ -542,7 +543,7 @@ public class WikiConnector extends org.a
   public void outputSpecificationHeader(IHTTPOutput out, DocumentSpecification ds, List<String> tabsArray)
     throws ManifoldCFException, IOException
   {
-    tabsArray.add("Namespace and Titles");
+    tabsArray.add(Messages.getString("WikiConnector.NamespaceAndTitles"));
     
     out.print(
 "<script type=\"text/javascript\">\n"+
@@ -583,10 +584,11 @@ public class WikiConnector extends org.a
   *@param tabName is the current tab name.
   */
   @Override
+
   public void outputSpecificationBody(IHTTPOutput out, DocumentSpecification ds, String tabName)
     throws ManifoldCFException, IOException
   {
-    if (tabName.equals("Namespace and Titles"))
+    if (tabName.equals(Messages.getString("WikiConnector.NamespaceAndTitles")))
     {
       boolean seenAny = false;
       // Output table column headers
@@ -594,13 +596,13 @@ public class WikiConnector extends org.a
 "<table class=\"displaytable\">\n"+
 "  <tr><td class=\"separator\" colspan=\"2\"><hr/></td></tr>\n"+
 "  <tr>\n"+
-"    <td class=\"description\"><nobr>Namespaces and titles:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.NamespaceAndTitles2") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
 "          <td class=\"formcolumnheader\"></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Namespace</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Title prefix</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WikiConnector.Namespace") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WikiConnector.TitlePrefix") + "</nobr></td>\n"+
 "        </tr>\n"
       );
 
@@ -624,7 +626,7 @@ public class WikiConnector extends org.a
 "              <input type=\"hidden\" name=\""+nsOpName+"\" value=\"\"/>\n"+
 "              <input type=\"hidden\" name=\""+nsNsName+"\" value=\""+((namespace==null)?"":org.apache.manifoldcf.ui.util.Encoder.attributeEscape(namespace))+"\"/>\n"+
 "              <input type=\"hidden\" name=\""+nsTitlePrefix+"\" value=\""+((titlePrefix==null)?"":org.apache.manifoldcf.ui.util.Encoder.attributeEscape(titlePrefix))+"\"/>\n"+
-"              <input type=\"button\" value=\"Delete\" onClick='Javascript:NsDelete("+Integer.toString(k)+")' alt=\""+"Delete namespace/title #"+Integer.toString(k)+"\"/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WikiConnector.Delete") + "\" onClick='Javascript:NsDelete("+Integer.toString(k)+")' alt=\""+"Delete namespace/title #"+Integer.toString(k)+"\"/>\n"+
 "            </nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
@@ -646,7 +648,7 @@ public class WikiConnector extends org.a
       if (k == 0)
       {
         out.print(
-"        <tr class=\"formrow\"><td colspan=\"3\" class=\"formmessage\">No specification; all default namespace documents currently included</td></tr>\n"
+"        <tr class=\"formrow\"><td colspan=\"3\" class=\"formmessage\">" + Messages.getString("WikiConnector.NoSpecification") + "</td></tr>\n"
         );
       }
 
@@ -677,13 +679,13 @@ public class WikiConnector extends org.a
 "              <a name=\""+"ns_"+Integer.toString(k)+"\"/>\n"+
 "              <input type=\"hidden\" name=\"nsop\" value=\"\"/>\n"+
 "              <input type=\"hidden\" name=\"nscount\" value=\""+Integer.toString(k)+"\"/>\n"+
-"              <input type=\"button\" value=\"Add\" onClick='Javascript:NsAdd("+Integer.toString(k)+")' alt=\"Add namespace/prefix\"/>\n"+
+"              <input type=\"button\" value=\"" + Messages.getString("WikiConnector.Add") + "\" onClick='Javascript:NsAdd("+Integer.toString(k)+")' alt=\"" + Messages.getString("WikiConnector.AddNamespacePrefix") + "\"/>\n"+
 "            </nobr>\n"+
 "          </td>\n"+
 "          <td class=\"formcolumncell\">\n"+
 "            <nobr>\n"+
 "              <select name=\"nsnsname\">\n"+
-"                <option value=\"\" selected=\"true\">-- Use default --</option>\n"
+"                <option value=\"\" selected=\"true\">-- " + Messages.getString("WikiConnector.UseDefault") + " --</option>\n"
         );
         for (int l = 0 ; l < nameSpaceNames.length ; l++)
         {
@@ -709,7 +711,7 @@ public class WikiConnector extends org.a
       catch (ServiceInterruption e)
       {
         out.print(
-"        <tr class=\"formrow\"><td colspan=\"3\" class=\"formmessage\">Transient error: "+org.apache.manifoldcf.ui.util.Encoder.bodyEscape(e.getMessage())+"</td></tr>\n"
+"        <tr class=\"formrow\"><td colspan=\"3\" class=\"formmessage\">" + Messages.getString("WikiConnector.TransientError") + org.apache.manifoldcf.ui.util.Encoder.bodyEscape(e.getMessage())+"</td></tr>\n"
         );
       }
 
@@ -834,12 +836,12 @@ public class WikiConnector extends org.a
 "  <tr>\n"
     );
     out.print(
-"    <td class=\"description\"><nobr>Namespace and title:</nobr></td>\n"+
+"    <td class=\"description\"><nobr>" + Messages.getString("WikiConnector.NamespaceAndTitles2") + "</nobr></td>\n"+
 "    <td class=\"boxcell\">\n"+
 "      <table class=\"formtable\">\n"+
 "        <tr class=\"formheaderrow\">\n"+
-"          <td class=\"formcolumnheader\"><nobr>Namespace</nobr></td>\n"+
-"          <td class=\"formcolumnheader\"><nobr>Title prefix</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WikiConnector.Namespace") + "</nobr></td>\n"+
+"          <td class=\"formcolumnheader\"><nobr>" + Messages.getString("WikiConnector.TitlePrefix") + "</nobr></td>\n"+
 "        </tr>\n"
     );
 
@@ -871,7 +873,7 @@ public class WikiConnector extends org.a
     
     if (k == 0)
       out.print(
-"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\">All default namespace documents included</td></tr>\n"
+"        <tr class=\"formrow\"><td class=\"formmessage\" colspan=\"2\">" + Messages.getString("WikiConnector.AllDefaultNamespaceDocumentsIncluded") + "</td></tr>\n"
       );
     
     out.print(
@@ -2519,6 +2521,7 @@ public class WikiConnector extends org.a
       this.namespaces = namespaces;
     }
 
+
     protected BaseProcessingContext createChild(String namespaceURI, String localName, String qName, Attributes atts)
     {
       return new WikiGetNamespacesQueryContext(theStream,namespaceURI,localName,qName,atts,namespaces);

Modified: incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/incrementalingest/IncrementalIngester.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/incrementalingest/IncrementalIngester.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/incrementalingest/IncrementalIngester.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/incrementalingest/IncrementalIngester.java Mon Dec 19 07:34:58 2011
@@ -132,6 +132,7 @@ public class IncrementalIngester extends
 
       // Get rid of indexes that shouldn't be there
       Map indexes = getTableIndexes(null,null);
+if (indexes != null){
       Iterator iter = indexes.keySet().iterator();
       while (iter.hasNext())
       {
@@ -148,7 +149,7 @@ public class IncrementalIngester extends
           // This index shouldn't be here; drop it
           performRemoveIndex(indexName);
       }
-
+}
       // Add the ones we didn't find
       if (uriHashIndex != null)
         performAddIndex(null,uriHashIndex);

Modified: incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnection/OutputConnectionManager.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnection/OutputConnectionManager.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnection/OutputConnectionManager.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnection/OutputConnectionManager.java Mon Dec 19 07:34:58 2011
@@ -107,6 +107,7 @@ public class OutputConnectionManager ext
       
       // Get rid of indexes that shouldn't be there
       Map indexes = getTableIndexes(null,null);
+if (indexes != null){
       Iterator iter = indexes.keySet().iterator();
       while (iter.hasNext())
       {
@@ -119,7 +120,7 @@ public class OutputConnectionManager ext
           // This index shouldn't be here; drop it
           performRemoveIndex(indexName);
       }
-
+}
       // Add the ones we didn't find
       if (classIndex != null)
         performAddIndex(null,classIndex);

Modified: incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnmgr/OutputConnectorManager.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnmgr/OutputConnectorManager.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnmgr/OutputConnectorManager.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/framework/agents/src/main/java/org/apache/manifoldcf/agents/outputconnmgr/OutputConnectorManager.java Mon Dec 19 07:34:58 2011
@@ -86,6 +86,7 @@ public class OutputConnectorManager exte
 
       // Get rid of indexes that shouldn't be there
       Map indexes = getTableIndexes(null,null);
+if (indexes != null){
       Iterator iter = indexes.keySet().iterator();
       while (iter.hasNext())
       {
@@ -98,6 +99,7 @@ public class OutputConnectorManager exte
           // This index shouldn't be here; drop it
           performRemoveIndex(indexName);
       }
+}
 
       // Add the ones we didn't find
       if (descriptionIndex != null)

Modified: incubator/lcf/branches/CONNECTORS-314/framework/build.xml
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/build.xml?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/build.xml (original)
+++ incubator/lcf/branches/CONNECTORS-314/framework/build.xml Mon Dec 19 07:34:58 2011
@@ -48,10 +48,14 @@
         <javac srcdir="core/src/main/java" destdir="build/core/classes" target="1.5" source="1.5" debug="true" debuglevel="lines,vars,source">
             <classpath>
                 <fileset dir="lib"> 
-                    <include name="*.jar"/> 
+                    <include name="*.jar"/>
                 </fileset>
             </classpath>
         </javac>
+        <native2ascii encoding="UTF-8" src="core/src/main/java" dest="core/src/main/java" ext="" includes="**/*.utf8" />
+        <copy todir="build/core/classes">
+             <fileset dir="core/src/main/java" includes="**/*.properties"/>
+        </copy>
     </target>
 
     <target name="compile-ui-core" depends="compile-core">
@@ -170,6 +174,8 @@
                 <pathelement location="${java.home}/../lib/tools.jar"/>
                 <fileset dir="lib"> 
                     <include name="*.jar"/> 
+
+
                 </fileset>
                 <pathelement location="build/core/classes"/>
                 <pathelement location="build/ui-core/classes"/>
@@ -181,6 +187,7 @@
             </classpath>
 
         </javac>
+        <native2ascii encoding="UTF-8" src="crawler-ui/src/main/webapp/WEB-INF/classes" dest="crawler-ui/src/main/webapp/WEB-INF/classes" ext="" includes="**/*.utf8"/>
     </target>
 
     <target name="jar-core" depends="compile-core">
@@ -328,6 +335,12 @@
                 <include name="*.tld"/>
             </fileset>
         </copy>
+        <mkdir dir="build/webapp/crawler-ui/WEB-INF/classes"/>
+        <copy todir="build/webapp/crawler-ui/WEB-INF/classes">
+            <fileset dir="crawler-ui/src/main/webapp/WEB-INF/classes">
+                <include name="*.properties"/>
+            </fileset>
+        </copy>
         <copy todir="build/webapp/crawler-ui">
             <fileset dir="crawler-ui/src/main/webapp" includes="**/*.jsp,**/*.css,**/*.png,**/*.html"/>
         </copy>

Modified: incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/database/DBInterfaceMySQL.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/database/DBInterfaceMySQL.java?rev=1220632&r1=1220631&r2=1220632&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/database/DBInterfaceMySQL.java (original)
+++ incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/database/DBInterfaceMySQL.java Mon Dec 19 07:34:58 2011
@@ -19,24 +19,57 @@
 package org.apache.manifoldcf.core.database;
 
 import org.apache.manifoldcf.core.interfaces.*;
+import org.apache.manifoldcf.core.system.ManifoldCF;
 import java.util.*;
 
 public class DBInterfaceMySQL extends Database implements IDBInterface
 {
   public static final String _rcsid = "@(#)$Id: DBInterfaceMySQL.java 999670 2010-09-21 22:18:19Z kwright $";
 
-  private static final String _url = "jdbc:mysql://localhost/";
-  private static final String _driver = "org.gjt.mm.mysql.Driver";
+  /** MySQL driver property */
+  public static final String mysqlDriverProperty = "org.apache.manifoldcf.mysql.database.driver";
+  /** MySQL databaseName property */
+  public static final String mysqlDatabaseNameProperty = "org.apache.manifoldcf.database.name";
+  /** MySQL url property */
+  public static final String mysqlUrlProperty = "org.apache.manifoldcf.mysql.database.url";
 
+  private static final String _url = "jdbc:mysql://localhost/";
+  private static final String _driver = "com.mysql.jdbc.Driver";
   protected String cacheKey;
 
   public DBInterfaceMySQL(IThreadContext tc, String databaseName, String userName, String password)
     throws ManifoldCFException
   {
-    super(tc,_url+databaseName,_driver,databaseName,userName,password);
+
+    super(tc,getJdbcUrl(databaseName),getJdbcDriver(),databaseName,userName,password);
     cacheKey = CacheKeyFactory.makeDatabaseKey(this.databaseName);
   }
 
+  private static String getJdbcUrl(final String databaseName)
+  {
+    String url =  ManifoldCF.getProperty(mysqlUrlProperty);
+
+    if (url == null || url.length() < 1)
+       url = "jdbc:mysql://localhost/";
+    url += databaseName;
+    return url;
+  }
+
+  private static String getJdbcDatabaseName(){
+    String databaseName =  ManifoldCF.getProperty(mysqlDatabaseNameProperty);
+
+    if (databaseName == null || databaseName.length() < 1)
+      databaseName = "manifoldfc";
+    return databaseName;
+  }
+
+  private static String getJdbcDriver(){
+    String driver =  ManifoldCF.getProperty(mysqlDriverProperty);
+    if (driver == null || driver.length() < 1)
+      driver = "com.mysql.jdbc.Driver";
+    return driver;
+  }
+
   /** Initialize.  This method is called once per JVM instance, in order to set up
   * database communication.
   */
@@ -69,7 +102,7 @@ public class DBInterfaceMySQL extends Da
   public void performLock(String tableName)
     throws ManifoldCFException
   {
-    performModification("LOCK TABLE "+tableName+" IN EXCLUSIVE MODE",null,null);
+    //performModification("LOCK TABLE "+tableName+" IN EXCLUSIVE MODE",null,null);
   }
 
   /** Perform an insert operation.
@@ -262,9 +295,7 @@ public class DBInterfaceMySQL extends Da
       }
     }
     queryBuffer.append(')');
-
     performModification(queryBuffer.toString(),null,invalidateKeys);
-
   }
 
   /** Perform a table alter operation.
@@ -387,19 +418,33 @@ public class DBInterfaceMySQL extends Da
     throws ManifoldCFException
   {
     // Connect to super database
+
     Database masterDatabase = new DBInterfaceMySQL(context,"mysql",adminUserName,adminPassword);
+
     List list = new ArrayList();
+try{
     list.add("utf8");
     masterDatabase.executeQuery("CREATE DATABASE "+databaseName+" CHARACTER SET ?",list,
       null,invalidateKeys,null,false,0,null,null);
+} catch (ManifoldCFException e){
+if (e.getErrorCode() != 4)
+	throw new ManifoldCFException(e.getMessage());
+}
     if (userName != null)
     {
+try {
       list.clear();
       list.add(userName);
       list.add("localhost");
       list.add(password);
       masterDatabase.executeQuery("GRANT ALL ON "+databaseName+".* TO ?@? IDENTIFIED BY ?",list,
         null,invalidateKeys,null,false,0,null,null);
+} catch (ManifoldCFException e){
+if (e.getErrorCode() != 4)
+	throw new ManifoldCFException(e.getMessage());
+}
+      masterDatabase.executeQuery("USE " + getJdbcDatabaseName(),null,
+        null,invalidateKeys,null,false,0,null,null);
     }
   }
 
@@ -413,7 +458,11 @@ public class DBInterfaceMySQL extends Da
   {
     // Connect to super database
     Database masterDatabase = new DBInterfaceMySQL(context,"mysql",adminUserName,adminPassword);
+    //Database masterDatabase = new DBInterfaceMySQL(context,getJdbcDatabaseName(),adminUserName,adminPassword);
+
     masterDatabase.executeQuery("DROP DATABASE "+databaseName,null,null,invalidateKeys,null,false,0,null,null);
+      masterDatabase.executeQuery("USE " + getJdbcDatabaseName(),null,
+        null,invalidateKeys,null,false,0,null,null);
   }
 
   /** Perform a general database modification query.
@@ -424,7 +473,11 @@ public class DBInterfaceMySQL extends Da
   public void performModification(String query, List params, StringSet invalidateKeys)
     throws ManifoldCFException
   {
+try{
+    executeQuery("USE " + getJdbcDatabaseName(),null,null,invalidateKeys,null,false,0,null,null);
     executeQuery(query,params,null,invalidateKeys,null,false,0,null,null);
+} catch(Exception e){
+}
   }
 
   /** Get a table's schema.
@@ -436,9 +489,11 @@ public class DBInterfaceMySQL extends Da
   public Map<String,ColumnDescription> getTableSchema(String tableName, StringSet cacheKeys, String queryClass)
     throws ManifoldCFException
   {
+Map<String,ColumnDescription> rval = null;
+    try {
     IResultSet set = performQuery("DESCRIBE "+tableName,null,cacheKeys,queryClass);
     // Digest the result
-    Map<String,ColumnDescription> rval = new HashMap<String,ColumnDescription>();
+    rval = new HashMap<String,ColumnDescription>();
     int i = 0;
     while (i < set.getRowCount())
     {
@@ -450,6 +505,9 @@ public class DBInterfaceMySQL extends Da
       rval.put(fieldName,new ColumnDescription(type,isPrimaryKey,isNull,null,null,false));
     }
 
+    } catch (Exception e) {
+rval = null;
+    }
     return rval;
   }
 

Added: incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/Messages.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/Messages.java?rev=1220632&view=auto
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/Messages.java (added)
+++ incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/Messages.java Mon Dec 19 07:34:58 2011
@@ -0,0 +1,103 @@
+/* $Id: Messages.java 1001023 2011-12-12 18:41:28Z hozawa $ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package org.apache.manifoldcf.core.i18n;
+
+import java.text.MessageFormat;
+import java.util.Locale;
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+
+public final class Messages
+{
+public static final String DEFAULT_BUNDLE_NAME="common";
+
+  /** Constructor - do no instantiate
+  */
+  public Messages()
+  {
+  }
+  
+  public static String getString(String messageKey)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, Locale.getDefault(), messageKey, null);
+  }
+  
+  public static String getString(String messageKey, Object[] args)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, Locale.getDefault(), messageKey, args);
+  }
+  
+  public static String getString(Locale locale, String messageKey)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+  
+  public static String getString(Locale locale, String messageKey, Object[] args)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+  
+  public static String getString(String bundleName, String messageKey)
+  {
+    return getString(bundleName, Locale.getDefault(), messageKey, null);
+  }
+  
+  public static String getString(String bundleName, String messageKey, Object[] args)
+  {
+    return getString(bundleName, Locale.getDefault(), messageKey, args);
+  }
+  
+  public static String getString(String bundleName, Locale locale, String messageKey)
+  {
+    return getString(bundleName, locale, messageKey, null);
+  }
+  
+  public static String getString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    ResourceBundle resources = null;
+    String message = null;
+    String formatMessage = null;
+    try
+    {
+      resources = getBundle(bundleName, locale);
+      message = resources.getString(messageKey);
+      if (args != null)
+       {
+         formatMessage = MessageFormat.format(message, args);
+       }
+       else
+       {
+         formatMessage = message;
+       }
+     }
+     catch (MissingResourceException e)
+     {
+       System.out.println("Missing resource bundle:" + messageKey);
+     }
+     return formatMessage;
+   }
+   
+   protected static ResourceBundle getBundle(String bundleName, Locale locale)
+   {
+     String path = "org.apache.manifoldcf.core.i18n." + bundleName;
+     return ResourceBundle.getBundle(path, locale);   
+    }
+}
+

Added: incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/common.properties
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/common.properties?rev=1220632&view=auto
==============================================================================
--- incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/common.properties (added)
+++ incubator/lcf/branches/CONNECTORS-314/framework/core/src/main/java/org/apache/manifoldcf/core/i18n/common.properties Mon Dec 19 07:34:58 2011
@@ -0,0 +1,6 @@
+SolrConnector.Arguments=Arguments
+SolrConnector.Arguments2=Arguments:
+SolrConnector.Commits=Commits
+SolrConnector.Documents=Documents
+SolrConnector.Schema=Schema
+SolrConnector.Server=Server



Mime
View raw message