@@ -297,18 +297,18 @@ |
||
297 | 297 | { |
298 | 298 | $cn = __CLASS__; |
299 | 299 | $exprops = ["\0$cn\0_resultMap"]; |
300 | - if (!$this->_parameterMapName) $exprops[] = "\0$cn\0_parameterMapName"; |
|
301 | - if (!$this->_parameterMap) $exprops[] = "\0$cn\0_parameterMap"; |
|
302 | - if (!$this->_parameterClassName) $exprops[] = "\0$cn\0_parameterClassName"; |
|
303 | - if (!$this->_resultMapName) $exprops[] = "\0$cn\0_resultMapName"; |
|
304 | - if (!$this->_resultMap) $exprops[] = "\0$cn\0_resultMap"; |
|
305 | - if (!$this->_resultClassName) $exprops[] = "\0$cn\0_resultClassName"; |
|
306 | - if (!$this->_cacheModelName) $exprops[] = "\0$cn\0_cacheModelName"; |
|
307 | - if (!$this->_SQL) $exprops[] = "\0$cn\0_SQL"; |
|
308 | - if (!$this->_listClass) $exprops[] = "\0$cn\0_listClass"; |
|
309 | - if (!$this->_typeHandler) $exprops[] = "\0$cn\0_typeHandler"; |
|
310 | - if (!$this->_extendStatement) $exprops[] = "\0$cn\0_extendStatement"; |
|
311 | - if (!$this->_cache) $exprops[] = "\0$cn\0_cache"; |
|
300 | + if(!$this->_parameterMapName) $exprops[] = "\0$cn\0_parameterMapName"; |
|
301 | + if(!$this->_parameterMap) $exprops[] = "\0$cn\0_parameterMap"; |
|
302 | + if(!$this->_parameterClassName) $exprops[] = "\0$cn\0_parameterClassName"; |
|
303 | + if(!$this->_resultMapName) $exprops[] = "\0$cn\0_resultMapName"; |
|
304 | + if(!$this->_resultMap) $exprops[] = "\0$cn\0_resultMap"; |
|
305 | + if(!$this->_resultClassName) $exprops[] = "\0$cn\0_resultClassName"; |
|
306 | + if(!$this->_cacheModelName) $exprops[] = "\0$cn\0_cacheModelName"; |
|
307 | + if(!$this->_SQL) $exprops[] = "\0$cn\0_SQL"; |
|
308 | + if(!$this->_listClass) $exprops[] = "\0$cn\0_listClass"; |
|
309 | + if(!$this->_typeHandler) $exprops[] = "\0$cn\0_typeHandler"; |
|
310 | + if(!$this->_extendStatement) $exprops[] = "\0$cn\0_extendStatement"; |
|
311 | + if(!$this->_cache) $exprops[] = "\0$cn\0_cache"; |
|
312 | 312 | |
313 | 313 | return array_diff(parent::__sleep(), $exprops); |
314 | 314 | } |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | */ |
82 | 82 | public function setImplementation($value) |
83 | 83 | { |
84 | - if (isset(self::$_cacheTypes[$value])) |
|
84 | + if(isset(self::$_cacheTypes[$value])) |
|
85 | 85 | $this->_implementation = $value; |
86 | 86 | else |
87 | 87 | $this->_implementation = TPropertyValue::ensureEnum($value, 'Prado\\Data\\SqlMap\\Configuration\\TSqlMapCacheTypes'); |
@@ -121,7 +121,7 @@ discard block |
||
121 | 121 | public function getImplementationClass() |
122 | 122 | { |
123 | 123 | $implementation = $this->_implementation; |
124 | - if (isset(self::$_cacheTypes[$implementation])) return self::$_cacheTypes[$implementation]; |
|
124 | + if(isset(self::$_cacheTypes[$implementation])) return self::$_cacheTypes[$implementation]; |
|
125 | 125 | |
126 | 126 | switch(TPropertyValue::ensureEnum($implementation, 'Prado\\Data\\SqlMap\\Configuration\\TSqlMapCacheTypes')) |
127 | 127 | { |
@@ -23,6 +23,6 @@ |
||
23 | 23 | { |
24 | 24 | private $_generate; |
25 | 25 | |
26 | - public function getGenerate(){ return $this->_generate; } |
|
27 | - public function setGenerate($value){ $this->_generate = $value; } |
|
26 | + public function getGenerate() { return $this->_generate; } |
|
27 | + public function setGenerate($value) { $this->_generate = $value; } |
|
28 | 28 | } |
29 | 29 | \ No newline at end of file |
@@ -199,9 +199,9 @@ |
||
199 | 199 | public function __sleep() |
200 | 200 | { |
201 | 201 | $exprops = []; $cn = __CLASS__; |
202 | - if (!count($this->_tree)) $exprops[] = "\0$cn\0_tree"; |
|
203 | - if (!count($this->_entries)) $exprops[] = "\0$cn\0_entries"; |
|
204 | - if (!count($this->_list)) $exprops[] = "\0$cn\0_list"; |
|
202 | + if(!count($this->_tree)) $exprops[] = "\0$cn\0_tree"; |
|
203 | + if(!count($this->_entries)) $exprops[] = "\0$cn\0_entries"; |
|
204 | + if(!count($this->_list)) $exprops[] = "\0$cn\0_list"; |
|
205 | 205 | return array_diff(parent::__sleep(), $exprops); |
206 | 206 | } |
207 | 207 | } |
208 | 208 | \ No newline at end of file |
@@ -47,7 +47,7 @@ |
||
47 | 47 | public function executeQueryForMap($connection, $parameter, $keyProperty, $valueProperty = null, $skip = -1, $max = -1, $delegate = null) |
48 | 48 | { |
49 | 49 | $sql = $this->createCommand($connection, $parameter, $skip, $max); |
50 | - $key = $this->getCacheKey([clone($sql), $keyProperty, $valueProperty,$skip, $max]); |
|
50 | + $key = $this->getCacheKey([clone($sql), $keyProperty, $valueProperty, $skip, $max]); |
|
51 | 51 | $map = $this->getStatement()->getCache()->get($key); |
52 | 52 | if($map === null) |
53 | 53 | { |
@@ -27,32 +27,32 @@ |
||
27 | 27 | private $_parameterNames; |
28 | 28 | private $_parameterValues; |
29 | 29 | |
30 | - public function getPreparedSql(){ return $this->_sqlString; } |
|
31 | - public function setPreparedSql($value){ $this->_sqlString = $value; } |
|
30 | + public function getPreparedSql() { return $this->_sqlString; } |
|
31 | + public function setPreparedSql($value) { $this->_sqlString = $value; } |
|
32 | 32 | |
33 | 33 | public function getParameterNames($needed = true) |
34 | 34 | { |
35 | - if (!$this->_parameterNames and $needed) |
|
35 | + if(!$this->_parameterNames and $needed) |
|
36 | 36 | $this->_parameterNames = new TList; |
37 | 37 | return $this->_parameterNames; |
38 | 38 | } |
39 | 39 | |
40 | - public function setParameterNames($value){ $this->_parameterNames = $value; } |
|
40 | + public function setParameterNames($value) { $this->_parameterNames = $value; } |
|
41 | 41 | |
42 | 42 | public function getParameterValues($needed = true) |
43 | 43 | { |
44 | - if (!$this->_parameterValues and $needed) |
|
44 | + if(!$this->_parameterValues and $needed) |
|
45 | 45 | $this->_parameterValues = new TMap; |
46 | 46 | return $this->_parameterValues; |
47 | 47 | } |
48 | 48 | |
49 | - public function setParameterValues($value){ $this->_parameterValues = $value; } |
|
49 | + public function setParameterValues($value) { $this->_parameterValues = $value; } |
|
50 | 50 | |
51 | 51 | public function __sleep() |
52 | 52 | { |
53 | 53 | $exprops = []; $cn = __CLASS__; |
54 | - if (!$this->_parameterNames or !$this->_parameterNames->getCount()) $exprops[] = "\0$cn\0_parameterNames"; |
|
55 | - if (!$this->_parameterValues or !$this->_parameterValues->getCount()) $exprops[] = "\0$cn\0_parameterValues"; |
|
54 | + if(!$this->_parameterNames or !$this->_parameterNames->getCount()) $exprops[] = "\0$cn\0_parameterNames"; |
|
55 | + if(!$this->_parameterValues or !$this->_parameterValues->getCount()) $exprops[] = "\0$cn\0_parameterValues"; |
|
56 | 56 | return array_diff(parent::__sleep(), $exprops); |
57 | 57 | } |
58 | 58 | } |
@@ -53,7 +53,7 @@ |
||
53 | 53 | $properties = $prepared->getParameterNames(false); |
54 | 54 | //$parameters = $prepared->getParameterValues(); |
55 | 55 | $registry = $manager->getTypeHandlers(); |
56 | - if ($properties) |
|
56 | + if($properties) |
|
57 | 57 | for($i = 0, $k = $properties->getCount(); $i < $k; $i++) |
58 | 58 | { |
59 | 59 | $property = $statement->parameterMap()->getProperty($i); |
@@ -26,18 +26,18 @@ |
||
26 | 26 | private $_keys; |
27 | 27 | private $_method = TMappedStatement::QUERY_FOR_LIST; |
28 | 28 | |
29 | - public function getStatement(){ return $this->_statement; } |
|
30 | - public function setStatement($value){ $this->_statement = $value; } |
|
29 | + public function getStatement() { return $this->_statement; } |
|
30 | + public function setStatement($value) { $this->_statement = $value; } |
|
31 | 31 | |
32 | - public function getResultProperty(){ return $this->_property; } |
|
33 | - public function setResultProperty($value){ $this->_property = $value; } |
|
32 | + public function getResultProperty() { return $this->_property; } |
|
33 | + public function setResultProperty($value) { $this->_property = $value; } |
|
34 | 34 | |
35 | - public function getResultObject(){ return $this->_resultObject; } |
|
36 | - public function setResultObject($value){ $this->_resultObject = $value; } |
|
35 | + public function getResultObject() { return $this->_resultObject; } |
|
36 | + public function setResultObject($value) { $this->_resultObject = $value; } |
|
37 | 37 | |
38 | - public function getKeys(){ return $this->_keys; } |
|
39 | - public function setKeys($value){ $this->_keys = $value; } |
|
38 | + public function getKeys() { return $this->_keys; } |
|
39 | + public function setKeys($value) { $this->_keys = $value; } |
|
40 | 40 | |
41 | - public function getMethod(){ return $this->_method; } |
|
42 | - public function setMethod($value){ $this->_method = $value; } |
|
41 | + public function getMethod() { return $this->_method; } |
|
42 | + public function setMethod($value) { $this->_method = $value; } |
|
43 | 43 | } |
44 | 44 | \ No newline at end of file |
@@ -74,15 +74,15 @@ |
||
74 | 74 | { |
75 | 75 | return xmlrpc_server_call_method($this->_xmlrpcServer, $requestPayload, null); |
76 | 76 | } |
77 | - catch(TRpcException $e) |
|
77 | + catch (TRpcException $e) |
|
78 | 78 | { |
79 | 79 | return $this->createErrorResponse($e); |
80 | 80 | } |
81 | - catch(THttpException $e) |
|
81 | + catch (THttpException $e) |
|
82 | 82 | { |
83 | 83 | throw $e; |
84 | 84 | } |
85 | - catch(\Exception $e) |
|
85 | + catch (\Exception $e) |
|
86 | 86 | { |
87 | 87 | return $this->createErrorResponse(new TRpcException('An internal error occured')); |
88 | 88 | } |