Learning NHibernate 4

Suhas Chatekar

  • 出版商: Packt Publishing
  • 出版日期: 2015-07-31
  • 售價: $2,180
  • 貴賓價: 9.5$2,071
  • 語言: 英文
  • 頁數: 402
  • 裝訂: Paperback
  • ISBN: 1784393568
  • ISBN-13: 9781784393564
  • 相關分類: Java 相關技術
  • 海外代購書籍(需單獨結帳)

相關主題

商品描述

Explore the full potential of NHibernate to build robust data access code

About This Book

  • Build a robust and scalable data access layer using NHibernate's features and practical wisdom
  • Use patterns such as specification and query object to make data access layer maintainable and extensible
  • Work effectively with legacy databases using lesser known NHibernate features

Who This Book Is For

This book targets .NET developers who have never used an ORM before, developers who have used an ORM before but are new to NHibernate, or have used NHibernate sparingly and want to learn more about NHibernate.

What You Will Learn

  • Map domain entities to a database schema using the different mapping mechanisms available
  • Configure NHibernate through XML configuration
  • Save, update, and delete entities in the database and query data from a database using different querying methods
  • Optimize database operations for speed and memory consumption
  • Use NHibernate in real-life software projects
  • Get to know about data access patterns such as repository, specification, and query object
  • Use NHibernate with legacy databases

In Detail

Connecting the object-oriented world of .NET to the relational world of databases has always been fiddly but with the onset of ORMs such as NHibernate, developers have finally got some relief in this area.

You will begin with a bird's eye view of NHibernate, touching upon its core concepts. You will define domain model and map it with database schema using different techniques. You will then look into multiple ways of storing domain entities in a database and learn important concepts such as transitive persistence, transactions and unit of work. This will be followed by retrieving data from database. Next, you will optimize your code, explore concepts such as the onion architecture, and learn where NHibernate fits best in an application's architecture. After introducing a well-known repository pattern into our application, you will learn to deal with legacy databases. We will conclude with infrequently used features such as stateless sessions, the second level cache, concurrency, and so on, which might come handy.

商品描述(中文翻譯)

探索 NHibernate 的全部潛力,建立強大的數據訪問代碼

關於本書



  • 使用 NHibernate 的功能和實用智慧來建立強大且可擴展的數據訪問層

  • 使用規範和查詢對象等模式,使數據訪問層易於維護和擴展

  • 使用較少人知的 NHibernate 功能,有效地處理遺留數據庫

本書適合對象


本書針對從未使用過 ORM 的 .NET 開發人員、曾使用過 ORM 但對 NHibernate 不熟悉的開發人員,以及對 NHibernate 使用有限且希望深入了解的開發人員。

你將學到什麼



  • 使用不同的映射機制將領域實體映射到數據庫模式

  • 通過 XML 配置來配置 NHibernate

  • 在數據庫中保存、更新和刪除實體,並使用不同的查詢方法從數據庫中查詢數據

  • 優化數據庫操作以提高速度和內存消耗

  • 在實際軟件項目中使用 NHibernate

  • 了解存取數據的模式,如存儲庫、規範和查詢對象

  • 與遺留數據庫一起使用 NHibernate

詳細內容


將 .NET 的面向對象世界與關聯數據庫的世界連接一直是一個棘手的問題,但隨著 NHibernate 等 ORM 的出現,開發人員終於在這個領域獲得了一些解脫。


你將從 NHibernate 的整體概覽開始,涉及其核心概念。你將定義領域模型並使用不同的技術將其映射到數據庫模式。然後,你將探索將領域實體存儲到數據庫的多種方式,並學習重要概念,如遞歸持久性、事務和工作單元。接下來,你將從數據庫中檢索數據。然後,你將優化代碼,探索概念,如洋蔥架構,並學習 NHibernate 在應用程序架構中的最佳適用場景。在將著名的存儲庫模式引入我們的應用程序後,你將學習如何處理遺留數據庫。最後,我們將介紹一些不常用的功能,如無狀態會話、第二級緩存、並發等,這些功能可能會派上用場。