forked from eloquent/composer-config-reader
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathAuthor.php
More file actions
88 lines (80 loc) · 1.75 KB
/
Author.php
File metadata and controls
88 lines (80 loc) · 1.75 KB
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
<?php
namespace Eloquent\Composer\Configuration\Element;
/**
* Represents an author.
*/
class Author
{
/**
* Construct a new author.
*
* @param string $name The author's name.
* @param string|null $email The author's email address.
* @param string|null $homepage The URI of the author's home page.
* @param string|null $role The author's role.
* @param mixed $rawData The raw data describing the author.
*/
public function __construct(
$name,
$email = null,
$homepage = null,
$role = null,
$rawData = null
) {
$this->name = $name;
$this->email = $email;
$this->homepage = $homepage;
$this->role = $role;
$this->rawData = $rawData;
}
/**
* Get the author's name.
*
* @return string The author's name.
*/
public function name()
{
return $this->name;
}
/**
* Get the author's email address.
*
* @return string|null The author's email address.
*/
public function email()
{
return $this->email;
}
/**
* Get the URI of the author's home page.
*
* @return string|null The URI of the author's home page.
*/
public function homepage()
{
return $this->homepage;
}
/**
* Get the author's role.
*
* @return string|null The author's role.
*/
public function role()
{
return $this->role;
}
/**
* Get the raw author data.
*
* @return mixed The raw author data.
*/
public function rawData()
{
return $this->rawData;
}
private $name;
private $email;
private $homepage;
private $role;
private $rawData;
}