Skip to content

Commit

Permalink
Merge pull request #135 from wmde/versionfix
Browse files Browse the repository at this point in the history
Add missing release notes and @SInCE tags
  • Loading branch information
thiemowmde committed Jun 8, 2015
2 parents 543f414 + 6e58609 commit 84b2eac
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 18 deletions.
2 changes: 2 additions & 0 deletions RELEASE-NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
* Renamed `SerializerFactory::newSnaksSerializer` to `SerializerFactory::newSnakListSerializer`, leaving a b/c alias
* Renamed `DeserializerFactory::newClaimDeserializer` to `DeserializerFactory::newStatementDeserializer`, leaving a b/c alias
* Renamed `DeserializerFactory::newSnaksDeserializer` to `DeserializerFactory::newSnakListDeserializer`, leaving a b/c alias
* Added `SerializerFactory::newStatementListSerializer`
* Added `DeserializerFactory::newStatementListDeserializer`

## 1.3.0 (2015-01-28)

Expand Down
19 changes: 8 additions & 11 deletions src/DeserializerFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,10 @@ public function __construct( Deserializer $dataValueDeserializer, EntityIdParser
* @return DispatchableDeserializer
*/
public function newEntityDeserializer() {
$fingerprintDeserializer = new FingerprintDeserializer();
return new DispatchingDeserializer( array(
new ItemDeserializer( $this->newEntityIdDeserializer(), $this->newFingerprintDeserializer(), $this->newStatementListDeserializer(), $this->newSiteLinkDeserializer() ),
new PropertyDeserializer( $this->newEntityIdDeserializer(), $this->newFingerprintDeserializer(), $this->newStatementListDeserializer() )
new ItemDeserializer( $this->newEntityIdDeserializer(), $fingerprintDeserializer, $this->newStatementListDeserializer(), $this->newSiteLinkDeserializer() ),
new PropertyDeserializer( $this->newEntityIdDeserializer(), $fingerprintDeserializer, $this->newStatementListDeserializer() )
) );
}

Expand All @@ -81,6 +82,8 @@ public function newClaimsDeserializer() {
/**
* Returns a Deserializer that can deserialize StatementList objects.
*
* @since 1.4
*
* @return Deserializer
*/
public function newStatementListDeserializer() {
Expand Down Expand Up @@ -134,6 +137,8 @@ public function newReferenceDeserializer() {
/**
* Returns a Deserializer that can deserialize SnakList objects.
*
* @since 1.4
*
* @return Deserializer
*/
public function newSnakListDeserializer() {
Expand All @@ -144,6 +149,7 @@ public function newSnakListDeserializer() {
* b/c alias for newSnakListDeserializer
*
* @deprecated since 1.4 - use newSnakListDeserializer instead
*
* @return Deserializer
*/
public function newSnaksDeserializer() {
Expand All @@ -168,13 +174,4 @@ public function newEntityIdDeserializer() {
return new EntityIdDeserializer( $this->entityIdParser );
}

/**
* Returns a Deserializer that can deserialize Fingerprint objects.
*
* @return Deserializer
*/
public function newFingerprintDeserializer() {
return new FingerprintDeserializer();
}

}
5 changes: 5 additions & 0 deletions src/SerializerFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@ public function newClaimsSerializer() {
/**
* Returns a Serializer that can serialize StatementList objects.
*
* @since 1.4
*
* @return Serializer
*/
public function newStatementListSerializer() {
Expand Down Expand Up @@ -146,6 +148,8 @@ public function newReferenceSerializer() {
/**
* Returns a Serializer that can serialize SnakList objects.
*
* @since 1.4
*
* @return Serializer
*/
public function newSnakListSerializer() {
Expand All @@ -156,6 +160,7 @@ public function newSnakListSerializer() {
* b/c alias for newSnakListSerializer
*
* @deprecated since 1.4 - use newSnakListSerializer instead
*
* @return Serializer
*/
public function newSnaksSerializer() {
Expand Down
7 changes: 0 additions & 7 deletions tests/unit/DeserializerFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,4 @@ public function testNewEntityIdDeserializer() {
);
}

public function testNewFingerprintDeserializer() {
$this->assertDeserializesWithoutException(
$this->buildDeserializerFactory()->newFingerprintDeserializer(),
array()
);
}

}

0 comments on commit 84b2eac

Please sign in to comment.