Platform Class

Definition

Platform specific helpers.

public static class Platform
Inheritance
Platform

Remarks

Properties

AppContext

The current application's context.

CurrentActivity

Gets the current Activity. This value is set OnCreate, OnPause, and OnResume.

MapServiceToken

Get or sets the map API key.

Methods

GetCurrentUIViewController()

Get the currently visible UIViewController.

Init(Activity, Bundle)

Initialize Xamarin.Essentials with Android's activity and bundle.

Init(Application)

Initialize Xamarin.Essentials with Android's application class.

OnRequestPermissionsResult(Int32, String[], Permission[])

Pass permission request results from an activity's overridden method to the library for handling internal permission requests.

OnResume()

Pass Resume lifecycle events of your main activity to be used for internal API handling.

OpenUrl(UIApplication, NSUrl, NSDictionary)

Passes the OpenUrl callback of your app to be used for internal API handling.

WaitForActivityAsync(CancellationToken)

Wait for an Activity to be create or active.

Events

ActivityStateChanged

Event that is triggered when any Android Activity's state changes.

Applies to