NHibernate 3 Beginner's Guide

Dr. Gabriel Nicolas Schenker, Aaron Cure

  • 出版商: Packt Publishing
  • 出版日期: 2011-08-20
  • 售價: $1,710
  • 貴賓價: 9.5$1,625
  • 語言: 英文
  • 頁數: 368
  • 裝訂: Paperback
  • ISBN: 1849516022
  • ISBN-13: 9781849516020
  • 相關分類: Java 相關技術
  • 下單後立即進貨 (約3~4週)

商品描述

Rapidly retrieve data from your database into .NET objects

  • Incorporate robust, efficient data access into your .Net projects
  • Reduce hours of application development time and get better application architecture and performance
  • Create your domain model first and then derive the database structure automatically from the model
  • Test, profile, and monitor data access to tune the performance and make your applications fly
  • Clear, precise step-by-step directions to get you up and running quickly

In Detail

Ideally, we would want to persist the objects our application uses and produces AS IS, without having to first transform them in complex ways. NHibernate is a framework that provides us with an object-oriented access to a relational database without having to write SQL and with little or no database-specific data access code. Definitely, if you are a .NET developer, knowing more about NHibernate will simplify and reduce your efforts in developing .Net applications.NHibernate 3 Beginner's Guide introduces Nhibernate with step-by-step examples, and is the easiest way to learn about bridging the gap between object-oriented .NET applications and the relational database that stores the application's data. It is a beginner's guide to NHibernate that starts from scratch. Successive chapters build upon earlier concepts, while the sample code presents various ways to accomplish typical data access tasks.

NHibernate 3 Beginner's Guide examines all of the topics required to get a functional data access layer implemented while writing the least amount of code possible, presenting options along the way to handle particular edge cases or situations as they arise. The book begins with an introduction to NHIbernate 3 and then moves on to creating the development environment. Then it teaches you how to create a model, define a database schema, and map the model to the database then covers sessions and transactions. This is succeeded by testing, profiling, and configuration, validation of data and writing queries. Finally, we wrap up with notes on the common pitfalls that you should avoid.

Once you complete reading the book, you will have gained the skills and knowledge to incorporate NHibernate into your own applications.

An easy-to-follow guide that will show you how to connect the NHibernate object-relational mapper to your projects to create a rich, efficient, object-oriented data access layer with little or no additional work

What you will learn from this book

  • Create a domain model
  • Learn different techniques to map the domain model to the underlying database
  • Build the database from your model automatically
  • Use session and transactions to persist and retrieve data
  • Efficiently query the database by using LINQ to NHibernate and HQL
  • Configure your system for use of NHibernate in a clear and concise way
  • Write unit and integration tests for your data access layer
  • Learn about the common pitfalls that should be avoided
  • Implement data validation on the entity level
  • Monitor and profile your data access

Approach

This is a beginner's guide with comprehensive step-by-step instructions. There are appropriate screenshots throughout the book and plenty of code, which is explained in a well-thought-out format.

Who this book is written for

If you are a new or seasoned developer of .NET web or desktop applications who is looking for a better way to access database data, then this book is for you. It is a basic introduction to NHibernate, with enough information to get a solid foundation in using NHibernate. Some advanced concepts are presented where appropriate to enhance functionality or in situations where they are commonly used. Absolutely no knowledge of NHibernate is required to read this book.