[MediaWiki-commits] [Gerrit] Deprecated and removed some getPrefixedId usage in the DataM... - change (mediawiki...Wikibase)

2013-05-22 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Deprecated and removed some getPrefixedId usage in the 
DataModel component
..


Deprecated and removed some getPrefixedId usage in the DataModel component

Change-Id: Id80f31c8841c332d35dbf467cff1c739e0008613
---
M DataModel/DataModel/Entity/Entity.php
M DataModel/DataModel/Entity/EntityId.php
M DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
3 files changed, 7 insertions(+), 2 deletions(-)

Approvals:
  Daniel Kinzler: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/DataModel/DataModel/Entity/Entity.php 
b/DataModel/DataModel/Entity/Entity.php
index bf1ee16..0cba035 100644
--- a/DataModel/DataModel/Entity/Entity.php
+++ b/DataModel/DataModel/Entity/Entity.php
@@ -179,6 +179,7 @@
 * Returns a prefixed version of the entity's id or null if it is not 
in the datastore yet.
 *
 * @since 0.2
+* @deprecated since 0.4
 *
 * @return string|null
 */
@@ -897,6 +898,7 @@
 * Parses the claim GUID and returns the prefixed entity ID it contains.
 *
 * @since 0.3
+* @deprecated since 0.4
 *
 * @param string $claimKey
 *
diff --git a/DataModel/DataModel/Entity/EntityId.php 
b/DataModel/DataModel/Entity/EntityId.php
index d7f4a46..e51b855 100644
--- a/DataModel/DataModel/Entity/EntityId.php
+++ b/DataModel/DataModel/Entity/EntityId.php
@@ -187,7 +187,10 @@
}
 
/**
-* Return a string representation of this entity id. Equal to 
getPrefixedId().
+* Return a string representation of this entity id.
+*
+* Note: this was previously documented to be equal to the now 
deprecated getPrefixedId
+* This will stop being the case when getPrefixedId gets removed, so 
should not be relied upon.
 *
 * @since 0.3
 *
diff --git a/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php 
b/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
index f5ae894..b82d3ac 100644
--- a/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
+++ b/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
@@ -109,7 +109,7 @@
 
$this->assertInstanceOf( '\Wikibase\PropertyValueSnak', 
$instance );
$this->assertTrue( $instance->getDataValue()->equals( 
$dataValue ) );
-   $this->assertEquals( $property->getPrefixedId(), 
$instance->getPropertyId()->getPrefixedId() );
+   $this->assertEquals( $property->getId(), 
$instance->getPropertyId() );
}
 
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/64490
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id80f31c8841c332d35dbf467cff1c739e0008613
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Jeroen De Dauw 
Gerrit-Reviewer: Anja Jentzsch 
Gerrit-Reviewer: Ataherivand 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: Daniel Kinzler 
Gerrit-Reviewer: Daniel Werner 
Gerrit-Reviewer: Denny Vrandecic 
Gerrit-Reviewer: Henning Snater 
Gerrit-Reviewer: Jens Ohlig 
Gerrit-Reviewer: Jeroen De Dauw 
Gerrit-Reviewer: John Erling Blad 
Gerrit-Reviewer: Lydia Pintscher 
Gerrit-Reviewer: Markus Kroetzsch 
Gerrit-Reviewer: Nikola Smolenski 
Gerrit-Reviewer: Silke Meyer 
Gerrit-Reviewer: Tobias Gritschacher 
Gerrit-Reviewer: jenkins-bot

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Deprecated and removed some getPrefixedId usage in the DataM... - change (mediawiki...Wikibase)

2013-05-18 Thread Jeroen De Dauw (Code Review)
Jeroen De Dauw has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/64490


Change subject: Deprecated and removed some getPrefixedId usage in the 
DataModel component
..

Deprecated and removed some getPrefixedId usage in the DataModel component

Change-Id: Id80f31c8841c332d35dbf467cff1c739e0008613
---
M DataModel/DataModel/Entity/Entity.php
M DataModel/DataModel/Entity/EntityId.php
M DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
3 files changed, 5 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/90/64490/1

diff --git a/DataModel/DataModel/Entity/Entity.php 
b/DataModel/DataModel/Entity/Entity.php
index bf1ee16..0cba035 100644
--- a/DataModel/DataModel/Entity/Entity.php
+++ b/DataModel/DataModel/Entity/Entity.php
@@ -179,6 +179,7 @@
 * Returns a prefixed version of the entity's id or null if it is not 
in the datastore yet.
 *
 * @since 0.2
+* @deprecated since 0.4
 *
 * @return string|null
 */
@@ -897,6 +898,7 @@
 * Parses the claim GUID and returns the prefixed entity ID it contains.
 *
 * @since 0.3
+* @deprecated since 0.4
 *
 * @param string $claimKey
 *
diff --git a/DataModel/DataModel/Entity/EntityId.php 
b/DataModel/DataModel/Entity/EntityId.php
index d7f4a46..3e43fda 100644
--- a/DataModel/DataModel/Entity/EntityId.php
+++ b/DataModel/DataModel/Entity/EntityId.php
@@ -187,7 +187,8 @@
}
 
/**
-* Return a string representation of this entity id. Equal to 
getPrefixedId().
+* Return a string representation of this entity id.
+* Note: this will not change equal to the deprecated getPrefixedId
 *
 * @since 0.3
 *
diff --git a/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php 
b/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
index f5ae894..b82d3ac 100644
--- a/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
+++ b/DataModel/tests/phpunit/Snak/PropertyValueSnakTest.php
@@ -109,7 +109,7 @@
 
$this->assertInstanceOf( '\Wikibase\PropertyValueSnak', 
$instance );
$this->assertTrue( $instance->getDataValue()->equals( 
$dataValue ) );
-   $this->assertEquals( $property->getPrefixedId(), 
$instance->getPropertyId()->getPrefixedId() );
+   $this->assertEquals( $property->getId(), 
$instance->getPropertyId() );
}
 
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/64490
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id80f31c8841c332d35dbf467cff1c739e0008613
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Jeroen De Dauw 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits