コード例 #1
0
ファイル: Models.php プロジェクト: harp-orm/harp
 /**
  * Add all models from a different Models collection
  *
  * @param Models $other
  */
 public function addAll(Models $other)
 {
     if ($other->count() > 0) {
         $this->models->addAll($other->models);
     }
     return $this;
 }
コード例 #2
0
ファイル: Update.php プロジェクト: harp-orm/harp
 public function executeModels(Models $models)
 {
     if ($models->count() == 1) {
         $this->model($models->getFirst());
     } else {
         $this->models($models);
     }
     $this->execute();
 }
コード例 #3
0
ファイル: LinkMany.php プロジェクト: harp-orm/harp
 /**
  * @return int
  */
 public function count()
 {
     return $this->current->count();
 }
コード例 #4
0
ファイル: Save.php プロジェクト: harp-orm/harp
 /**
  * @return int
  */
 public function count()
 {
     return $this->models->count();
 }