blob: 631fdd20f83e6f241e02adfe71e7ffea8e8079d1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
  | 
<?php
namespace App\Message;
use App\Message\Base;
/**
 * Name message
 *
 * @author Phil Burton <phil@pgburton.com>
 */
class Name extends Base
{
    /**
     * The list of vars we need to inject
     *
     * @var array
     */
    protected $injects = ['inject', 'second'];
    /**
     * The array of important vars
     *
     * @var string
     */
    protected $important = ['inject'];
    /**
     * Inject
     * @var string
     */
    public $inject;
    /**
     * Second inject
     *
     * @var string
     */
    public $second = "second";
    /**
     * Construct to set any inject vars from functions if required
     *
     * @author Phil Burton <phil@pgburton.com>
     */
    public function __construct(Handler $handler)
    {
        $this->inject = $this->getInject();
        parent::__construct($handler);
    }
    /**
     * Get our inject value
     *
     * @author Phil Burton <phil@pgburton.com>
     * @return string
     */
    public function getInject()
    {
        return (string) time();
    }
}
 
  |