MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / GetStaticMethodPointer

Function GetStaticMethodPointer

Source/Engine/Scripting/Runtime/DotNet.cpp:1965–1977  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1963}
1964
1965void* GetStaticMethodPointer(StringView methodName)
1966{
1967 void* fun;
1968 if (CachedFunctions.TryGet(methodName, fun))
1969 return fun;
1970 PROFILE_CPU();
1971 PROFILE_MEM(ScriptingCSharp);
1972 const int rc = get_function_pointer(NativeInteropTypeName, FLAX_CORECLR_STRING(methodName).Get(), UNMANAGEDCALLERSONLY_METHOD, nullptr, nullptr, &fun);
1973 if (rc != 0)
1974 LOG(Fatal, "Failed to get unmanaged function pointer for method '{0}': 0x{1:x}", methodName, (unsigned int)rc);
1975 CachedFunctions.Add(methodName, fun);
1976 return fun;
1977}
1978
1979#elif DOTNET_HOST_MONO
1980

Callers 15

RegisterNativeLibraryFunction · 0.85
LoadEngineMethod · 0.85
UnloadEngineMethod · 0.85
BoxMethod · 0.85
UnboxMethod · 0.85
NewMethod · 0.85
InitMethod · 0.85
GetClassMethod · 0.85
ToStringMethod · 0.85
GetHashCodeMethod · 0.85

Calls 6

OnMonoAssemblyLoadFunction · 0.85
StringFunction · 0.50
TryGetMethod · 0.45
GetMethod · 0.45
AddMethod · 0.45
LengthMethod · 0.45

Tested by

no test coverage detected