From 13505a82dd84123082af8504a19ca29bf9884b86 Mon Sep 17 00:00:00 2001 From: Gamesh Date: Wed, 18 Dec 2013 12:53:33 +0200 Subject: [PATCH] setters should provide fluent interface setNew, setDeleted and resetModified should return $this as all the other setters to provide fluent interface. --- runtime/lib/om/BaseObject.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/runtime/lib/om/BaseObject.php b/runtime/lib/om/BaseObject.php index 44b075599..b6eef4c03 100644 --- a/runtime/lib/om/BaseObject.php +++ b/runtime/lib/om/BaseObject.php @@ -116,10 +116,12 @@ public function isNew() * by Propel-generated children and Peers. * * @param boolean $b the state of the object. + * @return self */ public function setNew($b) { $this->_new = (boolean) $b; + return $this; } /** @@ -137,11 +139,12 @@ public function isDeleted() * * @param boolean $b The deleted state of this object. * - * @return void + * @return self */ public function setDeleted($b) { $this->_deleted = (boolean) $b; + return $this; } /** @@ -242,7 +245,7 @@ public function postHydrate($row, $startcol = 0, $rehydrate = false) * * @param string $col If supplied, only the specified column is reset. * - * @return void + * @return self */ public function resetModified($col = null) { @@ -253,6 +256,7 @@ public function resetModified($col = null) } else { $this->modifiedColumns = array(); } + return $this; } /**