Category Archives: ORM

Why Repository SaveUpdate is a smell

One of the idioms I see a fair amount of is the SaveUpdate method on a Repository. The intent is usually to persist an item to storage, using a SaveUpdate method to lazily avoid the question of whether it is … Continue reading 

Also posted in .Net, DDD, NHibernate | 5 Comments

It’s turtles all the way down

Normal 0 false false false EN-GB X-NONE X-NONE MicrosoftInternetExplorer4   Classically an ORM persists an object model to a relational model. Typically just use it to retrieve or persist the state of the objects in our model, not provide integration … Continue reading 

Also posted in Architecture, DDD, Object-Orientation | 5 Comments

Introduction to NHibernate, pt. 6

Last time we looked at mapping value types and user defined types. This time I want to look at sessions. Understanding sessions is one of the challenges for any developers approaching ORMs for the first time, because they can represent … Continue reading 

Also posted in NHibernate | Leave a comment

Introduction to NHibernate, pt.5

Last time around Last time we looked at how we map inheritance in NHibernate. This time I want to look at value types. Mapping Value types NHibernate supports a ‘fine-grained object model’. That is to say it allows us to … Continue reading 

Also posted in NHibernate, Object-Orientation | 9 Comments

ALT.NET Seattle 2009, some impressions

Having just got back from Alt.Net Seattle 2009, I wanted to post a few reflections. Mostly this is just a dump of things that grabbed my attention – its not meant to be any kind of documentation of the convesations … Continue reading 

Also posted in Agile, altnetconf, Events, Mocks, NHibernate | 10 Comments

Introduction to NHibernate, pt. 4

Last time we started looking at the parts of an OO model that need translation to relational form when we looked at mapping relationships. This time we will look at another area where we need to translate: mapping inheritance hierarchies. … Continue reading 

Also posted in NHibernate, Object-Orientation | 1 Comment

Introduction to NHibernate, Part 3

    Last time we looked at mapping an entity. This time we will look at mapping the entity’s relationships. Mapping Relationships  The collection types that NHibernate understands are: <set>, <list>, <map>, <bag>, <array> and <primitive-array>   <set> is the … Continue reading 

Also posted in NHibernate | 6 Comments

Introduction to NHibernate, Part 2

  Last time we introduced setting up the configuration file. This time we will look at the basics of mapping. Mapping Entities How you map your entities depends upon your preferred approach. Attributes or mapping files You can use either … Continue reading 

Also posted in ., NHibernate | 11 Comments

Introduction to NHibernate, Part 1

To go alongside my set of posts on LINQ To SQL I wanted to post an Introduction to NHibernate. These posts are not intended as any kind of masterclass, so experienced NHibernate hands might want to skip them. They are … Continue reading 

Also posted in NHibernate, Object-Orientation | 4 Comments

Impedance Mismatch Reframing

  This is a reply to Stephen Fortes post Impedance Mismatch from a ways back. I would have posted about it sooner but I sadly just saw it today when a co-worker Stefan Moser linked it over to me. I … Continue reading 

| Leave a comment