Esempio n. 1
0
        protected internal virtual string[] getDeploymentDescriptorLocations(AbstractProcessApplication processApplication)
        {
            ProcessApplication annotation = processApplication.GetType().getAnnotation(typeof(ProcessApplication));

            if (annotation == null)
            {
                return(new string[] { ProcessApplication.DEFAULT_META_INF_PROCESSES_XML });
            }
            else
            {
                return(annotation.deploymentDescriptors());
            }
        }
Esempio n. 2
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
//ORIGINAL LINE: protected String[] getDeploymentDescriptors(org.jboss.as.server.deployment.DeploymentUnit deploymentUnit) throws org.jboss.as.server.deployment.DeploymentUnitProcessingException
        protected internal virtual string[] getDeploymentDescriptors(DeploymentUnit deploymentUnit)
        {
//JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final':
//ORIGINAL LINE: final org.jboss.as.ee.component.ComponentDescription processApplicationComponent = org.camunda.bpm.container.impl.jboss.deployment.marker.ProcessApplicationAttachments.getProcessApplicationComponent(deploymentUnit);
            ComponentDescription processApplicationComponent = ProcessApplicationAttachments.getProcessApplicationComponent(deploymentUnit);
//JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final':
//ORIGINAL LINE: final String paClassName = processApplicationComponent.getComponentClassName();
            string paClassName = processApplicationComponent.ComponentClassName;

            string[] deploymentDescriptorResourceNames = null;

            Module module = deploymentUnit.getAttachment(MODULE);

            Type paClass = null;

            try
            {
                paClass = (Type)module.ClassLoader.loadClass(paClassName);
            }
            catch (ClassNotFoundException)
            {
                throw new DeploymentUnitProcessingException("Unable to load process application class '" + paClassName + "'.");
            }

            ProcessApplication annotation = paClass.getAnnotation(typeof(ProcessApplication));

            if (annotation == null)
            {
                deploymentDescriptorResourceNames = new string[] { PROCESSES_XML };
            }
            else
            {
                deploymentDescriptorResourceNames = annotation.deploymentDescriptors();
            }
            return(deploymentDescriptorResourceNames);
        }