AppDynamics Xamarin SDK  2021.9.0
Real user monitoring for your Xamarin app.
Classes | Static Public Member Functions | List of all members
AppDynamics.Droid.Agent Class Reference

Android specific initializer. More...

Static Public Member Functions

static void Init (Application application)
 Initialize the Android Specific Instrumentation More...
 
static void Init (Activity activity, Bundle bundle)
 Initialize the Android Specific Instrumentation More...
 

Detailed Description

Android specific initializer.

Member Function Documentation

§ Init() [1/2]

static void AppDynamics.Droid.Agent.Init ( Application  application)
inlinestatic

Initialize the Android Specific Instrumentation

Without this, Android instrumentation will not work properly.

§ Init() [2/2]

static void AppDynamics.Droid.Agent.Init ( Activity  activity,
Bundle  bundle 
)
inlinestatic

Initialize the Android Specific Instrumentation

You need to call this line in your MainActivity.cs. Without this, Android instrumentation will not work properly.

public class MainActivity : global::Xamarin.Forms.Platform.Android.FormsAppCompatActivity
{
protected override void OnCreate(Bundle bundle)
{
base.OnCreate(bundle); //existing code
global::Xamarin.Forms.Forms.Init(this, bundle);
AppDynamics.Droid.Agent.Init(this, bundle); //initialize the agent on the Android Platform
LoadApplication(new App());
}
}

The documentation for this class was generated from the following file: