Package org.jboss.forge.addon.resource

Examples of org.jboss.forge.addon.resource.DirectoryResource.mkdirs()


   public Result execute(UIExecutionContext context) throws Exception
   {
      DirectoryResource cloneFolder = targetDirectory.getValue();
      if (!cloneFolder.exists())
      {
         cloneFolder.mkdirs();
      }
      Git clone = null;
      try
      {
         clone = gitUtils.clone(cloneFolder, uri.getValue());
View Full Code Here


      JavaSourceFacet sourceFacet = getFaceted().getFacet(JavaSourceFacet.class);

      DirectoryResource entityRoot = sourceFacet.getBasePackageResource().getChildDirectory(DEFAULT_ENTITY_PACKAGE);
      if (!entityRoot.exists())
      {
         entityRoot.mkdirs();
      }

      return entityRoot;
   }
View Full Code Here

         // Install required facets
         WebResourcesFacet webFacet = facetFactory.install(project, WebResourcesFacet.class);
         DirectoryResource webRoot = webFacet.getWebRootDirectory();
         if (!webRoot.exists())
         {
            webRoot.mkdirs();
         }
      }
      return super.install();
   }
View Full Code Here

      JavaSourceFacet sourceFacet = getFaceted().getFacet(JavaSourceFacet.class);

      DirectoryResource entityRoot = sourceFacet.getBasePackageDirectory().getChildDirectory(DEFAULT_ENTITY_PACKAGE);
      if (!entityRoot.exists())
      {
         entityRoot.mkdirs();
      }

      return entityRoot;
   }
View Full Code Here

      {
         Project project = getFaceted();
         DirectoryResource webRoot = project.getFacet(WebResourcesFacet.class).getWebRootDirectory();
         if (!webRoot.exists())
         {
            webRoot.mkdirs();
         }
      }
      return super.install();
   }
View Full Code Here

   {
      Result result = Results.success("Project named '" + named.getValue() + "' has been created.");
      DirectoryResource directory = targetLocation.getValue();
      DirectoryResource targetDir = directory.getChildDirectory(named.getValue());

      if (targetDir.mkdirs() || overwrite.getValue())
      {
         ProjectType value = type.getValue();

         Project project = null;
         if (value != null)
View Full Code Here

   public Result execute(UIExecutionContext context) throws Exception
   {
      DirectoryResource cloneFolder = targetDirectory.getValue();
      if (!cloneFolder.exists())
      {
         cloneFolder.mkdirs();
      }
      Git clone = null;
      try
      {
         CloneCommand cloneCommand = Git.cloneRepository().setURI(uri.getValue())
View Full Code Here

            }
            else
            {
               DirectoryResource directory = resourceFactory.create(DirectoryResource.class,
                        new File(resource.getFullyQualifiedName()));
               directory.mkdirs();
            }
         }
      }

      return Results.success();
View Full Code Here

   {
      Result result = Results.success("New project has been created.");
      DirectoryResource directory = targetLocation.getValue();
      DirectoryResource targetDir = directory.getChildDirectory(named.getValue());

      if (targetDir.mkdirs() || overwrite.getValue())
      {
         ProjectType value = type.getValue();

         Project project = null;
         if (value != null)
View Full Code Here

            }
            else
            {
               DirectoryResource directory = resourceFactory.create(DirectoryResource.class,
                        new File(resource.getFullyQualifiedName()));
               directory.mkdirs();
            }
         }
      }

      return Results.success();
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.