Loading apishim/33/com/android/networkstack/apishim/EthernetManagerShimImpl.java +7 −0 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,7 @@ import androidx.annotation.RequiresApi; import com.android.networkstack.apishim.common.EthernetManagerShim; import com.android.networkstack.apishim.common.EthernetManagerShim; import java.util.List; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.Executor; import java.util.concurrent.Executor; Loading Loading @@ -95,4 +96,10 @@ public class EthernetManagerShimImpl public void setIncludeTestInterfaces(boolean include) { public void setIncludeTestInterfaces(boolean include) { mEm.setIncludeTestInterfaces(include); mEm.setIncludeTestInterfaces(include); } } @Override @NonNull public List<String> getInterfaceList() { return mEm.getInterfaceList(); } } } apishim/common/com/android/networkstack/apishim/common/EthernetManagerShim.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -21,7 +21,7 @@ import android.net.IpConfiguration; import androidx.annotation.NonNull; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.annotation.Nullable; import java.util.List; import java.util.concurrent.Executor; import java.util.concurrent.Executor; /** API shim for EthernetManager */ /** API shim for EthernetManager */ Loading Loading @@ -55,4 +55,9 @@ public interface EthernetManagerShim { default void setIncludeTestInterfaces(boolean include) throws UnsupportedApiLevelException { default void setIncludeTestInterfaces(boolean include) throws UnsupportedApiLevelException { throw new UnsupportedApiLevelException("Not supported until API 30"); throw new UnsupportedApiLevelException("Not supported until API 30"); } } /** Shim for EthernetManager#getInterfaceList */ default List<String> getInterfaceList() throws UnsupportedApiLevelException { throw new UnsupportedApiLevelException("Not supported until API 33"); } } } Loading
apishim/33/com/android/networkstack/apishim/EthernetManagerShimImpl.java +7 −0 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,7 @@ import androidx.annotation.RequiresApi; import com.android.networkstack.apishim.common.EthernetManagerShim; import com.android.networkstack.apishim.common.EthernetManagerShim; import java.util.List; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.Executor; import java.util.concurrent.Executor; Loading Loading @@ -95,4 +96,10 @@ public class EthernetManagerShimImpl public void setIncludeTestInterfaces(boolean include) { public void setIncludeTestInterfaces(boolean include) { mEm.setIncludeTestInterfaces(include); mEm.setIncludeTestInterfaces(include); } } @Override @NonNull public List<String> getInterfaceList() { return mEm.getInterfaceList(); } } }
apishim/common/com/android/networkstack/apishim/common/EthernetManagerShim.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -21,7 +21,7 @@ import android.net.IpConfiguration; import androidx.annotation.NonNull; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.annotation.Nullable; import java.util.List; import java.util.concurrent.Executor; import java.util.concurrent.Executor; /** API shim for EthernetManager */ /** API shim for EthernetManager */ Loading Loading @@ -55,4 +55,9 @@ public interface EthernetManagerShim { default void setIncludeTestInterfaces(boolean include) throws UnsupportedApiLevelException { default void setIncludeTestInterfaces(boolean include) throws UnsupportedApiLevelException { throw new UnsupportedApiLevelException("Not supported until API 30"); throw new UnsupportedApiLevelException("Not supported until API 30"); } } /** Shim for EthernetManager#getInterfaceList */ default List<String> getInterfaceList() throws UnsupportedApiLevelException { throw new UnsupportedApiLevelException("Not supported until API 33"); } } }