diff options
-rw-r--r-- | core/java/android/net/MatchAllNetworkSpecifier.java | 3 | ||||
-rw-r--r-- | tests/net/common/java/android/net/MatchAllNetworkSpecifierTest.kt | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/core/java/android/net/MatchAllNetworkSpecifier.java b/core/java/android/net/MatchAllNetworkSpecifier.java index 68a39355198b..70c4a7235b9d 100644 --- a/core/java/android/net/MatchAllNetworkSpecifier.java +++ b/core/java/android/net/MatchAllNetworkSpecifier.java @@ -43,7 +43,8 @@ public final class MatchAllNetworkSpecifier extends NetworkSpecifier implements } /** @hide */ - public boolean satisfiedBy(NetworkSpecifier other) { + @Override + public boolean canBeSatisfiedBy(NetworkSpecifier other) { /* * The method is called by a NetworkRequest to see if it is satisfied by a proposed * network (e.g. as offered by a network factory). Since MatchAllNetweorkSpecifier must diff --git a/tests/net/common/java/android/net/MatchAllNetworkSpecifierTest.kt b/tests/net/common/java/android/net/MatchAllNetworkSpecifierTest.kt index ef15b668e24c..a50f0461fae6 100644 --- a/tests/net/common/java/android/net/MatchAllNetworkSpecifierTest.kt +++ b/tests/net/common/java/android/net/MatchAllNetworkSpecifierTest.kt @@ -39,12 +39,12 @@ class MatchAllNetworkSpecifierTest { } @Test(expected = IllegalStateException::class) - fun testSatisfiedBy() { + fun testCanBeSatisfiedBy() { val specifier = MatchAllNetworkSpecifier() val discoverySession = Mockito.mock(DiscoverySession::class.java) val peerHandle = Mockito.mock(PeerHandle::class.java) val wifiAwareNetworkSpecifier = WifiAwareNetworkSpecifier.Builder(discoverySession, peerHandle).build() - specifier.satisfiedBy(wifiAwareNetworkSpecifier) + specifier.canBeSatisfiedBy(wifiAwareNetworkSpecifier) } } |