Heystack\Core\DataObjectGenerate\DataObjectGenerator
Generates SilverStripe DataObject classes and extensions based on added schemas
Schemas are retrieved via the provided schema service. Using this information this service
can generate DataObject classes that are by default saved into "mysite/code/HeystackStorage"
The service will generate both Cached* files and Stored* file. The Cached* files are not meant
to be overwritten by developers but the Stored* file are able to be edited, and as long
as the "force" flag isn't used in the process method, the edited Stored classes will not be overwritten
- Author: Cam Spiers <cameron@heyday.co.nz>
Synopsis
class DataObjectGenerator
{
- // members
- private array $processingFlatStorage = ;
- private $storageLocation;
- // methods
- public void __construct()
- public void process()
- protected void writeDataObject()
- protected void writeModelAdmin()
- public bool|string isReference()
- protected array processFlatStorage()
- protected mixed processParentStorage()
- protected mixed processChildStorage()
- protected mixed beautify()
- protected void output()
- protected SSViewer getDataObjectSSViewer()
- protected SSViewer getModelAdminSSViewer()
- // Inherited methods from HasSchemaServiceTrait
- public void setSchemaService()
- public SchemaService getSchemaService()
Hierarchy
Members
private
- $processingFlatStorage — array
- $storageLocation — string
protected
- $schemaService — \Heystack\Core\DataObjectSchema\SchemaService