}
}
protected RARDeploymentMetaData mergeMetaData(VFSDeploymentUnit unit, Map<Class<?>, List<Object>> metadata) throws Exception
{
RARDeploymentMetaData deployment = new RARDeploymentMetaData();
ConnectorMetaData cmd = getInstance(metadata, ConnectorMetaData.class);
if (cmd != null)
deployment.setConnectorMetaData(cmd);
JBossRAMetaData jrmd = getInstance(metadata, JBossRAMetaData.class);
if (jrmd != null)
deployment.setRaXmlMetaData(jrmd);
VFSDeploymentUnit parent = unit.getParent();
String name = unit.getSimpleName();
if (parent != null)
name = parent.getSimpleName() + "#" + name;
VirtualFile file = unit.getMetaDataFile(jeeSpecRarDD);
deployment.getConnectorMetaData().setURL(file.toURL());
metaDataRepository.addConnectorMetaData(name, deployment.getConnectorMetaData());
return deployment;
}