public class

ImmutableMutabilityPlan

extends Object
implements MutabilityPlan<T>
java.lang.Object
   ↳ org.hibernate.type.descriptor.java.ImmutableMutabilityPlan<T>

Class Overview

Mutability plan for immutable objects

Summary

Fields
public static final ImmutableMutabilityPlan INSTANCE
Public Constructors
ImmutableMutabilityPlan()
Public Methods
T assemble(Serializable cached)
Assemble a previously disassembled value.
T deepCopy(T value)
Return a deep copy of the value.
Serializable disassemble(T value)
Return a "disassembled" representation of the value.
boolean isMutable()
Can the internal state of instances of T be changed?
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.hibernate.type.descriptor.java.MutabilityPlan

Fields

public static final ImmutableMutabilityPlan INSTANCE

Public Constructors

public ImmutableMutabilityPlan ()

Public Methods

public T assemble (Serializable cached)

Assemble a previously disassembled value. This is used when pulling values from the second level cache. Compliment to disassemble(T)

Parameters
cached The disassembled state
Returns
  • The re-assembled value.

public T deepCopy (T value)

Return a deep copy of the value.

Parameters
value The value to deep copy
Returns
  • The deep copy.

public Serializable disassemble (T value)

Return a "disassembled" representation of the value. This is used to push values onto the second level cache. Compliment to assemble(Serializable)

Parameters
value The value to disassemble
Returns
  • The disassembled value.

public boolean isMutable ()

Can the internal state of instances of T be changed?

Returns
  • True if the internal state can be changed; false otherwise.