当前位置:首页 » 软件开发
开发技术指南» 文章正文
    引言: Typically when I map my applicat
 

 

    摘要:introduction xml has become one of the major technologies used today for business integration software evolution. lots of object models are being used today to manipulate xml in various ways. axi......
    摘要:in part one of this series, we looked at five free or nearly-free java html renderers, evaluating them in terms of support for modern standards (xhtml and css1/css2 support), support for legacy pages......


Hibernate: Discriminators and Table-Per-Subclass
typically when i map my application to a relational database, each record in the database is modeled by an object in java. hibernate is designed specifically to solve the problem of creating java objects for the records in the database, without writing miles and miles of code that converts sql results to objects, and vice-versa. while i dont intend to use this tip entry to thoroughly cover the basics of hibernate, i will set up a basic example.

say i have the class user, and we want to map it to our database. piece of cake so far - here is our main bootstrap test class: 【程序编程相关:Linux on the Desktop

before i get too far ahead of myself, however, let me explain what i want to achieve. what i would like to explain in this tip is how to map inheritence of your beans with varying tables in your database. the comprehensive details of hibernate inheritence mapping can be found at this url: http://www.hibernate.org/hib_docs/v3/reference/en/html/inheritance.html - today ill be discussing inheritence mapping of the variety table per subclass, using a discriminator . while each type of mapping has its various advantages and disadvantages, i am describing the table with discriminator variety here because it is the implementation i see most often in legacy applications not using hibernate (it seems to be fairly common) - and you may have a need for it. the variety that doesnt have a discriminator is easier anyway, so this example describes more than enough for you to try the recommended hibernate format - table per subclass - no discriminator - if you so wish). 【推荐阅读:Integrating Java Ope


...   下一页
    摘要:without soa, says orbitzs chief technology officer, his company - founded in 2000 and successfully ipod since then - wouldnt be able to leverage its main competititive advantage: speed to market. he......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE