Author: scabanovich
Date: 2012-05-25 15:23:06 -0400 (Fri, 25 May 2012)
New Revision: 41438
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/META-INF/MANIFEST.MF
trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/src/org/jboss/tools/cdi/deltaspike/core/DeltaspikeSecurityExtension.java
Log:
JBIDE-11552
https://issues.jboss.org/browse/JBIDE-11552
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/META-INF/MANIFEST.MF
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/META-INF/MANIFEST.MF 2012-05-25
19:09:56 UTC (rev 41437)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/META-INF/MANIFEST.MF 2012-05-25
19:23:06 UTC (rev 41438)
@@ -20,5 +20,6 @@
org.eclipse.jdt.core;bundle-version="3.7.0"
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
-Export-Package: org.jboss.tools.cdi.deltaspike.core
+Export-Package: org.jboss.tools.cdi.deltaspike.core,
+ org.jboss.tools.cdi.deltaspike.core.validation
Bundle-Vendor: JBoss by Red Hat
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/src/org/jboss/tools/cdi/deltaspike/core/DeltaspikeSecurityExtension.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/src/org/jboss/tools/cdi/deltaspike/core/DeltaspikeSecurityExtension.java 2012-05-25
19:09:56 UTC (rev 41437)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.deltaspike.core/src/org/jboss/tools/cdi/deltaspike/core/DeltaspikeSecurityExtension.java 2012-05-25
19:23:06 UTC (rev 41438)
@@ -27,7 +27,6 @@
import org.jboss.tools.cdi.core.IRootDefinitionContext;
import org.jboss.tools.cdi.core.IStereotypeDeclaration;
import org.jboss.tools.cdi.core.extension.ICDIExtension;
-import org.jboss.tools.cdi.core.extension.IDefinitionContextExtension;
import org.jboss.tools.cdi.core.extension.feature.IBuildParticipantFeature;
import org.jboss.tools.cdi.core.extension.feature.IProcessAnnotatedMemberFeature;
import org.jboss.tools.cdi.core.extension.feature.IProcessAnnotatedTypeFeature;
@@ -61,7 +60,7 @@
}
@Override
- public IDefinitionContextExtension getContext() {
+ public DeltaspikeSecurityDefinitionContext getContext() {
return context;
}
@@ -97,7 +96,7 @@
contextCopy.allAuthorizerMethods.getAuthorizerMembers().add(authorizer);
List<SecurityBindingDeclaration> ds =
findAnnotationAnnotatedWithSecurityBindingType(memberDefinition,
contextCopy.getRootContext());
for (SecurityBindingDeclaration d: ds) {
- DeltaspikeSecurityBindingConfiguration c =
((DeltaspikeSecurityDefinitionContext)this.context.getWorkingCopy()).getConfiguration(d.getBinding().getTypeName());
+ DeltaspikeSecurityBindingConfiguration c =
contextCopy.getConfiguration(d.getBinding().getTypeName());
authorizer.addBinding(d, c);
c.getAuthorizerMembers().add(authorizer);
addToDependencies(c, authorizer.getMethod(), context);
@@ -300,8 +299,7 @@
public static Set<DeltaspikeAuthorityMethod>
collectAuthorizerMethods(Set<DeltaspikeSecurityExtension> parents, String
securityBindingTypeName) {
Set<DeltaspikeAuthorityMethod> result = new
HashSet<DeltaspikeAuthorityMethod>();
for (DeltaspikeSecurityExtension ext: parents) {
- DeltaspikeSecurityDefinitionContext context =
(DeltaspikeSecurityDefinitionContext)ext.getContext();
- DeltaspikeSecurityBindingConfiguration c =
context.getConfiguration(securityBindingTypeName);
+ DeltaspikeSecurityBindingConfiguration c =
ext.getContext().getConfiguration(securityBindingTypeName);
if(c != null) {
result.addAll(c.getAuthorizerMembers());
}