Completed
Push — feature/0.7.0 ( d06a69...2e2153 )
by Ryuichi
04:48
created
WebStream/Log/Logger.php 2 patches
Doc Comments   +5 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 
86 86
     /**
87 87
      * インスタンスを返却する
88
-     * @return WebStream\Module\Logger ロガーインスタンス
88
+     * @return Logger ロガーインスタンス
89 89
      */
90 90
     public static function getInstance()
91 91
     {
@@ -171,6 +171,8 @@  discard block
 block discarded – undo
171 171
      * @param string ログレベル文字列
172 172
      * @param string 出力文字列
173 173
      * @param array<mixed> 埋め込み値リスト
174
+     * @param integer $level
175
+     * @param string $msg
174 176
      */
175 177
     public function write($level, $msg, $context = null)
176 178
     {
@@ -267,6 +269,8 @@  discard block
 block discarded – undo
267 269
      * ローテートを実行する
268 270
      * @param integer 作成日時のUnixTime
269 271
      * @param integer 現在日時のUnixTime
272
+     * @param integer $from
273
+     * @param integer $to
270 274
      */
271 275
     private function runRotate($from, $to)
272 276
     {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
         date_default_timezone_set('Asia/Tokyo');
164 164
         $msec = sprintf("%2d", floatval(microtime()) * 100);
165 165
 
166
-        return strftime("%Y-%m-%d %H:%M:%S") . "," . $msec;
166
+        return strftime("%Y-%m-%d %H:%M:%S").",".$msec;
167 167
     }
168 168
 
169 169
     /**
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
         $content = fread($handle, $size);
228 228
         fclose($handle);
229 229
         if (!preg_match('/^\d{10}$/', $content)) {
230
-            throw new LoggerException("Invalid log state file contents: " . $content);
230
+            throw new LoggerException("Invalid log state file contents: ".$content);
231 231
         }
232 232
 
233 233
         return intval($content);
Please login to merge, or discard this patch.
WebStream/Module/Utility/LoggerUtils.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
      */
19 19
     public function defaultLoggerFormatter()
20 20
     {
21
-        return '[%d{' . $this->defaultDateTimeFormatter() . '.%f}][%5L] %m';
21
+        return '[%d{'.$this->defaultDateTimeFormatter().'.%f}][%5L] %m';
22 22
     }
23 23
 
24 24
     /**
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
                 continue;
46 46
             }
47 47
             $msg .= PHP_EOL;
48
-            $msg .= "\t#" . trim($stacktraceLine);
48
+            $msg .= "\t#".trim($stacktraceLine);
49 49
         }
50 50
 
51 51
         return $msg;
Please login to merge, or discard this patch.
WebStream/IO/File.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
 
31 31
     /**
32 32
      * constructor
33
-     * @param string $filepath ファイルパス
33
+     * @param string $filePath ファイルパス
34 34
      */
35 35
     public function __construct(stirng $filePath)
36 36
     {
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
             while (@is_link($filePath)) {
86 86
                 $linkPath = readlink($filePath);
87 87
                 if ($linkPath === false) {
88
-                    throw new IOException("Symbolic link read error: " . $filePath);
88
+                    throw new IOException("Symbolic link read error: ".$filePath);
89 89
                 }
90 90
                 $filePath = $linkPath;
91 91
             }
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
 
178 178
         // 読み込み不可のシンボリックリンクの場合、例外を発生させる
179 179
         if (!$this->isReadable()) {
180
-            throw new IOException("No read access to " . $this->filePath);
180
+            throw new IOException("No read access to ".$this->filePath);
181 181
         }
182 182
 
183 183
         return @is_link($this->filePath);
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
             $length = filesize($filePath);
198 198
 
199 199
             if ($length === false) {
200
-                throw new IOException("Cannot get filesize of " . $filePath);
200
+                throw new IOException("Cannot get filesize of ".$filePath);
201 201
             }
202 202
         }
203 203
 
Please login to merge, or discard this patch.
WebStream/IO/FileInputStream.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,11 +30,11 @@  discard block
 block discarded – undo
30 30
         } else if (is_string($file)) {
31 31
             $this->file = new File($file);
32 32
         } else {
33
-            throw new InvalidArgumentException("Unable to open file: " . $file);
33
+            throw new InvalidArgumentException("Unable to open file: ".$file);
34 34
         }
35 35
         $stream = @fopen($this->file->getAbsoluteFilePath(), 'r');
36 36
         if (!is_resource($stream) || $stream === false) {
37
-            throw new IOException("Unable open " . $this->file->getAbsoluteFilePath());
37
+            throw new IOException("Unable open ".$this->file->getAbsoluteFilePath());
38 38
         }
39 39
 
40 40
         parent::__construct($stream);
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
     public function reset()
134 134
     {
135 135
         if (!$this->isMarkSupported()) {
136
-            throw new IOException(get_class($this) . " does not support mark and reset.");
136
+            throw new IOException(get_class($this)." does not support mark and reset.");
137 137
         }
138 138
 
139 139
         // ポインタ位置をmark位置に移動
Please login to merge, or discard this patch.
WebStream/IO/InputStream.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
     public function mark()
84 84
     {
85 85
         if (!$this->isMarkSupported()) {
86
-            throw new IOException(get_class($this) . " does not support mark.");
86
+            throw new IOException(get_class($this)." does not support mark.");
87 87
         }
88 88
 
89 89
         $this->markedPosition = $this->cursorPosition;
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
     public function reset()
97 97
     {
98 98
         if (!$this->isMarkSupported()) {
99
-            throw new IOException(get_class($this) . " does not support mark and reset.");
99
+            throw new IOException(get_class($this)." does not support mark and reset.");
100 100
         }
101 101
 
102 102
         // mark位置を初期値に戻す
Please login to merge, or discard this patch.
WebStream/IO/StringInputStream.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 namespace WebStream\IO;
3 3
 
4 4
 use WebStream\Exception\Extend\InvalidArgumentException;
5
-use WebStream\Exception\Extend\IOException;
6 5
 
7 6
 /**
8 7
  * StringInputStream
Please login to merge, or discard this patch.
WebStream/IO/FileOutputStream.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,14 +30,14 @@
 block discarded – undo
30 30
         } elseif (is_string($file)) {
31 31
             $this->file = new File($file);
32 32
         } else {
33
-            throw new InvalidArgumentException("Invalid argument type: " . $file);
33
+            throw new InvalidArgumentException("Invalid argument type: ".$file);
34 34
         }
35 35
 
36 36
         $mode = $isAppend ? 'ab' : 'wb';
37 37
         $stream = @fopen($this->file->getAbsoluteFilePath(), $mode);
38 38
 
39 39
         if (!is_resource($stream) || $stream === false) {
40
-            throw new IOException("Unable open " . $this->file->getAbsoluteFilePath());
40
+            throw new IOException("Unable open ".$this->file->getAbsoluteFilePath());
41 41
         }
42 42
 
43 43
         parent::__construct($stream);
Please login to merge, or discard this patch.