Exemplo n.º 1
0
 public function testContains()
 {
     $col = new ObjectCollection();
     $book1 = new Book();
     $book1->setTitle('Foo');
     $book2 = new Book();
     $book2->setTitle('Bar');
     $col = new ObjectCollection();
     $this->assertFalse($col->contains($book1));
     $this->assertFalse($col->contains($book2));
     $col[] = $book1;
     $this->assertTrue($col->contains($book1));
     $this->assertFalse($col->contains($book2));
 }
Exemplo n.º 2
0
 /**
  * Method called to associate a ChildBet object to this object
  * through the ChildBet foreign key attribute.
  *
  * @param  ChildBet $l ChildBet
  * @return $this|\ApostaAiApi\Models\User The current object (for fluent API support)
  */
 public function addBet(ChildBet $l)
 {
     if ($this->collBets === null) {
         $this->initBets();
         $this->collBetsPartial = true;
     }
     if (!$this->collBets->contains($l)) {
         $this->doAddBet($l);
         if ($this->betsScheduledForDeletion and $this->betsScheduledForDeletion->contains($l)) {
             $this->betsScheduledForDeletion->remove($this->betsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 3
0
 /**
  * Method called to associate a ChildRIssuesXmlplugin object to this object
  * through the ChildRIssuesXmlplugin foreign key attribute.
  *
  * @param  ChildRIssuesXmlplugin $l ChildRIssuesXmlplugin
  * @return $this|\Plugins The current object (for fluent API support)
  */
 public function addRIssuesXmlplugin(ChildRIssuesXmlplugin $l)
 {
     if ($this->collRIssuesXmlplugins === null) {
         $this->initRIssuesXmlplugins();
         $this->collRIssuesXmlpluginsPartial = true;
     }
     if (!$this->collRIssuesXmlplugins->contains($l)) {
         $this->doAddRIssuesXmlplugin($l);
         if ($this->rIssuesXmlpluginsScheduledForDeletion and $this->rIssuesXmlpluginsScheduledForDeletion->contains($l)) {
             $this->rIssuesXmlpluginsScheduledForDeletion->remove($this->rIssuesXmlpluginsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childтипытехникимтр object to this object
  * through the Childтипытехникимтр foreign key attribute.
  *
  * @param  Childтипытехникимтр $l Childтипытехникимтр
  * @return $this|\отображаемыетипытехникимтр The current object (for fluent API support)
  */
 public function addтипытехникимтр(Childтипытехникимтр $l)
 {
     if ($this->collтипытехникимтрs === null) {
         $this->initтипытехникимтрs();
         $this->collтипытехникимтрsPartial = true;
     }
     if (!$this->collтипытехникимтрs->contains($l)) {
         $this->doAddтипытехникимтр($l);
         if ($this->�ипытехникимтрsScheduledForDeletion and $this->�ипытехникимтрsScheduledForDeletion->contains($l)) {
             $this->�ипытехникимтрsScheduledForDeletion->remove($this->�ипытехникимтрsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 5
0
 /**
  * Method called to associate a ChildBan object to this object
  * through the ChildBan foreign key attribute.
  *
  * @param  ChildBan $l ChildBan
  * @return $this|\Models\User The current object (for fluent API support)
  */
 public function addBanRelatedByBannedBy(ChildBan $l)
 {
     if ($this->collBansRelatedByBannedBy === null) {
         $this->initBansRelatedByBannedBy();
         $this->collBansRelatedByBannedByPartial = true;
     }
     if (!$this->collBansRelatedByBannedBy->contains($l)) {
         $this->doAddBanRelatedByBannedBy($l);
         if ($this->bansRelatedByBannedByScheduledForDeletion and $this->bansRelatedByBannedByScheduledForDeletion->contains($l)) {
             $this->bansRelatedByBannedByScheduledForDeletion->remove($this->bansRelatedByBannedByScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 6
0
 /**
  * Method called to associate a LyricLanguage object to this object
  * through the LyricLanguage foreign key attribute.
  *
  * @param  LyricLanguage $l LyricLanguage
  * @return $this|\Tekstove\ApiBundle\Model\Language The current object (for fluent API support)
  */
 public function addLyricLanguage(LyricLanguage $l)
 {
     if ($this->collLyricLanguages === null) {
         $this->initLyricLanguages();
         $this->collLyricLanguagesPartial = true;
     }
     if (!$this->collLyricLanguages->contains($l)) {
         $this->doAddLyricLanguage($l);
         if ($this->lyricLanguagesScheduledForDeletion and $this->lyricLanguagesScheduledForDeletion->contains($l)) {
             $this->lyricLanguagesScheduledForDeletion->remove($this->lyricLanguagesScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 7
0
 /**
  * Method called to associate a ChildTask object to this object
  * through the ChildTask foreign key attribute.
  *
  * @param  ChildTask $l ChildTask
  * @return $this|\Project The current object (for fluent API support)
  */
 public function addTask(ChildTask $l)
 {
     if ($this->collTasks === null) {
         $this->initTasks();
         $this->collTasksPartial = true;
     }
     if (!$this->collTasks->contains($l)) {
         $this->doAddTask($l);
         if ($this->tasksScheduledForDeletion and $this->tasksScheduledForDeletion->contains($l)) {
             $this->tasksScheduledForDeletion->remove($this->tasksScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 8
0
 /**
  * Method called to associate a ChildDeliveryTypeI18n object to this object
  * through the ChildDeliveryTypeI18n foreign key attribute.
  *
  * @param  ChildDeliveryTypeI18n $l ChildDeliveryTypeI18n
  * @return $this|\App\Propel\DeliveryType The current object (for fluent API support)
  */
 public function addDeliveryTypeI18n(ChildDeliveryTypeI18n $l)
 {
     if ($l && ($locale = $l->getLocale())) {
         $this->setLocale($locale);
         $this->currentTranslations[$locale] = $l;
     }
     if ($this->collDeliveryTypeI18ns === null) {
         $this->initDeliveryTypeI18ns();
         $this->collDeliveryTypeI18nsPartial = true;
     }
     if (!$this->collDeliveryTypeI18ns->contains($l)) {
         $this->doAddDeliveryTypeI18n($l);
         if ($this->deliveryTypeI18nsScheduledForDeletion and $this->deliveryTypeI18nsScheduledForDeletion->contains($l)) {
             $this->deliveryTypeI18nsScheduledForDeletion->remove($this->deliveryTypeI18nsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a ChildПредписания object to this object
  * through the ChildПредписания foreign key attribute.
  *
  * @param  ChildПредписания $l ChildПредписания
  * @return $this|\СтатусыЗаявкиЗавершение The current object (for fluent API support)
  */
 public function addПредписания(ChildПредписания $l)
 {
     if ($this->collПредписанияs === null) {
         $this->initПредписанияs();
         $this->collПредписанияsPartial = true;
     }
     if (!$this->collПредписанияs->contains($l)) {
         $this->doAddПредписания($l);
         if ($this->�редписанияsScheduledForDeletion and $this->�редписанияsScheduledForDeletion->contains($l)) {
             $this->�редписанияsScheduledForDeletion->remove($this->�редписанияsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childфизическиеобъёмы object to this object
  * through the Childфизическиеобъёмы foreign key attribute.
  *
  * @param  Childфизическиеобъёмы $l Childфизическиеобъёмы
  * @return $this|\типыработ The current object (for fluent API support)
  */
 public function addфизическиеобъёмы(Childфизическиеобъёмы $l)
 {
     if ($this->collфизическиеобъёмыs === null) {
         $this->initфизическиеобъёмыs();
         $this->collфизическиеобъёмыsPartial = true;
     }
     if (!$this->collфизическиеобъёмыs->contains($l)) {
         $this->doAddфизическиеобъёмы($l);
         if ($this->�изическиеобъёмыsScheduledForDeletion and $this->�изическиеобъёмыsScheduledForDeletion->contains($l)) {
             $this->�изическиеобъёмыsScheduledForDeletion->remove($this->�изическиеобъёмыsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 11
0
 /**
  * Method called to associate a ChildRating object to this object
  * through the ChildRating foreign key attribute.
  *
  * @param  ChildRating $l ChildRating
  * @return $this|\Models\Comment The current object (for fluent API support)
  */
 public function addRating(ChildRating $l)
 {
     if ($this->collRatings === null) {
         $this->initRatings();
         $this->collRatingsPartial = true;
     }
     if (!$this->collRatings->contains($l)) {
         $this->doAddRating($l);
         if ($this->ratingsScheduledForDeletion and $this->ratingsScheduledForDeletion->contains($l)) {
             $this->ratingsScheduledForDeletion->remove($this->ratingsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childмобилизацияпомесяцам object to this object
  * through the Childмобилизацияпомесяцам foreign key attribute.
  *
  * @param  Childмобилизацияпомесяцам $l Childмобилизацияпомесяцам
  * @return $this|\типытехникимобилизация The current object (for fluent API support)
  */
 public function addмобилизацияпомесяцам(Childмобилизацияпомесяцам $l)
 {
     if ($this->collмобилизацияпомесяцамs === null) {
         $this->initмобилизацияпомесяцамs();
         $this->collмобилизацияпомесяцамsPartial = true;
     }
     if (!$this->collмобилизацияпомесяцамs->contains($l)) {
         $this->doAddмобилизацияпомесяцам($l);
         if ($this->�обилизацияпомесяцамsScheduledForDeletion and $this->�обилизацияпомесяцамsScheduledForDeletion->contains($l)) {
             $this->�обилизацияпомесяцамsScheduledForDeletion->remove($this->�обилизацияпомесяцамsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 13
0
 /**
  * Method called to associate a ChildWishlistProduct object to this object
  * through the ChildWishlistProduct foreign key attribute.
  *
  * @param  ChildWishlistProduct $l ChildWishlistProduct
  * @return $this|\App\Propel\Wishlist The current object (for fluent API support)
  */
 public function addWishlistProduct(ChildWishlistProduct $l)
 {
     if ($this->collWishlistProducts === null) {
         $this->initWishlistProducts();
         $this->collWishlistProductsPartial = true;
     }
     if (!$this->collWishlistProducts->contains($l)) {
         $this->doAddWishlistProduct($l);
         if ($this->wishlistProductsScheduledForDeletion and $this->wishlistProductsScheduledForDeletion->contains($l)) {
             $this->wishlistProductsScheduledForDeletion->remove($this->wishlistProductsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 14
0
 /**
  * Method called to associate a ArtistLyric object to this object
  * through the ArtistLyric foreign key attribute.
  *
  * @param  ArtistLyric $l ArtistLyric
  * @return $this|\Tekstove\ApiBundle\Model\Artist The current object (for fluent API support)
  */
 public function addArtistLyric(ArtistLyric $l)
 {
     if ($this->collArtistLyrics === null) {
         $this->initArtistLyrics();
         $this->collArtistLyricsPartial = true;
     }
     if (!$this->collArtistLyrics->contains($l)) {
         $this->doAddArtistLyric($l);
         if ($this->artistLyricsScheduledForDeletion and $this->artistLyricsScheduledForDeletion->contains($l)) {
             $this->artistLyricsScheduledForDeletion->remove($this->artistLyricsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 15
0
 /**
  * Method called to associate a ChildResource object to this object
  * through the ChildResource foreign key attribute.
  *
  * @param  ChildResource $l ChildResource
  * @return $this|\App\Propel\ResourceType The current object (for fluent API support)
  */
 public function addResource(ChildResource $l)
 {
     if ($this->collResources === null) {
         $this->initResources();
         $this->collResourcesPartial = true;
     }
     if (!$this->collResources->contains($l)) {
         $this->doAddResource($l);
         if ($this->resourcesScheduledForDeletion and $this->resourcesScheduledForDeletion->contains($l)) {
             $this->resourcesScheduledForDeletion->remove($this->resourcesScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a ChildКалендарь object to this object
  * through the ChildКалендарь foreign key attribute.
  *
  * @param  ChildКалендарь $l ChildКалендарь
  * @return $this|\днинедели The current object (for fluent API support)
  */
 public function addКалендарь(ChildКалендарь $l)
 {
     if ($this->collКалендарьs === null) {
         $this->initКалендарьs();
         $this->collКалендарьsPartial = true;
     }
     if (!$this->collКалендарьs->contains($l)) {
         $this->doAddКалендарь($l);
         if ($this->�алендарьsScheduledForDeletion and $this->�алендарьsScheduledForDeletion->contains($l)) {
             $this->�алендарьsScheduledForDeletion->remove($this->�алендарьsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childпроизводственныепрограммы object to this object
  * through the Childпроизводственныепрограммы foreign key attribute.
  *
  * @param  Childпроизводственныепрограммы $l Childпроизводственныепрограммы
  * @return $this|\программы The current object (for fluent API support)
  */
 public function addпроизводственныепрограммы(Childпроизводственныепрограммы $l)
 {
     if ($this->collпроизводственныепрограммыs === null) {
         $this->initпроизводственныепрограммыs();
         $this->collпроизводственныепрограммыsPartial = true;
     }
     if (!$this->collпроизводственныепрограммыs->contains($l)) {
         $this->doAddпроизводственныепрограммы($l);
         if ($this->�роизводственныепрограммыsScheduledForDeletion and $this->�роизводственныепрограммыsScheduledForDeletion->contains($l)) {
             $this->�роизводственныепрограммыsScheduledForDeletion->remove($this->�роизводственныепрограммыsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 18
0
 /**
  * Method called to associate a ChildSession object to this object
  * through the ChildSession foreign key attribute.
  *
  * @param  ChildSession $l ChildSession
  * @return $this|\CyberdenBundle\Model\Station The current object (for fluent API support)
  */
 public function addSession(ChildSession $l)
 {
     if ($this->collSessions === null) {
         $this->initSessions();
         $this->collSessionsPartial = true;
     }
     if (!$this->collSessions->contains($l)) {
         $this->doAddSession($l);
         if ($this->sessionsScheduledForDeletion and $this->sessionsScheduledForDeletion->contains($l)) {
             $this->sessionsScheduledForDeletion->remove($this->sessionsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 19
0
 /**
  * Method called to associate a ChildTemplates object to this object
  * through the ChildTemplates foreign key attribute.
  *
  * @param  ChildTemplates $l ChildTemplates
  * @return $this|\Templatenames The current object (for fluent API support)
  */
 public function addTemplates(ChildTemplates $l)
 {
     if ($this->collTemplatess === null) {
         $this->initTemplatess();
         $this->collTemplatessPartial = true;
     }
     if (!$this->collTemplatess->contains($l)) {
         $this->doAddTemplates($l);
         if ($this->templatessScheduledForDeletion and $this->templatessScheduledForDeletion->contains($l)) {
             $this->templatessScheduledForDeletion->remove($this->templatessScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childвыработка object to this object
  * through the Childвыработка foreign key attribute.
  *
  * @param  Childвыработка $l Childвыработка
  * @return $this|\типытехникивыработка The current object (for fluent API support)
  */
 public function addвыработка(Childвыработка $l)
 {
     if ($this->collвыработкаs === null) {
         $this->initвыработкаs();
         $this->collвыработкаsPartial = true;
     }
     if (!$this->collвыработкаs->contains($l)) {
         $this->doAddвыработка($l);
         if ($this->�ыработкаsScheduledForDeletion and $this->�ыработкаsScheduledForDeletion->contains($l)) {
             $this->�ыработкаsScheduledForDeletion->remove($this->�ыработкаsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 21
0
 /**
  * Method called to associate a ChildImageGalleryMap object to this object
  * through the ChildImageGalleryMap foreign key attribute.
  *
  * @param  ChildImageGalleryMap $l ChildImageGalleryMap
  * @return $this|\Models\Image The current object (for fluent API support)
  */
 public function addImageGalleryMap(ChildImageGalleryMap $l)
 {
     if ($this->collImageGalleryMaps === null) {
         $this->initImageGalleryMaps();
         $this->collImageGalleryMapsPartial = true;
     }
     if (!$this->collImageGalleryMaps->contains($l)) {
         $this->doAddImageGalleryMap($l);
         if ($this->imageGalleryMapsScheduledForDeletion and $this->imageGalleryMapsScheduledForDeletion->contains($l)) {
             $this->imageGalleryMapsScheduledForDeletion->remove($this->imageGalleryMapsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
 /**
  * Method called to associate a Childучасткиработ object to this object
  * through the Childучасткиработ foreign key attribute.
  *
  * @param  Childучасткиработ $l Childучасткиработ
  * @return $this|\Проекты The current object (for fluent API support)
  */
 public function addучасткиработ(Childучасткиработ $l)
 {
     if ($this->collучасткиработs === null) {
         $this->initучасткиработs();
         $this->collучасткиработsPartial = true;
     }
     if (!$this->collучасткиработs->contains($l)) {
         $this->doAddучасткиработ($l);
         if ($this->�часткиработsScheduledForDeletion and $this->�часткиработsScheduledForDeletion->contains($l)) {
             $this->�часткиработsScheduledForDeletion->remove($this->�часткиработsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 23
0
 public function testContainsMatchesNotSimilarNewObjects()
 {
     $col = new ObjectCollection();
     $b1 = new Book();
     $b1->setTitle('Bar');
     $b1->setISBN('012345');
     $b2 = clone $b1;
     $this->assertFalse($col->contains($b1), 'contains() returns false on an empty collection');
     $col = new ObjectCollection(array($b1));
     $this->assertTrue($col->contains($b1));
     $this->assertFalse($col->contains($b2));
 }
Exemplo n.º 24
0
 /**
  * Method called to associate a ChildRFieldpostprocessorForfield object to this object
  * through the ChildRFieldpostprocessorForfield foreign key attribute.
  *
  * @param  ChildRFieldpostprocessorForfield $l ChildRFieldpostprocessorForfield
  * @return $this|\Fieldpostprocessor The current object (for fluent API support)
  */
 public function addRFieldpostprocessorForfield(ChildRFieldpostprocessorForfield $l)
 {
     if ($this->collRFieldpostprocessorForfields === null) {
         $this->initRFieldpostprocessorForfields();
         $this->collRFieldpostprocessorForfieldsPartial = true;
     }
     if (!$this->collRFieldpostprocessorForfields->contains($l)) {
         $this->doAddRFieldpostprocessorForfield($l);
         if ($this->rFieldpostprocessorForfieldsScheduledForDeletion and $this->rFieldpostprocessorForfieldsScheduledForDeletion->contains($l)) {
             $this->rFieldpostprocessorForfieldsScheduledForDeletion->remove($this->rFieldpostprocessorForfieldsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 25
0
 /**
  * Method called to associate a ChildAlbum object to this object
  * through the ChildAlbum foreign key attribute.
  *
  * @param  ChildAlbum $l ChildAlbum
  * @return $this|\Tekstove\ApiBundle\Model\User The current object (for fluent API support)
  */
 public function addAlbum(ChildAlbum $l)
 {
     if ($this->collAlbums === null) {
         $this->initAlbums();
         $this->collAlbumsPartial = true;
     }
     if (!$this->collAlbums->contains($l)) {
         $this->doAddAlbum($l);
         if ($this->albumsScheduledForDeletion and $this->albumsScheduledForDeletion->contains($l)) {
             $this->albumsScheduledForDeletion->remove($this->albumsScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 26
0
 /**
  * Method called to associate a ChildFileMeta object to this object
  * through the ChildFileMeta foreign key attribute.
  *
  * @param  ChildFileMeta $l ChildFileMeta
  * @return $this|\UserAttributes The current object (for fluent API support)
  */
 public function addFileMeta(ChildFileMeta $l)
 {
     if ($this->collFileMetas === null) {
         $this->initFileMetas();
         $this->collFileMetasPartial = true;
     }
     if (!$this->collFileMetas->contains($l)) {
         $this->doAddFileMeta($l);
         if ($this->fileMetasScheduledForDeletion and $this->fileMetasScheduledForDeletion->contains($l)) {
             $this->fileMetasScheduledForDeletion->remove($this->fileMetasScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 27
0
 /**
  * Method called to associate a ChildUser object to this object
  * through the ChildUser foreign key attribute.
  *
  * @param  ChildUser $l ChildUser
  * @return $this|\App\Propel\File The current object (for fluent API support)
  */
 public function addUser(ChildUser $l)
 {
     if ($this->collUsers === null) {
         $this->initUsers();
         $this->collUsersPartial = true;
     }
     if (!$this->collUsers->contains($l)) {
         $this->doAddUser($l);
         if ($this->usersScheduledForDeletion and $this->usersScheduledForDeletion->contains($l)) {
             $this->usersScheduledForDeletion->remove($this->usersScheduledForDeletion->search($l));
         }
     }
     return $this;
 }
Exemplo n.º 28
0
 /**
  * Method called to associate a ChildTourQuery object to this object
  * through the ChildTourQuery foreign key attribute.
  *
  * @param  ChildTourQuery $l ChildTourQuery
  * @return $this|\User The current object (for fluent API support)
  */
 public function addTourQuery(ChildTourQuery $l)
 {
     if ($this->collTourQueries === null) {
         $this->initTourQueries();
         $this->collTourQueriesPartial = true;
     }
     if (!$this->collTourQueries->contains($l)) {
         $this->doAddTourQuery($l);
         if ($this->tourQueriesScheduledForDeletion and $this->tourQueriesScheduledForDeletion->contains($l)) {
             $this->tourQueriesScheduledForDeletion->remove($this->tourQueriesScheduledForDeletion->search($l));
         }
     }
     return $this;
 }