Examples of XMLGrammarDescription


Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

     *
     * @param grammar The Grammar.
     */
    public void putGrammar(Grammar grammar) {
        synchronized (fGrammars) {
            XMLGrammarDescription desc = grammar.getGrammarDescription();
            int hash = hashCode(desc);
            int index = (hash & 0x7FFFFFFF) % fGrammars.length;
            for (Entry entry = fGrammars[index]; entry != null; entry = entry.next) {
                if (entry.hash == hash && equals(entry.desc, desc)) {
                    entry.grammar = grammar;
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

     */
    public void putGrammar(Grammar grammar) {
        if (!fPoolIsLocked) {
            synchronized (fGrammars) {
                clean();
                XMLGrammarDescription desc = grammar.getGrammarDescription();
                int hash = hashCode(desc);
                int index = (hash & 0x7FFFFFFF) % fGrammars.length;
                for (Entry entry = fGrammars[index]; entry != null; entry = entry.next) {
                    if (entry.hash == hash && equals(entry.desc, desc)) {
                        if (entry.grammar.get() != grammar) {
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

    } // resolveEntity(String,String,String):XMLInputSource
   
    /** Determines the type of resource being resolved **/
    private String getType(XMLResourceIdentifier resourceIdentifier) {
        if (resourceIdentifier instanceof XMLGrammarDescription) {
            XMLGrammarDescription desc = (XMLGrammarDescription) resourceIdentifier;
            if (XMLGrammarDescription.XML_SCHEMA.equals(desc.getGrammarType())) {
                return XSD_TYPE;
            }
        }
        return XML_TYPE;
    } // getType(XMLResourceIdentifier):String
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

     * @param grammar The Grammar.
     */
    public void putGrammar(Grammar grammar) {
        if(!fPoolIsLocked) {
            synchronized (fGrammars) {
                XMLGrammarDescription desc = grammar.getGrammarDescription();
                int hash = hashCode(desc);
                int index = (hash & 0x7FFFFFFF) % fGrammars.length;
                for (Entry entry = fGrammars[index]; entry != null; entry = entry.next) {
                    if (entry.hash == hash && equals(entry.desc, desc)) {
                        entry.grammar = grammar;
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

  {
    if (!this.fPoolIsLocked)
      synchronized (this.fGrammars)
      {
        clean();
        XMLGrammarDescription localXMLGrammarDescription = paramGrammar.getGrammarDescription();
        int i = hashCode(localXMLGrammarDescription);
        int j = (i & 0x7FFFFFFF) % this.fGrammars.length;
        for (Entry localEntry1 = this.fGrammars[j]; localEntry1 != null; localEntry1 = localEntry1.next)
        {
          if ((localEntry1.hash != i) || (!equals(localEntry1.desc, localXMLGrammarDescription)))
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

    } // resolveEntity(String,String,String):XMLInputSource
   
    /** Determines the type of resource being resolved **/
    private String getType(XMLResourceIdentifier resourceIdentifier) {
        if (resourceIdentifier instanceof XMLGrammarDescription) {
            XMLGrammarDescription desc = (XMLGrammarDescription) resourceIdentifier;
            if (XMLGrammarDescription.XML_SCHEMA.equals(desc.getGrammarType())) {
                return XSD_TYPE;
            }
        }
        return XML_TYPE;
    } // getType(XMLResourceIdentifier):String
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

  private String getType(XMLResourceIdentifier paramXMLResourceIdentifier)
  {
    if ((paramXMLResourceIdentifier instanceof XMLGrammarDescription))
    {
      XMLGrammarDescription localXMLGrammarDescription = (XMLGrammarDescription)paramXMLResourceIdentifier;
      if ("http://www.w3.org/2001/XMLSchema".equals(localXMLGrammarDescription.getGrammarType()))
        return "http://www.w3.org/2001/XMLSchema";
    }
    return "http://www.w3.org/TR/REC-xml";
  }
View Full Code Here

Examples of org.apache.xerces.xni.grammars.XMLGrammarDescription

  public void putGrammar(Grammar paramGrammar)
  {
    if (!this.fPoolIsLocked)
      synchronized (this.fGrammars)
      {
        XMLGrammarDescription localXMLGrammarDescription = paramGrammar.getGrammarDescription();
        int i = hashCode(localXMLGrammarDescription);
        int j = (i & 0x7FFFFFFF) % this.fGrammars.length;
        for (Entry localEntry1 = this.fGrammars[j]; localEntry1 != null; localEntry1 = localEntry1.next)
        {
          if ((localEntry1.hash != i) || (!equals(localEntry1.desc, localXMLGrammarDescription)))
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.