All Parcelable CREATOR fields are @NonNull.
If they were null, then the Parcelable would fail to work. Bug: 126726802 Test: manual Change-Id: I7929ffa2f20e5de1c8e68e8263cca99496e9d014 Exempt-From-Owner-Approval: Trivial API annotations
This commit is contained in:
@@ -61,7 +61,7 @@ public class CaptivePortal implements Parcelable {
|
||||
out.writeStrongBinder(mBinder);
|
||||
}
|
||||
|
||||
public static final Parcelable.Creator<CaptivePortal> CREATOR
|
||||
public static final @android.annotation.NonNull Parcelable.Creator<CaptivePortal> CREATOR
|
||||
= new Parcelable.Creator<CaptivePortal>() {
|
||||
@Override
|
||||
public CaptivePortal createFromParcel(Parcel in) {
|
||||
|
||||
@@ -54,7 +54,7 @@ public final class ConnectionInfo implements Parcelable {
|
||||
out.writeInt(remote.getPort());
|
||||
}
|
||||
|
||||
public static final Creator<ConnectionInfo> CREATOR = new Creator<ConnectionInfo>() {
|
||||
public static final @android.annotation.NonNull Creator<ConnectionInfo> CREATOR = new Creator<ConnectionInfo>() {
|
||||
public ConnectionInfo createFromParcel(Parcel in) {
|
||||
int protocol = in.readInt();
|
||||
InetAddress localAddress;
|
||||
|
||||
@@ -84,7 +84,7 @@ public class DhcpInfo implements Parcelable {
|
||||
}
|
||||
|
||||
/** Implement the Parcelable interface {@hide} */
|
||||
public static final Creator<DhcpInfo> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<DhcpInfo> CREATOR =
|
||||
new Creator<DhcpInfo>() {
|
||||
public DhcpInfo createFromParcel(Parcel in) {
|
||||
DhcpInfo info = new DhcpInfo();
|
||||
|
||||
@@ -189,7 +189,7 @@ public class IpConfiguration implements Parcelable {
|
||||
}
|
||||
|
||||
/** Implement the Parcelable interface */
|
||||
public static final Creator<IpConfiguration> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<IpConfiguration> CREATOR =
|
||||
new Creator<IpConfiguration>() {
|
||||
public IpConfiguration createFromParcel(Parcel in) {
|
||||
IpConfiguration config = new IpConfiguration();
|
||||
|
||||
@@ -285,7 +285,7 @@ public final class IpPrefix implements Parcelable {
|
||||
/**
|
||||
* Implement the Parcelable interface.
|
||||
*/
|
||||
public static final Creator<IpPrefix> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<IpPrefix> CREATOR =
|
||||
new Creator<IpPrefix>() {
|
||||
public IpPrefix createFromParcel(Parcel in) {
|
||||
byte[] address = in.createByteArray();
|
||||
|
||||
@@ -105,7 +105,7 @@ public class KeepalivePacketData implements Parcelable {
|
||||
}
|
||||
|
||||
/** Parcelable Creator */
|
||||
public static final Parcelable.Creator<KeepalivePacketData> CREATOR =
|
||||
public static final @android.annotation.NonNull Parcelable.Creator<KeepalivePacketData> CREATOR =
|
||||
new Parcelable.Creator<KeepalivePacketData>() {
|
||||
public KeepalivePacketData createFromParcel(Parcel in) {
|
||||
return new KeepalivePacketData(in);
|
||||
|
||||
@@ -356,7 +356,7 @@ public class LinkAddress implements Parcelable {
|
||||
/**
|
||||
* Implement the Parcelable interface.
|
||||
*/
|
||||
public static final Creator<LinkAddress> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<LinkAddress> CREATOR =
|
||||
new Creator<LinkAddress>() {
|
||||
public LinkAddress createFromParcel(Parcel in) {
|
||||
InetAddress address = null;
|
||||
|
||||
@@ -1574,7 +1574,7 @@ public final class LinkProperties implements Parcelable {
|
||||
/**
|
||||
* Implement the Parcelable interface.
|
||||
*/
|
||||
public static final Creator<LinkProperties> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<LinkProperties> CREATOR =
|
||||
new Creator<LinkProperties>() {
|
||||
public LinkProperties createFromParcel(Parcel in) {
|
||||
LinkProperties netProp = new LinkProperties();
|
||||
|
||||
@@ -167,7 +167,7 @@ public final class MacAddress implements Parcelable {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public static final Parcelable.Creator<MacAddress> CREATOR =
|
||||
public static final @android.annotation.NonNull Parcelable.Creator<MacAddress> CREATOR =
|
||||
new Parcelable.Creator<MacAddress>() {
|
||||
public MacAddress createFromParcel(Parcel in) {
|
||||
return new MacAddress(in.readLong());
|
||||
|
||||
@@ -470,7 +470,7 @@ public class Network implements Parcelable {
|
||||
dest.writeInt(netId);
|
||||
}
|
||||
|
||||
public static final Creator<Network> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<Network> CREATOR =
|
||||
new Creator<Network>() {
|
||||
public Network createFromParcel(Parcel in) {
|
||||
int netId = in.readInt();
|
||||
|
||||
@@ -1442,7 +1442,7 @@ public final class NetworkCapabilities implements Parcelable {
|
||||
dest.writeString(mSSID);
|
||||
}
|
||||
|
||||
public static final Creator<NetworkCapabilities> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<NetworkCapabilities> CREATOR =
|
||||
new Creator<NetworkCapabilities>() {
|
||||
@Override
|
||||
public NetworkCapabilities createFromParcel(Parcel in) {
|
||||
|
||||
@@ -557,7 +557,7 @@ public class NetworkInfo implements Parcelable {
|
||||
}
|
||||
}
|
||||
|
||||
public static final Creator<NetworkInfo> CREATOR = new Creator<NetworkInfo>() {
|
||||
public static final @android.annotation.NonNull Creator<NetworkInfo> CREATOR = new Creator<NetworkInfo>() {
|
||||
@Override
|
||||
public NetworkInfo createFromParcel(Parcel in) {
|
||||
int netType = in.readInt();
|
||||
|
||||
@@ -100,7 +100,7 @@ public class NetworkMisc implements Parcelable {
|
||||
out.writeInt(skip464xlat ? 1 : 0);
|
||||
}
|
||||
|
||||
public static final Creator<NetworkMisc> CREATOR = new Creator<NetworkMisc>() {
|
||||
public static final @android.annotation.NonNull Creator<NetworkMisc> CREATOR = new Creator<NetworkMisc>() {
|
||||
@Override
|
||||
public NetworkMisc createFromParcel(Parcel in) {
|
||||
NetworkMisc networkMisc = new NetworkMisc();
|
||||
|
||||
@@ -363,7 +363,7 @@ public class NetworkRequest implements Parcelable {
|
||||
dest.writeInt(requestId);
|
||||
dest.writeString(type.name());
|
||||
}
|
||||
public static final Creator<NetworkRequest> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<NetworkRequest> CREATOR =
|
||||
new Creator<NetworkRequest>() {
|
||||
public NetworkRequest createFromParcel(Parcel in) {
|
||||
NetworkCapabilities nc = NetworkCapabilities.CREATOR.createFromParcel(in);
|
||||
|
||||
@@ -87,7 +87,7 @@ public class NetworkState implements Parcelable {
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public static final Creator<NetworkState> CREATOR = new Creator<NetworkState>() {
|
||||
public static final @android.annotation.NonNull Creator<NetworkState> CREATOR = new Creator<NetworkState>() {
|
||||
@Override
|
||||
public NetworkState createFromParcel(Parcel in) {
|
||||
return new NetworkState(in);
|
||||
|
||||
@@ -342,7 +342,7 @@ public class ProxyInfo implements Parcelable {
|
||||
dest.writeStringArray(mParsedExclusionList);
|
||||
}
|
||||
|
||||
public static final Creator<ProxyInfo> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<ProxyInfo> CREATOR =
|
||||
new Creator<ProxyInfo>() {
|
||||
public ProxyInfo createFromParcel(Parcel in) {
|
||||
String host = null;
|
||||
|
||||
@@ -486,7 +486,7 @@ public final class RouteInfo implements Parcelable {
|
||||
/**
|
||||
* Implement the Parcelable interface.
|
||||
*/
|
||||
public static final Creator<RouteInfo> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<RouteInfo> CREATOR =
|
||||
new Creator<RouteInfo>() {
|
||||
public RouteInfo createFromParcel(Parcel in) {
|
||||
IpPrefix dest = in.readParcelable(null);
|
||||
|
||||
@@ -212,7 +212,7 @@ public final class StaticIpConfiguration implements Parcelable {
|
||||
}
|
||||
|
||||
/** Implement the Parcelable interface */
|
||||
public static final Creator<StaticIpConfiguration> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<StaticIpConfiguration> CREATOR =
|
||||
new Creator<StaticIpConfiguration>() {
|
||||
public StaticIpConfiguration createFromParcel(Parcel in) {
|
||||
return readFromParcel(in);
|
||||
|
||||
@@ -194,7 +194,7 @@ public class TcpKeepalivePacketData extends KeepalivePacketData implements Parce
|
||||
}
|
||||
|
||||
/** Parcelable Creator. */
|
||||
public static final Parcelable.Creator<TcpKeepalivePacketData> CREATOR =
|
||||
public static final @android.annotation.NonNull Parcelable.Creator<TcpKeepalivePacketData> CREATOR =
|
||||
new Parcelable.Creator<TcpKeepalivePacketData>() {
|
||||
public TcpKeepalivePacketData createFromParcel(Parcel in) {
|
||||
return new TcpKeepalivePacketData(in);
|
||||
|
||||
@@ -91,7 +91,7 @@ public final class UidRange extends UidRangeParcel {
|
||||
* The parceling code is autogenerated by the superclass.
|
||||
*/
|
||||
|
||||
public static final Creator<UidRange> CREATOR =
|
||||
public static final @android.annotation.NonNull Creator<UidRange> CREATOR =
|
||||
new Creator<UidRange>() {
|
||||
@Override
|
||||
public UidRange createFromParcel(Parcel in) {
|
||||
|
||||
Reference in New Issue
Block a user