IJavaPeerable Interface
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Support for using Java object instances.
public interface IJavaPeerable : IDisposable
type IJavaPeerable = interface
interface IDisposable
- Derived
- Implements
Remarks
The IJavaPeerable
interface provides access to a Java object instance, invocation of members on that Java instance, control over the lifetime of that object instance, and callbacks for when the wrapper is being disposed or finalized. The following operations are permitted:
- Object instance access is available through the PeerReference property. :
- Member access and invocation is available through the JniPeerMembers property. :
- Object lifetime control through Java.Interop.IJavaPeerable.Dispose and DisposeUnlessReferenced() methods. :
- Value visibilty is controlled through Java.Interop.IJavaPeerable.DisposeUnlessRegistered. :
- Disposal and finalization callbacks through the Disposed() and Finalized() methods. :
Properties
JniIdentityHashCode |
Returns the value of |
JniManagedPeerState |
State of the managed peer. |
JniPeerMembers |
Member access and invocation support. |
PeerReference |
Returns a JniObjectReference of the wrapped Java object instance. |
Methods
Disposed() |
Called when the instance has been disposed. |
DisposeUnlessReferenced() |
If there are no outstanding references to this instance, then
calls |
Finalized() |
Called when the instance has been finalized. |
SetJniIdentityHashCode(Int32) |
Set the value returned by |
SetJniManagedPeerState(JniManagedPeerStates) | |
SetPeerReference(JniObjectReference) |
Set the value returned by |
UnregisterFromRuntime() |
Unregister this instance so that the runtime will not return it from future Java.Interop.JniRuntime+JniValueManager.PeekValue invocations. |
Extension Methods
GetJniTypeName(IJavaPeerable) |