4 * An actor, either a committer or an author.
18 public function __construct($name, $email = null) {
20 $this->email
= $email;
22 public function __toString() {
27 * Parses a string from John Doe <jdoe@example.com> to this object.
29 public static function fromString($string) {
30 if (preg_match('/(.*) <(.+?)>/', $string, $matches)) {
31 list($x, $name, $email) = $matches;
32 return new Git_Actor($name, $email);
34 return new Git_Actor($string);