-remove unused exports -A href -> a href -javadoc tweaks
Index: SchemaValidate.java =================================================================== RCS file: /home/cvspublic/ant/src/main/org/apache/tools/ant/taskdefs/optional/SchemaValidate.java,v retrieving revision 1.5 diff -u -r1.5 SchemaValidate.java --- SchemaValidate.java 23 Feb 2005 13:04:16 -0000 1.5 +++ SchemaValidate.java 23 Mar 2005 02:19:12 -0000 @@ -18,7 +18,6 @@ import org.apache.tools.ant.BuildException; import org.apache.tools.ant.Project; -import org.apache.tools.ant.types.DTDLocation; import org.apache.tools.ant.util.XmlConstants; import org.apache.tools.ant.util.JAXPUtils; import org.xml.sax.XMLReader; @@ -29,8 +28,6 @@ import javax.xml.parsers.SAXParserFactory; import javax.xml.parsers.SAXParser; import javax.xml.parsers.ParserConfigurationException; -import java.util.List; -import java.util.ArrayList; import java.util.Iterator; import java.util.HashMap; import java.io.File; @@ -52,15 +49,15 @@ public class SchemaValidate extends XMLValidateTask { /** map of all declared schemas; we catch and complain about redefinitions */ - private HashMap schemaLocations= new HashMap(); + private HashMap schemaLocations = new HashMap(); /** full checking of a schema */ - private boolean fullChecking=true; + private boolean fullChecking = true; /** * flag to disable DTD support. Best left enabled. */ - private boolean disableDTD=false; + private boolean disableDTD = false; /** * default URL for nonamespace schemas @@ -106,7 +103,7 @@ } /** - * set nonamespace handling up for xerces or other parsers + * Set nonamespace handling up for xerces or other parsers * @param property name of the property to set */ private void setNoNamespaceSchemaProperty(String property) { @@ -118,9 +115,9 @@ } /** - * set schema attributes in a JAXP12 engine - * @see <A href="http://java.sun.com/xml/jaxp/change-requests-11.html"> - * JAXP 1.2 Approved CHANGES</A> + * Set schema attributes in a JAXP12 engine + * @see <a href="http://java.sun.com/xml/jaxp/change-requests-11.html"> + * JAXP 1.2 Approved CHANGES</a> * @return */ public boolean enableJAXP12SchemaValidation() { @@ -139,24 +136,24 @@ } /** - * add the schema - * @param location + * Add the schema + * @param schemaLocation * @throws BuildException if there is no namespace, or if there already * is a declaration of this schema with a different value */ - public void addConfiguredSchema(SchemaLocation location) { - log("adding schema "+location,Project.MSG_DEBUG); - location.validateNamespace(); + public void addConfiguredSchema(SchemaLocation schemaLocation) { + log("adding schema "+schemaLocation,Project.MSG_DEBUG); + schemaLocation.validateNamespace(); SchemaLocation old=(SchemaLocation) schemaLocations.get( - location.getNamespace()); - if(old!=null && !old.equals(location)) { - throw new BuildException(ERROR_DUPLICATE_SCHEMA+location); + schemaLocation.getNamespace()); + if(old!=null && !old.equals(schemaLocation)) { + throw new BuildException(ERROR_DUPLICATE_SCHEMA+schemaLocation); } - schemaLocations.put(location.getNamespace(), location); + schemaLocations.put(schemaLocation.getNamespace(), schemaLocation); } /** - * enable full schema checking. Slower but better. + * Enable full schema checking. Slower but better. * @param fullChecking */ public void setFullChecking(boolean fullChecking) { @@ -165,17 +162,17 @@ /** - * create a schema location to hold the anonymous + * Create a schema location to hold the anonymous * schema */ protected void createAnonymousSchema() { - if(anonymousSchema==null) { - anonymousSchema=new SchemaLocation(); + if(anonymousSchema == null) { + anonymousSchema = new SchemaLocation(); } anonymousSchema.setNamespace("(no namespace)"); } /** - * identify the URL of the default schema + * Identify the URL of the default schema * @param defaultSchemaURL */ public void setNoNamespaceURL(String defaultSchemaURL) { @@ -184,7 +181,7 @@ } /** - * identify a file containing the default schema + * Identify a file containing the default schema * @param defaultSchemaFile */ public void setNoNamespaceFile(File defaultSchemaFile) { @@ -193,7 +190,7 @@ } /** - * flag to disable DTD support. + * Flag to disable DTD support. * @param disableDTD */ public void setDisableDTD(boolean disableDTD) { @@ -254,7 +251,7 @@ } /** - * build a string list of all schema locations, then set the relevant + * Build a string list of all schema locations, then set the relevant * property. */ protected void addSchemaLocations() { @@ -278,24 +275,23 @@ } /** - * get the URL of the no namespace schema + * Get the URL of the no namespace schema * @return */ protected String getNoNamespaceSchemaURL() { - if(anonymousSchema==null) { + if(anonymousSchema == null) { return null; - } else { - return anonymousSchema.getSchemaLocationURL(); - } + } + return anonymousSchema.getSchemaLocationURL(); } /** - * set a feature if it is supported, log at verbose level if + * Set a feature if it is supported, log at verbose level if * not * @param feature * @param value */ - protected void setFeatureIfSupported(String feature,boolean value) { + protected void setFeatureIfSupported(String feature, boolean value) { try { getXmlReader().setFeature(feature, value); } catch (SAXNotRecognizedException e) { @@ -306,8 +302,7 @@ } /** - * handler called on successful file validation. - * + * Handler called on successful file validation. * @param fileProcessed number of files processed. */ protected void onSuccessfulValidation(int fileProcessed) {
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]