org.jboss.deployers.vfs.spi.deployer
Class JBossExtensionDeployer<U,V,T>

java.lang.Object
  extended by org.jboss.deployers.spi.deployer.helpers.AbstractDeployer
      extended by org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployer
          extended by org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput<T>
              extended by org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer<T>
                  extended by org.jboss.deployers.vfs.spi.deployer.MultipleVFSParsingDeployer<T>
                      extended by org.jboss.deployers.vfs.spi.deployer.MultipleJBossXBDeployer<T>
                          extended by org.jboss.deployers.vfs.spi.deployer.MultipleSchemaResolverDeployer<T>
                              extended by org.jboss.deployers.vfs.spi.deployer.JBossExtensionDeployer<U,V,T>
Type Parameters:
U - the spec type
V - the jboss type
T - the expected type
All Implemented Interfaces:
Deployer, JarExtensionProvider, Ordered, FileMatcher

public abstract class JBossExtensionDeployer<U,V,T>
extends MultipleSchemaResolverDeployer<T>

JBossExtensionDeployer.

Author:
Ales Justin

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.jboss.deployers.spi.Ordered
Ordered.OrderedComparator
 
Field Summary
 
Fields inherited from class org.jboss.deployers.spi.deployer.helpers.AbstractDeployer
log
 
Fields inherited from interface org.jboss.deployers.spi.Ordered
COMPARATOR
 
Constructor Summary
JBossExtensionDeployer(Class<T> output, String specName, Class<U> specClass, String jbossName, Class<V> jbossClass)
           
JBossExtensionDeployer(Class<T> output, String specName, Class<U> specClass, String jbossName, Class<V> jbossClass, Set<Class<?>> excluded)
           
 
Method Summary
protected  T mergeMetaData(VFSDeploymentUnit unit, Map<Class<?>,List<Object>> metadata)
          Merge metadatas into single piece of metatdata
protected  T mergeMetaData(VFSDeploymentUnit unit, T root, Map<Class<?>,List<Object>> metadata, Set<String> missingFiles)
          Merge metadatas into single piece of metatdata
protected abstract  T mergeMetaData(VFSDeploymentUnit unit, U spec, V jboss)
          Merge spec and extension.
protected static Map<String,Class<?>> toMap(String specName, Class<?> specClass, String jbossName, Class<?> jbossClass)
           
 
Methods inherited from class org.jboss.deployers.vfs.spi.deployer.MultipleSchemaResolverDeployer
create, destroy, parse, registerMetaDataClass
 
Methods inherited from class org.jboss.deployers.vfs.spi.deployer.MultipleJBossXBDeployer
getFeatures, getHelper, isUseSchemaValidation, isUseValidation, setFeatures, setUseSchemaValidation, setUseValidation, start
 
Methods inherited from class org.jboss.deployers.vfs.spi.deployer.MultipleVFSParsingDeployer
getInstance, getMappings, getSuffixClass, matchFileToClass, matchFileToClass, matchFileToClass, mergeFiles, parse
 
Methods inherited from class org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer
accepts, accepts, allowsMultipleFiles, getAltMappings, getMetadataFile, handleMultipleFiles, init, isDeployable, openStreamAndValidate, parse, parse, parse, parse, parseAndInit, setAllowMultipleFiles
 
Methods inherited from class org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput
allowsReparse, createMetaData, createMetaData, createMetaData, createMetaData, deploy, getAttachmentKey, getJarExtension, getMetaData, getName, getNames, getOutput, getSuffix, isBuildManagedObject, isIncludeDeploymentFile, setAttachmentKey, setBuildManagedObject, setIncludeDeploymentFile, setJarExtension, setName, setNames, setSuffix
 
Methods inherited from class org.jboss.deployers.spi.deployer.helpers.AbstractDeployer
addInput, addInput, addOutput, addOutput, getInput, getInputs, getOutputs, getRelativeOrder, getStage, isAllInputs, isComponentsOnly, isParentFirst, isTopLevelOnly, isWantComponents, setAllInputs, setComponentsOnly, setInput, setInputs, setInputs, setInputs, setOutput, setOutputs, setOutputs, setOutputs, setParentFirst, setRelativeOrder, setStage, setTopLevelOnly, setWantComponents, undeploy
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JBossExtensionDeployer

public JBossExtensionDeployer(Class<T> output,
                              String specName,
                              Class<U> specClass,
                              String jbossName,
                              Class<V> jbossClass)

JBossExtensionDeployer

public JBossExtensionDeployer(Class<T> output,
                              String specName,
                              Class<U> specClass,
                              String jbossName,
                              Class<V> jbossClass,
                              Set<Class<?>> excluded)
Method Detail

toMap

protected static Map<String,Class<?>> toMap(String specName,
                                            Class<?> specClass,
                                            String jbossName,
                                            Class<?> jbossClass)

mergeMetaData

protected T mergeMetaData(VFSDeploymentUnit unit,
                          T root,
                          Map<Class<?>,List<Object>> metadata,
                          Set<String> missingFiles)
                   throws Exception
Description copied from class: MultipleVFSParsingDeployer
Merge metadatas into single piece of metatdata

Overrides:
mergeMetaData in class MultipleVFSParsingDeployer<T>
Parameters:
unit - the unit
root - possibly null pre-existing root
metadata - the metadatas
missingFiles - file names that are missing matching file
Returns:
merged metadata
Throws:
Exception - for any error

mergeMetaData

protected T mergeMetaData(VFSDeploymentUnit unit,
                          Map<Class<?>,List<Object>> metadata)
                   throws Exception
Description copied from class: MultipleVFSParsingDeployer
Merge metadatas into single piece of metatdata

Specified by:
mergeMetaData in class MultipleVFSParsingDeployer<T>
Parameters:
unit - the unit
metadata - the metadatas
Returns:
merged metadata
Throws:
Exception - for any error

mergeMetaData

protected abstract T mergeMetaData(VFSDeploymentUnit unit,
                                   U spec,
                                   V jboss)
                            throws Exception
Merge spec and extension.

Parameters:
unit - deployment unit
spec - the spec metadata instance
jboss - the jboss metadata instance
Returns:
merged metadata
Throws:
Exception - for any error


Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.