-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAnnotation.hh
46 lines (39 loc) · 939 Bytes
/
Annotation.hh
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
<?hh // strict
/**
* @copyright 2010-2015, The Titon Project
* @license http://opensource.org/licenses/bsd-license.php
* @link http://titon.io
*/
namespace Titon\Annotation;
/**
* The Annotation class represents either a class or method annotation (attribute in Hack terms)
* in object form. Custom annotation classes encapsulate metadata through constructor arguments.
*
* @package Titon\Annotation
*/
class Annotation {
/**
* The unique annotation name.
*
* @var string
*/
protected string $name = '';
/**
* Return the annotation name.
*
* @return string
*/
final public function getName(): string {
return $this->name;
}
/**
* Set the annotation name.
*
* @param string $name
* @return $this
*/
final public function setName(string $name): this {
$this->name = $name;
return $this;
}
}