public interface IdentifierLoadAccess
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getReference(java.io.Serializable id)
Return the persistent instance with the given identifier, assuming that the instance exists.
|
java.lang.Object |
load(java.io.Serializable id)
Return the persistent instance with the given identifier, or null if there is no such persistent instance.
|
IdentifierLoadAccess |
with(LockOptions lockOptions)
Specify the
LockOptions to use when retrieving the entity. |
IdentifierLoadAccess with(LockOptions lockOptions)
LockOptions
to use when retrieving the entity.lockOptions
- The lock options to use.this
, for method chainingjava.lang.Object getReference(java.io.Serializable id)
load(java.io.Serializable)
instead. Use this only to retrieve an instance that you assume exists, where non-existence would be an
actual error.id
- The identifier for which to obtain a referencejava.lang.Object load(java.io.Serializable id)
id
- The identifiernull
Copyright © 2001-2013 Red Hat, Inc. All Rights Reserved.