Example #1
0
        public jvmtiError GetObjectHashCode(JvmVirtualMachineRemoteHandle virtualMachine, JvmObjectRemoteHandle @object, out int hashCode)
        {
            JavaVM machine = JavaVM.GetInstance(virtualMachine);

            int        hashCodeResult = 0;
            jvmtiError result         = jvmtiError.Internal;

            machine.InvokeOnJvmThread(
                (environment) =>
            {
                jvmtiInterface rawInterface = environment.RawInterface;
                result = rawInterface.GetObjectHashCode(environment.Handle, @object, out hashCodeResult);
            });

            hashCode = hashCodeResult;
            return(result);
        }