[jbosstools-issues] [JBoss JIRA] Assigned: (JBIDE-1574) Inner classes invalidate Seam component

Denis Golovin (JIRA) jira-events at lists.jboss.org
Thu Jan 3 12:58:43 EST 2008


     [ http://jira.jboss.com/jira/browse/JBIDE-1574?page=all ]

Denis Golovin reassigned JBIDE-1574:
------------------------------------

    Assignee: Alexey Kazakov

> Inner classes invalidate Seam component
> ---------------------------------------
>
>                 Key: JBIDE-1574
>                 URL: http://jira.jboss.com/jira/browse/JBIDE-1574
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: Seam
>    Affects Versions: 2.0.0.GA
>         Environment: Windows XP SP2
> Eclipse Version 3.3.1.1
> JBoss Tools IDE 2.0GA
> Subclipse 1.2.6
>            Reporter: Chris Simons
>         Assigned To: Alexey Kazakov
>
> Inner classes within a Seam component preclude the outer class from registration as a Seam component.
> We validated this by removing an inner class from a Session bean and saw as it appeared under the "Seam Components" view.
> We then added the inner class back into the bean and watched as the Seam component disappeared.
> This also precluded the component from receiving Content Assist/code completion.
> An example:
> @Stateful
> @Scope(ScopeType.SESSION)
> @Name("valueManager")
> public class ValueManager extends PopupBean implements ValueManagerLocal
> {
>     /**
>      * Used to perform logging of information, debug error or general errors. 
>      */
>     @Logger
>     Log log;
>     
>     /**
>      * Injects the current user information
>      */
>     @In
>     User currentUser;
>     
>     /**
>      * Injects the entity manager
>      */
>     @In
>     private EntityManager entityManager;
>     /**
>      * Injects the seam expressions
>      */
>     @In
>     private Expressions expressions;
>     
>     /**
>      * Injects the FacesContext
>      */
>     @In
>     private FacesContext facesContext;
>     
>     /** Reference to FacesMessages **/
>     @In
>     private FacesMessages facesMessages;
>       
>     .....
>     .....
>     
>     @Remove
>     @Destroy
>     public void destroy()
>     {
>     }
>     private class Values extends HashMap
>     {
>         public Object get(Object category)
>         {
>             log.info("The value in category " + category.toString());
>             
>             EntityManager em = (EntityManager)Component.getInstance("entityManager");
>             return em.createNamedQuery("findValuesByCategory")
>                     .setParameter("category", category).getResultList();
>         }
>     }
> }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbosstools-issues mailing list