public final class EntityKey extends Object implements Serializable
equals(java.lang.Object)).
Performance considerations: lots of instances of this type are created at runtime. Make sure each one is as small as possible
by storing just the essential needed.| Constructor and Description |
|---|
EntityKey(Serializable id,
EntityPersister persister)
Construct a unique identifier for an entity class instance.
|
| Modifier and Type | Method and Description |
|---|---|
static EntityKey |
deserialize(ObjectInputStream ois,
SessionFactoryImplementor sessionFactory)
Custom deserialization routine used during deserialization of a
Session/PersistenceContext for increased performance.
|
boolean |
equals(Object other) |
String |
getEntityName() |
Serializable |
getIdentifier() |
int |
hashCode() |
boolean |
isBatchLoadable() |
void |
serialize(ObjectOutputStream oos)
Custom serialization routine used during serialization of a
Session/PersistenceContext for increased performance.
|
String |
toString() |
public EntityKey(Serializable id, EntityPersister persister)
SessionImplementor.generateEntityKey(java.io.Serializable, org.hibernate.persister.entity.EntityPersister) method was added to hide the session-specific changes.id - The entity idpersister - The entity persisterpublic boolean isBatchLoadable()
public Serializable getIdentifier()
public String getEntityName()
public void serialize(ObjectOutputStream oos) throws IOException
oos - The stream to which we should write the serial data.IOException - Thrown by Java I/Opublic static EntityKey deserialize(ObjectInputStream ois, SessionFactoryImplementor sessionFactory) throws IOException, ClassNotFoundException
ois - The stream from which to read the entry.sessionFactory - The SessionFactory owning the Session being deserialized.IOException - Thrown by Java I/OClassNotFoundException - Thrown by Java I/OCopyright © 2018 JBoss by Red Hat. All rights reserved.