NativeLibrary.TryGetExport(IntPtr, String, IntPtr) メソッド

定義

エクスポートされたシンボルのアドレスを取得し、メソッド呼び出しが成功したかどうかを示す値を返します。

public:
 static bool TryGetExport(IntPtr handle, System::String ^ name, [Runtime::InteropServices::Out] IntPtr % address);
public static bool TryGetExport(IntPtr handle, string name, out IntPtr address);
static member TryGetExport : nativeint * string * nativeint -> bool
Public Shared Function TryGetExport (handle As IntPtr, name As String, ByRef address As IntPtr) As Boolean

パラメーター

handle
IntPtr

nativeint

ネイティブ ライブラリ OS ハンドル。

name
String

エクスポートされたシンボルの名前。

address
IntPtr

nativeint

メソッドから制御が戻るときに、シンボル アドレス (存在する場合) が格納されます。

返品

true エクスポートされたシンボルのアドレスが正常に見つかった場合。それ以外の場合は false

例外

handleZero または namenull

注釈

これは OS 呼び出しに関する単純なラッパーであり、名前のマングリングは実行しません。

IntPtr.Zero以外の無効なhandle パラメーターを使用してこのメソッドを呼び出すことはサポートされていないため、未定義の動作になります。

適用対象