Condividi tramite


Location.Mock Property

Definition

Returns true if this location is marked as a mock location. -or- Sets whether this location is marked as a mock location.

public virtual bool Mock { [Android.Runtime.Register("isMock", "()Z", "GetIsMockHandler", ApiSince=31)] get; [Android.Runtime.Register("setMock", "(Z)V", "GetSetMock_ZHandler", ApiSince=31)] set; }
[<get: Android.Runtime.Register("isMock", "()Z", "GetIsMockHandler", ApiSince=31)>]
[<set: Android.Runtime.Register("setMock", "(Z)V", "GetSetMock_ZHandler", ApiSince=31)>]
member this.Mock : bool with get, set

Property Value

Attributes

Remarks

Property getter documentation:

Returns true if this location is marked as a mock location. If this location comes from the Android framework, this indicates that the location was provided by a test location provider, and thus may not be related to the actual location of the device.

Java documentation for android.location.Location.isMock().

Property setter documentation:

Sets whether this location is marked as a mock location.

Java documentation for android.location.Location.setMock(boolean).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to