jef.disconnection
Interface FieldDisconnector
- All Superinterfaces:
- Disconnector
- All Known Implementing Classes:
- DefaultFieldDisconnector
public interface FieldDisconnector
- extends Disconnector
This interface defines the contract every concrete class responsible of extracting a field's
definition from a Java class has to adhere to.
- Author:
- frusso@dev.java.net
extract
void extract(FieldInfoStructure fieldInfo,
DisconnectedField disconnectedField,
DeepCopier deepCopier)
throws DisconnectionFailedException
- This method copies into the
disconnectField instance provided as parameter the
fieldInfo object. Actually this is a real copy, that is the source
fieldInfo gets cloned and all its references to cp_infos
entries are correctly updated.
What this means is that the copy of a field from a source Dna to a target
DisconnectField data structure entails a deep copy of all the referenced
cp_infos. This is a required step to bring into the target
DisconnectedField all the other information on which the field definition is
based.
Note: if using a stateful deep copier it is fundamental to perform all the deep copy
invocations by means of the same DeepCopier instance.
- Parameters:
fieldInfo - The reference to the field to be copied into the target
disconnectMethoddisconnectField - The target DisconnectedField instance in which the disconnected
method will be stored for a subsequent injectiondeepCopier - The DeepCopier instance needed to perform the deep copy operation
- Throws:
DisconnectionFailedException