I came across a post that mentioned Tuplizer in NHibernate, can anybody provide a good definition or reference for Tuplizer?
相关问题
-
NHibernate Query
with detached criteria… - Fluent NHibernate automap PostGIS geometry type
- Using NHibernate to execute DDL statements
- Setting Linq to NHibernate ADO Command Timeout
- NHibernate: many-to-one and lazy
相关文章
- Fluent NHibernate — Saving Entity with Composite K
- Is this the right way of using ThenFetch() to load
- Can Persistence Ignorance Scale?
- How to find if a referenced object can be deleted?
- NHibernate SQL query slow
- NHibernate: How to perform eager subselect fetchin
- Nhibernate Conformist Mapping “Unable to determine
- Using NHibernate transaction in SqlBulkCopy
Well, it might help to understand what a tuple is, first:
http://en.wikipedia.org/wiki/Tuple
Python is most notable for having first class support for Tuples, though some other languages do as well (F#)
http://diveintopython3.ep.io/native-datatypes.html#tuples
and of course!
https://stackoverflow.com/search?q=tuples
From ITuplizer's source code:
In the words of Fabio Maulo:
Some things you can do with custom tuplizers:
org.hibernate.tuple.Tuplizer, and its sub-interfaces, are responsible for managing a particular representation of a piece of data given that representation's org.hibernate.EntityMode. If a given piece of data is thought of as a data structure, then a tuplizer is the thing that knows how to create such a data structure and how to extract values from and inject values into such a data structure. For example, for the POJO entity mode, the corresponding tuplizer knows how create the POJO through its constructor. It also knows how to access the POJO properties using the defined property accessors. There are two high-level types of Tuplizers, represented by the org.hibernate.tuple.entity.EntityTuplizer and org.hibernate.tuple.component.ComponentTuplizer interfaces. EntityTuplizers are responsible for managing the above mentioned contracts in regards to entities, while ComponentTuplizers do the same for components.