You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by st...@locus.apache.org on 2000/01/06 18:59:04 UTC
cvs commit: xml-xerces/java/src/org/apache/xerces/validators/datatype BinaryValidator.java
stefano 00/01/06 09:59:04
Modified: java/src/org/apache/xerces/validators/datatype
BinaryValidator.java
Log:
can anyone tell me how something like this can find its way into the CVS?
Revision Changes Path
1.2 +24 -20 xml-xerces/java/src/org/apache/xerces/validators/datatype/BinaryValidator.java
Index: BinaryValidator.java
===================================================================
RCS file: /home/cvs/xml-xerces/java/src/org/apache/xerces/validators/datatype/BinaryValidator.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- BinaryValidator.java 2000/01/06 00:14:57 1.1
+++ BinaryValidator.java 2000/01/06 17:59:04 1.2
@@ -2,7 +2,7 @@
* The Apache Software License, Version 1.1
*
*
- * Copyright (c) 1999 The Apache Software Foundation. All rights
+ * Copyright (c) 1999 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -10,7 +10,7 @@
* are met:
*
* 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
+ * notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
@@ -18,7 +18,7 @@
* distribution.
*
* 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
+ * if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
@@ -26,7 +26,7 @@
*
* 4. The names "Xerces" and "Apache Software Foundation" must
* not be used to endorse or promote products derived from this
- * software without prior written permission. For written
+ * software without prior written permission. For written
* permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache",
@@ -57,6 +57,7 @@
package org.apache.xerces.validators.datatype;
+import java.util.Enumeration;
import java.util.Hashtable;
import java.util.Locale;
@@ -69,28 +70,30 @@
*/
public class BinaryValidator implements InternalDatatypeValidator {
- private Locale fLocale;
+
+ private Locale fLocale;
+
/**
* validate that a string is a W3C binary type
*
* validate returns true or false depending on whether the string content is an
* instance of the W3C binary datatype
- *
+ *
* @param content A string containing the content to be validated
*
* @exception throws InvalidDatatypeException if the content is
* not a W3C binary type
*/
+ public void validate(String content) throws InvalidDatatypeValueException {
+ // just say yes
+ }
- public void validate(String content) throws InvalidDatatypeValueException {
+ public void validate(int contentIndex) throws InvalidDatatypeValueException {
// just say yes
- }
-
- public void validate(int contentIndex) throws InvalidDatatypeValueException {
- }
-
- public void setFacets(Hashtable facets) throws UnknownFacetException, IllegalFacetException, IllegalFacetValueException {
- for (Enumeration e = facets.keys(); e.hasMoreElements;) {
+ }
+
+ public void setFacets(Hashtable facets) throws UnknownFacetException, IllegalFacetException, IllegalFacetValueException {
+ for (Enumeration e = facets.keys(); e.hasMoreElements();) {
String key = (String) e.nextElement();
if (key.equals(DatatypeValidator.LENGTH)) {
} else if (key.equals(DatatypeValidator.MINLENGTH)) {
@@ -99,13 +102,14 @@
} else {
throw new IllegalFacetException();
}
- } }
-
- public void setFacets(int facets[]) throws UnknownFacetException, IllegalFacetException, IllegalFacetValueException {
- }
+ }
+ }
+
+ public void setFacets(int facets[]) throws UnknownFacetException, IllegalFacetException, IllegalFacetValueException {
+ }
- public void setBasetype(DatatypeValidator base) {
- }
+ public void setBasetype(DatatypeValidator base) {
+ }
/**
* set the locate to be used for error messages