Package org.robolectric.shadows
Class ShadowMediaRouter
java.lang.Object
org.robolectric.shadows.ShadowMediaRouter
@Implements(android.media.MediaRouter.class) public class ShadowMediaRouter extends Object
Shadow class for
MediaRouter.-
Field Summary
Fields Modifier and Type Field Description static StringBLUETOOTH_DEVICE_NAME -
Constructor Summary
Constructors Constructor Description ShadowMediaRouter() -
Method Summary
Modifier and Type Method Description voidaddBluetoothRoute()Adds the Bluetooth A2DP route and ensures it's the selected route, simulating connecting a Bluetooth device.booleanisBluetoothRouteSelected(int type)Returns whether the Bluetooth A2DP route is the currently selected route.voidremoveBluetoothRoute()Removes the Bluetooth A2DP route, simulating disconnecting the Bluetooth device.static voidreset()
-
Field Details
-
BLUETOOTH_DEVICE_NAME
- See Also:
- Constant Field Values
-
-
Constructor Details
-
ShadowMediaRouter
public ShadowMediaRouter()
-
-
Method Details
-
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
-