Announcement Announcement Module
Collapse
No announcement yet.
JPA metamodel generator Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • JPA metamodel generator

    While hibernate's jpamodelgen won't run on Roo annotated entities, Is there any plans of creating a roo add-on to do this ? Coding to Criteria API is proving to be difficult without it.

    Regards
    Sathya

  • #2
    Hello Sathyakumar,

    Your question is bringing an opportunity for learning something new to me...

    Please educate me: what is jpa metamodel generator for? what are the benefits for using it?

    What is the relevance of the Criteria api?

    Thank you in advance
    jD

    Note: I know I could Google it. However, I think It would be better to get an opinion for a real developer/user.

    Comment


    • #3
      Hi jD,

      JPA 2.0 has introduced Criteria API - basically building your queries using java objects and thereby do a compile time checking on the validity of the queries rather than realizing a wrong JPQL query syntax in runtime (plus java developers who are averse to SQL syntax might prefer this more),

      As a developer to actually use Criteria API, you will be needing a metamodel class corresponding to the actual entities. These metamodel classes are typically generated

      here is a nice article on it (and is actually the first link when you google ).


      Regards
      Sathya

      Comment


      • #4
        Hi Sathya,

        It looks to me like a very interesting nice-to-have feature...

        Thank you very much for your valuable information

        B. Roogards
        jD

        Comment


        • #5
          For the time being, if you push-in refactor the entities, the Hibernate JPA 2 Metamodel Generator works without problems.

          Comment

          Working...
          X