internal JvmFieldRemoteHandle(JvmClassRemoteHandle @class, jfieldID field) { Class = @class; Handle = field.Handle.ToInt64(); }
public jvmtiError GetMethodDeclaringClass(JvmVirtualMachineRemoteHandle virtualMachine, JvmMethodRemoteHandle method, out JvmClassRemoteHandle declaringClass) { throw new NotImplementedException(); }
public jvmtiError GetClassLoader(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out JvmObjectRemoteHandle classLoader) { throw new NotImplementedException(); }
public jvmtiError GetSourceDebugExtension(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out string sourceDebugExtension) { throw new NotImplementedException(); }
public jvmtiError IsInterface(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out bool isInterface) { throw new NotImplementedException(); }
public jvmtiError IsModifiableClass(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out bool isModifiableClass) { throw new NotImplementedException(); }
public jvmtiError GetClassVersionNumbers(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out int minorVersion, out int majorVersion) { throw new NotImplementedException(); }
public jvmtiError GetConstantPool(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out byte[] constantPool) { throw new NotImplementedException(); }
public jvmtiError GetClassFields(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out JvmFieldRemoteHandle[] fields) { throw new NotImplementedException(); }
public jvmtiError GetImplementedInterfaces(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out JvmClassRemoteHandle[] interfaces) { throw new NotImplementedException(); }
public jvmtiError GetClassMethods(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out JvmMethodRemoteHandle[] methods) { JavaVM machine = JavaVM.GetInstance(virtualMachine); List <JvmMethodRemoteHandle> methodsList = new List <JvmMethodRemoteHandle>(); jvmtiError result = jvmtiError.Internal; machine.InvokeOnJvmThread( (environment) => { jvmtiInterface rawInterface = environment.RawInterface; IntPtr methodsPtr = IntPtr.Zero; try { int methodCount; result = rawInterface.GetClassMethods(environment.Handle, @class, out methodCount, out methodsPtr); unsafe { jmethodID *rawMethods = (jmethodID *)methodsPtr; for (int i = 0; i < methodCount; i++) { methodsList.Add(new JvmMethodRemoteHandle(rawMethods[i])); } } } finally { rawInterface.Deallocate(environment.Handle, methodsPtr); } }); methods = methodsList.ToArray(); return(result); }
public jvmtiError GetClassModifiers(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out JvmAccessModifiers modifiers) { throw new NotImplementedException(); }
public jvmtiError GetSourceFileName(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out string sourceName) { JavaVM machine = JavaVM.GetInstance(virtualMachine); string sourceNameResult = null; jvmtiError result = jvmtiError.Internal; machine.InvokeOnJvmThread( (environment) => { jvmtiInterface rawInterface = environment.RawInterface; IntPtr sourceNamePtr = IntPtr.Zero; try { result = rawInterface.GetSourceFileName(environment.Handle, @class, out sourceNamePtr); unsafe { if (sourceNamePtr != IntPtr.Zero) { sourceNameResult = ModifiedUTF8Encoding.GetString((byte *)sourceNamePtr); } } } finally { rawInterface.Deallocate(environment.Handle, sourceNamePtr); } }); sourceName = sourceNameResult; return(result); }
public jvmtiError GetClassStatus(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out jvmtiClassStatus status) { throw new NotImplementedException(); }
public jvmtiError GetClassSignature(JvmVirtualMachineRemoteHandle virtualMachine, JvmClassRemoteHandle @class, out string signature, out string generic) { JavaVM machine = JavaVM.GetInstance(virtualMachine); string signatureResult = null; string genericResult = null; jvmtiError result = jvmtiError.Internal; machine.InvokeOnJvmThread( (environment) => { jvmtiInterface rawInterface = environment.RawInterface; IntPtr signaturePtr = IntPtr.Zero; IntPtr genericPtr = IntPtr.Zero; try { result = rawInterface.GetClassSignature(environment.Handle, @class, out signaturePtr, out genericPtr); unsafe { if (signaturePtr != IntPtr.Zero) { signatureResult = ModifiedUTF8Encoding.GetString((byte *)signaturePtr); } if (genericPtr != IntPtr.Zero) { genericResult = ModifiedUTF8Encoding.GetString((byte *)genericPtr); } } } finally { rawInterface.Deallocate(environment.Handle, signaturePtr); rawInterface.Deallocate(environment.Handle, genericPtr); } }); signature = signatureResult; generic = genericResult; return(result); }