Home » Search

About entity

41-50 of 200 Refresh
JPA Doc
34

contains(entity)

Method javax.persistence.EntityManager boolean contains(   Object  entity ) Check if the instance is a managed entity instance belonging to the current persistence context. Parameters: entity - entity instance Returns: boolean indicating if entity is in persistence context Throws: IllegalArgumentException - if not an entity Since: JPA 1.0
JPA Doc
34

entity(cls)

Method javax.persistence.metamodel.Metamodel EntityType entity(   Class  cls ) Return the metamodel entity type representing the entity. Parameters: cls - the type of the represented entity Returns: the metamodel entity type Throws: IllegalArgumentException - if not an entity Since: JPA 2.0
JPA Doc
34

from(entity)

Method javax.persistence.criteria.AbstractQuery Root from(   EntityType   entity ) Create and add a query root corresponding to the given entity, forming a cartesian product with any existing roots. Parameters: entity - metamodel entity representing the entity of type X Returns: query root corresponding to the given entity Since: JPA 2.0
JPA Doc
34

isLoaded(entity)

Method javax.persistence.PersistenceUtil boolean isLoaded(   Object  entity ) Determine the load state of an entity. This method can be used to determine the load state of an entity passed as a reference. An entity is considered loaded if all attributes for which FetchType.EAGER has been specified
JPA Doc
34

isLoadedWithReference(entity, attributeName)

Method javax.persistence.spi.ProviderUtil LoadState isLoadedWithReference(   Object  entity,   String attributeName ) If the provider determines that the entity has been provided by ... . If a provider determines that the entity has been provided by itself and that either the entity attributes
JPA Doc
34

getLockMode(entity)

Method javax.persistence.EntityManager LockModeType getLockMode(   Object  entity ) Get the current lock mode for the entity instance. Parameters: entity - entity instance Returns: lock mode Throws ... is not a managed entity and a transaction is active Since: JPA 2.0
JPA Doc
34

isLoaded(entity, attributeName)

Method javax.persistence.PersistenceUnitUtil boolean isLoaded(   Object  entity,   String attributeName ) Determine the load state of a given persistent attribute of an entity belonging to the persistence unit. Parameters: entity - entity instance containing the attribute attributeName - name
Manual
34

JPA Lifecycle Events

Callback methods are user defined methods that are attached to entity lifecycle events ... methods are methods that are defined within an entity class. For example, the following entity class defines all the supported callback methods with empty implementations: @ Entity public static class
JPA Doc
33

Entity.name

Annotation Element javax.persistence. Entity String name (Optional) The entity name. Defaults to the unqualified name of the entity class. This name is used to refer to the entity in queries. The name must not be a reserved literal in the Java Persistence query language. Default value: "" Since: JPA 1.0
JPA Doc
33

isLoaded(entity, attributeName)

Method javax.persistence.PersistenceUtil boolean isLoaded(   Object  entity,   String attributeName ) Determine the load state of a given persistent attribute. Parameters: entity - entity containing ... if entity's state has not been loaded or if the attribute state has not been loaded, else true Since: JPA 2.0