Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove deprecated lang.Generic::getClassName() #120

Merged
merged 1 commit into from
Jan 23, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions src/main/php/lang/Generic.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,6 @@ public function hashCode();
* @return bool TRUE if the compared object is equal to this object
*/
public function equals($cmp);

/**
* Returns the fully qualified class name for this class
* (e.g. "io.File")
*
* @deprecated Use nameof($this) instead.
* @return string fully qualified class name
*/
public function getClassName();

/**
* Returns the runtime class of an object.
Expand Down
11 changes: 0 additions & 11 deletions src/main/php/lang/Object.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,17 +39,6 @@ public function equals($cmp) {
return $this === $cmp;
}

/**
* Returns the fully qualified class name for this class
* (e.g. "io.File")
*
* @deprecated Use nameof($this) instead.
* @return string fully qualified class name
*/
public function getClassName() {
return nameof($this);
}

/**
* Returns the runtime class of an object.
*
Expand Down
11 changes: 0 additions & 11 deletions src/main/php/lang/Throwable.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -261,17 +261,6 @@ public function equals($cmp) {
return $this === $cmp;
}

/**
* Returns the fully qualified class name for this class
* (e.g. "io.File")
*
* @deprecated Use nameof($this) instead.
* @return string fully qualified class name
*/
public function getClassName() {
return nameof($this);
}

/**
* Returns the runtime class of an object.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,12 +113,6 @@ public function classMethod() {
$this->assertEquals(XPClass::forName('lang.Throwable'), (new Throwable('Test'))->getClass());
}

/** @deprecated */
#[@test]
public function classNameMethod() {
$this->assertEquals('lang.Throwable', (new Throwable('Test'))->getClassName());
}

#[@test]
public function compoundMessage() {
$this->assertEquals(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,6 @@ public function an_object_is_not_equal_to_a_primitive() {
$this->assertFalse((new Object())->equals(0));
}

/** @deprecated */
#[@test]
public function getClassName_returns_fully_qualified_class_name() {
$this->assertEquals('lang.Object', (new Object())->getClassName());
}

#[@test]
public function getClass_returns_XPClass_object() {
$this->assertEquals(XPClass::forName('lang.Object'), (new Object())->getClass());
Expand Down
29 changes: 0 additions & 29 deletions src/test/php/net/xp_framework/unittest/core/ThisTest.class.php

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,6 @@ public function nameof() {
);
}

/** @deprecated */
#[@test]
public function getClassNameMethod() {
$this->assertEquals(
'net.xp_framework.unittest.core.generics.Lookup<string,unittest.TestCase>',
$this->fixture->getClassName()
);
}

#[@test]
public function nameOfClass() {
$this->assertEquals(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,9 @@ public function allInterfacesAreImplemented() {
#[@test]
public function iteratorMethods() {
$expected= [
'hashcode', 'equals', 'getclassname', 'getclass', 'tostring', // lang.Object
'getproxyclass', 'newproxyinstance', // lang.reflect.Proxy
'hasnext', 'next' // util.XPIterator
'hashcode', 'equals', 'getclass', 'tostring', // lang.Object
'getproxyclass', 'newproxyinstance', // lang.reflect.Proxy
'hasnext', 'next' // util.XPIterator
];

$class= $this->proxyClassFor([$this->iteratorClass]);
Expand Down