Package org.jboss.deployers.spi.structure

Examples of org.jboss.deployers.spi.structure.StructureMetaData


/*  58 */     return result;
/*     */   }
/*     */
/*     */   public ContextInfo addContext(PredeterminedManagedObjectAttachments context, String path, List<ClassPathEntry> classPath)
/*     */   {
/*  72 */     StructureMetaData structure = assureStructure(context);
/*  73 */     ContextInfo result = StructureMetaDataFactory.createContextInfo(path, classPath);
/*  74 */     structure.addContext(result);
/*  75 */     return result;
/*     */   }
View Full Code Here


/*  75 */     return result;
/*     */   }
/*     */
/*     */   public ContextInfo addContext(PredeterminedManagedObjectAttachments context, String path, String metaDataPath, List<ClassPathEntry> classPath)
/*     */   {
/*  90 */     StructureMetaData structure = assureStructure(context);
/*  91 */     ContextInfo result = StructureMetaDataFactory.createContextInfo(path, metaDataPath, classPath);
/*  92 */     structure.addContext(result);
/*  93 */     return result;
/*     */   }
View Full Code Here

/*  93 */     return result;
/*     */   }
/*     */
/*     */   public ContextInfo addContext(PredeterminedManagedObjectAttachments context, String path, List<String> metaDataPath, List<ClassPathEntry> classPath)
/*     */   {
/* 108 */     StructureMetaData structure = assureStructure(context);
/* 109 */     ContextInfo result = StructureMetaDataFactory.createContextInfo(path, metaDataPath, classPath);
/* 110 */     structure.addContext(result);
/* 111 */     return result;
/*     */   }
View Full Code Here

/*     */     else
/*     */     {
/* 196 */       mutable = (MutableAttachments)attachments;
/*     */     }
/*     */
/* 199 */     StructureMetaData structure = (StructureMetaData)mutable.getAttachment(StructureMetaData.class);
/*     */
/* 201 */     if (structure == null)
/*     */     {
/* 203 */       structure = StructureMetaDataFactory.createStructureMetaData();
/* 204 */       mutable.addAttachment(StructureMetaData.class, structure);
View Full Code Here

   {
      StructureContext parentContext = context.getParentContext();
      if (parentContext == null)
         return false;

      StructureMetaData smd = parentContext.getMetaData();
      ContextInfo info = smd.getContext("");
      List<MetaDataEntry> metadataPaths = info.getMetaDataPath();
      if (metadataPaths != null && metadataPaths.isEmpty() == false)
      {
         String relativePath = AbstractStructureDeployer.getRelativePath(context.getParent(), context.getFile());
         for (MetaDataEntry entry : metadataPaths)
View Full Code Here

      log.debugf("Removed structure deployer %1s", deployer);
   }
  
   public boolean determineStructure(VirtualFile file, StructureContext parentContext) throws DeploymentException
   {
      StructureMetaData structure = StructureMetaDataFactory.createStructureMetaData();
      StructureContext context = new StructureContext(file, structure, parentContext);
      boolean result = doDetermineStructure(context);
      if (result)
      {
         String relativePath = AbstractStructureDeployer.getRelativePath(context.getParent(), file);
        
         // Something said it recognised it
         ContextInfo recognised = structure.getContext("");
         if (recognised == null)
            throw new IllegalStateException("Something recognised the deployment, but there is no context? " + file);
        
         // Create the context in the parent structure
         ContextInfo parentContextInfo;
         List<MetaDataEntry> metaDataPath = recognised.getMetaDataPath();
         if (metaDataPath == null || metaDataPath.isEmpty())
            parentContextInfo = StructureMetaDataFactory.createContextInfo(relativePath, recognised.getClassPath());
         else
            parentContextInfo = StructureMetaDataFactory.createContextInfo(recognised.getClassPath(), metaDataPath, relativePath);

         // copy the modification type information
         parentContextInfo.setModificationType(recognised.getModificationType());
         StructureMetaData structureMetaData = parentContext.getMetaData();
         structureMetaData.addContext(parentContextInfo);
         MutableAttachments attachments = (MutableAttachments) parentContextInfo.getPredeterminedManagedObjects();
         attachments.addAttachment(StructureMetaData.class, structure);
      }
      return result;
   }
View Full Code Here

    * @param structureContext the context
    * @throws IOException if errors occur during mounting
    */
   protected void mountChildren(StructureContext structureContext) throws IOException
   {
      final StructureMetaData structureMetaData = structureContext.getMetaData();
      final VirtualFile structureRoot = structureContext.getRoot();
      for(ContextInfo contextInfo : structureMetaData.getContexts())
      {
         final String contextPath = contextInfo.getPath();
         if(hasValidSuffix(contextPath))
         {
            final VirtualFile child = structureRoot.getChild(contextPath);
View Full Code Here

      }
   }

   protected boolean hasStructureBeenModifed(VirtualFile root, VFSDeploymentContext deploymentContext) throws IOException
   {
      StructureMetaData structureMetaData = deploymentContext.getTransientManagedObjects().getAttachment(StructureMetaData.class);
      return hasStructureBeenModified(root, structureMetaData, null);
   }
View Full Code Here

               }
            }
         }
         if ("".equals(path) == false)
         {
            StructureMetaData structureMetaData = contextInfo.getPredeterminedManagedObjects().getAttachment(StructureMetaData.class);
            return hasStructureBeenModified(contextRoot, structureMetaData, CURRENT_PATH);
         }
      }
      return false;
   }
View Full Code Here

      StructureBuilder builder = getStructureBuilder();
      if (builder == null)
         throw new IllegalStateException("No structure builder has been configured");
     
      Attachments attachments = deployment.getPredeterminedManagedObjects();
      StructureMetaData structureMetaData = attachments.getAttachment(StructureMetaData.class);
      if (structureMetaData == null)
      {
         structureMetaData = StructureMetaDataFactory.createStructureMetaData();
         try
         {
View Full Code Here

TOP

Related Classes of org.jboss.deployers.spi.structure.StructureMetaData

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.