/**
  * Initializes the object.
  * This method is called at the end of the constructor. The default implementation will trigger
  * an [[EVENT_INIT]] event. If you override this method, make sure you call the parent implementation at the end
  * to ensure triggering of the event.
  */
 public function init()
 {
     parent::init();
     $this->trigger(self::EVENT_INIT);
 }
Example #2
0
 /**
  * 
  */
 public static function query()
 {
     // Get collection name
     $collectionName = static::$collectionName;
     // Init query
     return Query::init($collectionName, get_called_class());
 }