Skip to content

Commit

Permalink
Fix for WELD-699
Browse files Browse the repository at this point in the history
Reverting back to Observes.notifyObserver from Observes.receive
to be compatible with the specification.
  • Loading branch information
wwwsahoo authored and pmuir committed Oct 31, 2010
1 parent 6399c51 commit 230aa7b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -102,7 +102,7 @@ protected ObserverMethodImpl(final WeldMethod<T, ? super X> observer, final RIBe
this.id = new StringBuilder().append(ID_PREFIX).append(ID_SEPARATOR)/*.append(manager.getId()).append(ID_SEPARATOR)*/.append(ObserverMethod.class.getSimpleName()).append(ID_SEPARATOR).append(declaringBean.getBeanClass().getName()).append(".").append(observer.getSignature()).toString();
this.bindings = new HashSet<Annotation>(observerMethod.getAnnotatedParameters(Observes.class).get(0).getMetaAnnotations(Qualifier.class));
Observes observesAnnotation = observerMethod.getAnnotatedParameters(Observes.class).get(0).getAnnotation(Observes.class);
this.reception = observesAnnotation.receive();
this.reception = observesAnnotation.notifyObserver();
transactionPhase = TransactionPhase.IN_PROGRESS;
this.newInjectionPoints = new HashSet<WeldInjectionPoint<?, ?>>();
for (WeldInjectionPoint<?, ?> injectionPoint : Beans.getParameterInjectionPoints(null, observerMethod))
Expand Down
Expand Up @@ -11,7 +11,7 @@ public class Cat

private Mouse mouse;

public void observe(@Observes(receive=IF_EXISTS) Mouse mouse)
public void observe(@Observes(notifyObserver=IF_EXISTS) Mouse mouse)
{
this.mouse = mouse;
}
Expand Down

0 comments on commit 230aa7b

Please sign in to comment.