Package org.apache.xerces.impl

Examples of org.apache.xerces.impl.RevalidationHandler


                            ObjectFactory.findClassLoader(),
                            true));

        }
        // return first available validator           
        RevalidationHandler val = validators[freeValidatorIndex];
        validators[freeValidatorIndex--] = null;
        return val;
  }
View Full Code Here


       // REVISIT: implement support for DTD validators as well
       ++freeValidatorIndex;
       if (validators.length == freeValidatorIndex ){
            // resize size of the validators
            currentSize+=SIZE;
            RevalidationHandler newarray[] new RevalidationHandler[currentSize];
            System.arraycopy(validators, 0, newarray, 0, validators.length);
            validators = newarray;
       }
       validators[freeValidatorIndex]=validator;
  }
View Full Code Here

                            ObjectFactory.findClassLoader(),
                            true));

        }
        // return first available validator           
        RevalidationHandler val = validators[freeValidatorIndex];
        validators[freeValidatorIndex--] = null;
        return val;
  }
View Full Code Here

       // REVISIT: implement support for DTD validators as well
       ++freeValidatorIndex;
       if (validators.length == freeValidatorIndex ){
            // resize size of the validators
            currentSize+=SIZE;
            RevalidationHandler newarray[] new RevalidationHandler[currentSize];
            System.arraycopy(validators, 0, newarray, 0, validators.length);
            validators = newarray;
       }
       validators[freeValidatorIndex]=validator;
  }
View Full Code Here

                            ObjectFactory.findClassLoader(),
                            true));

        }
        // return first available validator           
        RevalidationHandler val = validators[freeValidatorIndex];
        validators[freeValidatorIndex--] = null;
        return val;
  }
View Full Code Here

       // REVISIT: implement support for DTD validators as well
       ++freeValidatorIndex;
       if (validators.length == freeValidatorIndex ){
            // resize size of the validators
            currentSize+=SIZE;
            RevalidationHandler newarray[] new RevalidationHandler[currentSize];
            System.arraycopy(validators, 0, newarray, 0, validators.length);
            validators = newarray;
       }
       validators[freeValidatorIndex]=validator;
  }
View Full Code Here

                            ObjectFactory.findClassLoader(),
                            true));

        }
        // return first available validator           
        RevalidationHandler val = validators[freeValidatorIndex];
        validators[freeValidatorIndex--] = null;
        return val;
  }
View Full Code Here

       // REVISIT: implement support for DTD validators as well
       ++freeValidatorIndex;
       if (validators.length == freeValidatorIndex ){
            // resize size of the validators
            currentSize+=SIZE;
            RevalidationHandler newarray[] new RevalidationHandler[currentSize];
            System.arraycopy(validators, 0, newarray, 0, validators.length);
            validators = newarray;
       }
       validators[freeValidatorIndex]=validator;
  }
View Full Code Here

            while (freeSchemaValidatorIndex >= 0) {
                // return first available validator
                SoftReference ref = schemaValidators[freeSchemaValidatorIndex];
                RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                if (holder != null && holder.handler != null) {
                    RevalidationHandler val = holder.handler;
                    holder.handler = null;
                    --freeSchemaValidatorIndex;
                    return val;
                }
                schemaValidators[freeSchemaValidatorIndex--] = null;
            }
            return (RevalidationHandler) (ObjectFactory
                    .newInstance(
                        "org.apache.xerces.impl.xs.XMLSchemaValidator",
                        ObjectFactory.findClassLoader(),
                        true));
        }
        else if(schemaType == XMLGrammarDescription.XML_DTD) {
            // return an instance of XML11DTDValidator
            if ("1.1".equals(xmlVersion)) {
                while (freeXML11DTDValidatorIndex >= 0) {
                    // return first available validator
                    SoftReference ref = xml11DTDValidators[freeXML11DTDValidatorIndex];
                    RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                    if (holder != null && holder.handler != null) {
                        RevalidationHandler val = holder.handler;
                        holder.handler = null;
                        --freeXML11DTDValidatorIndex;
                        return val;
                    }
                    xml11DTDValidators[freeXML11DTDValidatorIndex--] = null;
                }
                return (RevalidationHandler) (ObjectFactory
                        .newInstance(
                                "org.apache.xerces.impl.dtd.XML11DTDValidator",
                                ObjectFactory.findClassLoader(),
                                true));
            }
            // return an instance of XMLDTDValidator
            else {
                while (freeXML10DTDValidatorIndex >= 0) {
                    // return first available validator
                    SoftReference ref = xml10DTDValidators[freeXML10DTDValidatorIndex];
                    RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                    if (holder != null && holder.handler != null) {
                        RevalidationHandler val = holder.handler;
                        holder.handler = null;
                        --freeXML10DTDValidatorIndex;
                        return val;
                    }
                    xml10DTDValidators[freeXML10DTDValidatorIndex--] = null;
View Full Code Here

            while (freeSchemaValidatorIndex >= 0) {
                // return first available validator
                SoftReference ref = schemaValidators[freeSchemaValidatorIndex];
                RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                if (holder != null && holder.handler != null) {
                    RevalidationHandler val = holder.handler;
                    holder.handler = null;
                    --freeSchemaValidatorIndex;
                    return val;
                }
                schemaValidators[freeSchemaValidatorIndex--] = null;
            }
            return (RevalidationHandler) (ObjectFactory
                    .newInstance(
                        "org.apache.xerces.impl.xs.XMLSchemaValidator",
                        ObjectFactory.findClassLoader(),
                        true));
        }
        else if(schemaType == XMLGrammarDescription.XML_DTD) {
            // return an instance of XML11DTDValidator
            if ("1.1".equals(xmlVersion)) {
                while (freeXML11DTDValidatorIndex >= 0) {
                    // return first available validator
                    SoftReference ref = xml11DTDValidators[freeXML11DTDValidatorIndex];
                    RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                    if (holder != null && holder.handler != null) {
                        RevalidationHandler val = holder.handler;
                        holder.handler = null;
                        --freeXML11DTDValidatorIndex;
                        return val;
                    }
                    xml11DTDValidators[freeXML11DTDValidatorIndex--] = null;
                }
                return (RevalidationHandler) (ObjectFactory
                        .newInstance(
                                "org.apache.xerces.impl.dtd.XML11DTDValidator",
                                ObjectFactory.findClassLoader(),
                                true));
            }
            // return an instance of XMLDTDValidator
            else {
                while (freeXML10DTDValidatorIndex >= 0) {
                    // return first available validator
                    SoftReference ref = xml10DTDValidators[freeXML10DTDValidatorIndex];
                    RevalidationHandlerHolder holder = (RevalidationHandlerHolder) ref.get();
                    if (holder != null && holder.handler != null) {
                        RevalidationHandler val = holder.handler;
                        holder.handler = null;
                        --freeXML10DTDValidatorIndex;
                        return val;
                    }
                    xml10DTDValidators[freeXML10DTDValidatorIndex--] = null;
View Full Code Here

TOP

Related Classes of org.apache.xerces.impl.RevalidationHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.