Package org.apache.openjpa.enhance
package org.apache.openjpa.enhance
OpenJPA Enhancer
This package provides a bytecode enhancer used to post-process classes for use in a OpenJPA runtime. A tool for generating application identity class sourcecode is also provided.
-
ClassDescriptionGenerates a class appropriate for use as an application identity class.Run flags.Interface implemented by metadata factories that can load non-existant object id classes.Instances of this interface can convert a positional index for a
FieldMetaData
that uses property access into the underlying field name.Redefines the method bodies of existing classes.Generates Java class code from metadata.Instances that implement this marker interface are dynamically-generated subtypes of managed types that were loaded before being enhanced.Interface for dynamically generated classes.Factory for creating newDynamicStorage
classes.Consumes persistent field values.Manages persistent fields.Supplies persistent field values.Factory for obtaining anInstrumentation
instance.Redefines the method bodies of existing unenhanced classes to make them notify state managers of mutations.Instances of this interface can provide an underlying instance.Transformer that makes persistent classes implement thePersistenceCapable
interface at runtime.GeneratesPCData
instances which avoid primitive wrappers to optimize memory use and performance at the cost of slightly higher startup time.DynamicPCData
s generated will implement this interface to simplify initialization.Bytecode enhancer used to enhance persistent classes from metadata.Plugin interface for additional enhancement.Run flags.Java agent that makes persistent classes work with OpenJPA at runtime.Tracks registered persistence-capable classes.Listener for persistent class registration events.Validates that a given type meets the JPA contract, plus a few OpenJPA-specific additions for subclassing / redefinition: must have an accessible no-args constructor must be a public or protected class must not be final must not extend an enhanced class all persistent data represented by accessible setter/getter methods (persistent properties) if versioning is to be used, exactly one persistent property for the numeric version data When using property access, the backing field for a persistent property must be: private set only in the designated setter, in the constructor, or inObject.clone()
,readObject(ObjectInputStream)
, orExternalizable.readExternal(ObjectInput)
. read only in the designated getter and the constructor.The interface that persistent instances will implement.Helper methods for managed types that use method redefinition for field tracking.Implementation of thePersistenceCapable
interface that can handle the persistence-capable contract for instances that were not enhanced before class load time.Reflection utilities used to support and augment enhancement.Possible values for theopenjpa.RuntimeUnenhancedClasses
configuration setting.Internal state manager for managed instances.