|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
/** |
|
4
|
|
|
* Platine Console |
|
5
|
|
|
* |
|
6
|
|
|
* Platine Console is a powerful library with support of custom |
|
7
|
|
|
* style to build command line interface applications |
|
8
|
|
|
* |
|
9
|
|
|
* This content is released under the MIT License (MIT) |
|
10
|
|
|
* |
|
11
|
|
|
* Copyright (c) 2020 Platine Console |
|
12
|
|
|
* Copyright (c) 2017-2020 Jitendra Adhikari |
|
13
|
|
|
* |
|
14
|
|
|
* Permission is hereby granted, free of charge, to any person obtaining a copy |
|
15
|
|
|
* of this software and associated documentation files (the "Software"), to deal |
|
16
|
|
|
* in the Software without restriction, including without limitation the rights |
|
17
|
|
|
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
18
|
|
|
* copies of the Software, and to permit persons to whom the Software is |
|
19
|
|
|
* furnished to do so, subject to the following conditions: |
|
20
|
|
|
* |
|
21
|
|
|
* The above copyright notice and this permission notice shall be included in all |
|
22
|
|
|
* copies or substantial portions of the Software. |
|
23
|
|
|
* |
|
24
|
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
|
25
|
|
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
|
26
|
|
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
|
27
|
|
|
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
|
28
|
|
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
|
29
|
|
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
|
30
|
|
|
* SOFTWARE. |
|
31
|
|
|
*/ |
|
32
|
|
|
|
|
33
|
|
|
/** |
|
34
|
|
|
* @file Writer.php |
|
35
|
|
|
* |
|
36
|
|
|
* The Output Writer class |
|
37
|
|
|
* |
|
38
|
|
|
* @package Platine\Console\Output |
|
39
|
|
|
* @author Platine Developers Team |
|
40
|
|
|
* @copyright Copyright (c) 2020 |
|
41
|
|
|
* @license http://opensource.org/licenses/MIT MIT License |
|
42
|
|
|
* @link http://www.iacademy.cf |
|
43
|
|
|
* @version 1.0.0 |
|
44
|
|
|
* @filesource |
|
45
|
|
|
*/ |
|
46
|
|
|
|
|
47
|
|
|
declare(strict_types=1); |
|
48
|
|
|
|
|
49
|
|
|
namespace Platine\Console\Output; |
|
50
|
|
|
|
|
51
|
|
|
/** |
|
52
|
|
|
* Class Writer |
|
53
|
|
|
* @package Platine\Console\Output |
|
54
|
|
|
* |
|
55
|
|
|
* @method Writer bold(string $text, bool $eol = false) |
|
56
|
|
|
* @method Writer dim(string $text, bool $eol = false) |
|
57
|
|
|
* @method Writer italic(string $text, bool $eol = false) |
|
58
|
|
|
* @method Writer underline(string $text, bool $eol = false) |
|
59
|
|
|
* @method Writer black(string $text, bool $eol = false) |
|
60
|
|
|
* @method Writer red(string $text, bool $eol = false) |
|
61
|
|
|
* @method Writer green(string $text, bool $eol = false) |
|
62
|
|
|
* @method Writer yellow(string $text, bool $eol = false) |
|
63
|
|
|
* @method Writer blue(string $text, bool $eol = false) |
|
64
|
|
|
* @method Writer purple(string $text, bool $eol = false) |
|
65
|
|
|
* @method Writer cyan(string $text, bool $eol = false) |
|
66
|
|
|
* @method Writer white(string $text, bool $eol = false) |
|
67
|
|
|
* @method Writer gray(string $text, bool $eol = false) |
|
68
|
|
|
* @method Writer darkgray(string $text, bool $eol = false) |
|
69
|
|
|
* @method Writer bgBlack(string $text, bool $eol = false) |
|
70
|
|
|
* @method Writer bgRed(string $text, bool $eol = false) |
|
71
|
|
|
* @method Writer bgGreen(string $text, bool $eol = false) |
|
72
|
|
|
* @method Writer bgYellow(string $text, bool $eol = false) |
|
73
|
|
|
* @method Writer bgBlue(string $text, bool $eol = false) |
|
74
|
|
|
* @method Writer bgPurple(string $text, bool $eol = false) |
|
75
|
|
|
* @method Writer bgCyan(string $text, bool $eol = false) |
|
76
|
|
|
* @method Writer bgWhite(string $text, bool $eol = false) |
|
77
|
|
|
* @method Writer bgGray(string $text, bool $eol = false) |
|
78
|
|
|
* @method Writer bgDarkgray(string $text, bool $eol = false) |
|
79
|
|
|
* @method Writer boldBlack(string $text, bool $eol = false) |
|
80
|
|
|
* @method Writer boldRed(string $text, bool $eol = false) |
|
81
|
|
|
* @method Writer boldGreen(string $text, bool $eol = false) |
|
82
|
|
|
* @method Writer boldYellow(string $text, bool $eol = false) |
|
83
|
|
|
* @method Writer boldBlue(string $text, bool $eol = false) |
|
84
|
|
|
* @method Writer boldPurple(string $text, bool $eol = false) |
|
85
|
|
|
* @method Writer boldCyan(string $text, bool $eol = false) |
|
86
|
|
|
* @method Writer boldWhite(string $text, bool $eol = false) |
|
87
|
|
|
* @method Writer boldGray(string $text, bool $eol = false) |
|
88
|
|
|
* @method Writer boldDarkgray(string $text, bool $eol = false) |
|
89
|
|
|
* @method Writer dimBlack(string $text, bool $eol = false) |
|
90
|
|
|
* @method Writer dimRed(string $text, bool $eol = false) |
|
91
|
|
|
* @method Writer dimGreen(string $text, bool $eol = false) |
|
92
|
|
|
* @method Writer dimYellow(string $text, bool $eol = false) |
|
93
|
|
|
* @method Writer dimBlue(string $text, bool $eol = false) |
|
94
|
|
|
* @method Writer dimPurple(string $text, bool $eol = false) |
|
95
|
|
|
* @method Writer dimCyan(string $text, bool $eol = false) |
|
96
|
|
|
* @method Writer dimWhite(string $text, bool $eol = false) |
|
97
|
|
|
* @method Writer dimGray(string $text, bool $eol = false) |
|
98
|
|
|
* @method Writer dimDarkgray(string $text, bool $eol = false) |
|
99
|
|
|
* @method Writer italicBlack(string $text, bool $eol = false) |
|
100
|
|
|
* @method Writer italicRed(string $text, bool $eol = false) |
|
101
|
|
|
* @method Writer italicGreen(string $text, bool $eol = false) |
|
102
|
|
|
* @method Writer italicYellow(string $text, bool $eol = false) |
|
103
|
|
|
* @method Writer italicBlue(string $text, bool $eol = false) |
|
104
|
|
|
* @method Writer italicPurple(string $text, bool $eol = false) |
|
105
|
|
|
* @method Writer italicCyan(string $text, bool $eol = false) |
|
106
|
|
|
* @method Writer italicWhite(string $text, bool $eol = false) |
|
107
|
|
|
* @method Writer italicGray(string $text, bool $eol = false) |
|
108
|
|
|
* @method Writer italicDarkgray(string $text, bool $eol = false) |
|
109
|
|
|
* @method Writer underlineBlack(string $text, bool $eol = false) |
|
110
|
|
|
* @method Writer underlineRed(string $text, bool $eol = false) |
|
111
|
|
|
* @method Writer underlineGreen(string $text, bool $eol = false) |
|
112
|
|
|
* @method Writer underlineYellow(string $text, bool $eol = false) |
|
113
|
|
|
* @method Writer underlineBlue(string $text, bool $eol = false) |
|
114
|
|
|
* @method Writer underlinePurple(string $text, bool $eol = false) |
|
115
|
|
|
* @method Writer underlineCyan(string $text, bool $eol = false) |
|
116
|
|
|
* @method Writer underlineWhite(string $text, bool $eol = false) |
|
117
|
|
|
* @method Writer underlineGray(string $text, bool $eol = false) |
|
118
|
|
|
* @method Writer underlineDarkgray(string $text, bool $eol = false) |
|
119
|
|
|
* @method Writer boldBgBlack(string $text, bool $eol = false) |
|
120
|
|
|
* @method Writer boldBgRed(string $text, bool $eol = false) |
|
121
|
|
|
* @method Writer boldBgGreen(string $text, bool $eol = false) |
|
122
|
|
|
* @method Writer boldBgYellow(string $text, bool $eol = false) |
|
123
|
|
|
* @method Writer boldBgBlue(string $text, bool $eol = false) |
|
124
|
|
|
* @method Writer boldBgPurple(string $text, bool $eol = false) |
|
125
|
|
|
* @method Writer boldBgCyan(string $text, bool $eol = false) |
|
126
|
|
|
* @method Writer boldBgWhite(string $text, bool $eol = false) |
|
127
|
|
|
* @method Writer boldBgGray(string $text, bool $eol = false) |
|
128
|
|
|
* @method Writer boldBgDarkgray(string $text, bool $eol = false) |
|
129
|
|
|
* @method Writer dimBgBlack(string $text, bool $eol = false) |
|
130
|
|
|
* @method Writer dimBgRed(string $text, bool $eol = false) |
|
131
|
|
|
* @method Writer dimBgGreen(string $text, bool $eol = false) |
|
132
|
|
|
* @method Writer dimBgYellow(string $text, bool $eol = false) |
|
133
|
|
|
* @method Writer dimBgBlue(string $text, bool $eol = false) |
|
134
|
|
|
* @method Writer dimBgPurple(string $text, bool $eol = false) |
|
135
|
|
|
* @method Writer dimBgCyan(string $text, bool $eol = false) |
|
136
|
|
|
* @method Writer dimBgWhite(string $text, bool $eol = false) |
|
137
|
|
|
* @method Writer dimBgGray(string $text, bool $eol = false) |
|
138
|
|
|
* @method Writer dimBgDarkgray(string $text, bool $eol = false) |
|
139
|
|
|
* @method Writer italicBgBlack(string $text, bool $eol = false) |
|
140
|
|
|
* @method Writer italicBgRed(string $text, bool $eol = false) |
|
141
|
|
|
* @method Writer italicBgGreen(string $text, bool $eol = false) |
|
142
|
|
|
* @method Writer italicBgYellow(string $text, bool $eol = false) |
|
143
|
|
|
* @method Writer italicBgBlue(string $text, bool $eol = false) |
|
144
|
|
|
* @method Writer italicBgPurple(string $text, bool $eol = false) |
|
145
|
|
|
* @method Writer italicBgCyan(string $text, bool $eol = false) |
|
146
|
|
|
* @method Writer italicBgWhite(string $text, bool $eol = false) |
|
147
|
|
|
* @method Writer italicBgGray(string $text, bool $eol = false) |
|
148
|
|
|
* @method Writer italicBgDarkgray(string $text, bool $eol = false) |
|
149
|
|
|
* @method Writer underlineBgBlack(string $text, bool $eol = false) |
|
150
|
|
|
* @method Writer underlineBgRed(string $text, bool $eol = false) |
|
151
|
|
|
* @method Writer underlineBgGreen(string $text, bool $eol = false) |
|
152
|
|
|
* @method Writer underlineBgYellow(string $text, bool $eol = false) |
|
153
|
|
|
* @method Writer underlineBgBlue(string $text, bool $eol = false) |
|
154
|
|
|
* @method Writer underlineBgPurple(string $text, bool $eol = false) |
|
155
|
|
|
* @method Writer underlineBgCyan(string $text, bool $eol = false) |
|
156
|
|
|
* @method Writer underlineBgWhite(string $text, bool $eol = false) |
|
157
|
|
|
* @method Writer underlineBgGray(string $text, bool $eol = false) |
|
158
|
|
|
* @method Writer underlineBgDarkgray(string $text, bool $eol = false) |
|
159
|
|
|
* @method Writer boldBlackBgRed(string $text, bool $eol = false) |
|
160
|
|
|
* @method Writer boldBlackBgGreen(string $text, bool $eol = false) |
|
161
|
|
|
* @method Writer boldBlackBgYellow(string $text, bool $eol = false) |
|
162
|
|
|
* @method Writer boldBlackBgBlue(string $text, bool $eol = false) |
|
163
|
|
|
* @method Writer boldBlackBgPurple(string $text, bool $eol = false) |
|
164
|
|
|
* @method Writer boldBlackBgCyan(string $text, bool $eol = false) |
|
165
|
|
|
* @method Writer boldBlackBgWhite(string $text, bool $eol = false) |
|
166
|
|
|
* @method Writer boldBlackBgGray(string $text, bool $eol = false) |
|
167
|
|
|
* @method Writer boldBlackBgDarkgray(string $text, bool $eol = false) |
|
168
|
|
|
* @method Writer boldRedBgBlack(string $text, bool $eol = false) |
|
169
|
|
|
* @method Writer boldRedBgGreen(string $text, bool $eol = false) |
|
170
|
|
|
* @method Writer boldRedBgYellow(string $text, bool $eol = false) |
|
171
|
|
|
* @method Writer boldRedBgBlue(string $text, bool $eol = false) |
|
172
|
|
|
* @method Writer boldRedBgPurple(string $text, bool $eol = false) |
|
173
|
|
|
* @method Writer boldRedBgCyan(string $text, bool $eol = false) |
|
174
|
|
|
* @method Writer boldRedBgWhite(string $text, bool $eol = false) |
|
175
|
|
|
* @method Writer boldRedBgGray(string $text, bool $eol = false) |
|
176
|
|
|
* @method Writer boldRedBgDarkgray(string $text, bool $eol = false) |
|
177
|
|
|
* @method Writer boldGreenBgBlack(string $text, bool $eol = false) |
|
178
|
|
|
* @method Writer boldGreenBgRed(string $text, bool $eol = false) |
|
179
|
|
|
* @method Writer boldGreenBgYellow(string $text, bool $eol = false) |
|
180
|
|
|
* @method Writer boldGreenBgBlue(string $text, bool $eol = false) |
|
181
|
|
|
* @method Writer boldGreenBgPurple(string $text, bool $eol = false) |
|
182
|
|
|
* @method Writer boldGreenBgCyan(string $text, bool $eol = false) |
|
183
|
|
|
* @method Writer boldGreenBgWhite(string $text, bool $eol = false) |
|
184
|
|
|
* @method Writer boldGreenBgGray(string $text, bool $eol = false) |
|
185
|
|
|
* @method Writer boldGreenBgDarkgray(string $text, bool $eol = false) |
|
186
|
|
|
* @method Writer boldYellowBgBlack(string $text, bool $eol = false) |
|
187
|
|
|
* @method Writer boldYellowBgRed(string $text, bool $eol = false) |
|
188
|
|
|
* @method Writer boldYellowBgGreen(string $text, bool $eol = false) |
|
189
|
|
|
* @method Writer boldYellowBgBlue(string $text, bool $eol = false) |
|
190
|
|
|
* @method Writer boldYellowBgPurple(string $text, bool $eol = false) |
|
191
|
|
|
* @method Writer boldYellowBgCyan(string $text, bool $eol = false) |
|
192
|
|
|
* @method Writer boldYellowBgWhite(string $text, bool $eol = false) |
|
193
|
|
|
* @method Writer boldYellowBgGray(string $text, bool $eol = false) |
|
194
|
|
|
* @method Writer boldYellowBgDarkgray(string $text, bool $eol = false) |
|
195
|
|
|
* @method Writer boldBlueBgBlack(string $text, bool $eol = false) |
|
196
|
|
|
* @method Writer boldBlueBgRed(string $text, bool $eol = false) |
|
197
|
|
|
* @method Writer boldBlueBgGreen(string $text, bool $eol = false) |
|
198
|
|
|
* @method Writer boldBlueBgYellow(string $text, bool $eol = false) |
|
199
|
|
|
* @method Writer boldBlueBgPurple(string $text, bool $eol = false) |
|
200
|
|
|
* @method Writer boldBlueBgCyan(string $text, bool $eol = false) |
|
201
|
|
|
* @method Writer boldBlueBgWhite(string $text, bool $eol = false) |
|
202
|
|
|
* @method Writer boldBlueBgGray(string $text, bool $eol = false) |
|
203
|
|
|
* @method Writer boldBlueBgDarkgray(string $text, bool $eol = false) |
|
204
|
|
|
* @method Writer boldPurpleBgBlack(string $text, bool $eol = false) |
|
205
|
|
|
* @method Writer boldPurpleBgRed(string $text, bool $eol = false) |
|
206
|
|
|
* @method Writer boldPurpleBgGreen(string $text, bool $eol = false) |
|
207
|
|
|
* @method Writer boldPurpleBgYellow(string $text, bool $eol = false) |
|
208
|
|
|
* @method Writer boldPurpleBgBlue(string $text, bool $eol = false) |
|
209
|
|
|
* @method Writer boldPurpleBgCyan(string $text, bool $eol = false) |
|
210
|
|
|
* @method Writer boldPurpleBgWhite(string $text, bool $eol = false) |
|
211
|
|
|
* @method Writer boldPurpleBgGray(string $text, bool $eol = false) |
|
212
|
|
|
* @method Writer boldPurpleBgDarkgray(string $text, bool $eol = false) |
|
213
|
|
|
* @method Writer boldCyanBgBlack(string $text, bool $eol = false) |
|
214
|
|
|
* @method Writer boldCyanBgRed(string $text, bool $eol = false) |
|
215
|
|
|
* @method Writer boldCyanBgGreen(string $text, bool $eol = false) |
|
216
|
|
|
* @method Writer boldCyanBgYellow(string $text, bool $eol = false) |
|
217
|
|
|
* @method Writer boldCyanBgBlue(string $text, bool $eol = false) |
|
218
|
|
|
* @method Writer boldCyanBgPurple(string $text, bool $eol = false) |
|
219
|
|
|
* @method Writer boldCyanBgWhite(string $text, bool $eol = false) |
|
220
|
|
|
* @method Writer boldCyanBgGray(string $text, bool $eol = false) |
|
221
|
|
|
* @method Writer boldCyanBgDarkgray(string $text, bool $eol = false) |
|
222
|
|
|
* @method Writer boldWhiteBgBlack(string $text, bool $eol = false) |
|
223
|
|
|
* @method Writer boldWhiteBgRed(string $text, bool $eol = false) |
|
224
|
|
|
* @method Writer boldWhiteBgGreen(string $text, bool $eol = false) |
|
225
|
|
|
* @method Writer boldWhiteBgYellow(string $text, bool $eol = false) |
|
226
|
|
|
* @method Writer boldWhiteBgBlue(string $text, bool $eol = false) |
|
227
|
|
|
* @method Writer boldWhiteBgPurple(string $text, bool $eol = false) |
|
228
|
|
|
* @method Writer boldWhiteBgCyan(string $text, bool $eol = false) |
|
229
|
|
|
* @method Writer boldWhiteBgGray(string $text, bool $eol = false) |
|
230
|
|
|
* @method Writer boldWhiteBgDarkgray(string $text, bool $eol = false) |
|
231
|
|
|
* @method Writer boldGrayBgBlack(string $text, bool $eol = false) |
|
232
|
|
|
* @method Writer boldGrayBgRed(string $text, bool $eol = false) |
|
233
|
|
|
* @method Writer boldGrayBgGreen(string $text, bool $eol = false) |
|
234
|
|
|
* @method Writer boldGrayBgYellow(string $text, bool $eol = false) |
|
235
|
|
|
* @method Writer boldGrayBgBlue(string $text, bool $eol = false) |
|
236
|
|
|
* @method Writer boldGrayBgPurple(string $text, bool $eol = false) |
|
237
|
|
|
* @method Writer boldGrayBgCyan(string $text, bool $eol = false) |
|
238
|
|
|
* @method Writer boldGrayBgWhite(string $text, bool $eol = false) |
|
239
|
|
|
* @method Writer boldGrayBgDarkgray(string $text, bool $eol = false) |
|
240
|
|
|
* @method Writer boldDarkgrayBgBlack(string $text, bool $eol = false) |
|
241
|
|
|
* @method Writer boldDarkgrayBgRed(string $text, bool $eol = false) |
|
242
|
|
|
* @method Writer boldDarkgrayBgGreen(string $text, bool $eol = false) |
|
243
|
|
|
* @method Writer boldDarkgrayBgYellow(string $text, bool $eol = false) |
|
244
|
|
|
* @method Writer boldDarkgrayBgBlue(string $text, bool $eol = false) |
|
245
|
|
|
* @method Writer boldDarkgrayBgPurple(string $text, bool $eol = false) |
|
246
|
|
|
* @method Writer boldDarkgrayBgCyan(string $text, bool $eol = false) |
|
247
|
|
|
* @method Writer boldDarkgrayBgWhite(string $text, bool $eol = false) |
|
248
|
|
|
* @method Writer boldDarkgrayBgGray(string $text, bool $eol = false) |
|
249
|
|
|
* @method Writer dimBlackBgRed(string $text, bool $eol = false) |
|
250
|
|
|
* @method Writer dimBlackBgGreen(string $text, bool $eol = false) |
|
251
|
|
|
* @method Writer dimBlackBgYellow(string $text, bool $eol = false) |
|
252
|
|
|
* @method Writer dimBlackBgBlue(string $text, bool $eol = false) |
|
253
|
|
|
* @method Writer dimBlackBgPurple(string $text, bool $eol = false) |
|
254
|
|
|
* @method Writer dimBlackBgCyan(string $text, bool $eol = false) |
|
255
|
|
|
* @method Writer dimBlackBgWhite(string $text, bool $eol = false) |
|
256
|
|
|
* @method Writer dimBlackBgGray(string $text, bool $eol = false) |
|
257
|
|
|
* @method Writer dimBlackBgDarkgray(string $text, bool $eol = false) |
|
258
|
|
|
* @method Writer dimRedBgBlack(string $text, bool $eol = false) |
|
259
|
|
|
* @method Writer dimRedBgGreen(string $text, bool $eol = false) |
|
260
|
|
|
* @method Writer dimRedBgYellow(string $text, bool $eol = false) |
|
261
|
|
|
* @method Writer dimRedBgBlue(string $text, bool $eol = false) |
|
262
|
|
|
* @method Writer dimRedBgPurple(string $text, bool $eol = false) |
|
263
|
|
|
* @method Writer dimRedBgCyan(string $text, bool $eol = false) |
|
264
|
|
|
* @method Writer dimRedBgWhite(string $text, bool $eol = false) |
|
265
|
|
|
* @method Writer dimRedBgGray(string $text, bool $eol = false) |
|
266
|
|
|
* @method Writer dimRedBgDarkgray(string $text, bool $eol = false) |
|
267
|
|
|
* @method Writer dimGreenBgBlack(string $text, bool $eol = false) |
|
268
|
|
|
* @method Writer dimGreenBgRed(string $text, bool $eol = false) |
|
269
|
|
|
* @method Writer dimGreenBgYellow(string $text, bool $eol = false) |
|
270
|
|
|
* @method Writer dimGreenBgBlue(string $text, bool $eol = false) |
|
271
|
|
|
* @method Writer dimGreenBgPurple(string $text, bool $eol = false) |
|
272
|
|
|
* @method Writer dimGreenBgCyan(string $text, bool $eol = false) |
|
273
|
|
|
* @method Writer dimGreenBgWhite(string $text, bool $eol = false) |
|
274
|
|
|
* @method Writer dimGreenBgGray(string $text, bool $eol = false) |
|
275
|
|
|
* @method Writer dimGreenBgDarkgray(string $text, bool $eol = false) |
|
276
|
|
|
* @method Writer dimYellowBgBlack(string $text, bool $eol = false) |
|
277
|
|
|
* @method Writer dimYellowBgRed(string $text, bool $eol = false) |
|
278
|
|
|
* @method Writer dimYellowBgGreen(string $text, bool $eol = false) |
|
279
|
|
|
* @method Writer dimYellowBgBlue(string $text, bool $eol = false) |
|
280
|
|
|
* @method Writer dimYellowBgPurple(string $text, bool $eol = false) |
|
281
|
|
|
* @method Writer dimYellowBgCyan(string $text, bool $eol = false) |
|
282
|
|
|
* @method Writer dimYellowBgWhite(string $text, bool $eol = false) |
|
283
|
|
|
* @method Writer dimYellowBgGray(string $text, bool $eol = false) |
|
284
|
|
|
* @method Writer dimYellowBgDarkgray(string $text, bool $eol = false) |
|
285
|
|
|
* @method Writer dimBlueBgBlack(string $text, bool $eol = false) |
|
286
|
|
|
* @method Writer dimBlueBgRed(string $text, bool $eol = false) |
|
287
|
|
|
* @method Writer dimBlueBgGreen(string $text, bool $eol = false) |
|
288
|
|
|
* @method Writer dimBlueBgYellow(string $text, bool $eol = false) |
|
289
|
|
|
* @method Writer dimBlueBgPurple(string $text, bool $eol = false) |
|
290
|
|
|
* @method Writer dimBlueBgCyan(string $text, bool $eol = false) |
|
291
|
|
|
* @method Writer dimBlueBgWhite(string $text, bool $eol = false) |
|
292
|
|
|
* @method Writer dimBlueBgGray(string $text, bool $eol = false) |
|
293
|
|
|
* @method Writer dimBlueBgDarkgray(string $text, bool $eol = false) |
|
294
|
|
|
* @method Writer dimPurpleBgBlack(string $text, bool $eol = false) |
|
295
|
|
|
* @method Writer dimPurpleBgRed(string $text, bool $eol = false) |
|
296
|
|
|
* @method Writer dimPurpleBgGreen(string $text, bool $eol = false) |
|
297
|
|
|
* @method Writer dimPurpleBgYellow(string $text, bool $eol = false) |
|
298
|
|
|
* @method Writer dimPurpleBgBlue(string $text, bool $eol = false) |
|
299
|
|
|
* @method Writer dimPurpleBgCyan(string $text, bool $eol = false) |
|
300
|
|
|
* @method Writer dimPurpleBgWhite(string $text, bool $eol = false) |
|
301
|
|
|
* @method Writer dimPurpleBgGray(string $text, bool $eol = false) |
|
302
|
|
|
* @method Writer dimPurpleBgDarkgray(string $text, bool $eol = false) |
|
303
|
|
|
* @method Writer dimCyanBgBlack(string $text, bool $eol = false) |
|
304
|
|
|
* @method Writer dimCyanBgRed(string $text, bool $eol = false) |
|
305
|
|
|
* @method Writer dimCyanBgGreen(string $text, bool $eol = false) |
|
306
|
|
|
* @method Writer dimCyanBgYellow(string $text, bool $eol = false) |
|
307
|
|
|
* @method Writer dimCyanBgBlue(string $text, bool $eol = false) |
|
308
|
|
|
* @method Writer dimCyanBgPurple(string $text, bool $eol = false) |
|
309
|
|
|
* @method Writer dimCyanBgWhite(string $text, bool $eol = false) |
|
310
|
|
|
* @method Writer dimCyanBgGray(string $text, bool $eol = false) |
|
311
|
|
|
* @method Writer dimCyanBgDarkgray(string $text, bool $eol = false) |
|
312
|
|
|
* @method Writer dimWhiteBgBlack(string $text, bool $eol = false) |
|
313
|
|
|
* @method Writer dimWhiteBgRed(string $text, bool $eol = false) |
|
314
|
|
|
* @method Writer dimWhiteBgGreen(string $text, bool $eol = false) |
|
315
|
|
|
* @method Writer dimWhiteBgYellow(string $text, bool $eol = false) |
|
316
|
|
|
* @method Writer dimWhiteBgBlue(string $text, bool $eol = false) |
|
317
|
|
|
* @method Writer dimWhiteBgPurple(string $text, bool $eol = false) |
|
318
|
|
|
* @method Writer dimWhiteBgCyan(string $text, bool $eol = false) |
|
319
|
|
|
* @method Writer dimWhiteBgGray(string $text, bool $eol = false) |
|
320
|
|
|
* @method Writer dimWhiteBgDarkgray(string $text, bool $eol = false) |
|
321
|
|
|
* @method Writer dimGrayBgBlack(string $text, bool $eol = false) |
|
322
|
|
|
* @method Writer dimGrayBgRed(string $text, bool $eol = false) |
|
323
|
|
|
* @method Writer dimGrayBgGreen(string $text, bool $eol = false) |
|
324
|
|
|
* @method Writer dimGrayBgYellow(string $text, bool $eol = false) |
|
325
|
|
|
* @method Writer dimGrayBgBlue(string $text, bool $eol = false) |
|
326
|
|
|
* @method Writer dimGrayBgPurple(string $text, bool $eol = false) |
|
327
|
|
|
* @method Writer dimGrayBgCyan(string $text, bool $eol = false) |
|
328
|
|
|
* @method Writer dimGrayBgWhite(string $text, bool $eol = false) |
|
329
|
|
|
* @method Writer dimGrayBgDarkgray(string $text, bool $eol = false) |
|
330
|
|
|
* @method Writer dimDarkgrayBgBlack(string $text, bool $eol = false) |
|
331
|
|
|
* @method Writer dimDarkgrayBgRed(string $text, bool $eol = false) |
|
332
|
|
|
* @method Writer dimDarkgrayBgGreen(string $text, bool $eol = false) |
|
333
|
|
|
* @method Writer dimDarkgrayBgYellow(string $text, bool $eol = false) |
|
334
|
|
|
* @method Writer dimDarkgrayBgBlue(string $text, bool $eol = false) |
|
335
|
|
|
* @method Writer dimDarkgrayBgPurple(string $text, bool $eol = false) |
|
336
|
|
|
* @method Writer dimDarkgrayBgCyan(string $text, bool $eol = false) |
|
337
|
|
|
* @method Writer dimDarkgrayBgWhite(string $text, bool $eol = false) |
|
338
|
|
|
* @method Writer dimDarkgrayBgGray(string $text, bool $eol = false) |
|
339
|
|
|
* @method Writer italicBlackBgRed(string $text, bool $eol = false) |
|
340
|
|
|
* @method Writer italicBlackBgGreen(string $text, bool $eol = false) |
|
341
|
|
|
* @method Writer italicBlackBgYellow(string $text, bool $eol = false) |
|
342
|
|
|
* @method Writer italicBlackBgBlue(string $text, bool $eol = false) |
|
343
|
|
|
* @method Writer italicBlackBgPurple(string $text, bool $eol = false) |
|
344
|
|
|
* @method Writer italicBlackBgCyan(string $text, bool $eol = false) |
|
345
|
|
|
* @method Writer italicBlackBgWhite(string $text, bool $eol = false) |
|
346
|
|
|
* @method Writer italicBlackBgGray(string $text, bool $eol = false) |
|
347
|
|
|
* @method Writer italicBlackBgDarkgray(string $text, bool $eol = false) |
|
348
|
|
|
* @method Writer italicRedBgBlack(string $text, bool $eol = false) |
|
349
|
|
|
* @method Writer italicRedBgGreen(string $text, bool $eol = false) |
|
350
|
|
|
* @method Writer italicRedBgYellow(string $text, bool $eol = false) |
|
351
|
|
|
* @method Writer italicRedBgBlue(string $text, bool $eol = false) |
|
352
|
|
|
* @method Writer italicRedBgPurple(string $text, bool $eol = false) |
|
353
|
|
|
* @method Writer italicRedBgCyan(string $text, bool $eol = false) |
|
354
|
|
|
* @method Writer italicRedBgWhite(string $text, bool $eol = false) |
|
355
|
|
|
* @method Writer italicRedBgGray(string $text, bool $eol = false) |
|
356
|
|
|
* @method Writer italicRedBgDarkgray(string $text, bool $eol = false) |
|
357
|
|
|
* @method Writer italicGreenBgBlack(string $text, bool $eol = false) |
|
358
|
|
|
* @method Writer italicGreenBgRed(string $text, bool $eol = false) |
|
359
|
|
|
* @method Writer italicGreenBgYellow(string $text, bool $eol = false) |
|
360
|
|
|
* @method Writer italicGreenBgBlue(string $text, bool $eol = false) |
|
361
|
|
|
* @method Writer italicGreenBgPurple(string $text, bool $eol = false) |
|
362
|
|
|
* @method Writer italicGreenBgCyan(string $text, bool $eol = false) |
|
363
|
|
|
* @method Writer italicGreenBgWhite(string $text, bool $eol = false) |
|
364
|
|
|
* @method Writer italicGreenBgGray(string $text, bool $eol = false) |
|
365
|
|
|
* @method Writer italicGreenBgDarkgray(string $text, bool $eol = false) |
|
366
|
|
|
* @method Writer italicYellowBgBlack(string $text, bool $eol = false) |
|
367
|
|
|
* @method Writer italicYellowBgRed(string $text, bool $eol = false) |
|
368
|
|
|
* @method Writer italicYellowBgGreen(string $text, bool $eol = false) |
|
369
|
|
|
* @method Writer italicYellowBgBlue(string $text, bool $eol = false) |
|
370
|
|
|
* @method Writer italicYellowBgPurple(string $text, bool $eol = false) |
|
371
|
|
|
* @method Writer italicYellowBgCyan(string $text, bool $eol = false) |
|
372
|
|
|
* @method Writer italicYellowBgWhite(string $text, bool $eol = false) |
|
373
|
|
|
* @method Writer italicYellowBgGray(string $text, bool $eol = false) |
|
374
|
|
|
* @method Writer italicYellowBgDarkgray(string $text, bool $eol = false) |
|
375
|
|
|
* @method Writer italicBlueBgBlack(string $text, bool $eol = false) |
|
376
|
|
|
* @method Writer italicBlueBgRed(string $text, bool $eol = false) |
|
377
|
|
|
* @method Writer italicBlueBgGreen(string $text, bool $eol = false) |
|
378
|
|
|
* @method Writer italicBlueBgYellow(string $text, bool $eol = false) |
|
379
|
|
|
* @method Writer italicBlueBgPurple(string $text, bool $eol = false) |
|
380
|
|
|
* @method Writer italicBlueBgCyan(string $text, bool $eol = false) |
|
381
|
|
|
* @method Writer italicBlueBgWhite(string $text, bool $eol = false) |
|
382
|
|
|
* @method Writer italicBlueBgGray(string $text, bool $eol = false) |
|
383
|
|
|
* @method Writer italicBlueBgDarkgray(string $text, bool $eol = false) |
|
384
|
|
|
* @method Writer italicPurpleBgBlack(string $text, bool $eol = false) |
|
385
|
|
|
* @method Writer italicPurpleBgRed(string $text, bool $eol = false) |
|
386
|
|
|
* @method Writer italicPurpleBgGreen(string $text, bool $eol = false) |
|
387
|
|
|
* @method Writer italicPurpleBgYellow(string $text, bool $eol = false) |
|
388
|
|
|
* @method Writer italicPurpleBgBlue(string $text, bool $eol = false) |
|
389
|
|
|
* @method Writer italicPurpleBgCyan(string $text, bool $eol = false) |
|
390
|
|
|
* @method Writer italicPurpleBgWhite(string $text, bool $eol = false) |
|
391
|
|
|
* @method Writer italicPurpleBgGray(string $text, bool $eol = false) |
|
392
|
|
|
* @method Writer italicPurpleBgDarkgray(string $text, bool $eol = false) |
|
393
|
|
|
* @method Writer italicCyanBgBlack(string $text, bool $eol = false) |
|
394
|
|
|
* @method Writer italicCyanBgRed(string $text, bool $eol = false) |
|
395
|
|
|
* @method Writer italicCyanBgGreen(string $text, bool $eol = false) |
|
396
|
|
|
* @method Writer italicCyanBgYellow(string $text, bool $eol = false) |
|
397
|
|
|
* @method Writer italicCyanBgBlue(string $text, bool $eol = false) |
|
398
|
|
|
* @method Writer italicCyanBgPurple(string $text, bool $eol = false) |
|
399
|
|
|
* @method Writer italicCyanBgWhite(string $text, bool $eol = false) |
|
400
|
|
|
* @method Writer italicCyanBgGray(string $text, bool $eol = false) |
|
401
|
|
|
* @method Writer italicCyanBgDarkgray(string $text, bool $eol = false) |
|
402
|
|
|
* @method Writer italicWhiteBgBlack(string $text, bool $eol = false) |
|
403
|
|
|
* @method Writer italicWhiteBgRed(string $text, bool $eol = false) |
|
404
|
|
|
* @method Writer italicWhiteBgGreen(string $text, bool $eol = false) |
|
405
|
|
|
* @method Writer italicWhiteBgYellow(string $text, bool $eol = false) |
|
406
|
|
|
* @method Writer italicWhiteBgBlue(string $text, bool $eol = false) |
|
407
|
|
|
* @method Writer italicWhiteBgPurple(string $text, bool $eol = false) |
|
408
|
|
|
* @method Writer italicWhiteBgCyan(string $text, bool $eol = false) |
|
409
|
|
|
* @method Writer italicWhiteBgGray(string $text, bool $eol = false) |
|
410
|
|
|
* @method Writer italicWhiteBgDarkgray(string $text, bool $eol = false) |
|
411
|
|
|
* @method Writer italicGrayBgBlack(string $text, bool $eol = false) |
|
412
|
|
|
* @method Writer italicGrayBgRed(string $text, bool $eol = false) |
|
413
|
|
|
* @method Writer italicGrayBgGreen(string $text, bool $eol = false) |
|
414
|
|
|
* @method Writer italicGrayBgYellow(string $text, bool $eol = false) |
|
415
|
|
|
* @method Writer italicGrayBgBlue(string $text, bool $eol = false) |
|
416
|
|
|
* @method Writer italicGrayBgPurple(string $text, bool $eol = false) |
|
417
|
|
|
* @method Writer italicGrayBgCyan(string $text, bool $eol = false) |
|
418
|
|
|
* @method Writer italicGrayBgWhite(string $text, bool $eol = false) |
|
419
|
|
|
* @method Writer italicGrayBgDarkgray(string $text, bool $eol = false) |
|
420
|
|
|
* @method Writer italicDarkgrayBgBlack(string $text, bool $eol = false) |
|
421
|
|
|
* @method Writer italicDarkgrayBgRed(string $text, bool $eol = false) |
|
422
|
|
|
* @method Writer italicDarkgrayBgGreen(string $text, bool $eol = false) |
|
423
|
|
|
* @method Writer italicDarkgrayBgYellow(string $text, bool $eol = false) |
|
424
|
|
|
* @method Writer italicDarkgrayBgBlue(string $text, bool $eol = false) |
|
425
|
|
|
* @method Writer italicDarkgrayBgPurple(string $text, bool $eol = false) |
|
426
|
|
|
* @method Writer italicDarkgrayBgCyan(string $text, bool $eol = false) |
|
427
|
|
|
* @method Writer italicDarkgrayBgWhite(string $text, bool $eol = false) |
|
428
|
|
|
* @method Writer italicDarkgrayBgGray(string $text, bool $eol = false) |
|
429
|
|
|
* @method Writer underlineBlackBgRed(string $text, bool $eol = false) |
|
430
|
|
|
* @method Writer underlineBlackBgGreen(string $text, bool $eol = false) |
|
431
|
|
|
* @method Writer underlineBlackBgYellow(string $text, bool $eol = false) |
|
432
|
|
|
* @method Writer underlineBlackBgBlue(string $text, bool $eol = false) |
|
433
|
|
|
* @method Writer underlineBlackBgPurple(string $text, bool $eol = false) |
|
434
|
|
|
* @method Writer underlineBlackBgCyan(string $text, bool $eol = false) |
|
435
|
|
|
* @method Writer underlineBlackBgWhite(string $text, bool $eol = false) |
|
436
|
|
|
* @method Writer underlineBlackBgGray(string $text, bool $eol = false) |
|
437
|
|
|
* @method Writer underlineBlackBgDarkgray(string $text, bool $eol = false) |
|
438
|
|
|
* @method Writer underlineRedBgBlack(string $text, bool $eol = false) |
|
439
|
|
|
* @method Writer underlineRedBgGreen(string $text, bool $eol = false) |
|
440
|
|
|
* @method Writer underlineRedBgYellow(string $text, bool $eol = false) |
|
441
|
|
|
* @method Writer underlineRedBgBlue(string $text, bool $eol = false) |
|
442
|
|
|
* @method Writer underlineRedBgPurple(string $text, bool $eol = false) |
|
443
|
|
|
* @method Writer underlineRedBgCyan(string $text, bool $eol = false) |
|
444
|
|
|
* @method Writer underlineRedBgWhite(string $text, bool $eol = false) |
|
445
|
|
|
* @method Writer underlineRedBgGray(string $text, bool $eol = false) |
|
446
|
|
|
* @method Writer underlineRedBgDarkgray(string $text, bool $eol = false) |
|
447
|
|
|
* @method Writer underlineGreenBgBlack(string $text, bool $eol = false) |
|
448
|
|
|
* @method Writer underlineGreenBgRed(string $text, bool $eol = false) |
|
449
|
|
|
* @method Writer underlineGreenBgYellow(string $text, bool $eol = false) |
|
450
|
|
|
* @method Writer underlineGreenBgBlue(string $text, bool $eol = false) |
|
451
|
|
|
* @method Writer underlineGreenBgPurple(string $text, bool $eol = false) |
|
452
|
|
|
* @method Writer underlineGreenBgCyan(string $text, bool $eol = false) |
|
453
|
|
|
* @method Writer underlineGreenBgWhite(string $text, bool $eol = false) |
|
454
|
|
|
* @method Writer underlineGreenBgGray(string $text, bool $eol = false) |
|
455
|
|
|
* @method Writer underlineGreenBgDarkgray(string $text, bool $eol = false) |
|
456
|
|
|
* @method Writer underlineYellowBgBlack(string $text, bool $eol = false) |
|
457
|
|
|
* @method Writer underlineYellowBgRed(string $text, bool $eol = false) |
|
458
|
|
|
* @method Writer underlineYellowBgGreen(string $text, bool $eol = false) |
|
459
|
|
|
* @method Writer underlineYellowBgBlue(string $text, bool $eol = false) |
|
460
|
|
|
* @method Writer underlineYellowBgPurple(string $text, bool $eol = false) |
|
461
|
|
|
* @method Writer underlineYellowBgCyan(string $text, bool $eol = false) |
|
462
|
|
|
* @method Writer underlineYellowBgWhite(string $text, bool $eol = false) |
|
463
|
|
|
* @method Writer underlineYellowBgGray(string $text, bool $eol = false) |
|
464
|
|
|
* @method Writer underlineYellowBgDarkgray(string $text, bool $eol = false) |
|
465
|
|
|
* @method Writer underlineBlueBgBlack(string $text, bool $eol = false) |
|
466
|
|
|
* @method Writer underlineBlueBgRed(string $text, bool $eol = false) |
|
467
|
|
|
* @method Writer underlineBlueBgGreen(string $text, bool $eol = false) |
|
468
|
|
|
* @method Writer underlineBlueBgYellow(string $text, bool $eol = false) |
|
469
|
|
|
* @method Writer underlineBlueBgPurple(string $text, bool $eol = false) |
|
470
|
|
|
* @method Writer underlineBlueBgCyan(string $text, bool $eol = false) |
|
471
|
|
|
* @method Writer underlineBlueBgWhite(string $text, bool $eol = false) |
|
472
|
|
|
* @method Writer underlineBlueBgGray(string $text, bool $eol = false) |
|
473
|
|
|
* @method Writer underlineBlueBgDarkgray(string $text, bool $eol = false) |
|
474
|
|
|
* @method Writer underlinePurpleBgBlack(string $text, bool $eol = false) |
|
475
|
|
|
* @method Writer underlinePurpleBgRed(string $text, bool $eol = false) |
|
476
|
|
|
* @method Writer underlinePurpleBgGreen(string $text, bool $eol = false) |
|
477
|
|
|
* @method Writer underlinePurpleBgYellow(string $text, bool $eol = false) |
|
478
|
|
|
* @method Writer underlinePurpleBgBlue(string $text, bool $eol = false) |
|
479
|
|
|
* @method Writer underlinePurpleBgCyan(string $text, bool $eol = false) |
|
480
|
|
|
* @method Writer underlinePurpleBgWhite(string $text, bool $eol = false) |
|
481
|
|
|
* @method Writer underlinePurpleBgGray(string $text, bool $eol = false) |
|
482
|
|
|
* @method Writer underlinePurpleBgDarkgray(string $text, bool $eol = false) |
|
483
|
|
|
* @method Writer underlineCyanBgBlack(string $text, bool $eol = false) |
|
484
|
|
|
* @method Writer underlineCyanBgRed(string $text, bool $eol = false) |
|
485
|
|
|
* @method Writer underlineCyanBgGreen(string $text, bool $eol = false) |
|
486
|
|
|
* @method Writer underlineCyanBgYellow(string $text, bool $eol = false) |
|
487
|
|
|
* @method Writer underlineCyanBgBlue(string $text, bool $eol = false) |
|
488
|
|
|
* @method Writer underlineCyanBgPurple(string $text, bool $eol = false) |
|
489
|
|
|
* @method Writer underlineCyanBgWhite(string $text, bool $eol = false) |
|
490
|
|
|
* @method Writer underlineCyanBgGray(string $text, bool $eol = false) |
|
491
|
|
|
* @method Writer underlineCyanBgDarkgray(string $text, bool $eol = false) |
|
492
|
|
|
* @method Writer underlineWhiteBgBlack(string $text, bool $eol = false) |
|
493
|
|
|
* @method Writer underlineWhiteBgRed(string $text, bool $eol = false) |
|
494
|
|
|
* @method Writer underlineWhiteBgGreen(string $text, bool $eol = false) |
|
495
|
|
|
* @method Writer underlineWhiteBgYellow(string $text, bool $eol = false) |
|
496
|
|
|
* @method Writer underlineWhiteBgBlue(string $text, bool $eol = false) |
|
497
|
|
|
* @method Writer underlineWhiteBgPurple(string $text, bool $eol = false) |
|
498
|
|
|
* @method Writer underlineWhiteBgCyan(string $text, bool $eol = false) |
|
499
|
|
|
* @method Writer underlineWhiteBgGray(string $text, bool $eol = false) |
|
500
|
|
|
* @method Writer underlineWhiteBgDarkgray(string $text, bool $eol = false) |
|
501
|
|
|
* @method Writer underlineGrayBgBlack(string $text, bool $eol = false) |
|
502
|
|
|
* @method Writer underlineGrayBgRed(string $text, bool $eol = false) |
|
503
|
|
|
* @method Writer underlineGrayBgGreen(string $text, bool $eol = false) |
|
504
|
|
|
* @method Writer underlineGrayBgYellow(string $text, bool $eol = false) |
|
505
|
|
|
* @method Writer underlineGrayBgBlue(string $text, bool $eol = false) |
|
506
|
|
|
* @method Writer underlineGrayBgPurple(string $text, bool $eol = false) |
|
507
|
|
|
* @method Writer underlineGrayBgCyan(string $text, bool $eol = false) |
|
508
|
|
|
* @method Writer underlineGrayBgWhite(string $text, bool $eol = false) |
|
509
|
|
|
* @method Writer underlineGrayBgDarkgray(string $text, bool $eol = false) |
|
510
|
|
|
* @method Writer underlineDarkgrayBgBlack(string $text, bool $eol = false) |
|
511
|
|
|
* @method Writer underlineDarkgrayBgRed(string $text, bool $eol = false) |
|
512
|
|
|
* @method Writer underlineDarkgrayBgGreen(string $text, bool $eol = false) |
|
513
|
|
|
* @method Writer underlineDarkgrayBgYellow(string $text, bool $eol = false) |
|
514
|
|
|
* @method Writer underlineDarkgrayBgBlue(string $text, bool $eol = false) |
|
515
|
|
|
* @method Writer underlineDarkgrayBgPurple(string $text, bool $eol = false) |
|
516
|
|
|
* @method Writer underlineDarkgrayBgCyan(string $text, bool $eol = false) |
|
517
|
|
|
* @method Writer underlineDarkgrayBgWhite(string $text, bool $eol = false) |
|
518
|
|
|
* @method Writer underlineDarkgrayBgGray(string $text, bool $eol = false) |
|
519
|
|
|
* @method Writer blackBgRed(string $text, bool $eol = false) |
|
520
|
|
|
* @method Writer blackBgGreen(string $text, bool $eol = false) |
|
521
|
|
|
* @method Writer blackBgYellow(string $text, bool $eol = false) |
|
522
|
|
|
* @method Writer blackBgBlue(string $text, bool $eol = false) |
|
523
|
|
|
* @method Writer blackBgPurple(string $text, bool $eol = false) |
|
524
|
|
|
* @method Writer blackBgCyan(string $text, bool $eol = false) |
|
525
|
|
|
* @method Writer blackBgWhite(string $text, bool $eol = false) |
|
526
|
|
|
* @method Writer blackBgGray(string $text, bool $eol = false) |
|
527
|
|
|
* @method Writer blackBgDarkgray(string $text, bool $eol = false) |
|
528
|
|
|
* @method Writer redBgBlack(string $text, bool $eol = false) |
|
529
|
|
|
* @method Writer redBgGreen(string $text, bool $eol = false) |
|
530
|
|
|
* @method Writer redBgYellow(string $text, bool $eol = false) |
|
531
|
|
|
* @method Writer redBgBlue(string $text, bool $eol = false) |
|
532
|
|
|
* @method Writer redBgPurple(string $text, bool $eol = false) |
|
533
|
|
|
* @method Writer redBgCyan(string $text, bool $eol = false) |
|
534
|
|
|
* @method Writer redBgWhite(string $text, bool $eol = false) |
|
535
|
|
|
* @method Writer redBgGray(string $text, bool $eol = false) |
|
536
|
|
|
* @method Writer redBgDarkgray(string $text, bool $eol = false) |
|
537
|
|
|
* @method Writer greenBgBlack(string $text, bool $eol = false) |
|
538
|
|
|
* @method Writer greenBgRed(string $text, bool $eol = false) |
|
539
|
|
|
* @method Writer greenBgYellow(string $text, bool $eol = false) |
|
540
|
|
|
* @method Writer greenBgBlue(string $text, bool $eol = false) |
|
541
|
|
|
* @method Writer greenBgPurple(string $text, bool $eol = false) |
|
542
|
|
|
* @method Writer greenBgCyan(string $text, bool $eol = false) |
|
543
|
|
|
* @method Writer greenBgWhite(string $text, bool $eol = false) |
|
544
|
|
|
* @method Writer greenBgGray(string $text, bool $eol = false) |
|
545
|
|
|
* @method Writer greenBgDarkgray(string $text, bool $eol = false) |
|
546
|
|
|
* @method Writer yellowBgBlack(string $text, bool $eol = false) |
|
547
|
|
|
* @method Writer yellowBgRed(string $text, bool $eol = false) |
|
548
|
|
|
* @method Writer yellowBgGreen(string $text, bool $eol = false) |
|
549
|
|
|
* @method Writer yellowBgBlue(string $text, bool $eol = false) |
|
550
|
|
|
* @method Writer yellowBgPurple(string $text, bool $eol = false) |
|
551
|
|
|
* @method Writer yellowBgCyan(string $text, bool $eol = false) |
|
552
|
|
|
* @method Writer yellowBgWhite(string $text, bool $eol = false) |
|
553
|
|
|
* @method Writer yellowBgGray(string $text, bool $eol = false) |
|
554
|
|
|
* @method Writer yellowBgDarkgray(string $text, bool $eol = false) |
|
555
|
|
|
* @method Writer blueBgBlack(string $text, bool $eol = false) |
|
556
|
|
|
* @method Writer blueBgRed(string $text, bool $eol = false) |
|
557
|
|
|
* @method Writer blueBgGreen(string $text, bool $eol = false) |
|
558
|
|
|
* @method Writer blueBgYellow(string $text, bool $eol = false) |
|
559
|
|
|
* @method Writer blueBgPurple(string $text, bool $eol = false) |
|
560
|
|
|
* @method Writer blueBgCyan(string $text, bool $eol = false) |
|
561
|
|
|
* @method Writer blueBgWhite(string $text, bool $eol = false) |
|
562
|
|
|
* @method Writer blueBgGray(string $text, bool $eol = false) |
|
563
|
|
|
* @method Writer blueBgDarkgray(string $text, bool $eol = false) |
|
564
|
|
|
* @method Writer purpleBgBlack(string $text, bool $eol = false) |
|
565
|
|
|
* @method Writer purpleBgRed(string $text, bool $eol = false) |
|
566
|
|
|
* @method Writer purpleBgGreen(string $text, bool $eol = false) |
|
567
|
|
|
* @method Writer purpleBgYellow(string $text, bool $eol = false) |
|
568
|
|
|
* @method Writer purpleBgBlue(string $text, bool $eol = false) |
|
569
|
|
|
* @method Writer purpleBgCyan(string $text, bool $eol = false) |
|
570
|
|
|
* @method Writer purpleBgWhite(string $text, bool $eol = false) |
|
571
|
|
|
* @method Writer purpleBgGray(string $text, bool $eol = false) |
|
572
|
|
|
* @method Writer purpleBgDarkgray(string $text, bool $eol = false) |
|
573
|
|
|
* @method Writer cyanBgBlack(string $text, bool $eol = false) |
|
574
|
|
|
* @method Writer cyanBgRed(string $text, bool $eol = false) |
|
575
|
|
|
* @method Writer cyanBgGreen(string $text, bool $eol = false) |
|
576
|
|
|
* @method Writer cyanBgYellow(string $text, bool $eol = false) |
|
577
|
|
|
* @method Writer cyanBgBlue(string $text, bool $eol = false) |
|
578
|
|
|
* @method Writer cyanBgPurple(string $text, bool $eol = false) |
|
579
|
|
|
* @method Writer cyanBgWhite(string $text, bool $eol = false) |
|
580
|
|
|
* @method Writer cyanBgGray(string $text, bool $eol = false) |
|
581
|
|
|
* @method Writer cyanBgDarkgray(string $text, bool $eol = false) |
|
582
|
|
|
* @method Writer whiteBgBlack(string $text, bool $eol = false) |
|
583
|
|
|
* @method Writer whiteBgRed(string $text, bool $eol = false) |
|
584
|
|
|
* @method Writer whiteBgGreen(string $text, bool $eol = false) |
|
585
|
|
|
* @method Writer whiteBgYellow(string $text, bool $eol = false) |
|
586
|
|
|
* @method Writer whiteBgBlue(string $text, bool $eol = false) |
|
587
|
|
|
* @method Writer whiteBgPurple(string $text, bool $eol = false) |
|
588
|
|
|
* @method Writer whiteBgCyan(string $text, bool $eol = false) |
|
589
|
|
|
* @method Writer whiteBgGray(string $text, bool $eol = false) |
|
590
|
|
|
* @method Writer whiteBgDarkgray(string $text, bool $eol = false) |
|
591
|
|
|
* @method Writer grayBgBlack(string $text, bool $eol = false) |
|
592
|
|
|
* @method Writer grayBgRed(string $text, bool $eol = false) |
|
593
|
|
|
* @method Writer grayBgGreen(string $text, bool $eol = false) |
|
594
|
|
|
* @method Writer grayBgYellow(string $text, bool $eol = false) |
|
595
|
|
|
* @method Writer grayBgBlue(string $text, bool $eol = false) |
|
596
|
|
|
* @method Writer grayBgPurple(string $text, bool $eol = false) |
|
597
|
|
|
* @method Writer grayBgCyan(string $text, bool $eol = false) |
|
598
|
|
|
* @method Writer grayBgWhite(string $text, bool $eol = false) |
|
599
|
|
|
* @method Writer grayBgDarkgray(string $text, bool $eol = false) |
|
600
|
|
|
* @method Writer darkgrayBgBlack(string $text, bool $eol = false) |
|
601
|
|
|
* @method Writer darkgrayBgRed(string $text, bool $eol = false) |
|
602
|
|
|
* @method Writer darkgrayBgGreen(string $text, bool $eol = false) |
|
603
|
|
|
* @method Writer darkgrayBgYellow(string $text, bool $eol = false) |
|
604
|
|
|
* @method Writer darkgrayBgBlue(string $text, bool $eol = false) |
|
605
|
|
|
* @method Writer darkgrayBgPurple(string $text, bool $eol = false) |
|
606
|
|
|
* @method Writer darkgrayBgCyan(string $text, bool $eol = false) |
|
607
|
|
|
* @method Writer darkgrayBgWhite(string $text, bool $eol = false) |
|
608
|
|
|
* @method Writer darkgrayBgGray(string $text, bool $eol = false) |
|
609
|
|
|
*/ |
|
610
|
|
|
class Writer |
|
611
|
|
|
{ |
|
612
|
|
|
|
|
613
|
|
|
/** |
|
614
|
|
|
* The output stream |
|
615
|
|
|
* @var resource |
|
616
|
|
|
*/ |
|
617
|
|
|
protected $stream; |
|
618
|
|
|
|
|
619
|
|
|
/** |
|
620
|
|
|
* The output error stream |
|
621
|
|
|
* @var resource |
|
622
|
|
|
*/ |
|
623
|
|
|
protected $errorStream; |
|
624
|
|
|
|
|
625
|
|
|
/** |
|
626
|
|
|
* Color method to be called |
|
627
|
|
|
* @var string |
|
628
|
|
|
*/ |
|
629
|
|
|
protected string $method = ''; |
|
630
|
|
|
|
|
631
|
|
|
/** |
|
632
|
|
|
* The color instance |
|
633
|
|
|
* @var Color |
|
634
|
|
|
*/ |
|
635
|
|
|
protected Color $color; |
|
636
|
|
|
|
|
637
|
|
|
/** |
|
638
|
|
|
* The cursor instance |
|
639
|
|
|
* @var Cursor |
|
640
|
|
|
*/ |
|
641
|
|
|
protected Cursor $cursor; |
|
642
|
|
|
|
|
643
|
|
|
/** |
|
644
|
|
|
* Create new instance |
|
645
|
|
|
* @param string|null $path the output write path |
|
646
|
|
|
* @param Color|null $color the color instance |
|
647
|
|
|
*/ |
|
648
|
|
|
public function __construct(?string $path = null, ?Color $color = null) |
|
649
|
|
|
{ |
|
650
|
|
|
$stream = null; |
|
651
|
|
|
if ($path !== null) { |
|
652
|
|
|
$stream = fopen($path, 'w'); |
|
653
|
|
|
} |
|
654
|
|
|
|
|
655
|
|
|
$this->stream = $stream ?? STDOUT; |
|
656
|
|
|
$this->errorStream = $stream ?? STDERR; |
|
657
|
|
|
|
|
658
|
|
|
$this->color = $color ?? new Color(); |
|
659
|
|
|
$this->cursor = new Cursor(); |
|
660
|
|
|
} |
|
661
|
|
|
|
|
662
|
|
|
/** |
|
663
|
|
|
* Return the color instance |
|
664
|
|
|
* @return Color |
|
665
|
|
|
*/ |
|
666
|
|
|
public function getColor(): Color |
|
667
|
|
|
{ |
|
668
|
|
|
return $this->color; |
|
669
|
|
|
} |
|
670
|
|
|
|
|
671
|
|
|
/** |
|
672
|
|
|
* Return the cursor instance |
|
673
|
|
|
* @return Cursor |
|
674
|
|
|
*/ |
|
675
|
|
|
public function getCursor(): Cursor |
|
676
|
|
|
{ |
|
677
|
|
|
return $this->cursor; |
|
678
|
|
|
} |
|
679
|
|
|
|
|
680
|
|
|
/** |
|
681
|
|
|
* Write the formatted text to standard output. |
|
682
|
|
|
* @param string $text |
|
683
|
|
|
* @param bool $eol |
|
684
|
|
|
* @return $this |
|
685
|
|
|
*/ |
|
686
|
|
|
public function write(string $text, bool $eol = false): self |
|
687
|
|
|
{ |
|
688
|
|
|
$method = 'line'; |
|
689
|
|
|
if (!empty($this->method)) { |
|
690
|
|
|
$method = $this->method; |
|
691
|
|
|
$this->method = ''; |
|
692
|
|
|
} |
|
693
|
|
|
|
|
694
|
|
|
$styledText = $this->color->{$method}($text); |
|
695
|
|
|
if ($eol) { |
|
696
|
|
|
$styledText .= PHP_EOL; |
|
697
|
|
|
} |
|
698
|
|
|
|
|
699
|
|
|
return $this->doWrite($styledText, false); |
|
700
|
|
|
} |
|
701
|
|
|
|
|
702
|
|
|
/** |
|
703
|
|
|
* Write the formatted text to standard error. |
|
704
|
|
|
* @param string $text |
|
705
|
|
|
* @param bool $eol |
|
706
|
|
|
* @return $this |
|
707
|
|
|
*/ |
|
708
|
|
|
public function writeError(string $text, bool $eol = false): self |
|
709
|
|
|
{ |
|
710
|
|
|
$styledText = $this->color->red($text); |
|
711
|
|
|
if ($eol) { |
|
712
|
|
|
$styledText .= PHP_EOL; |
|
713
|
|
|
} |
|
714
|
|
|
|
|
715
|
|
|
return $this->doWrite($styledText, true); |
|
716
|
|
|
} |
|
717
|
|
|
|
|
718
|
|
|
/** |
|
719
|
|
|
* Write formatted text in HTML style |
|
720
|
|
|
* @see Color::colors |
|
721
|
|
|
* |
|
722
|
|
|
* @param string $text |
|
723
|
|
|
* @param bool $eol |
|
724
|
|
|
* @return $this |
|
725
|
|
|
*/ |
|
726
|
|
|
public function colors(string $text, bool $eol = false): self |
|
727
|
|
|
{ |
|
728
|
|
|
$styledText = $this->color->colors($text); |
|
729
|
|
|
if ($eol) { |
|
730
|
|
|
$styledText .= PHP_EOL; |
|
731
|
|
|
} |
|
732
|
|
|
|
|
733
|
|
|
return $this->doWrite($styledText, false); |
|
734
|
|
|
} |
|
735
|
|
|
|
|
736
|
|
|
/** |
|
737
|
|
|
* Write the raw text to stream. |
|
738
|
|
|
* @param string $text |
|
739
|
|
|
* @param bool $error |
|
740
|
|
|
* @return $this |
|
741
|
|
|
*/ |
|
742
|
|
|
public function raw(string $text, bool $error = false): self |
|
743
|
|
|
{ |
|
744
|
|
|
return $this->doWrite($text, $error); |
|
745
|
|
|
} |
|
746
|
|
|
|
|
747
|
|
|
/** |
|
748
|
|
|
* Generate table for the console |
|
749
|
|
|
* @param array<int, array<int, array<string, string>>> $rows |
|
750
|
|
|
* @param array<string, string> $styles |
|
751
|
|
|
* @return self |
|
752
|
|
|
*/ |
|
753
|
|
|
public function table(array $rows, array $styles = []): self |
|
754
|
|
|
{ |
|
755
|
|
|
$table = (new Table())->render($rows, $styles); |
|
756
|
|
|
|
|
757
|
|
|
return $this->colors($table, true); |
|
758
|
|
|
} |
|
759
|
|
|
|
|
760
|
|
|
/** |
|
761
|
|
|
* Write EOL count times. |
|
762
|
|
|
* @param int $count |
|
763
|
|
|
* @return $this |
|
764
|
|
|
*/ |
|
765
|
|
|
public function eol(int $count = 1): self |
|
766
|
|
|
{ |
|
767
|
|
|
return $this->doWrite(str_repeat(PHP_EOL, max($count, 1)), false); |
|
768
|
|
|
} |
|
769
|
|
|
|
|
770
|
|
|
/** |
|
771
|
|
|
* Magic call to handle dynamic color, style |
|
772
|
|
|
* @param string $method |
|
773
|
|
|
* @param array<int, mixed> $args |
|
774
|
|
|
* @return $this |
|
775
|
|
|
*/ |
|
776
|
|
|
public function __call(string $method, array $args = []) |
|
777
|
|
|
{ |
|
778
|
|
|
if (method_exists($this->cursor, $method)) { |
|
779
|
|
|
return $this->cursor->{$method}(...$args); |
|
780
|
|
|
} |
|
781
|
|
|
|
|
782
|
|
|
$this->method = $method; |
|
783
|
|
|
|
|
784
|
|
|
return $this->write(...$args); |
|
|
|
|
|
|
785
|
|
|
} |
|
786
|
|
|
|
|
787
|
|
|
/** |
|
788
|
|
|
* Write to the standard output or standard error stream. |
|
789
|
|
|
* @param string $text |
|
790
|
|
|
* @param bool $error |
|
791
|
|
|
* @return $this |
|
792
|
|
|
*/ |
|
793
|
|
|
protected function doWrite(string $text, bool $error = false): self |
|
794
|
|
|
{ |
|
795
|
|
|
$stream = $error ? |
|
796
|
|
|
$this->errorStream |
|
797
|
|
|
: $this->stream; |
|
798
|
|
|
|
|
799
|
|
|
fwrite($stream, $text); |
|
800
|
|
|
|
|
801
|
|
|
return $this; |
|
802
|
|
|
} |
|
803
|
|
|
} |
|
804
|
|
|
|