Created
August 31, 2010 14:21
-
-
Save ALRubinger/559090 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
boolean isEjb3ComponentDeployment(final DeploymentUnit unit) | |
{ | |
// Obtain the Merged Metadata | |
final JBossEnterpriseBeanMetaData ejb = unit.getAttachment(JBossEnterpriseBeanMetaData.class); | |
// If metadata's not present as an attachment, return | |
if (ejb == null) | |
{ | |
log.warn("ALR - NO JBEBMD attachment"); | |
return false; | |
} | |
// If this is not an EJB3 Deployment, return | |
if (ejb.getJBossMetaData().isEJB3x()) | |
{ | |
log.warn("ALR - NOT EJB3x"); | |
return false; | |
} | |
// Meets conditions | |
log.warn("ALR - MEETS CONDITIONS"); | |
return true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment