java.lang.Object
org.eclipse.persistence.sdo.helper.FileCodeWriter
- All Implemented Interfaces:
CodeWriter
Purpose:Used in conjunction with SDOClassGenerator. FileCodeWriter will be used by default with SDOClassGenerator unless another CodeWriter is specified by the user. Writes files to the file system.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the sourceDir variable.voidsetSourceDir(String sourceDir) Sets the sourceDir variable.voidwriteFile(String dir, String filename, StringBuffer content) Called by both writeInterface and writeImplvoidwriteImpl(String dir, String filename, StringBuffer content) Called from org.eclipse.persistence.sdo.helper.SDOClassGenerator for each generated interface if a CodeWriter was passed into the generate method.voidwriteInterface(String dir, String filename, StringBuffer content) Called from org.eclipse.persistence.sdo.helper.SDOClassGenerator for each generated interface if a CodeWriter was passed into the generate method.
-
Constructor Details
-
FileCodeWriter
public FileCodeWriter()
-
-
Method Details
-
writeInterface
Called from org.eclipse.persistence.sdo.helper.SDOClassGenerator for each generated interface if a CodeWriter was passed into the generate method.
- Specified by:
writeInterfacein interfaceCodeWriter- Parameters:
dir- The directory corresponding to the package of the generated source filefilename- The name of the generated source file including the .java extensioncontent- StringBuffer containing the contents of the generated interface.
-
writeImpl
Called from org.eclipse.persistence.sdo.helper.SDOClassGenerator for each generated interface if a CodeWriter was passed into the generate method.
- Specified by:
writeImplin interfaceCodeWriter- Parameters:
dir- The directory corresponding to the package of the generated source filefilename- The name of the generated source file including the .java extensioncontent- StringBuffer containing the contents of the generated implementation class.
-
writeFile
Called by both writeInterface and writeImpl
- Parameters:
dir- The directory corresponding to the package of the generated source file param filename The name of the generated source file including the .java extensioncontent- StringBuffer containing the contents of the generate Java file
-
setSourceDir
Sets the sourceDir variable.- Parameters:
sourceDir-
-
getSourceDir
Gets the sourceDir variable.
-