Removed dep on API
[ninja.git] / src / op5 / ninja_sdk / orm / ORMWrapperGenerator.php
blob67090185772a0618ac1d7438bbe0ab7470c48d59
1 <?php
3 class ORMWrapperGenerator extends class_generator {
5 private $structure;
6 private $modifiers = false;
7 private $baseclasspath = false;
9 public function __construct( $classname, $modifiers=false, $baseclasspath=false ) {
10 $this->classname = $classname;
11 $this->modifiers = $modifiers;
12 $this->baseclasspath = $baseclasspath;
13 $this->set_model();
15 if( $this->modifiers === false ) {
16 $this->modifiers = array();
20 public function generate($skip_generated_note = true) {
21 parent::generate($skip_generated_note);
22 $baseclassname = 'Base'.$this->classname;
23 if( $this->baseclasspath ) {
24 $this->classfile($this->baseclasspath,true);
26 $this->init_class( $baseclassname, $this->modifiers );
27 $this->finish_class();