|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.hibernate.type.AbstractType
org.hibernate.type.EntityType
org.hibernate.type.ManyToOneType
A many-to-one association to an entity
| Field Summary |
| Fields inherited from class org.hibernate.type.EntityType |
isEmbeddedInXML, uniqueKeyPropertyName |
| Constructor Summary | |
ManyToOneType(String className)
|
|
ManyToOneType(String className,
boolean lazy)
|
|
ManyToOneType(String className,
String uniqueKeyPropertyName,
boolean lazy,
boolean isEmbeddedInXML,
boolean ignoreNotFound)
|
|
| Method Summary | |
Object |
assemble(Serializable oid,
SessionImplementor session,
Object owner)
Reconstruct the object from its cached "disassembled" state. |
Serializable |
disassemble(Object value,
SessionImplementor session,
Object owner)
Return a cacheable "disassembled" representation of the object. |
int |
getColumnSpan(Mapping mapping)
How many columns are used to persist this type. |
ForeignKeyDirection |
getForeignKeyDirection()
Get the foreign key directionality of this association |
Object |
hydrate(ResultSet rs,
String[] names,
SessionImplementor session,
Object owner)
Retrieve an instance of the mapped class, or the identifier of an entity or collection, from a JDBC resultset. |
boolean |
isAlwaysDirtyChecked()
Do we dirty check this association, even when there are no columns to be updated? |
boolean |
isModified(Object old,
Object current,
SessionImplementor session)
Has the parent object been modified, compared to the current database state? |
protected boolean |
isNullable()
|
boolean |
isOneToOne()
|
void |
nullSafeSet(PreparedStatement st,
Object value,
int index,
boolean[] settable,
SessionImplementor session)
Write an instance of the mapped class to a prepared statement, ignoring some columns. |
void |
nullSafeSet(PreparedStatement st,
Object value,
int index,
SessionImplementor session)
Write an instance of the mapped class to a prepared statement. |
int[] |
sqlTypes(Mapping mapping)
Return the SQL type codes for the columns mapped by this type. |
boolean |
useLHSPrimaryKey()
Is the primary key of the owning entity table to be used in the join? |
| Methods inherited from class org.hibernate.type.AbstractType |
getHashCode, isAnyType, isCollectionType, isComponentType, isEqual, replaceNode, semiResolve |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.hibernate.type.Type |
getHashCode, isAnyType, isCollectionType, isComponentType, isEqual, semiResolve |
| Constructor Detail |
public ManyToOneType(String className)
public ManyToOneType(String className,
boolean lazy)
public ManyToOneType(String className,
String uniqueKeyPropertyName,
boolean lazy,
boolean isEmbeddedInXML,
boolean ignoreNotFound)
| Method Detail |
protected boolean isNullable()
isNullable in class EntityTypepublic boolean isAlwaysDirtyChecked()
AssociationType
public int getColumnSpan(Mapping mapping)
throws MappingException
Type
MappingException
public int[] sqlTypes(Mapping mapping)
throws MappingException
Type
MappingExceptionTypes
public void nullSafeSet(PreparedStatement st,
Object value,
int index,
boolean[] settable,
SessionImplementor session)
throws HibernateException,
SQLException
Type
st - value - the object to writeindex - statement parameter indexsettable - an array indicating which columns to ignoresession -
SQLException
HibernateException
public void nullSafeSet(PreparedStatement st,
Object value,
int index,
SessionImplementor session)
throws HibernateException,
SQLException
Type
st - value - the object to writeindex - statement parameter indexsession -
SQLException
HibernateExceptionpublic boolean isOneToOne()
isOneToOne in class EntityTypepublic ForeignKeyDirection getForeignKeyDirection()
AssociationType
public Object hydrate(ResultSet rs,
String[] names,
SessionImplementor session,
Object owner)
throws HibernateException,
SQLException
Type
hydrate in interface Typehydrate in class AbstractTypeHibernateException
SQLExceptionpublic boolean useLHSPrimaryKey()
AssociationType
public boolean isModified(Object old,
Object current,
SessionImplementor session)
throws HibernateException
Type
isModified in interface TypeisModified in class AbstractTypeHibernateException
public Serializable disassemble(Object value,
SessionImplementor session,
Object owner)
throws HibernateException
Type
disassemble in interface Typedisassemble in class AbstractTypeHibernateException
public Object assemble(Serializable oid,
SessionImplementor session,
Object owner)
throws HibernateException
Type
assemble in interface Typeassemble in class AbstractTypeHibernateException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||