diff options
| author | Jack Yu <jackyu@google.com> | 2019-03-02 20:59:32 -0800 |
|---|---|---|
| committer | android-build-merger <android-build-merger@google.com> | 2019-03-02 20:59:32 -0800 |
| commit | 766f960766c16f2faab964e1c61bb4a9dbbc97c5 (patch) | |
| tree | 0cf651f62779e7db79cccdb020cfd6d4792116c0 /core/java/android/net/LinkAddress.java | |
| parent | fa0a6004ca2005464c200f015c67dbfb537d751c (diff) | |
| parent | bc6c8b99c9909c7dc15a04cdde8089b2ff285067 (diff) | |
Merge "Fixed all APIs not meeting API review requirement" am: a3f1b3f15d am: a0e1501981
am: bc6c8b99c9
Change-Id: I9683c9616e524013eda818e34d817d636ff1f365
Diffstat (limited to 'core/java/android/net/LinkAddress.java')
| -rw-r--r-- | core/java/android/net/LinkAddress.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/core/java/android/net/LinkAddress.java b/core/java/android/net/LinkAddress.java index dcf64d538411..78a4e7293947 100644 --- a/core/java/android/net/LinkAddress.java +++ b/core/java/android/net/LinkAddress.java @@ -25,6 +25,7 @@ import static android.system.OsConstants.RT_SCOPE_LINK; import static android.system.OsConstants.RT_SCOPE_SITE; import static android.system.OsConstants.RT_SCOPE_UNIVERSE; +import android.annotation.NonNull; import android.annotation.SystemApi; import android.annotation.TestApi; import android.annotation.UnsupportedAppUsage; @@ -177,7 +178,7 @@ public class LinkAddress implements Parcelable { */ @SystemApi @TestApi - public LinkAddress(InetAddress address, int prefixLength) { + public LinkAddress(@NonNull InetAddress address, int prefixLength) { this(address, prefixLength, 0, 0); this.scope = scopeForUnicastAddress(address); } @@ -196,12 +197,12 @@ public class LinkAddress implements Parcelable { /** * Constructs a new {@code LinkAddress} from a string such as "192.0.2.5/24" or * "2001:db8::1/64". The flags are set to zero and the scope is determined from the address. - * @param string The string to parse. + * @param address The string to parse. * @hide */ @SystemApi @TestApi - public LinkAddress(String address) { + public LinkAddress(@NonNull String address) { this(address, 0, 0); this.scope = scopeForUnicastAddress(this.address); } @@ -209,7 +210,7 @@ public class LinkAddress implements Parcelable { /** * Constructs a new {@code LinkAddress} from a string such as "192.0.2.5/24" or * "2001:db8::1/64", with the specified flags and scope. - * @param string The string to parse. + * @param address The string to parse. * @param flags The address flags. * @param scope The address scope. * @hide |
