Top Description Methods
org.hibernate.bytecode.enhance.spi

public Interface Enhancer

Known Direct Implementers
org.hibernate.bytecode.enhance.internal.bytebuddy.EnhancerImpl

Class responsible for performing enhancement.
Authors
Steve Ebersole, Jason Greene, Luis Barreiro

Method Summary

Modifier and TypeMethod and Description
public byte[]

Returns:

The enhanced bytecode. If the original bytes are not enhanced, null is returned.
enhance
(String
The name of the class whose bytecode is being enhanced.
className
,
byte[]
The class's original (pre-enhancement) byte code
originalBytes
)

Performs the enhancement.

Method Detail

enhanceback to summary
public byte[] enhance(String className, byte[] originalBytes) throws EnhancementException

Performs the enhancement. It is possible to invoke this method concurrently, but when doing so make sure no two enhancement tasks are invoked on the same class in parallel: the Enhancer implementations are not required to guard against this.

Parameters
className:String

The name of the class whose bytecode is being enhanced.

originalBytes:byte[]

The class's original (pre-enhancement) byte code

Returns:byte[]

The enhanced bytecode. If the original bytes are not enhanced, null is returned.

Exceptions
EnhancementException:
Indicates a problem performing the enhancement