Package com.caucho.config

Examples of com.caucho.config.Config


    new Printer(args);
  }
 
  Printer(String []args)
  {
    Config config = new Config();
    config.setEL(false);

    if (args.length == 0) {
      System.out.println("usage: " + Printer.class.getName() + " <book.xml>");
      System.exit(1);
    }
   
    parseArgs(args);

    Path xtpFile = Vfs.lookup(_fileName);
    Book book = new Book();

    try {
      config.configure(book, xtpFile);

      OutputStreamWriter osw = new OutputStreamWriter(System.out);
      PrintWriter out = new PrintWriter(osw);

      if (_isNew) {
View Full Code Here


    try {
      is = persistenceXml.openRead();

      ConfigPersistence persistence = new ConfigPersistence(root);

      new Config().configure(persistence, is,
          "com/caucho/amber/cfg/persistence-31.rnc");

      for (ConfigPersistenceUnit unitConfig : persistence.getUnitList()) {
        PersistenceUnitManager pUnit
          = createPersistenceUnit(unitConfig.getName(),
View Full Code Here

        InputStream is = path.lookup(name).openRead();
        try {
          ConnectorConfig conn = new ConnectorConfig();

          new Config().configure(conn, is, "com/caucho/jca/jca.rnc");

          _connList.add(conn);
        } finally {
          is.close();
        }
View Full Code Here

    JarPath jar = JarPath.create(jarPath);

    try {
      MavenProject project = new MavenProject();

      new Config().configure(project, jar.lookup(key));

      Artifact artifact = project.toArtifact(jarPath);

      return artifact;
    } catch (IOException e) {
View Full Code Here

    if (systemConf != null) {
      try {
        Path path = Vfs.lookup(systemConf);

        Config config = new Config();

        config.configure(this, path, getSchema());
      }
      catch (Exception ex) {
        ex.printStackTrace();

        throw new RuntimeException(ex.toString());
View Full Code Here

 
  public void configureFile(Path resinConf)
  {
    BootResinConfig bootResin = _bootResinConfig;
   
    Config config = new Config();
    // server/10hc
    // config.setResinInclude(true);

    config.configure(bootResin, resinConf, bootResin.getSchema());
  }
View Full Code Here

        throw new ConfigException(L.l("missing ra.xml for rar {0}.  .rar files require a META-INF/ra.xml file.",
                                      _rarPath));

      _config = new ConnectorConfig();

      new Config().configure(_config, raXml, "com/caucho/jca/jca.rnc");
    } catch (ConfigException e) {
      throw e;
    } catch (Exception e) {
      throw ConfigException.create(e);
    }
View Full Code Here

        || _webApp.getJsp().isValidateTaglibSchema()) {
      schema = getSchema();
    }

    try {
      Config config = new Config();
      config.setEL(false);
      config.configure(taglib, is, schema);
    } catch (ConfigException e) {
      log.warning(e.toString());
      log.log(Level.FINER, e.toString(), e);

      taglib.setConfigException(e);
View Full Code Here

    try {
      Enumeration<URL> fragments
        = _classLoader.getResources("META-INF/web-fragment.xml");

      Config config = new Config();
      config.setEL(_servletAllowEL);

      if (log.isLoggable(Level.FINER) && fragments.hasMoreElements())
        log.finer(L.l("{0} loading web-fragments", this));

      while (fragments.hasMoreElements()) {
        URL url = fragments.nextElement();

        if (log.isLoggable(Level.FINER)) {
          log.log(Level.FINER,
            L.l("Loading web-fragment '{0}:{1}'.", this, url));
        }

        WebAppFragmentConfig fragmentConfig = new WebAppFragmentConfig();
        config.configure(fragmentConfig, Vfs.lookup(url.toString()));

        _webFragments.add(fragmentConfig);
      }
    } catch (IOException e) {
      if (log.isLoggable(Level.FINE))
View Full Code Here

      // jsp/10h4
      taglib.setJspVersion("2.0");
     
      if (implicitTld.canRead()) {
        Config config = new Config();
        ImplicitTld tldTaglib = new ImplicitTld();

        config.configure(tldTaglib, implicitTld);

        if (tldTaglib.getJspVersion() != null
            && tldTaglib.getJspVersion().compareTo("2.0") < 0)
          throw new ConfigException(L.l("'{0}' must have a jsp-version 2.0 or greater",
                                        implicitTld));
View Full Code Here

TOP

Related Classes of com.caucho.config.Config

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.