Android 12 Developer Preview is here! Try it out, and give us your feedback!

PlaceController

public class PlaceController
extends Object

java.lang.Object
   ↳ com.google.android.libraries.car.app.testing.model.PlaceController


A controller that allows testing of a Place.

This controller allows getting the following fields:

Summary

Public methods

Place get()

Retrieves the Place that this controller is controlling.

LatLng getLatLng()

Retrieves the LatLng that was set in the Place being controlled via Place.Builder.setLatLng(LatLng) or Place.builder(LatLng).

static PlaceController of(Place place)

Creates a PlaceController to control a Place for testing.

Inherited methods

Public methods

get

public Place get ()

Retrieves the Place that this controller is controlling.

Returns
Place

getLatLng

public LatLng getLatLng ()

Retrieves the LatLng that was set in the Place being controlled via Place.Builder.setLatLng(LatLng) or Place.builder(LatLng).

Returns
LatLng

of

public static PlaceController of (Place place)

Creates a PlaceController to control a Place for testing.

Parameters
place Place

Returns
PlaceController