1 Reply Latest reply on Jul 9, 2009 11:08 PM by Arbi Sookazian

    Unwrap vs Out

    soares gouveia Newbie

      Can somebody explain a little bit about @Unwrap and @Out annotations?
      Which one is more performatic? And what is the best pratices to use these annotaions?
      Which one is more appropriated for each case?

        • 1. Re: Unwrap vs Out
          Arbi Sookazian Master

          A good way to understand this is to read the Seam ref doc or a Seam book and then search the Seam core source or Seam example source code for examples of when/how to use those two annotations.


          @Out is a direct outjection to a specified (or default) scope whereas @Unwrap is associated with the manager component pattern.


          The @Unwrap method is called every time the component's name is referenced in a JSF, for example.  Outjection occurs for all @Out annotated context variables after a business method successfully completes.


          The concern is not performance, they are used for different scenarios...