1 Reply Latest reply on Dec 4, 2005 9:29 PM by Patrick Angeles

    Multiple instances of a Seam class

    Aaron Novice

      I read in the docs that you can differentiate between muliple classes by using the annotation injection:

      User currentUser;
      User assignedUser;
      User requestingUser;

      How can I "create" these objects in my managed bean? I mean, if I have an Entity Bean with a Seam name of "user", how do I reference a "new" user class.

      Owner information: #{user.username}
      Requesting User: #{user.username}
      Assigned to: #{user.username}

      Obviously, this will reference the same "user" instantiation. How can I create a NEW user instantiation, so I can do this:

      Owner information: #{currentUser.username}
      Requesting User: #{requestingUser.username}
      Assigned User: #{assignedUser.username}

      Thanks for your advice!! I feel that this is something super simple, but I cannot think of it.