| 1 | <?php |
||
| 16 | abstract class EntityId implements Comparable, Serializable { |
||
| 17 | |||
| 18 | protected $serialization; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * @return string |
||
| 22 | */ |
||
| 23 | public abstract function getEntityType(); |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @return string |
||
| 27 | */ |
||
| 28 | 31 | public function getSerialization() { |
|
| 31 | |||
| 32 | /** |
||
| 33 | * This is a human readable representation of the EntityId. |
||
| 34 | * This format is allowed to change and should therefore not |
||
| 35 | * be relied upon to be stable. |
||
| 36 | * |
||
| 37 | * @return string |
||
| 38 | */ |
||
| 39 | 5 | public function __toString() { |
|
| 42 | |||
| 43 | /** |
||
| 44 | * @see Comparable::equals |
||
| 45 | * |
||
| 46 | * @since 0.5 |
||
| 47 | * |
||
| 48 | * @param mixed $target |
||
| 49 | * |
||
| 50 | * @return bool |
||
| 51 | */ |
||
| 52 | 5 | public function equals( $target ) { |
|
| 60 | |||
| 61 | } |
||
| 62 |