Skip to content

Commit 7dddf9e

Browse files
committed
Merge pull request #624 from wmde/sinceDocument5
Add missing since tag to EntityDocument
2 parents e08b850 + 187adca commit 7dddf9e

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

src/Entity/EntityDocument.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
use InvalidArgumentException;
77

88
/**
9-
* Minimal interface for all objects that represent an entity.
10-
* All entities have an EntityId and an entity type.
9+
* Minimal interface for all objects that represent an entity. All entities have an entity type and
10+
* an EntityId.
1111
*
1212
* @since 0.8.2
1313
*
@@ -18,22 +18,22 @@
1818
interface EntityDocument extends Comparable {
1919

2020
/**
21-
* Returns the id of the entity or null if it does not have one.
21+
* Returns a type identifier for the entity, e.g. "item" or "property".
2222
*
2323
* @since 0.8.2
2424
*
25-
* @return EntityId|null
25+
* @return string
2626
*/
27-
public function getId();
27+
public function getType();
2828

2929
/**
30-
* Returns a type identifier for the entity, e.g. "item" or "property".
30+
* Returns the id of the entity or null if it does not have one.
3131
*
3232
* @since 0.8.2
3333
*
34-
* @return string
34+
* @return EntityId|null
3535
*/
36-
public function getType();
36+
public function getId();
3737

3838
/**
3939
* Sets the id of the entity. A specific derivative of EntityId is always supported.
@@ -45,8 +45,7 @@ public function getType();
4545
public function setId( $id );
4646

4747
/**
48-
* Returns true if the entity has no content.
49-
* Having an id set does not count as having content.
48+
* Returns true if the entity has no content. Having an id set does not count as having content.
5049
*
5150
* @since 4.3
5251
*
@@ -57,10 +56,11 @@ public function isEmpty();
5756
/**
5857
* @see Comparable::equals
5958
*
60-
* Two entities are considered equal if they are of the same
61-
* type and have the same value. The value does not include
62-
* the id, so entities with the same value but different id
63-
* are considered equal.
59+
* Two entities are considered equal if they are of the same type and have the same value. The
60+
* value does not include the id, so entities with the same value but different id are
61+
* considered equal.
62+
*
63+
* @since 5.0
6464
*
6565
* @param mixed $target
6666
*

0 commit comments

Comments
 (0)