Completed
Push — 2.0 ( 4129d9...bcdb61 )
by Marco
02:16
created
src/Comodojo/Extender/Task/Runner.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
 
98 98
             $thetask = $this->table->get($task)->getInstance($name, $parameters);
99 99
 
100
-            $this->events->emit( new TaskEvent('start', $thetask) );
100
+            $this->events->emit(new TaskEvent('start', $thetask));
101 101
 
102 102
             $pid = $thetask->getPid();
103 103
 
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
                 $this->stopwatch->getStartTime()
113 113
             );
114 114
 
115
-            $this->events->emit( new TaskStatusEvent('start', $thetask) );
115
+            $this->events->emit(new TaskStatusEvent('start', $thetask));
116 116
 
117 117
             try {
118 118
 
@@ -134,11 +134,11 @@  discard block
 block discarded – undo
134 134
 
135 135
             }
136 136
 
137
-            $this->events->emit( new TaskStatusEvent($status ? 'success' : 'error', $thetask) );
137
+            $this->events->emit(new TaskStatusEvent($status ? 'success' : 'error', $thetask));
138 138
 
139
-            $this->events->emit( new TaskStatusEvent('stop', $thetask) );
139
+            $this->events->emit(new TaskStatusEvent('stop', $thetask));
140 140
 
141
-            $this->events->emit( new TaskEvent('stop', $thetask) );
141
+            $this->events->emit(new TaskEvent('stop', $thetask));
142 142
 
143 143
             $this->stopwatch->stop();
144 144
 
Please login to merge, or discard this patch.
src/Comodojo/Extender/Task/Request.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -356,7 +356,7 @@
 block discarded – undo
356 356
 
357 357
     public function isChain() {
358 358
 
359
-        return ( $this->done !== null || $this->fail !== null || $this->pipe !== null );
359
+        return ($this->done !== null || $this->fail !== null || $this->pipe !== null);
360 360
 
361 361
     }
362 362
 
Please login to merge, or discard this patch.
Doc Comments   +7 added lines, -1 removed lines patch added patch discarded remove patch
@@ -116,6 +116,9 @@  discard block
 block discarded – undo
116 116
 
117 117
     }
118 118
 
119
+    /**
120
+     * @param string $name
121
+     */
119 122
     public function setName($name) {
120 123
 
121 124
         $this->name = $name;
@@ -135,6 +138,9 @@  discard block
 block discarded – undo
135 138
 
136 139
     }
137 140
 
141
+    /**
142
+     * @param string $task
143
+     */
138 144
     public function setTask($task) {
139 145
 
140 146
         $this->task = $task;
@@ -260,7 +266,7 @@  discard block
 block discarded – undo
260 266
     /**
261 267
      * Get start timestamp (microseconds)
262 268
      *
263
-     * @return float
269
+     * @return integer
264 270
      */
265 271
     public function getStartTimestamp() {
266 272
 
Please login to merge, or discard this patch.
test_socket_2.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
 
7 7
     $client = \Comodojo\Daemon\Socket\Client::create('unix://extender.sock');
8 8
 
9
-    $data = $client->send('scheduler:refresh',[]);
9
+    $data = $client->send('scheduler:refresh', []);
10 10
 
11 11
 } catch (Exception $e) {
12 12
 
Please login to merge, or discard this patch.
src/Comodojo/Extender/Components/Ipc.php 1 patch
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -48,6 +48,9 @@  discard block
 block discarded – undo
48 48
 
49 49
     }
50 50
 
51
+    /**
52
+     * @param integer $uid
53
+     */
51 54
     public function init($uid) {
52 55
 
53 56
         $this->ipc[$uid] = [];
@@ -72,6 +75,10 @@  discard block
 block discarded – undo
72 75
 
73 76
     }
74 77
 
78
+    /**
79
+     * @param integer $uid
80
+     * @param string $data
81
+     */
75 82
     public function write($uid, $data) {
76 83
 
77 84
         $writer = $this->ipc[$uid][self::WRITER];
Please login to merge, or discard this patch.
src/Comodojo/Extender/Orm/Entities/Schedule.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
     /**
137 137
      * Get cron expression of this schedule
138 138
      *
139
-     * @return string
139
+     * @return CronExpression
140 140
      */
141 141
     public function getExpression() {
142 142
 
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
     /**
148 148
      * set cron expression for this schedule
149 149
      *
150
-     * @param srting $expression A cron-compatible expression
150
+     * @param CronExpression $expression A cron-compatible expression
151 151
      * @return Schedule
152 152
      */
153 153
     public function setExpression(CronExpression $expression) {
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
     /**
178 178
      * Set enable/disable status
179 179
      *
180
-     * @param bool $enable
180
+     * @param boolean $enabled
181 181
      * @return Schedule
182 182
      */
183 183
     public function setEnabled($enabled) {
Please login to merge, or discard this patch.
src/Comodojo/Extender/Schedule/Manager.php 2 patches
Doc Comments   -2 removed lines patch added patch discarded remove patch
@@ -38,10 +38,8 @@
 block discarded – undo
38 38
     /**
39 39
      * Class constructor
40 40
      *
41
-     * @param string $manager_name
42 41
      * @param Configuration $configuration
43 42
      * @param LoggerInterface $logger
44
-     * @param TasksTable $tasks
45 43
      * @param EventsManager $events
46 44
      * @param EntityManager $em
47 45
      */
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
         $date = new DateTime();
139 139
         $timestamps = [];
140 140
 
141
-        foreach ($items as $schedule) {
141
+        foreach ( $items as $schedule ) {
142 142
 
143 143
             $timestamps[] = $schedule->getNextPlannedRun($date)->getTimestamp();
144 144
 
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
 
153 153
         $em = $this->getEntityManager();
154 154
 
155
-        foreach ($results as $result) {
155
+        foreach ( $results as $result ) {
156 156
 
157 157
             $id = $result->jid;
158 158
 
@@ -196,7 +196,7 @@  discard block
 block discarded – undo
196 196
 
197 197
         $records = [];
198 198
 
199
-        foreach ($schedules as $key => $schedule) {
199
+        foreach ( $schedules as $key => $schedule ) {
200 200
 
201 201
             try {
202 202
 
Please login to merge, or discard this patch.