setName('cloud_file'); $this->setPhpName('CloudFile'); $this->setClassname('CloudFile'); $this->setPackage('airtime'); $this->setUseIdGenerator(true); $this->setPrimaryKeyMethodInfo('cloud_file_id_seq'); // columns $this->addPrimaryKey('id', 'DbId', 'INTEGER', true, null, null); $this->addColumn('storage_backend', 'StorageBackend', 'VARCHAR', true, 512, null); $this->addColumn('resource_id', 'ResourceId', 'LONGVARCHAR', true, null, null); $this->addForeignKey('cc_file_id', 'CcFileId', 'INTEGER', 'cc_files', 'id', false, null, null); // validators } // initialize() /** * Build the RelationMap objects for this table relationships */ public function buildRelations() { $this->addRelation('CcFiles', 'CcFiles', RelationMap::MANY_TO_ONE, array('cc_file_id' => 'id', ), 'CASCADE', null); } // buildRelations() /** * * Gets the list of behaviors registered for this table * * @return array Associative array (name => parameters) of behaviors */ public function getBehaviors() { return array( 'delegate' => array ( 'to' => 'cc_files', ), ); } // getBehaviors() } // CloudFileTableMap