Package com.mchange.v2.codegen.bean
Class IndirectingSerializableExtension
java.lang.Object
com.mchange.v2.codegen.bean.SerializableExtension
com.mchange.v2.codegen.bean.IndirectingSerializableExtension
- All Implemented Interfaces:
GeneratorExtension
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionprotected
IndirectingSerializableExtension
(String indirectorClassName) We expect this indirector to be a public class with a public no_arg ctor; If you need the indirector initialized somehow, you'll have to extend the class. -
Method Summary
Modifier and TypeMethodDescriptionvoid
generate
(ClassInfo info, Class superclassType, Property[] props, Class[] propTypes, IndentedWriter iw) protected IndirectPolicy
indirectingPolicy
(Property prop, Class propType) protected void
writeExtraDeclarations
(ClassInfo info, Class superclassType, Property[] props, Class[] propTypes, IndentedWriter iw) protected void
writeIndirectStoreObject
(Property prop, Class propType, IndentedWriter iw) protected void
writeInitializeIndirector
(Property prop, Class propType, IndentedWriter iw) hook method...protected void
writeStoreObject
(Property prop, Class propType, IndentedWriter iw) protected void
writeUnstoreObject
(Property prop, Class propType, IndentedWriter iw) Methods inherited from class com.mchange.v2.codegen.bean.SerializableExtension
extraGeneralImports, extraInterfaceNames, generateExtraSerInitializers, generateExtraSerWriteStatements
-
Field Details
-
findIndirectorExpr
-
indirectorClassName
-
-
Constructor Details
-
IndirectingSerializableExtension
We expect this indirector to be a public class with a public no_arg ctor; If you need the indirector initialized somehow, you'll have to extend the class.- See Also:
-
IndirectingSerializableExtension
protected IndirectingSerializableExtension()
-
-
Method Details
-
extraSpecificImports
- Specified by:
extraSpecificImports
in interfaceGeneratorExtension
- Overrides:
extraSpecificImports
in classSerializableExtension
-
indirectingPolicy
-
writeInitializeIndirector
protected void writeInitializeIndirector(Property prop, Class propType, IndentedWriter iw) throws IOException hook method... does nothing by default... override at will. The indirector will be called, uh, "indirector". You are in the middle of a method when you define this.- Throws:
IOException
-
writeExtraDeclarations
protected void writeExtraDeclarations(ClassInfo info, Class superclassType, Property[] props, Class[] propTypes, IndentedWriter iw) throws IOException - Throws:
IOException
-
generate
public void generate(ClassInfo info, Class superclassType, Property[] props, Class[] propTypes, IndentedWriter iw) throws IOException - Specified by:
generate
in interfaceGeneratorExtension
- Overrides:
generate
in classSerializableExtension
- Throws:
IOException
-
writeStoreObject
protected void writeStoreObject(Property prop, Class propType, IndentedWriter iw) throws IOException - Overrides:
writeStoreObject
in classSerializableExtension
- Throws:
IOException
-
writeIndirectStoreObject
protected void writeIndirectStoreObject(Property prop, Class propType, IndentedWriter iw) throws IOException - Throws:
IOException
-
writeUnstoreObject
protected void writeUnstoreObject(Property prop, Class propType, IndentedWriter iw) throws IOException - Overrides:
writeUnstoreObject
in classSerializableExtension
- Throws:
IOException
-