File tree Expand file tree Collapse file tree 4 files changed +123
-3
lines changed Expand file tree Collapse file tree 4 files changed +123
-3
lines changed Original file line number Diff line number Diff line change @@ -333,6 +333,36 @@ public function addTrait($trait)
333
333
}
334
334
335
335
336
+ /**
337
+ * @param string|NULL
338
+ * @return self
339
+ */
340
+ public function setComment ($ val )
341
+ {
342
+ $ this ->documents = $ val ? array ((string ) $ val ) : array ();
343
+ return $ this ;
344
+ }
345
+
346
+
347
+ /**
348
+ * @return string|NULL
349
+ */
350
+ public function getComment ()
351
+ {
352
+ return implode ($ this ->documents ) ?: NULL ;
353
+ }
354
+
355
+
356
+ /**
357
+ * @param string
358
+ * @return self
359
+ */
360
+ public function addComment ($ val )
361
+ {
362
+ return $ this ->addDocument ($ val );
363
+ }
364
+
365
+
336
366
/**
337
367
* @param string[]
338
368
* @return self
Original file line number Diff line number Diff line change @@ -374,6 +374,36 @@ public function isVariadic()
374
374
}
375
375
376
376
377
+ /**
378
+ * @param string|NULL
379
+ * @return self
380
+ */
381
+ public function setComment ($ val )
382
+ {
383
+ $ this ->documents = $ val ? array ((string ) $ val ) : array ();
384
+ return $ this ;
385
+ }
386
+
387
+
388
+ /**
389
+ * @return string|NULL
390
+ */
391
+ public function getComment ()
392
+ {
393
+ return implode ($ this ->documents ) ?: NULL ;
394
+ }
395
+
396
+
397
+ /**
398
+ * @param string
399
+ * @return self
400
+ */
401
+ public function addComment ($ val )
402
+ {
403
+ return $ this ->addDocument ($ val );
404
+ }
405
+
406
+
377
407
/**
378
408
* @param string[]
379
409
* @return self
Original file line number Diff line number Diff line change @@ -29,11 +29,32 @@ class PhpFile extends Object
29
29
30
30
31
31
/**
32
- * @return string[]
32
+ * @param string|NULL
33
+ * @return self
33
34
*/
34
- public function getDocuments ( )
35
+ public function setComment ( $ val )
35
36
{
36
- return $ this ->documents ;
37
+ $ this ->documents = $ val ? array ((string ) $ val ) : array ();
38
+ return $ this ;
39
+ }
40
+
41
+
42
+ /**
43
+ * @return string|NULL
44
+ */
45
+ public function getComment ()
46
+ {
47
+ return implode ($ this ->documents ) ?: NULL ;
48
+ }
49
+
50
+
51
+ /**
52
+ * @param string
53
+ * @return self
54
+ */
55
+ public function addComment ($ val )
56
+ {
57
+ return $ this ->addDocument ($ val );
37
58
}
38
59
39
60
@@ -48,6 +69,15 @@ public function setDocuments(array $documents)
48
69
}
49
70
50
71
72
+ /**
73
+ * @return string[]
74
+ */
75
+ public function getDocuments ()
76
+ {
77
+ return $ this ->documents ;
78
+ }
79
+
80
+
51
81
/**
52
82
* @param string
53
83
* @return self
Original file line number Diff line number Diff line change @@ -137,6 +137,36 @@ public function getVisibility()
137
137
}
138
138
139
139
140
+ /**
141
+ * @param string|NULL
142
+ * @return self
143
+ */
144
+ public function setComment ($ val )
145
+ {
146
+ $ this ->documents = $ val ? array ((string ) $ val ) : array ();
147
+ return $ this ;
148
+ }
149
+
150
+
151
+ /**
152
+ * @return string|NULL
153
+ */
154
+ public function getComment ()
155
+ {
156
+ return implode ($ this ->documents ) ?: NULL ;
157
+ }
158
+
159
+
160
+ /**
161
+ * @param string
162
+ * @return self
163
+ */
164
+ public function addComment ($ val )
165
+ {
166
+ return $ this ->addDocument ($ val );
167
+ }
168
+
169
+
140
170
/**
141
171
* @param string[]
142
172
* @return self
You can’t perform that action at this time.
0 commit comments