[webbeans-commits] Webbeans SVN: r2895 - in ri/trunk: api/src/main/java/javax and 30 other directories.
webbeans-commits at lists.jboss.org
webbeans-commits at lists.jboss.org
Thu Jun 25 19:09:59 EDT 2009
Author: pete.muir at jboss.org
Date: 2009-06-25 19:09:58 -0400 (Thu, 25 Jun 2009)
New Revision: 2895
Added:
ri/trunk/api/src/main/java/javax/decorator/package-info.java
ri/trunk/api/src/main/java/javax/enterprise/context/BusyConversationException.java
ri/trunk/api/src/main/java/javax/enterprise/context/ContextException.java
ri/trunk/api/src/main/java/javax/enterprise/context/NonexistentConversationException.java
ri/trunk/api/src/main/java/javax/enterprise/event/
ri/trunk/api/src/main/java/javax/enterprise/event/TransactionPhase.java
ri/trunk/api/src/main/java/javax/enterprise/event/package-info.java
ri/trunk/api/src/main/java/javax/enterprise/inject/Policy.java
ri/trunk/api/src/main/java/javax/enterprise/inject/Specializes.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessAnnotatedType.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessBean.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessInjectionTarget.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessManagedBean.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProcessObserverMethod.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerField.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerMethod.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessSessionBean.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Producer.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/SessionBeanType.java
ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/
ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Model.java
ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Stereotype.java
ri/trunk/api/src/main/java/javax/interceptor/package-info.java
ri/trunk/core-api/src/main/java/org/jboss/webbeans/Realizes.java
Removed:
ri/trunk/api/src/main/java/javax/enterprise/inject/Model.java
ri/trunk/api/src/main/java/javax/enterprise/inject/Stereotype.java
ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Specializes.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ManagedBean.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProducerBean.java
ri/trunk/api/src/main/java/javax/event/
ri/trunk/api/src/main/java/javax/inject/Realizes.java
Modified:
ri/trunk/api/pom.xml
ri/trunk/api/src/main/java/javax/decorator/Decorator.java
ri/trunk/api/src/main/java/javax/enterprise/context/ContextNotActiveException.java
ri/trunk/api/src/main/java/javax/enterprise/context/Conversation.java
ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionCompletion.java
ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionFailure.java
ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionSuccess.java
ri/trunk/api/src/main/java/javax/enterprise/event/BeforeTransactionCompletion.java
ri/trunk/api/src/main/java/javax/enterprise/event/Event.java
ri/trunk/api/src/main/java/javax/enterprise/event/Notify.java
ri/trunk/api/src/main/java/javax/enterprise/event/Observer.java
ri/trunk/api/src/main/java/javax/enterprise/event/ObserverException.java
ri/trunk/api/src/main/java/javax/enterprise/event/Observes.java
ri/trunk/api/src/main/java/javax/enterprise/inject/Instance.java
ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/DeploymentType.java
ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Production.java
ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Standard.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterBeanDiscovery.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterDeploymentValidation.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AnnotatedField.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeanManager.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeBeanDiscovery.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Extension.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Interceptor.java
ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ObserverMethod.java
ri/trunk/api/src/main/java/javax/inject/Obtains.java
ri/trunk/api/src/main/java/javax/interceptor/Interceptor.java
ri/trunk/api/src/main/java/javax/interceptor/InterceptorBindingType.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanValidator.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/InstanceImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractClassBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/DisposalMethodBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/EnterpriseBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/ProducerMethodBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/standard/EventBean.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/AfterBeanDiscoveryImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/BeanDeployer.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/conversation/ConversationImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventManager.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventObserver.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/event/ObserverImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/event/TransactionalObserverImpl.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBAnnotated.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBMethod.java
ri/trunk/impl/src/main/java/org/jboss/webbeans/metadata/StereotypeModel.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/ActivitiesTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/Fox.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/Dusk.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/ELCurrentActivityTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/EventCurrentActivityTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InactiveScopeTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InjectedManagerCurrentActivityTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InstanceCurrentActivityTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/JndiManagerCurrentActivityTest.java
ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/NonNormalScopeTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserver.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesApplicationContext.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesRequestContext.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalOrderStereotype.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalStereotype.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/RequestScopedAnimalStereotype.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/annotatedItem/ClassAnnotatedItemTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/NormalScopedBean.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/SimpleEventTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/named/NamedBeanWithBindingTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerWithBindingTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/proxy/ProxyTest.java
ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/xml/beans/annotationtype/TestStereotype.java
Log:
Update API to 20090625, mark all old methods still required by TCK as @Deprecated, new methods in RI are throw new UnsupportedOperationException()
Modified: ri/trunk/api/pom.xml
===================================================================
--- ri/trunk/api/pom.xml 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/pom.xml 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,4 +1,5 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
@@ -9,15 +10,19 @@
<groupId>org.jboss.webbeans</groupId>
<artifactId>jsr299-api</artifactId>
- <version>1.0.0-SNAPSHOT</version>
+ <version>1.0.0-SNAPSHOT</version>
<packaging>jar</packaging>
<name>JSR-299 API</name>
<url>http://www.seamframework.org/WebBeans</url>
<dependencies>
- <dependency>
- <groupId>javax.el</groupId>
- <artifactId>el-api</artifactId>
- </dependency>
- </dependencies>
+ <dependency>
+ <groupId>javax.el</groupId>
+ <artifactId>el-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>ejb-api</artifactId>
+ </dependency>
+ </dependencies>
</project>
Modified: ri/trunk/api/src/main/java/javax/decorator/Decorator.java
===================================================================
--- ri/trunk/api/src/main/java/javax/decorator/Decorator.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/decorator/Decorator.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -24,7 +24,7 @@
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
/**
* Specifies that a class is a decorator.
Added: ri/trunk/api/src/main/java/javax/decorator/package-info.java
===================================================================
--- ri/trunk/api/src/main/java/javax/decorator/package-info.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/decorator/package-info.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,5 @@
+package javax.decorator;
+
+/**
+ * The package javax.decorator contains annotations relating to decorators.
+ */
Property changes on: ri/trunk/api/src/main/java/javax/decorator/package-info.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/context/BusyConversationException.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/context/BusyConversationException.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/context/BusyConversationException.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.context;
+
+/**
+ * The container ensures that a long-running conversation may be associated with
+ * at most one request at a time, by blocking or rejecting concurrent requests.
+ * If the container rejects a request, it must associate the request with a new
+ * transient conversation and throw an exception of type
+ * {@link BusyConversationException} from the restore view phase of the JSF
+ * lifecycle.
+ *
+ *
+ * @author Pete Muir
+ */
+
+public class BusyConversationException extends ContextException
+{
+
+ private static final long serialVersionUID = -3599813072560026919L;
+
+ public BusyConversationException()
+ {
+ super();
+ }
+
+ public BusyConversationException(String message)
+ {
+ super(message);
+ }
+
+ public BusyConversationException(Throwable cause)
+ {
+ super(cause);
+ }
+
+ public BusyConversationException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/context/BusyConversationException.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/context/ContextException.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/context/ContextException.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/context/ContextException.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.context;
+
+
+/**
+ * A ContextException is the base type for any context problem
+ *
+ * @author Pete Muir
+ * @author Shane Bryzak
+ */
+
+public class ContextException extends RuntimeException
+{
+
+ private static final long serialVersionUID = -3599813072560026919L;
+
+ public ContextException()
+ {
+ super();
+ }
+
+ public ContextException(String message)
+ {
+ super(message);
+ }
+
+ public ContextException(Throwable cause)
+ {
+ super(cause);
+ }
+
+ public ContextException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/context/ContextException.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: ri/trunk/api/src/main/java/javax/enterprise/context/ContextNotActiveException.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/context/ContextNotActiveException.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/context/ContextNotActiveException.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -19,17 +19,18 @@
/**
- * A ContextNotActiveException is thrown if at a particular point in the
- * execution of the program the scope is inactive with respect to the current
- * thread. When the scope is inactive, any invocation of the get() from the
+ * A {@link ContextNotActiveException} is thrown if at a particular point in the
+ * execution of the program the context is inactive with respect to the current
+ * thread. When the context is inactive, any invocation of the get() from the
* current thread upon the Context object for that scope results in a
* ContextNotActiveException.
*
+ *
* @author Pete Muir
* @author Shane Bryzak
*/
-public class ContextNotActiveException extends RuntimeException
+public class ContextNotActiveException extends ContextException
{
private static final long serialVersionUID = -3599813072560026919L;
Modified: ri/trunk/api/src/main/java/javax/enterprise/context/Conversation.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/context/Conversation.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/context/Conversation.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,62 +1,72 @@
/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package javax.enterprise.context;
/**
* Provides conversation management operations
*
* @author Pete Muir
- *
+ *
*/
-public interface Conversation
+public interface Conversation
{
-
+
/**
* Mark a transient conversation long running. The container will generate an
* id
+ *
+ * @throws IllegalStateException if the current conversation is marked long
+ * running
*/
public void begin();
-
+
/**
* Mark a transient conversation long running.
*
* @param id the id of the conversation
+ * @throws IllegalStateException if the current conversation is marked long
+ * running
+ * @throws IllegalArgumentException if a long running conversation with id
+ * already exists
*/
public void begin(String id);
-
+
/**
* Mark a long running conversation transient
+ *
+ * @throws IllegalStateException if the current conversation is marked
+ * transient
*/
public void end();
-
+
/**
* Determine if a conversation is long running or transient
*
* @return true if the conversation is long running
*/
public boolean isLongRunning();
-
+
/**
* Get the id associated with the current long running conversation
*
* @return the id of the current long running conversation
*/
public String getId();
-
+
/**
* Get the timeout for the current long running conversation.
*
@@ -66,11 +76,17 @@
* @return the current timeout in milliseconds
*/
public long getTimeout();
-
+
/**
* Set the timeout for the current long running conversation
*
* @param milliseconds the new timeout in milliseconds
*/
public void setTimeout(long milliseconds);
+
+ /**
+ * @return true if the conversation is marked transient, or false if it is
+ * marked long-running.
+ */
+ public boolean isTransient();
}
\ No newline at end of file
Added: ri/trunk/api/src/main/java/javax/enterprise/context/NonexistentConversationException.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/context/NonexistentConversationException.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/context/NonexistentConversationException.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.context;
+
+/**
+ * If the propagated conversation cannot be restored, the container must
+ * associate the request with a new transient conversation and throw an
+ * exception of type {@link NonexistentConversationException} from the
+ * restore view phase of the JSF lifecycle. The application may handle this
+ * exception using the JSF ExceptionHandler.
+ *
+ *
+ *
+ * @author Pete Muir
+ */
+
+public class NonexistentConversationException extends ContextException
+{
+
+ private static final long serialVersionUID = -3599813072560026919L;
+
+ public NonexistentConversationException()
+ {
+ super();
+ }
+
+ public NonexistentConversationException(String message)
+ {
+ super(message);
+ }
+
+ public NonexistentConversationException(Throwable cause)
+ {
+ super(cause);
+ }
+
+ public NonexistentConversationException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/context/NonexistentConversationException.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied: ri/trunk/api/src/main/java/javax/enterprise/event (from rev 2892, ri/trunk/api/src/main/java/javax/event)
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionCompletion.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/AfterTransactionCompletion.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionCompletion.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
@@ -31,6 +31,7 @@
*/
@Retention(RUNTIME)
@Target(PARAMETER)
+ at Deprecated
public @interface AfterTransactionCompletion
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionFailure.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/AfterTransactionFailure.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionFailure.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
@@ -31,6 +31,7 @@
*/
@Retention(RUNTIME)
@Target(PARAMETER)
+ at Deprecated
public @interface AfterTransactionFailure
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionSuccess.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/AfterTransactionSuccess.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/AfterTransactionSuccess.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
@@ -31,6 +31,7 @@
*/
@Retention(RUNTIME)
@Target(PARAMETER)
+ at Deprecated
public @interface AfterTransactionSuccess
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/BeforeTransactionCompletion.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/BeforeTransactionCompletion.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/BeforeTransactionCompletion.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
@@ -32,6 +32,7 @@
*/
@Retention(RUNTIME)
@Target(PARAMETER)
+ at Deprecated
public @interface BeforeTransactionCompletion
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/Event.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/Event.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/Event.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,10 +15,12 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import java.lang.annotation.Annotation;
+import javax.enterprise.inject.TypeLiteral;
+
/**
* An interface for firing events of a particular type, and registering
* observers for events of that type.
@@ -39,14 +41,30 @@
* @param event the event type
* @param bindings the event bindings
*/
+ @Deprecated
public void fire(T event, Annotation... bindings);
/**
+ * Fire an event
+ *
+ * @param event the event type
+ */
+ public void fire(T event);
+
+ public <U extends T> Event<U> select(Annotation... bindings);
+ public <U extends T> Event<U> select(Class<U> subtype, Annotation... bindings);
+ public <U extends T> Event<U> select(TypeLiteral<U> subtype, Annotation... bindings);
+
+
+ /**
* Register an observer for a specific type
*
* @param observer the observer to register
* @param bindings the bindings to observe the event for
*/
+ @Deprecated
public void observe(Observer<T> observer, Annotation... bindings);
+
+
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/Notify.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/Notify.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/Notify.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,28 +1,45 @@
-package javax.event;
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package javax.enterprise.event;
/**
- * An enumeration that is used to declare the condition under which an
- * observer method should be called. The default behavior is to
- * create the bean and invoke the observer method synchronously.
+ * An enumeration that is used to declare the condition under which an observer
+ * method should be called. The default behavior is to create the bean and
+ * invoke the observer method synchronously.
*
* @author Gavin King
* @author Dan Allen
*/
-public enum Notify {
- /**
- * Specifies that an observer method is only called if the current instance of
- * the bean declaring the observer method already exists.
- */
- IF_EXISTS,
-
- /**
- * Specifies that an observer method is called synchronously.
- */
- SYNCHRONOUSLY,
-
- /**
- * Specifies that an observer method receives the event notifications
- * asynchronously.
- */
- ASYNCHRONOUSLY
+public enum Notify
+{
+ /**
+ * Specifies that an observer method is only called if the current instance
+ * of the bean declaring the observer method already exists.
+ */
+ IF_EXISTS,
+
+ /**
+ * Specifies that an observer method is called synchronously.
+ */
+ SYNCHRONOUSLY,
+
+ /**
+ * Specifies that an observer method receives the event notifications
+ * asynchronously.
+ */
+ ASYNCHRONOUSLY
}
\ No newline at end of file
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/Observer.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/Observer.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/Observer.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,4 +1,20 @@
-package javax.event;
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package javax.enterprise.event;
/**
* The contract between the manager and an observer object.
@@ -6,7 +22,11 @@
*
* @author Gavin King
*
+ * @deprecated Removed in latest rev of spec.
+ *
+ * TODO Move into RI and remove TCK assertions
*/
+ at Deprecated
public interface Observer<T>
{
public boolean notify(T event);
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/ObserverException.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/ObserverException.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/ObserverException.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,23 +1,22 @@
/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
-package javax.event;
+package javax.enterprise.event;
-
/**
* Wraps any checked exceptions which occur during the notification of an
* observer
@@ -32,7 +31,7 @@
public ObserverException()
{
-
+
}
public ObserverException(String message)
Modified: ri/trunk/api/src/main/java/javax/enterprise/event/Observes.java
===================================================================
--- ri/trunk/api/src/main/java/javax/event/Observes.java 2009-06-25 20:27:55 UTC (rev 2892)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/Observes.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package javax.event;
+package javax.enterprise.event;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
Added: ri/trunk/api/src/main/java/javax/enterprise/event/TransactionPhase.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/event/TransactionPhase.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/TransactionPhase.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,62 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.event;
+
+/**
+ * The enumeration {@link TransactionPhase} identifies the kind
+ * of transactional observer method
+ *
+ * Transactional observer methods are observer methods which receive event
+ * notifications during the before or after completion phase of the
+ * transaction in which the event was fired. If no transaction is in progress
+ * when the event is fired, they are notified at the same time as other
+ * observers.
+ *
+ *
+ * @author Pete Muir
+ *
+ */
+public enum TransactionPhase
+{
+
+ IN_PROGRESS,
+
+ /**
+ * A before completion observer method is called during the before completion
+ * phase of the transaction.
+ */
+ BEFORE_COMPLETION,
+
+ /**
+ * An after completion observer method is called during the after completion
+ * phase of the transaction.
+ */
+ AFTER_COMPLETION,
+
+ /**
+ * An after failure observer method is called during the after completion
+ * phase of the transaction, only when the transaction fails.
+ */
+ AFTER_FAILURE,
+
+ /**
+ * A before completion observer method is called during the before completion
+ * phase of the transaction.
+ */
+ AFTER_SUCCESS
+
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/event/TransactionPhase.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/event/package-info.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/event/package-info.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/event/package-info.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,6 @@
+package javax.enterprise.event;
+
+/**
+ * The package javax.enterprise.event contains annotations and interfaces
+ * relating to events.
+ */
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/event/package-info.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/Instance.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/Instance.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/Instance.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -47,4 +47,15 @@
*
*/
public T get(Annotation... bindings);
+
+ public Instance<T> select(Annotation... bindings);
+
+ public <U extends T> Instance<U> select(Class<U> subtype, Annotation... bindings);
+
+ public <U extends T> Instance<U> select(TypeLiteral<U> subtype, Annotation... bindings);
+
+ public boolean isUnsatisfied();
+
+ public boolean isAmbiguous();
+
}
Deleted: ri/trunk/api/src/main/java/javax/enterprise/inject/Model.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/Model.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/Model.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,26 +0,0 @@
-package javax.enterprise.inject;
-
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-import java.lang.annotation.Retention;
-import java.lang.annotation.Target;
-
-import javax.enterprise.context.RequestScoped;
-
-/**
- * A stereotype for MVC model objects
- *
- * @author Gavin King
- */
-
- at Named
- at RequestScoped
- at Stereotype
- at Target( { TYPE, METHOD, FIELD })
- at Retention(RUNTIME)
-public @interface Model
-{
-}
\ No newline at end of file
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/Policy.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/Policy.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/Policy.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,39 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package javax.enterprise.inject;
+
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * Specifies that an annotation type is a deployment type.
+ *
+ * @author Gavin King
+ * @author Pete Muir
+ */
+
+ at Target(TYPE)
+ at Retention(RUNTIME)
+ at Documented
+public @interface Policy
+{
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/Policy.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied: ri/trunk/api/src/main/java/javax/enterprise/inject/Specializes.java (from rev 2892, ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Specializes.java)
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/Specializes.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/Specializes.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,41 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package javax.enterprise.inject;
+
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * Specifies that an implementation class directly specializes its superclass,
+ * of that a producer method directly specializes the method it overrides.
+ *
+ * @author Gavin King
+ * @author Pete Muir
+ */
+
+ at Target({TYPE, METHOD})
+ at Retention(RUNTIME)
+ at Documented
+public @interface Specializes
+{
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/Specializes.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted: ri/trunk/api/src/main/java/javax/enterprise/inject/Stereotype.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/Stereotype.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/Stereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package javax.enterprise.inject;
-
-import static java.lang.annotation.ElementType.ANNOTATION_TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-import java.lang.annotation.Annotation;
-import java.lang.annotation.Documented;
-import java.lang.annotation.Retention;
-import java.lang.annotation.Target;
-
-/**
- * Specifies that an annotation type is a stereotype.
- *
- * @author Pete Muir
- * @author Gavin King
- */
-
- at Retention(RUNTIME)
- at Target(ANNOTATION_TYPE)
- at Documented
-public @interface Stereotype
-{
-
- /**
- * Restrict the scope of the stereotyped bean
- *
- * @return the allowed scopes
- */
- public Class<? extends Annotation>[] supportedScopes() default {};
-
- /**
- * Require that stereotype beans have certain API types
- *
- * @return the required types
- */
- public Class<?>[] requiredTypes() default {};
-
-}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/DeploymentType.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/DeploymentType.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/DeploymentType.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -34,6 +34,7 @@
@Target(ANNOTATION_TYPE)
@Retention(RUNTIME)
@Documented
+ at Deprecated
public @interface DeploymentType
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Production.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Production.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Production.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -37,6 +37,7 @@
@Retention(RUNTIME)
@Documented
@DeploymentType
+ at Deprecated
public @interface Production
{
}
Deleted: ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Specializes.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Specializes.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Specializes.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,41 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package javax.enterprise.inject.deployment;
-
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.Retention;
-import java.lang.annotation.Target;
-
-/**
- * Specifies that an implementation class directly specializes its superclass,
- * of that a producer method directly specializes the method it overrides.
- *
- * @author Gavin King
- * @author Pete Muir
- */
-
- at Target({TYPE, METHOD})
- at Retention(RUNTIME)
- at Documented
-public @interface Specializes
-{
-}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Standard.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Standard.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/deployment/Standard.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -37,6 +37,7 @@
@Retention(RUNTIME)
@Documented
@DeploymentType
+ at Deprecated
public @interface Standard
{
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterBeanDiscovery.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterBeanDiscovery.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterBeanDiscovery.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,5 +1,31 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package javax.enterprise.inject.spi;
-public interface AfterBeanDiscovery {
- public void addDefinitionError(Throwable t);
+import javax.enterprise.context.spi.Context;
+
+public interface AfterBeanDiscovery
+{
+ public void addDefinitionError(Throwable t);
+
+ public void addBean(Bean<?> bean);
+
+ public void addObserverMethod(ObserverMethod<?, ?> observerMethod);
+
+ public void addContext(Context context);
+
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterDeploymentValidation.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterDeploymentValidation.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AfterDeploymentValidation.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,3 +1,19 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package javax.enterprise.inject.spi;
public interface AfterDeploymentValidation
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AnnotatedField.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AnnotatedField.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/AnnotatedField.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,4 +1,3 @@
-
/*
* JBoss, Home of Professional Open Source
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeanManager.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeanManager.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeanManager.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -28,9 +28,9 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.AmbiguousResolutionException;
import javax.enterprise.inject.UnsatisfiedResolutionException;
-import javax.event.Observer;
/**
* The contract between the application and the manager. Also the contract
@@ -46,201 +46,166 @@
public interface BeanManager
{
- /**
+ /**
* Obtains a contextual reference for a given bean and a given bean type.
*
- * @param bean
- * the Bean object representing the bean
- * @param beanType
- * a bean type that must be implemented by any proxy that is returned
+ * @param bean the Bean object representing the bean
+ * @param beanType a bean type that must be implemented by any proxy that is
+ * returned
* @return a contextual reference representing the bean
- * @throws IllegalArgumentException
- * if the given type is not a bean type of the given bean
+ * @throws IllegalArgumentException if the given type is not a bean type of
+ * the given bean
*/
- public Object getReference(Bean<?> bean, Type beanType, CreationalContext<?> creationalContext);
+ public Object getReference(Bean<?> bean, Type beanType, CreationalContext<?> ctx);
/**
* Obtains an instance of bean for a given injection point.
*
* This method should not be called by an application.
*
- * @param injectionPoint
- * the injection point the instance is needed for
- * @param creationalContext
- * the context in which the injection is occurring
+ * @param ij the injection point the instance is needed for
+ * @param ctx the context in which the injection is occurring
* @return an instance of the bean
- * @throws UnsatisfiedResolutionException
- * if no bean can be resolved for the given type and bindings
- * @throws AmbiguousResolutionException
- * if more than one bean is resolved for the given type and
- * bindings
+ * @throws UnsatisfiedResolutionException if no bean can be resolved for the
+ * given type and bindings
+ * @throws AmbiguousResolutionException if more than one bean is resolved for
+ * the given type and bindings
*/
- public Object getInjectableReference(InjectionPoint injectionPoint, CreationalContext<?> creationalContext);
+ public Object getInjectableReference(InjectionPoint ij, CreationalContext<?> ctx);
/**
- * Returns the set of beans which match the given required type and bindings and are
- * accessible to the class into which the BeanManager was injected, according to the
- * rules of typesafe resolution.
+ * Obtain an instance of a {@link CreationalContext} for the given contextual
*
+ * @param contextual the contextual to create a creational context for
+ * @return the {@link CreationalContext} instance
+ */
+ public <T> CreationalContext<T> createCreationalContext(Contextual<T> contextual);
+
+ /**
+ * Returns the set of beans which match the given required type and bindings
+ * and are accessible to the class into which the BeanManager was injected,
+ * according to the rules of typesafe resolution.
+ *
* Typesafe resolution usually occurs at container deployment time.
*
- * @param beanType
- * the type of the beans to be resolved
- * @param bindings
- * the bindings used to restrict the matched beans. If no bindings are passed to
- * getBeans(), the default binding @Current is assumed.
+ * @param beanType the type of the beans to be resolved
+ * @param bindings the bindings used to restrict the matched beans. If no
+ * bindings are passed to getBeans(), the default binding @Current
+ * is assumed.
* @return the matched beans
- * @throws IllegalArgumentException
- * if the given type represents a type variable, or
- * if two instances of the same binding type are given, or
- * if an instance of an annotation that is not a binding type is given
+ * @throws IllegalArgumentException if the given type represents a type
+ * variable
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are
+ * @throws IllegalArgumentException if an instance of an annotation that is
+ * not a binding type is given
*/
- public Set<Bean<?>> getBeans(Type beanType, Annotation... bindings);
+ public Set<Bean<?>> getBeans(Type beanType, Annotation... bindings);
-
/**
- * Returns the set of beans which match the given EL name and are accessible to the
- * class into which the BeanManager was injected, according to the rules of EL name
- * resolution.
+ * Returns the set of beans which match the given EL name and are accessible
+ * to the class into which the BeanManager was injected, according to the
+ * rules of EL name resolution.
*
- * @param name
- * the name used to restrict the beans matched
+ * @param name the name used to restrict the beans matched
* @return the matched beans
*/
- public Set<Bean<?>> getBeans(String name);
+ public Set<Bean<?>> getBeans(String name);
/**
- * Returns the Bean object representing the most specialized enabled bean registered
- * with the container that specializes the given bean,
-
+ * Returns the Bean object representing the most specialized enabled bean
+ * registered with the container that specializes the given bean,
+ *
* @param <X> The type of the bean
- * @param bean
- * The Bean representation of the bean.
- * @return the mest specialized enabled bean
+ * @param bean The Bean representation of the bean.
+ * @return the most specialized enabled bean
*/
- public <X> Bean<? extends X> getMostSpecializedBean(Bean<X> bean);
+ public <X> Bean<? extends X> getMostSpecializedBean(Bean<X> bean);
/**
* Returns the PassivationCapableBean with the given identifier.
*/
- public Bean<?> getPassivationCapableBean(String id);
+ public Bean<?> getPassivationCapableBean(String id);
/**
- * Allows resolution of an ambiguous dependency programatically, by returning the Bean
- * with the highest precedence deployment type in a set of beans.
-
+ * Apply the ambiguous dependency resolution rules
+ *
* @param <X> The type of the bean
* @param beans A set of beans of the given type
+ * @throws AmbiguousResolutionException if the ambiguous dependency
+ * resolution rules fail
*/
- public <X> Bean<? extends X> getHighestPrecedenceBean(Set<Bean<? extends X>> beans);
+ public <X> Bean<? extends X> resolve(Set<Bean<? extends X>> beans);
/**
- * Allows a new bean to be registered. This fires a ProcessBean event and then
- * registers a new bean with the container, thereby making it available for injection
- * into other beans.
+ * Validates the dependency
*
- * This method may be called at any time in the applications lifecycle.
- *
- * @param bean
- * the bean to register
+ * @param injectionPoint the injection point to validate
+ * @throws an InjectionException if there is a deployment problem (for
+ * example, an unsatisfied or unresolvable ambiguous dependency)
+ * associated with the injection point.
*/
- public void addBean(Bean<?> bean);
+ public void validate(InjectionPoint injectionPoint);
-
-
/**
- * Register an observer with the container, allowing it to begin receiving
- * event notifications.
+ * Fire an event
*
- * The observed event type is the actual type parameter of Observer declared
- * by the class of the observer object. The observer is notified when an
- * event object that is assignable to the observed event type is raised
- * with the observed event bindings.
- *
- * @param observer
- * the observer to register
- * @param bindings
- * event bindings to further restrict the events observed
- * passed
- * @throws IllegalArgumentException
- * if an annotation which is not a binding type is passed, or
- * if two instances of the same binding type are passed, or
- * if the runtime type of the observer object contains a type variable
+ * @param event the event object
+ * @param bindings the event bindings used to restrict the observers matched
+ * @throws IllegalArgumentException if the runtime type of the event object
+ * contains a type variable
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are given
+ * @throws IllegalArgumentException if an instance of an annotation that is
+ * not a binding type is given,
*/
- public void addObserver(Observer<?> observer, Annotation... bindings);
+ public void fireEvent(Object event, Annotation... bindings);
-
/**
- * An alternative mechanism for registering an observer. The observed event
- * type and event bindings for registration will be obtained from the
- * ObserverMethod instance
- * @param observerMethod
- * a the method to register for receiving events
- */
- public void addObserver(ObserverMethod<?, ?> observerMethod);
-
-
- /**
- * Remove an observer registration
+ * Obtains observers for an event by considering event type and bindings.
*
- * @param observer
- * the observer to register
- * @throws IllegalArgumentException
- * if an annotation which is not a event binding type is passed or
- * if two instances of the same binding type are passed
+ * @param <T> the type of the event to obtain
+ * @param event the event object
+ * @param bindings the bindings used to restrict the matched observers
+ * @return the resolved observers
+ * @throws IllegalArgumentException if a parameterized type with a type
+ * parameter or a wildcard is passed
+ * @throws IllegalArgumentException if an annotation which is not a event
+ * binding type is passed
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are passed
*/
- public void removeObserver(Observer<?> observer);
+ @Deprecated
+ public <T> Set<Observer<T>> resolveObservers(T event, Annotation... bindings);
-
/**
- * Fire an event
- *
- * @param event
- * the event object
- * @param bindings
- * the event bindings used to restrict the observers matched
- * @throws IllegalArgumentException
- * if the runtime type of the event object contains a type variable or
- * if two instances of the same binding type are given, or
- * if an instance of an annotation that is not a binding type is given,
- */
- public void fireEvent(Object event, Annotation... bindings);
-
- /**
* Obtains observers for an event by considering event type and bindings.
*
- * @param <T>
- * the type of the event to obtain
- * @param event
- * the event object
- * @param bindings
- * the bindings used to restrict the matched observers
+ * @param <T> the type of the event to obtain
+ * @param event the event object
+ * @param bindings the bindings used to restrict the matched observers
* @return the resolved observers
- * @throws IllegalArgumentException
- * if a parameterized type with a type parameter or a wildcard is
- * passed
- * @throws IllegalArgumentException
- * if an annotation which is not a event binding type is passed
- * @throws IllegalArgumentException
- * if two instances of the same binding type are passed
+ * @throws IllegalArgumentException if a parameterized type with a type
+ * parameter or a wildcard is passed
+ * @throws IllegalArgumentException if an annotation which is not a event
+ * binding type is passed
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are passed
*/
- public <T> Set<Observer<T>> resolveObservers(T event, Annotation... bindings);
+ public <T> Set<ObserverMethod<T, ?>> resolveObserverMethods(T event, Annotation... bindings);
/**
* Obtains an ordered list of enabled decorators for a set of bean types and
* a set of bindings
*
- * @param types
- * the set of bean types of the decorated bean
- * @param bindings
- * the bindings declared by the decorated bean
+ * @param types the set of bean types of the decorated bean
+ * @param bindings the bindings declared by the decorated bean
* @return the resolved decorators
- * @throws IllegalArgumentException
- * if the set of bean types is empty
- * @throws IllegalArgumentException
- * if an annotation which is not a binding type is passed
- * @throws IllegalArgumentException
- * if two instances of the same binding type are passed
+ * @throws IllegalArgumentException if the set of bean types is empty
+ * @throws IllegalArgumentException if an annotation which is not a binding
+ * type is passed
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are passed
*/
public List<Decorator<?>> resolveDecorators(Set<Type> types, Annotation... bindings);
@@ -248,32 +213,18 @@
* Obtains an ordered list of enabled interceptors for a set interceptor
* bindings
*
- * @param type
- * the type of the interception
- * @param bindings
- * the bindings used to restrict the matched interceptors
+ * @param type the type of the interception
+ * @param bindings the bindings used to restrict the matched interceptors
* @return the resolved interceptors
- * @throws IllegalArgumentException
- * if no interceptor binding type is passed
- * @throws IllegalArgumentException
- * if an annotation which is not a interceptor binding type is
- * passed
- * @throws IllegalArgumentException
- * if two instances of the same binding type are passed
+ * @throws IllegalArgumentException if no interceptor binding type is passed
+ * @throws IllegalArgumentException if an annotation which is not a
+ * interceptor binding type is passed
+ * @throws IllegalArgumentException if two instances of the same binding type
+ * are passed
*/
public List<Interceptor<?>> resolveInterceptors(InterceptionType type, Annotation... interceptorBindings);
/**
- * Validates the dependency
- * @throws
- * an InjectionException if there is a deployment problem
- * (for example, an unsatisfied or unresolvable ambiguous
- * dependency) associated with the injection point.
- * @param injectionPoint the injection point to validate
- */
- public void validate(InjectionPoint injectionPoint);
-
- /**
* Determine if the given annotationType is a scope type
*/
public boolean isScopeType(Class<? extends Annotation> annotationType);
@@ -283,7 +234,6 @@
*/
public boolean isBindingType(Class<? extends Annotation> annotationType);
-
/**
* Determine if the given annotationType is an interceptor binding type
*/
@@ -295,123 +245,126 @@
public boolean isStereotype(Class<? extends Annotation> annotationType);
/**
- * Return a ScopeType definition type for a given annotation representing a scope type
+ * Return a ScopeType definition type for a given annotation representing a
+ * scope type
*/
public ScopeType getScopeDefinition(Class<? extends Annotation> scopeType);
/**
- * Obtain the set of interceptor binding types meta-annotatinos for the given binding type
- * annotation
+ * Obtain the set of interceptor binding types meta-annotatinos for the given
+ * binding type annotation
*/
public Set<Annotation> getInterceptorBindingTypeDefinition(Class<? extends Annotation> bindingType);
-
/**
- * Obtain the set of binding types meta-annotations for the given stereotype annotation
+ * Obtain the set of binding types meta-annotations for the given stereotype
+ * annotation
*/
public Set<Annotation> getStereotypeDefinition(Class<? extends Annotation> stereotype);
-
-
+
/**
- * Exposes the list of enabled deployment types, in order of lower to higher precedence,
- * This method may be used by portable extensions to discover information about the
- * deployment.
- */
- public List<Class<? extends Annotation>> getEnabledDeploymentTypes();
-
- /**
- * Associate a custom Context with a scope.
- *
- * This method may be called at any time in the applications lifecycle.
- *
- * @param context
- * the context to register
- */
- public void addContext(Context context);
-
- /**
* Obtain an active context instance for the given scope type.
*
- * @param scopeType
- * the scope to get the context instance for
+ * @param scopeType the scope to get the context instance for
* @return the context instance
- * @throws ContextNotActiveException
- * if no active contexts exist for the given scope type
- * @throws IllegalArgumentException
- * if more than one active context exists for the given scope type
+ * @throws ContextNotActiveException if no active contexts exist for the
+ * given scope type
+ * @throws IllegalArgumentException if more than one active context exists
+ * for the given scope type
*/
public Context getContext(Class<? extends Annotation> scopeType);
-
+
/**
- * Returns the ELResolver for integration with the servlet engine and JSF implementation
- * This resolver will return a contextual instance of a bean if the name for resolution
- * resolves to exactly one bean
+ * Returns the ELResolver for integration with the servlet engine and JSF
+ * implementation This resolver will return a contextual instance of a bean
+ * if the name for resolution resolves to exactly one bean
*/
public ELResolver getELResolver();
-
+
/**
- * Parse and validate the standard metadata defined by JSR-299 for the specified class,
- * returning an InjectionTarget to allow injection into custom beans or
- * non-contextual instances by portable extensions
- *
- * @param <T>
- * The type of the class to inspect
- * @param type
- * The class to inspect
- * @returns
- * a container provided instance of InjectionTarget for the given type
- * @throws IllegalArgumentException
- * if there is a definition error associated with any injection point of the type.
+ * Get an {@link AnnotatedType} for the given class
+ * @param <T> the type
+ * @param type the type
+ * @return the {@link AnnotatedType}
*/
- public <T> InjectionTarget<T> createInjectionTarget(Class<T> type);
-
+ public <T> AnnotatedType<T> createAnnotatedType(Class<T> type);
+
/**
- * Returns an InjectionTarget to allow injection into custom beans
- * or non-contextual instances by portable extensions.
+ * Returns an InjectionTarget to allow injection into custom beans or
+ * non-contextual instances by portable extensions.
*
- * The container ignores the annotations and types declared by the elements of the
- * actual Java class and uses the metadata provided via the Annotated interface instead.
-
- * @param <T>
- * The type of the AnnotatedType to inspect
- * @param type
- * The AnnotatedType to inspect
- * @returns
- * a container provided instance of InjectionTarget for the given type
- * @throws IllegalArgumentException
- * if there is a definition error associated with any injection point of the type.
+ * The container ignores the annotations and types declared by the elements
+ * of the actual Java class and uses the metadata provided via the Annotated
+ * interface instead.
+ *
+ * @param <T> The type of the AnnotatedType to inspect
+ * @param type The AnnotatedType to inspect
+ * @returns a container provided instance of InjectionTarget for the given
+ * type
+ * @throws IllegalArgumentException if there is a definition error associated
+ * with any injection point of the type.
*/
public <T> InjectionTarget<T> createInjectionTarget(AnnotatedType<T> type);
+
+ /**
+ * Allows a new bean to be registered. This fires a ProcessBean event and
+ * then registers a new bean with the container, thereby making it available
+ * for injection into other beans.
+ *
+ * This method may be called at any time in the applications lifecycle.
+ *
+ * @param bean the bean to register
+ */
+ @Deprecated
+ public void addBean(Bean<?> bean);
/**
- * Parse and validate the standard metadata defined by JSR-299 for the specified class,
- * returning a ManagedBean instance representing that class.
- * @param <T>
- * The type of the class
- * @param type
- * The class for which a managed bean instance should be created
+ * Register an observer with the container, allowing it to begin receiving
+ * event notifications.
+ *
+ * The observed event type is the actual type parameter of Observer declared
+ * by the class of the observer object. The observer is notified when an
+ * event object that is assignable to the observed event type is raised with
+ * the observed event bindings.
+ *
+ * @param observer the observer to register
+ * @param bindings event bindings to further restrict the events observed
+ * passed
+ * @throws IllegalArgumentException if an annotation which is not a binding
+ * type is passed, or if two instances of the same binding type
+ * are passed, or if the runtime type of the observer object
+ * contains a type variable
*/
- public <T> ManagedBean<T> createManagedBean(Class<T> type);
+ @Deprecated
+ public void addObserver(Observer<?> observer, Annotation... bindings);
/**
- * Returns a ManagedBean instance representing the metadata described by the specified
- * type.
+ * Remove an observer registration
*
- * The container ignores the annotations and types declared by the elements of the
- * actual Java class and uses the metadata provided via the Annotated interface instead.
- * @param <T>
- * The type of the underlying bean
- * @param type
- * The metadata for construction of the ManagedBean
+ * @param observer the observer to register
+ * @throws IllegalArgumentException if an annotation which is not a event
+ * binding type is passed or if two instances of the same binding
+ * type are passed
*/
- public <T> ManagedBean<T> createManagedBean(AnnotatedType<T> type);
-
+ @Deprecated
+ public void removeObserver(Observer<?> observer);
+
/**
- * Obtain an instance of a {@link CreationalContext} for the given contextual
+ * Exposes the list of enabled deployment types, in order of lower to higher
+ * precedence, This method may be used by portable extensions to discover
+ * information about the deployment.
+ */
+ @Deprecated
+ public List<Class<? extends Annotation>> getEnabledDeploymentTypes();
+
+ /**
+ * Associate a custom Context with a scope.
*
- * @param contextual the contextual to create a creational context for
- * @return the {@link CreationalContext} instance
+ * This method may be called at any time in the applications lifecycle.
+ *
+ * @param context the context to register
*/
- public <T> CreationalContext<T> createCreationalContext(Contextual<T> contextual);
+ @Deprecated
+ public void addContext(Context context);
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeBeanDiscovery.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeBeanDiscovery.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeBeanDiscovery.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,3 +1,19 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package javax.enterprise.inject.spi;
import java.lang.annotation.Annotation;
@@ -2,7 +18,16 @@
-public interface BeforeBeanDiscovery {
- public void addBindingType(Class<? extends Annotation> bindingType);
- public void addScopeType(Class<? extends Annotation> scopeType, boolean normal, boolean passivating);
- public void addStereotype(Class<? extends Annotation> stereotype, Annotation... stereotypeDef);
- public void addInterceptorBindingType(Class<? extends Annotation> bindingType);
+/**
+ *
+ * @author Pete Muir
+ *
+ */
+public interface BeforeBeanDiscovery
+{
+ public void addBindingType(Class<? extends Annotation> bindingType);
+
+ public void addScopeType(Class<? extends Annotation> scopeType, boolean normal, boolean passivating);
+
+ public void addStereotype(Class<? extends Annotation> stereotype, Annotation... stereotypeDef);
+
+ public void addInterceptorBindingType(Class<? extends Annotation> bindingType);
}
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,21 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface BeforeShutdown
+{
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Extension.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Extension.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Extension.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,3 +1,25 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
package javax.enterprise.inject.spi;
+/**
+ *
+ * @author Pete Muir
+ *
+ */
public interface Extension {}
\ No newline at end of file
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,19 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package javax.enterprise.inject.spi;
-import java.util.Set;
-
import javax.enterprise.context.spi.CreationalContext;
-public interface InjectionTarget<X>
+/**
+ *
+ *
+ * @author Pete Muir
+ *
+ * @param <T>
+ */
+public interface InjectionTarget<T> extends Producer<T>
{
- public X produce(CreationalContext<X> ctx);
-
- public void inject(X instance, CreationalContext<X> ctx);
-
- public void dispose(X instance);
-
- public void destroy(X instance);
-
- public Set<InjectionPoint> getInjectionPoints();
-
+
+ public void inject(T instance, CreationalContext<T> ctx);
+
+ public void postConstruct(T instance);
+
+ public void preDestroy(T instance);
+
}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Interceptor.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Interceptor.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Interceptor.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -18,10 +18,11 @@
package javax.enterprise.inject.spi;
import java.lang.annotation.Annotation;
-import java.lang.reflect.Method;
import java.util.Set;
+import javax.interceptor.InvocationContext;
+
public interface Interceptor<T> extends Bean<T>
{
@@ -31,16 +32,9 @@
* @return the interceptor bindings
*/
public Set<Annotation> getInterceptorBindingTypes();
+
+ public boolean intercepts(InterceptionType type);
+ public Object intercept(InterceptionType type, T instance, InvocationContext ctx);
- /**
- * The interceptor method for the specified lifecycle callback or business
- * method
- *
- * @param type
- * the interception type
- * @return the method, or null if the interceptor does not intercept
- * lifecycle callbacks or business methods
- */
- public Method getMethod(InterceptionType type);
}
\ No newline at end of file
Deleted: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ManagedBean.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ManagedBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ManagedBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,11 +0,0 @@
-package javax.enterprise.inject.spi;
-
-import java.util.Set;
-
-public interface ManagedBean<X> extends Bean<X> {
- public AnnotatedType<X> getAnnotatedType();
- public InjectionTarget<X> getInjectionTarget();
- public Set<ProducerBean<X, ?>> getProducerBeans();
- public Set<ObserverMethod<X,?>> getObserverMethods();
- public Bean<X> getBeanClass();
-}
Modified: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ObserverMethod.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ObserverMethod.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ObserverMethod.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -4,13 +4,14 @@
import java.lang.reflect.Type;
import java.util.Set;
-import javax.event.Observer;
+import javax.enterprise.event.Notify;
+import javax.enterprise.event.TransactionPhase;
-public interface ObserverMethod<X, T> extends Observer<T> {
- public AnnotatedMethod<? super X> getAnnotatedMethod();
+public interface ObserverMethod<X, T> {
public Bean<X> getBean();
- public Type getObservedEventType();
- public Set<Annotation> getObservedEventBindings();
- public void notify(X instance, T event);
- public Set<InjectionPoint> getInjectionPoints();
+ public Type getObservedType();
+ public Set<Annotation> getObservedBindings();
+ public Notify getNotify();
+ public TransactionPhase getTransactionPhase();
+ public void notify(T event);
}
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessAnnotatedType.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessAnnotatedType.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessAnnotatedType.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,26 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessAnnotatedType<X>
+{
+ public AnnotatedType<X> getAnnotatedType();
+
+ public void setAnnotatedType(AnnotatedType<X> t!
ype);
+
+ public void veto();
+}
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessAnnotatedType.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessBean.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessBean.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,26 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessBean<X>
+{
+ public Annotated getAnnotated();
+
+ public Bean<X> getBean();
+
+ public void addDefinitionError(Thro!
wable t);
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessInjectionTarget.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessInjectionTarget.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessInjectionTarget.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,28 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessInjectionTarget<X>
+{
+ public AnnotatedType<X> getAnnotatedType();
+
+ public InjectionTarget<X> getInjectionTarget(!
);
+
+ public void setInjectionTarget(InjectionTarget<X> injectionTarget);
+
+ public void addDefinitionError(Throwable t);
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessInjectionTarget.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessManagedBean.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessManagedBean.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessManagedBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,22 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessManagedBean<X> extends ProcessBean<X>
+{
+ public AnnotatedType<X> getAnnotatedBeanClass();
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessManagedBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProcessObserverMethod.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProcessObserverMethod.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProcessObserverMethod.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,26 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessProcessObserverMethod<X, T>
+{
+ public AnnotatedMethod<X> getAnnotatedMethod();
+
+ public ObserverMethod<X, T> getO!
bserverMethod();
+
+ public void addDefinitionError(Throwable t);
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProcessObserverMethod.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.inject.spi;
+
+public interface ProcessProducer<X, T>
+{
+ public AnnotatedMember<X> getAnnotatedMember();
+
+ public Producer<T> getProducer();
+
+ pub!
lic void setProducer(Producer<T> producer);
+
+ public void addDefinitionError(Throwable t);
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerField.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerField.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerField.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,22 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessProducerField<X, T> extends ProcessBean<T>
+{
+ public AnnotatedField<X> getAnnotatedProducerField();
+}
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerField.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerMethod.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerMethod.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerMethod.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public interface ProcessProducerMethod<X, T> extends ProcessBean<T>
+{
+ public AnnotatedMethod<X> getAnnotatedProducerMethod();
+
+ public A!
nnotatedParameter<X> getAnnotatedDisposedParameter();
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessProducerMethod.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessSessionBean.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessSessionBean.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessSessionBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,27 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.inject.spi;
+
+public interface ProcessSessionBean<X> extends ProcessBean<Object>
+{
+ public AnnotatedType<X> getAnnotatedBeanClass();
+
+ public String !
getEjbName();
+
+ public SessionBeanType getSessionBeanType();
+}
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProcessSessionBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Producer.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Producer.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Producer.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+import java.util.Set;
+
+import javax.enterprise.context.spi.CreationalContext;
+/**
+ * The interface javax.enterprise.inject.spi.Producer provi!
des a generic operation for producing an instance of a type.
+
+ *
+ * @author Pete Muir
+ *
+ * @param <T>
+ */
+public interface Producer<T>
+{
+ public T produce(CreationalContext<T> ctx);
+
+ public void dispose(T instance);
+
+ public Set<InjectionPoint> getInjectionPoints();
+}
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/Producer.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProducerBean.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProducerBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/ProducerBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,9 +0,0 @@
-package javax.enterprise.inject.spi;
-
-public interface ProducerBean<X, T> extends Bean<T> {
- public AnnotatedMember<? super X> getAnnotatedProducer();
- public AnnotatedMethod<? super X> getAnnotatedDisposer();
- public Bean<X> getBean();
- public InjectionTarget<T> getInjectionTarget();
- public Bean<X> getBeanClass();
-}
Added: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/SessionBeanType.java
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/spi/SessionBeanType.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/spi/SessionBeanType.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,22 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package javax.enterprise.inject.spi;
+
+public enum SessionBeanType
+{
+ STATELESS, STATEFUL, SINGLETON
+}
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/spi/SessionBeanType.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied: ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Model.java (from rev 2892, ri/trunk/api/src/main/java/javax/enterprise/inject/Model.java)
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Model.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Model.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,27 @@
+package javax.enterprise.inject.stereotype;
+
+import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+import javax.enterprise.context.RequestScoped;
+import javax.enterprise.inject.Named;
+
+/**
+ * A stereotype for MVC model objects
+ *
+ * @author Gavin King
+ */
+
+ at Named
+ at RequestScoped
+ at Stereotype
+ at Target( { TYPE, METHOD, FIELD })
+ at Retention(RUNTIME)
+public @interface Model
+{
+}
\ No newline at end of file
Copied: ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Stereotype.java (from rev 2892, ri/trunk/api/src/main/java/javax/enterprise/inject/Stereotype.java)
===================================================================
--- ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Stereotype.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Stereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,55 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package javax.enterprise.inject.stereotype;
+
+import static java.lang.annotation.ElementType.ANNOTATION_TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Annotation;
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * Specifies that an annotation type is a stereotype.
+ *
+ * @author Pete Muir
+ * @author Gavin King
+ */
+
+ at Retention(RUNTIME)
+ at Target(ANNOTATION_TYPE)
+ at Documented
+public @interface Stereotype
+{
+
+ /**
+ * Restrict the scope of the stereotyped bean
+ *
+ * @return the allowed scopes
+ */
+ public Class<? extends Annotation>[] supportedScopes() default {};
+
+ /**
+ * Require that stereotype beans have certain API types
+ *
+ * @return the required types
+ */
+ public Class<?>[] requiredTypes() default {};
+
+}
Property changes on: ri/trunk/api/src/main/java/javax/enterprise/inject/stereotype/Stereotype.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: ri/trunk/api/src/main/java/javax/inject/Obtains.java
===================================================================
--- ri/trunk/api/src/main/java/javax/inject/Obtains.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/inject/Obtains.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -38,6 +38,7 @@
@Retention(RUNTIME)
@Target( { TYPE, METHOD, FIELD, PARAMETER })
@Documented
+ at Deprecated
public @interface Obtains
{
}
Deleted: ri/trunk/api/src/main/java/javax/inject/Realizes.java
===================================================================
--- ri/trunk/api/src/main/java/javax/inject/Realizes.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/inject/Realizes.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,40 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package javax.inject;
-
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.Retention;
-import java.lang.annotation.Target;
-
-/**
- * Specifies that an implementation class directly specializes its superclass,
- * of that a producer method directly specializes the method it overrides.
- *
- * @author Gavin King
- * @author Pete Muir
- */
-
- at Target(TYPE)
- at Retention(RUNTIME)
- at Documented
-public @interface Realizes
-{
-}
Modified: ri/trunk/api/src/main/java/javax/interceptor/Interceptor.java
===================================================================
--- ri/trunk/api/src/main/java/javax/interceptor/Interceptor.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/interceptor/Interceptor.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -20,10 +20,11 @@
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
+import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
/**
* Specifies that a class is an interceptor.
@@ -34,6 +35,5 @@
@Retention(RUNTIME)
@Target(TYPE)
@Stereotype
-public @interface Interceptor
-{
-}
+ at Documented
+public @interface Interceptor {}
Modified: ri/trunk/api/src/main/java/javax/interceptor/InterceptorBindingType.java
===================================================================
--- ri/trunk/api/src/main/java/javax/interceptor/InterceptorBindingType.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/api/src/main/java/javax/interceptor/InterceptorBindingType.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -34,6 +34,4 @@
@Target(ANNOTATION_TYPE)
@Retention(RUNTIME)
@Documented
-public @interface InterceptorBindingType
-{
-}
+public @interface InterceptorBindingType {}
Added: ri/trunk/api/src/main/java/javax/interceptor/package-info.java
===================================================================
--- ri/trunk/api/src/main/java/javax/interceptor/package-info.java (rev 0)
+++ ri/trunk/api/src/main/java/javax/interceptor/package-info.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,5 @@
+package javax.interceptor;
+
+/**
+ *
+ */
\ No newline at end of file
Property changes on: ri/trunk/api/src/main/java/javax/interceptor/package-info.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied: ri/trunk/core-api/src/main/java/org/jboss/webbeans/Realizes.java (from rev 2892, ri/trunk/api/src/main/java/javax/inject/Realizes.java)
===================================================================
--- ri/trunk/core-api/src/main/java/org/jboss/webbeans/Realizes.java (rev 0)
+++ ri/trunk/core-api/src/main/java/org/jboss/webbeans/Realizes.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.jboss.webbeans;
+
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * Specifies that an implementation class directly specializes its superclass,
+ * of that a producer method directly specializes the method it overrides.
+ *
+ * @author Gavin King
+ * @author Pete Muir
+ */
+
+ at Target(TYPE)
+ at Retention(RUNTIME)
+ at Documented
+public @interface Realizes
+{
+}
Property changes on: ri/trunk/core-api/src/main/java/org/jboss/webbeans/Realizes.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -48,6 +48,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.AmbiguousResolutionException;
import javax.enterprise.inject.BindingType;
import javax.enterprise.inject.InjectionException;
@@ -62,9 +63,7 @@
import javax.enterprise.inject.spi.InjectionTarget;
import javax.enterprise.inject.spi.InterceptionType;
import javax.enterprise.inject.spi.Interceptor;
-import javax.enterprise.inject.spi.ManagedBean;
import javax.enterprise.inject.spi.ObserverMethod;
-import javax.event.Observer;
import org.jboss.webbeans.bean.DecoratorBean;
import org.jboss.webbeans.bean.EnterpriseBean;
@@ -595,11 +594,6 @@
addObserver(observer, observer.getEventType(), observer.getBindingsAsArray());
}
- public void addObserver(ObserverMethod<?, ?> observerMethod)
- {
- addObserver(observerMethod, observerMethod.getObservedEventType(), new ArrayList<Annotation>(observerMethod.getObservedEventBindings()).toArray(new Annotation[0]));
- }
-
/**
* Does the actual observer registration
*
@@ -1048,16 +1042,6 @@
throw new UnsupportedOperationException("Not yet implemented");
}
- public <T> ManagedBean<T> createManagedBean(Class<T> type)
- {
- throw new UnsupportedOperationException("Not yet implemented");
- }
-
- public <T> ManagedBean<T> createManagedBean(AnnotatedType<T> type)
- {
- throw new UnsupportedOperationException("Not yet implemented");
- }
-
public <X> Bean<? extends X> getMostSpecializedBean(Bean<X> bean)
{
Contextual<?> key = bean;
@@ -1117,6 +1101,7 @@
throw new UnsupportedOperationException("Not yet implemented");
}
+ @Deprecated
public <X> Bean<? extends X> getHighestPrecedenceBean(Set<Bean<? extends X>> beans)
{
if (beans.size() == 1)
@@ -1158,5 +1143,29 @@
{
return new CreationalContextImpl<T>(contextual);
}
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.spi.BeanManager#createAnnotatedType(java.lang.Class)
+ */
+ public <T> AnnotatedType<T> createAnnotatedType(Class<T> type)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.spi.BeanManager#resolve(java.util.Set)
+ */
+ public <X> Bean<? extends X> resolve(Set<Bean<? extends X>> beans)
+ {
+ return getHighestPrecedenceBean(beans);
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.spi.BeanManager#resolveObserverMethods(java.lang.Object, java.lang.annotation.Annotation[])
+ */
+ public <T> Set<ObserverMethod<T, ?>> resolveObserverMethods(T event, Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
}
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanValidator.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanValidator.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanValidator.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -28,6 +28,7 @@
import java.util.Set;
import javax.enterprise.context.Dependent;
+import javax.enterprise.event.Event;
import javax.enterprise.inject.AmbiguousResolutionException;
import javax.enterprise.inject.Any;
import javax.enterprise.inject.Instance;
@@ -37,7 +38,6 @@
import javax.enterprise.inject.spi.Bean;
import javax.enterprise.inject.spi.Decorator;
import javax.enterprise.inject.spi.InjectionPoint;
-import javax.event.Event;
import javax.inject.Obtains;
import org.jboss.webbeans.bean.AbstractClassBean;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/InstanceImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/InstanceImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/InstanceImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -22,6 +22,7 @@
import java.util.Set;
import javax.enterprise.inject.Instance;
+import javax.enterprise.inject.TypeLiteral;
import javax.enterprise.inject.spi.Bean;
import org.jboss.webbeans.injection.resolution.ResolvableWBClass;
@@ -74,4 +75,44 @@
throw new UnsupportedOperationException("Not yet implemented");
}
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.Instance#isAmbiguous()
+ */
+ public boolean isAmbiguous()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.Instance#isUnsatisfied()
+ */
+ public boolean isUnsatisfied()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.Instance#select(java.lang.annotation.Annotation[])
+ */
+ public Instance<T> select(Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.Instance#select(java.lang.Class, java.lang.annotation.Annotation[])
+ */
+ public <U extends T> Instance<U> select(Class<U> subtype, Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /* (non-Javadoc)
+ * @see javax.enterprise.inject.Instance#select(javax.enterprise.inject.TypeLiteral, java.lang.annotation.Annotation[])
+ */
+ public <U extends T> Instance<U> select(TypeLiteral<U> subtype, Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
}
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -26,13 +26,13 @@
import javax.decorator.Decorates;
import javax.enterprise.context.Dependent;
+import javax.enterprise.event.Event;
import javax.enterprise.inject.BindingType;
import javax.enterprise.inject.Named;
-import javax.enterprise.inject.Stereotype;
-import javax.enterprise.inject.deployment.Specializes;
+import javax.enterprise.inject.Specializes;
import javax.enterprise.inject.deployment.Standard;
import javax.enterprise.inject.spi.Bean;
-import javax.event.Event;
+import javax.enterprise.inject.stereotype.Stereotype;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractClassBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractClassBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractClassBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -31,6 +31,7 @@
import javax.enterprise.context.Dependent;
import javax.enterprise.context.ScopeType;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.CreationException;
import javax.enterprise.inject.Disposes;
import javax.enterprise.inject.Initializer;
@@ -38,7 +39,6 @@
import javax.enterprise.inject.deployment.DeploymentType;
import javax.enterprise.inject.deployment.Production;
import javax.enterprise.inject.spi.Decorator;
-import javax.event.Observes;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/DisposalMethodBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/DisposalMethodBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/DisposalMethodBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -26,11 +26,11 @@
import javax.enterprise.context.Dependent;
import javax.enterprise.context.ScopeType;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.Disposes;
import javax.enterprise.inject.Initializer;
import javax.enterprise.inject.Produces;
import javax.enterprise.inject.deployment.DeploymentType;
-import javax.event.Observes;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/EnterpriseBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/EnterpriseBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/EnterpriseBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -30,8 +30,8 @@
import javax.decorator.Decorator;
import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.CreationException;
-import javax.event.Observes;
import javax.interceptor.Interceptor;
import org.jboss.webbeans.BeanManagerImpl;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/ProducerMethodBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/ProducerMethodBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/ProducerMethodBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -21,9 +21,9 @@
import java.util.Set;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.CreationException;
import javax.enterprise.inject.Disposes;
-import javax.event.Observes;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/standard/EventBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/standard/EventBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/standard/EventBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -22,8 +22,8 @@
import java.util.HashSet;
import java.util.Set;
+import javax.enterprise.event.Event;
import javax.enterprise.inject.TypeLiteral;
-import javax.event.Event;
import javax.inject.Obtains;
import org.jboss.webbeans.BeanManagerImpl;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/AfterBeanDiscoveryImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/AfterBeanDiscoveryImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/AfterBeanDiscoveryImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -3,7 +3,10 @@
import java.util.ArrayList;
import java.util.List;
+import javax.enterprise.context.spi.Context;
import javax.enterprise.inject.spi.AfterBeanDiscovery;
+import javax.enterprise.inject.spi.Bean;
+import javax.enterprise.inject.spi.ObserverMethod;
public class AfterBeanDiscoveryImpl implements AfterBeanDiscovery
{
@@ -19,4 +22,19 @@
return definitionErrors;
}
+ public void addBean(Bean<?> bean)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public void addContext(Context context)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public void addObserverMethod(ObserverMethod<?, ?> observerMethod)
+ {
+ throw new UnsupportedOperationException();
+ }
+
}
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/BeanDeployer.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/BeanDeployer.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bootstrap/BeanDeployer.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -22,16 +22,16 @@
import java.util.Set;
import javax.decorator.Decorator;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.BindingType;
import javax.enterprise.inject.Disposes;
import javax.enterprise.inject.Initializer;
import javax.enterprise.inject.Produces;
import javax.enterprise.inject.UnsatisfiedResolutionException;
import javax.enterprise.inject.deployment.DeploymentType;
-import javax.event.Observes;
-import javax.inject.Realizes;
import org.jboss.webbeans.BeanManagerImpl;
+import org.jboss.webbeans.Realizes;
import org.jboss.webbeans.bean.AbstractClassBean;
import org.jboss.webbeans.bean.DecoratorBean;
import org.jboss.webbeans.bean.DisposalMethodBean;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/conversation/ConversationImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/conversation/ConversationImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/conversation/ConversationImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -178,4 +178,10 @@
{
return cid == null ? super.hashCode() : cid.hashCode();
}
+
+
+ public boolean isTransient()
+ {
+ return !isLongRunning();
+ }
}
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -133,7 +133,7 @@
try
{
- Bean<?> bean = manager.getHighestPrecedenceBean(manager.getBeans(name));
+ Bean<?> bean = manager.resolve(manager.getBeans(name));
CreationalContext<?> creationalContext = manager.createCreationalContext(bean);
if (bean != null)
{
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -20,8 +20,9 @@
import java.lang.reflect.Type;
import java.util.Set;
-import javax.event.Event;
-import javax.event.Observer;
+import javax.enterprise.event.Event;
+import javax.enterprise.event.Observer;
+import javax.enterprise.inject.TypeLiteral;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.FacadeImpl;
@@ -34,7 +35,7 @@
* @author David Allen
*
* @param <T> The type of event being wrapped
- * @see javax.event.Event
+ * @see javax.enterprise.event.Event
*/
public class EventImpl<T> extends FacadeImpl<T> implements Event<T>
{
@@ -65,6 +66,7 @@
* @param event The event object
* @param bindings Additional binding types
*/
+ @Deprecated
public void fire(T event, Annotation... bindings)
{
getManager().fireEvent(event, mergeInBindings(bindings));
@@ -91,4 +93,24 @@
return buffer.toString();
}
+ public void fire(T event)
+ {
+ getManager().fireEvent(event, mergeInBindings());
+ }
+
+ public <U extends T> Event<U> select(Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public <U extends T> Event<U> select(Class<U> subtype, Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public <U extends T> Event<U> select(TypeLiteral<U> subtype, Annotation... bindings)
+ {
+ throw new UnsupportedOperationException();
+ }
+
}
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventManager.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventManager.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventManager.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -23,7 +23,7 @@
import java.util.HashSet;
import java.util.Set;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.context.DependentContext;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventObserver.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventObserver.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/event/EventObserver.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -21,8 +21,8 @@
import java.util.ArrayList;
import java.util.List;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.Current;
-import javax.event.Observer;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.metadata.MetaDataCache;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/event/ObserverImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/event/ObserverImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/event/ObserverImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -24,13 +24,13 @@
import javax.enterprise.context.Dependent;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Notify;
+import javax.enterprise.event.Observer;
+import javax.enterprise.event.ObserverException;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.Disposes;
import javax.enterprise.inject.Initializer;
import javax.enterprise.inject.Produces;
-import javax.event.Notify;
-import javax.event.Observer;
-import javax.event.ObserverException;
-import javax.event.Observes;
import org.jboss.webbeans.BeanManagerImpl;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/event/TransactionalObserverImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/event/TransactionalObserverImpl.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/event/TransactionalObserverImpl.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -19,12 +19,12 @@
import java.util.ArrayList;
import java.util.List;
-import javax.event.AfterTransactionCompletion;
-import javax.event.AfterTransactionFailure;
-import javax.event.AfterTransactionSuccess;
-import javax.event.BeforeTransactionCompletion;
-import javax.event.Notify;
-import javax.event.Observes;
+import javax.enterprise.event.AfterTransactionCompletion;
+import javax.enterprise.event.AfterTransactionFailure;
+import javax.enterprise.event.AfterTransactionSuccess;
+import javax.enterprise.event.BeforeTransactionCompletion;
+import javax.enterprise.event.Notify;
+import javax.enterprise.event.Observes;
import javax.transaction.Synchronization;
import org.jboss.webbeans.BeanManagerImpl;
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBAnnotated.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBAnnotated.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBAnnotated.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -24,9 +24,9 @@
import javax.enterprise.context.ScopeType;
import javax.enterprise.inject.BindingType;
-import javax.enterprise.inject.Stereotype;
import javax.enterprise.inject.deployment.DeploymentType;
import javax.enterprise.inject.spi.Annotated;
+import javax.enterprise.inject.stereotype.Stereotype;
/**
* AnnotatedItem provides a uniform access to the annotations on an annotated
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBMethod.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBMethod.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/introspector/WBMethod.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -24,12 +24,12 @@
import java.util.List;
import java.util.Set;
+import javax.enterprise.event.AfterTransactionCompletion;
+import javax.enterprise.event.AfterTransactionFailure;
+import javax.enterprise.event.AfterTransactionSuccess;
+import javax.enterprise.event.BeforeTransactionCompletion;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.Disposes;
-import javax.event.AfterTransactionCompletion;
-import javax.event.AfterTransactionFailure;
-import javax.event.AfterTransactionSuccess;
-import javax.event.BeforeTransactionCompletion;
-import javax.event.Observes;
/**
* AnnotatedType provides a uniform access to the annotations on an annotated
Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/metadata/StereotypeModel.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/metadata/StereotypeModel.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/metadata/StereotypeModel.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -24,8 +24,8 @@
import javax.enterprise.context.ScopeType;
import javax.enterprise.inject.BindingType;
import javax.enterprise.inject.Named;
-import javax.enterprise.inject.Stereotype;
import javax.enterprise.inject.deployment.DeploymentType;
+import javax.enterprise.inject.stereotype.Stereotype;
import javax.interceptor.InterceptorBindingType;
import org.jboss.webbeans.DefinitionException;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/ActivitiesTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/ActivitiesTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/ActivitiesTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -10,6 +10,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.AnnotationLiteral;
import javax.enterprise.inject.UnsatisfiedResolutionException;
import javax.enterprise.inject.deployment.Production;
@@ -17,7 +18,6 @@
import javax.enterprise.inject.spi.Bean;
import javax.enterprise.inject.spi.BeanManager;
import javax.enterprise.inject.spi.InjectionPoint;
-import javax.event.Observer;
import org.jboss.jsr299.tck.tests.implementation.enterprise.lifecycle.MockCreationalContext;
import org.jboss.testharness.impl.packaging.Artifact;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/Fox.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/Fox.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/Fox.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,6 +1,6 @@
package org.jboss.jsr299.tck.tests.activities;
-import javax.event.Observes;
+import javax.enterprise.event.Observes;
class Fox
{
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/Dusk.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/Dusk.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/Dusk.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,8 +1,8 @@
package org.jboss.jsr299.tck.tests.activities.current;
+import javax.enterprise.event.Event;
import javax.enterprise.inject.Any;
import javax.enterprise.inject.Initializer;
-import javax.event.Event;
class Dusk
{
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/ELCurrentActivityTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/ELCurrentActivityTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/ELCurrentActivityTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -10,12 +10,12 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.AnnotationLiteral;
import javax.enterprise.inject.deployment.Production;
import javax.enterprise.inject.spi.Bean;
import javax.enterprise.inject.spi.BeanManager;
import javax.enterprise.inject.spi.InjectionPoint;
-import javax.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/EventCurrentActivityTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/EventCurrentActivityTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/EventCurrentActivityTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -5,7 +5,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InactiveScopeTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InactiveScopeTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InactiveScopeTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -6,7 +6,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InjectedManagerCurrentActivityTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InjectedManagerCurrentActivityTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InjectedManagerCurrentActivityTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -5,7 +5,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InstanceCurrentActivityTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InstanceCurrentActivityTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/InstanceCurrentActivityTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -10,12 +10,12 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observer;
import javax.enterprise.inject.AnnotationLiteral;
import javax.enterprise.inject.deployment.Production;
import javax.enterprise.inject.spi.Bean;
import javax.enterprise.inject.spi.BeanManager;
import javax.enterprise.inject.spi.InjectionPoint;
-import javax.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/JndiManagerCurrentActivityTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/JndiManagerCurrentActivityTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/JndiManagerCurrentActivityTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -5,7 +5,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.testharness.impl.packaging.IntegrationTest;
Modified: ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/NonNormalScopeTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/NonNormalScopeTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/jsr299/tck/tests/activities/current/NonNormalScopeTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -5,7 +5,7 @@
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
-import javax.event.Observer;
+import javax.enterprise.event.Observer;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.manager.api.WebBeansManager;
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserver.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserver.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserver.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,7 +1,7 @@
package org.jboss.webbeans.test.unit.bootstrap;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.spi.AfterBeanDiscovery;
-import javax.event.Observes;
class InitializedObserver
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesApplicationContext.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesApplicationContext.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesApplicationContext.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,8 +1,8 @@
package org.jboss.webbeans.test.unit.bootstrap;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.Current;
import javax.enterprise.inject.spi.AfterBeanDiscovery;
-import javax.event.Observes;
class InitializedObserverWhichUsesApplicationContext
{
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesRequestContext.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesRequestContext.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/bootstrap/InitializedObserverWhichUsesRequestContext.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,8 +1,8 @@
package org.jboss.webbeans.test.unit.bootstrap;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.Current;
import javax.enterprise.inject.spi.AfterBeanDiscovery;
-import javax.event.Observes;
class InitializedObserverWhichUsesRequestContext
{
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalOrderStereotype.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalOrderStereotype.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalOrderStereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -6,7 +6,7 @@
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalStereotype.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalStereotype.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/AnimalStereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -9,7 +9,7 @@
import java.lang.annotation.Target;
import javax.enterprise.context.RequestScoped;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
@Stereotype(requiredTypes=Animal.class)
@Target( { TYPE, METHOD, FIELD })
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/RequestScopedAnimalStereotype.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/RequestScopedAnimalStereotype.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/definition/RequestScopedAnimalStereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -7,7 +7,7 @@
import java.lang.annotation.Target;
import javax.enterprise.context.RequestScoped;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
@Stereotype(requiredTypes=Animal.class, supportedScopes=RequestScoped.class)
@Target( { TYPE })
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/annotatedItem/ClassAnnotatedItemTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/annotatedItem/ClassAnnotatedItemTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/annotatedItem/ClassAnnotatedItemTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -4,9 +4,9 @@
import java.util.Iterator;
import java.util.Set;
-import javax.enterprise.inject.Stereotype;
import javax.enterprise.inject.deployment.DeploymentType;
import javax.enterprise.inject.deployment.Production;
+import javax.enterprise.inject.stereotype.Stereotype;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.introspector.WBClass;
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/NormalScopedBean.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/NormalScopedBean.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/NormalScopedBean.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -4,8 +4,8 @@
import java.io.Serializable;
import javax.enterprise.context.SessionScoped;
+import javax.enterprise.event.Event;
import javax.enterprise.inject.Any;
-import javax.event.Event;
@SessionScoped
public class NormalScopedBean implements Serializable
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/SimpleEventTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/SimpleEventTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/event/SimpleEventTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,9 +1,9 @@
package org.jboss.webbeans.test.unit.implementation.event;
+import javax.enterprise.event.Event;
+import javax.enterprise.event.Observes;
import javax.enterprise.inject.AnnotationLiteral;
import javax.enterprise.inject.Any;
-import javax.event.Event;
-import javax.event.Observes;
import org.jboss.testharness.impl.packaging.Artifact;
import org.jboss.webbeans.BeanManagerImpl;
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/named/NamedBeanWithBindingTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/named/NamedBeanWithBindingTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/named/NamedBeanWithBindingTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -15,7 +15,7 @@
@Test
public void testGetNamedBeanWithBinding()
{
- Bean<?> bean = getCurrentManager().getHighestPrecedenceBean(getCurrentManager().getBeans("namedBeanWithBinding"));
+ Bean<?> bean = getCurrentManager().resolve(getCurrentManager().getBeans("namedBeanWithBinding"));
NamedBeanWithBinding instance = (NamedBeanWithBinding) getCurrentManager().getReference(bean, Object.class, getCurrentManager().createCreationalContext(bean));
assert instance != null;
}
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -12,10 +12,10 @@
@Test
public void testNamedProducer()
{
- Bean<?> iemonBean = getCurrentManager().getHighestPrecedenceBean(getCurrentManager().getBeans("iemon"));
+ Bean<?> iemonBean = getCurrentManager().resolve(getCurrentManager().getBeans("iemon"));
String[] iemon = (String[]) getCurrentManager().getReference(iemonBean, Object.class, getCurrentManager().createCreationalContext(iemonBean));
assert iemon.length == 3;
- Bean<?> itoenBean = getCurrentManager().getHighestPrecedenceBean(getCurrentManager().getBeans("itoen"));
+ Bean<?> itoenBean = getCurrentManager().resolve(getCurrentManager().getBeans("itoen"));
String[] itoen = (String[]) getCurrentManager().getReference(itoenBean, Object.class, getCurrentManager().createCreationalContext(itoenBean));
assert itoen.length == 2;
}
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerWithBindingTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerWithBindingTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/producer/method/NamedProducerWithBindingTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -19,7 +19,7 @@
@Test
public void testGetNamedProducerWithBinding()
{
- Bean<?> bean = getCurrentManager().getHighestPrecedenceBean(getCurrentManager().getBeans("date"));
+ Bean<?> bean = getCurrentManager().resolve(getCurrentManager().getBeans("date"));
Date date = (Date) getCurrentManager().getReference(bean, Object.class, getCurrentManager().createCreationalContext(bean));
assertNotNull(date);
}
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/proxy/ProxyTest.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/proxy/ProxyTest.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/implementation/proxy/ProxyTest.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -13,7 +13,7 @@
@Test(description="WBRI-122")
public void testImplementationClassImplementsSerializable()
{
- Bean<?> bean = getCurrentManager().getHighestPrecedenceBean(getCurrentManager().getBeans("foo"));
+ Bean<?> bean = getCurrentManager().resolve(getCurrentManager().getBeans("foo"));
getCurrentManager().getReference(bean, Object.class, getCurrentManager().createCreationalContext(bean));
}
Modified: ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/xml/beans/annotationtype/TestStereotype.java
===================================================================
--- ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/xml/beans/annotationtype/TestStereotype.java 2009-06-25 23:04:35 UTC (rev 2894)
+++ ri/trunk/tests/src/test/java/org/jboss/webbeans/test/unit/xml/beans/annotationtype/TestStereotype.java 2009-06-25 23:09:58 UTC (rev 2895)
@@ -1,6 +1,6 @@
package org.jboss.webbeans.test.unit.xml.beans.annotationtype;
-import javax.enterprise.inject.Stereotype;
+import javax.enterprise.inject.stereotype.Stereotype;
@Stereotype
public @interface TestStereotype
More information about the weld-commits
mailing list