Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/BruceEckel/OnJava8-Examples
/ main
Method
main
reflection/FamilyVsExactType.java:38–41 ·
view source on GitHub ↗
(String[] args)
Source
from the content-addressed store, hash-verified
36
(x.getClass().equals(Derived.
class
)));
37
}
38
public
static
void
main(String[] args) {
39
test(
new
Base());
40
test(
new
Derived());
41
}
42
}
43
/* Output:
44
Testing x of type
class
reflection.Base
Callers
nothing calls this directly
Calls
1
test
Method · 0.95
Tested by
no test coverage detected