Android Guides | Samples

Java.Interop.ExportAttribute Class

Used on a method to indicate Java code generator to export a Java method that becomes an Android Callable Wrapper (ACW).

See Also: ExportAttribute


[System.AttributeUsage(System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.All, AllowMultiple=false, Inherited=false)]
public class ExportAttribute : Attribute


ExportAttribute and ExportFieldAttribute are used to generate Java method and/or field explicitly in Android Callable Wrappers (ACWs), with specific name. The Mono for Android build process does not usually generate Java methods that is not necessary, but they are required in some usage scenario. This attribute is introduced to support them.

For details, see ExportAttribute section of the documentation page.

This type is introduced in Mono for Android 4.2.


Namespace: Java.Interop
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions:

The members of Java.Interop.ExportAttribute are listed below.

See Also: Attribute

Public Constructors

Creates a new instance of this type.

Public Properties

NameString. Specifies the Java method name to be generated.
ThrowsType[]. Specifies which types could be thrown, which will be used to indicate the checked exceptions.