Examples of create()


Examples of org.apache.catalina.core.StandardContext.create()

            wsfsWrapper.setServletClass(servletClass);
            context.addChild(wsfsWrapper);
            context.addServletMapping(urlPattern, servletName);

            host.addChild(context);
            context.create();
        } catch (Exception e) {
            throw MESSAGES.createContextPhaseFailed(e);
        }
        try {
            context.start();

Examples of org.apache.catalina.startup.Catalina.create()

      // Set the resulting Server to the Catalina instance
      catalina.setServer(catalinaServer);

      // Start Tomcat
      catalina.create();
      catalinaServer.initialize();
      catalina.start();

      // Set up the authenticators in JNDI such that they can be configured for web apps
      InitialContext ic = new InitialContext();

Examples of org.apache.cloudstack.engine.subsystem.api.storage.DataStore.create()

         * templateStoreDao.persist(templateStore);
         */

        DataStore store = this.dataStoreMgr.getDataStore(imageStore.getId(), DataStoreRole.Image);
        TemplateInfo template = templateFactory.getTemplate(image.getId(), DataStoreRole.Image);
        DataObject templateOnStore = store.create(template);
        TemplateObjectTO to = new TemplateObjectTO();
        to.setPath(this.getImageInstallPath());
        CopyCmdAnswer answer = new CopyCmdAnswer(to);
        templateOnStore.processEvent(Event.CreateOnlyRequested);
        templateOnStore.processEvent(Event.OperationSuccessed, answer);

Examples of org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStore.create()

    @Override
    public AsyncCallFuture<VolumeApiResult> createManagedStorageAndVolumeFromTemplateAsync(VolumeInfo volumeInfo, long destDataStoreId,
            TemplateInfo srcTemplateInfo, long destHostId) {
        PrimaryDataStore destPrimaryDataStore = dataStoreMgr.getPrimaryDataStore(destDataStoreId);
        TemplateInfo destTemplateInfo = (TemplateInfo)destPrimaryDataStore.create(srcTemplateInfo);
        Host destHost = _hostDao.findById(destHostId);

        if (destHost == null) {
            throw new CloudRuntimeException("Destinatin host should not be null.");
        }

Examples of org.apache.cloudstack.storage.image.datastore.ImageStoreEntity.create()

            if (!imageStore.getProtocol().equalsIgnoreCase("nfs")) {
                s_logger.debug("can't find a nfs image store");
                return null;
            }

            DataObject objOnImageStore = imageStore.create(srcData);
            objOnImageStore.processEvent(Event.CreateOnlyRequested);

            Answer answer = this.copyObject(srcData, objOnImageStore);
            if (answer == null || !answer.getResult()) {
                if (answer != null) {

Examples of org.apache.cloudstack.utils.qemu.QemuImg.create()

                    Script.runSimpleBashScript("cp -p -r " + template.getPath() + "/* " + disk.getPath());
                } else if (format == PhysicalDiskFormat.QCOW2) {
                    QemuImgFile backingFile = new QemuImgFile(template.getPath(), template.getFormat());
                    QemuImgFile destFile = new QemuImgFile(disk.getPath());
                    QemuImg qemu = new QemuImg();
                    qemu.create(destFile, backingFile);
                } else if (format == PhysicalDiskFormat.RAW) {
                    QemuImgFile sourceFile = new QemuImgFile(template.getPath(), template.getFormat());
                    QemuImgFile destFile = new QemuImgFile(disk.getPath(), PhysicalDiskFormat.RAW);
                    QemuImg qemu = new QemuImg();
                    qemu.convert(sourceFile, destFile);

Examples of org.apache.commons.cli.OptionBuilder.create()

    protected void addOptionWithParam(String longOption, String shortOption, String argName, String desc) {
        OptionBuilder optionBuilder = OptionBuilder.hasArg().withArgName(argName);
        optionBuilder = optionBuilder.withLongOpt(longOption);
        optionBuilder = optionBuilder.withDescription(desc);
        Option option = optionBuilder.create(shortOption);
        options.addOption(option);
    }

}

Examples of org.apache.commons.cli2.builder.ArgumentBuilder.create()

                                    String defaultValue) {
    ArgumentBuilder argBuilder = new ArgumentBuilder().withName(name).withMinimum(1).withMaximum(1);
    if (defaultValue != null) {
      argBuilder = argBuilder.withDefault(defaultValue);
    }
    Argument arg = argBuilder.create();
    return new DefaultOptionBuilder().withLongName(name).withRequired(required).withShortName(shortName)
        .withArgument(arg).withDescription(description).create();
  }
 
  protected static Map<String,String> parseArguments(String[] args, Option... extraOpts) {

Examples of org.apache.commons.cli2.builder.DefaultOptionBuilder.create()

    DefaultOptionBuilder dob = builder.withShortName(shortName).withArgument(arg).withDescription(desc);

    if (longName != null) {
      dob = dob.withLongName(longName);
    }
    return dob.create();
  }

  private static void validatePermissions(CliSessionState ss, HiveConf conf, String perms) {
    perms = perms.trim();
    FsPermission fp = null;

Examples of org.apache.commons.cli2.builder.GroupBuilder.create()

    gBuilder.withOption(aBuilder.reset().withName(PROPERTIES).withDescription(
        "are configuration name-value pairs which override values. For example: wrapper.debug=true").withMinimum(0).withValidator(pValidator)
        .create());

    gBuilder.withMaximum(3);
    group = gBuilder.create();

  }

}
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.