Package org.eclipse.core.resources

Examples of org.eclipse.core.resources.IFolder.create()


    WGARuntime runtime = _page.getRuntime();   
    if(runtime != null){
      try {
        IFolder folder = runtime.getDesignRoot().getFolder(new Path(_page.getDesignName()));
        if (!folder.exists()) {
          folder.create(false, true, new NullProgressMonitor());
          DesignTemplate template = _page.getTemplate();
          WGADesignFactory.createDesign(folder, folder.getName(), template);
         
          if (!_page.isCreateContentStore()) {
            _page.getRuntime().register(folder, false, null, null, null, template.getProperties());
View Full Code Here


  }

  public void registerExternalDesign(WGADesign wgaDesign) throws IOException, CoreException {
    IFolder designFolder = getDesignRoot().getFolder(new Path(wgaDesign.getName()));
    if (!designFolder.exists()) {
      designFolder.create(false, true, new NullProgressMonitor());
      createDirlink(wgaDesign, designFolder);
      getDesignRoot().refreshLocal(IResource.DEPTH_INFINITE, null);
    }
  }
View Full Code Here

  }

  public void registerExternalPlugin(WGADesign wgaDesign) throws IOException, CoreException {
    IFolder pluginFolder = getPluginRoot().getFolder(wgaDesign.getName());
    if (!pluginFolder.exists()) {
      pluginFolder.create(false, true, new NullProgressMonitor());
      createDirlink(wgaDesign, pluginFolder);
      getPluginRoot().refreshLocal(IResource.DEPTH_INFINITE, null);
    }
  }
View Full Code Here

  }
 
  public static IFolder createFolder(IContainer container, String name, IProgressMonitor monitor) throws CoreException {
    IFolder folder = container.getFolder(new Path(name));
    if (!folder.exists()) {
      folder.create(false, true, monitor);       
    }
    return folder;
  }
 
  public static void copyWithVariableSubstitution(File source, File target, Map<String,String> variables, String varPrefix, String varSuffix) throws IOException {
View Full Code Here

    IFolder container = getFileContainer("labels_" + language.toLowerCase());
    if (container == null) {
      container = getFileContainerRoot().getFolder(new Path("labels_" + language.toLowerCase()));
    }
    if (!container.exists()) {
      container.create(false, true, new NullProgressMonitor());
    }
    return container;
  }

  public static Properties loadLabel(IFile labelFile) {
View Full Code Here

    if (!labelFile.exists()) {
      try {
        if (!labelFile.getParent().exists()) {
          if (labelFile.getParent() instanceof IFolder) {
            IFolder parentFolder = (IFolder) labelFile.getParent();
            parentFolder.create(false, true, new NullProgressMonitor());
          }
        }
        ByteArrayInputStream byteStream = new ByteArrayInputStream("".getBytes());
        labelFile.create(byteStream, true, new NullProgressMonitor());
       
View Full Code Here

      String innerLayoutName = _layoutPage.getInnerLayoutName();
     
      WGADesignStructureHelper helper = new WGADesignStructureHelper(designRoot);
      IFolder html = helper.getTmlRoot().getFolder("html");
      if (!html.exists()) {
        html.create(false, true, new NullProgressMonitor());
      }
     
      IFile outerLayoutFile = html.getFile(new Path(outerLayoutName + ".tml"));
      InputStream outerLayoutTemplate = null;
      try {
View Full Code Here

        }
      }
     
      IFolder inner = html.getFolder("inner");
      if (!inner.exists()) {
        inner.create(false, true, new NullProgressMonitor());
      }
     
      IFile innerLayoutFile = inner.getFile(innerLayoutName + ".tml");
      InputStream innerLayoutTemplate = null;
      try {
View Full Code Here

        IFile moveToFile = _metaDataFilesToMove.get(moveFrom);
        try {
          if (moveToFile.getParent() instanceof IFolder) {
            IFolder folder = (IFolder) moveToFile.getParent();
            if (!folder.exists()) {
              folder.create(true,true, new NullProgressMonitor());
            }
            moveFrom.move(moveToFile.getFullPath(), true, new NullProgressMonitor());
          }         
        } catch (CoreException e) {
          Plugin.getDefault().logError("Unable to execute TMLMetadataMaintenance." , e);
View Full Code Here

                        IContainer container = project;
                        for (int j = 0; j < segmentCount; j++) {
                            IFolder folder = container.getFolder(new Path(
                                sourcePath.segment(j)));
                            if (!folder.exists()) {
                                folder.create(true, true, null);
                            }
                            container = folder;
                        }
                    }
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.