Class ShadowMediaRouter


  • @Implements(android.media.MediaRouter.class)
    public class ShadowMediaRouter
    extends java.lang.Object
    Shadow class for MediaRouter.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addBluetoothRoute()
      Adds the Bluetooth A2DP route and ensures it's the selected route, simulating connecting a Bluetooth device.
      boolean isBluetoothRouteSelected​(int type)
      Returns whether the Bluetooth A2DP route is the currently selected route.
      void removeBluetoothRoute()
      Removes the Bluetooth A2DP route, simulating disconnecting the Bluetooth device.
      static void reset()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • BLUETOOTH_DEVICE_NAME

        public static final java.lang.String BLUETOOTH_DEVICE_NAME
        See Also:
        Constant Field Values
    • Constructor Detail

      • ShadowMediaRouter

        public ShadowMediaRouter()
    • Method Detail

      • addBluetoothRoute

        public void addBluetoothRoute()
        Adds the Bluetooth A2DP route and ensures it's the selected route, simulating connecting a Bluetooth device.
      • removeBluetoothRoute

        public void removeBluetoothRoute()
        Removes the Bluetooth A2DP route, simulating disconnecting the Bluetooth device.
      • isBluetoothRouteSelected

        public boolean isBluetoothRouteSelected​(int type)
        Returns whether the Bluetooth A2DP route is the currently selected route.
      • reset

        @Resetter
        public static void reset()