Package org.wikier.trioo.jtrioo.exceptions

Examples of org.wikier.trioo.jtrioo.exceptions.InvalidNamespaceException


    if (prefix != null && namespace != null) {
      if (namespace.endsWith("/") || namespace.endsWith("#")) {
        try {
          new URI(namespace);
        } catch (URISyntaxException e) {
          throw new InvalidNamespaceException("'" + namespace + "' is not a URI");
        }
        return mappings.put(prefix, namespace);
      } else {
        throw new InvalidNamespaceException("'" + namespace + "' is not a valid URI for a namespace");
      }
    } else {
      //FIXME: this implementation (HashBiMap) allows null keys and values, but we don't want them!
      throw new IllegalArgumentException("null parameters are not allowed");
    }
View Full Code Here

TOP

Related Classes of org.wikier.trioo.jtrioo.exceptions.InvalidNamespaceException

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.