11<?php
22
3+ /*
4+ * This file is part of the Active Collab DatabaseObject project.
5+ *
6+ * (c) A51 doo <[email protected] >. All rights reserved. 7+ */
8+
39namespace ActiveCollab \DatabaseObject ;
410
511use ActiveCollab \DatabaseConnection \ConnectionInterface ;
612use ActiveCollab \DatabaseConnection \Result \ResultInterface ;
7- use ActiveCollab \Etag \EtagInterface ;
813use ActiveCollab \Etag \EtagInterface \Implementation as EtagInterfaceImplementation ;
914use LogicException ;
1015use Psr \Log \LoggerInterface ;
@@ -46,18 +51,18 @@ public function __construct(ConnectionInterface &$connection, PoolInterface &$po
4651 }
4752
4853 /**
49- * Pre-configure the collection when it is created
54+ * Pre-configure the collection when it is created.
5055 */
5156 protected function configure ()
5257 {
5358 }
5459
5560 /**
56- * Return true if ready
61+ * Return true if ready.
5762 *
5863 * If collection declares that it is not ready, but execute methods get called, we should throw an exception
5964 *
60- * @return boolean
65+ * @return bool
6166 */
6267 protected function isReady ()
6368 {
@@ -70,7 +75,7 @@ protected function isReady()
7075 private $ application_identifier = 'APPv1.0 ' ;
7176
7277 /**
73- * Return application identifier
78+ * Return application identifier.
7479 *
7580 * @return string
7681 */
@@ -80,7 +85,7 @@ public function getApplicationIdentifier()
8085 }
8186
8287 /**
83- * Set application identifier
88+ * Set application identifier.
8489 *
8590 * @param string $value
8691 * @return $this
@@ -93,7 +98,7 @@ public function &setApplicationIdentifier($value)
9398 }
9499
95100 /**
96- * Prepare collection tag from bits of information
101+ * Prepare collection tag from bits of information.
97102 *
98103 * @param string $additional_identifier
99104 * @param string $visitor_identifier
@@ -106,7 +111,7 @@ protected function prepareTagFromBits($additional_identifier, $visitor_identifie
106111 }
107112
108113 /**
109- * Return true if this object can be tagged and cached on client side
114+ * Return true if this object can be tagged and cached on client side.
110115 *
111116 * @return bool|null
112117 */
@@ -120,10 +125,10 @@ public function canBeTagged()
120125 // ---------------------------------------------------
121126
122127 /**
123- * Set pagination configuration
128+ * Set pagination configuration.
124129 *
125- * @param integer $current_page
126- * @param integer $items_per_page
130+ * @param int $current_page
131+ * @param int $items_per_page
127132 * @return $this
128133 */
129134 public function &pagination ($ current_page = 1 , $ items_per_page = 100 )
@@ -132,7 +137,7 @@ public function &pagination($current_page = 1, $items_per_page = 100)
132137
133138 $ this ->currentPage ($ current_page );
134139
135- $ this ->items_per_page = (int )$ items_per_page ;
140+ $ this ->items_per_page = (int ) $ items_per_page ;
136141
137142 if ($ this ->items_per_page < 1 ) {
138143 $ this ->items_per_page = 100 ;
@@ -147,29 +152,29 @@ public function &pagination($current_page = 1, $items_per_page = 100)
147152 private $ is_paginated = false ;
148153
149154 /**
150- * Return true if collection is paginated
155+ * Return true if collection is paginated.
151156 *
152- * @return boolean
157+ * @return bool
153158 */
154159 public function isPaginated ()
155160 {
156161 return $ this ->is_paginated ;
157162 }
158163
159164 /**
160- * @var integer |null
165+ * @var int |null
161166 */
162167 private $ current_page = null ;
163168
164169 /**
165- * @var integer |null
170+ * @var int |null
166171 */
167172 private $ items_per_page = null ;
168173
169174 /**
170- * Set current page
175+ * Set current page.
171176 *
172- * @param integer $value
177+ * @param int $value
173178 * @return $this
174179 */
175180 public function ¤tPage ($ value )
@@ -188,27 +193,27 @@ public function ¤tPage($value)
188193 }
189194
190195 /**
191- * Return current page #
196+ * Return current page #.
192197 *
193- * @return integer |null
198+ * @return int |null
194199 */
195200 public function getCurrentPage ()
196201 {
197202 return $ this ->current_page ;
198203 }
199204
200205 /**
201- * Return number of items that are displayed per page
206+ * Return number of items that are displayed per page.
202207 *
203- * @return integer |null
208+ * @return int |null
204209 */
205210 public function getItemsPerPage ()
206211 {
207212 return $ this ->items_per_page ;
208213 }
209214
210215 /**
211- * Return array or property => value pairs that describes this object
216+ * Return array or property => value pairs that describes this object.
212217 *
213218 * @return array
214219 */
0 commit comments