Discussions

EJB design: Primary Key Class

  1. Primary Key Class (1 messages)

    Hi all,
    sorry for this stupid question but
    I don'n remember where I must put
    the Primary Key Class for an Entity Bean
    (with a compound PK): in the same package
    of the Entity Bean Class, in the package
    of the Entity Bean Interfaces or in any other
    package I want ?

    Many Tbanks
    Moreno
  2. Primary Key Class[ Go to top ]

    You can keep it in any package. You have to give the class name with complete package in your ejb-jar.xml. So it doesn't matter where you keep as long as it is within your jar file.

    <prim-key-class>aaa.bbb.ccc.UserPK</prim-key-class>

    Thanks,
    Senthil.