Skip to content

Commit

Permalink
Add native implementation of resource utility
Browse files Browse the repository at this point in the history
Signed-off-by: José Simões <jose.simoes@eclo.solutions>
  • Loading branch information
josesimoes committed Sep 7, 2018
1 parent 121d377 commit 9c390d4
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
1 change: 1 addition & 0 deletions CMake/Modules/FindNF_CoreCLR.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ set(NF_CoreCLR_SRCS
nf_rt_native_nanoFramework_Runtime_Native_Debug.cpp
nf_rt_native_nanoFramework_Runtime_Native_ExecutionConstraint.cpp
nf_rt_native_nanoFramework_Runtime_Native_Power.cpp
nf_rt_native_nanoFramework_Runtime_Native_ResourceUtility.cpp
nf_rt_native_nanoFramework_Runtime_Native_Rtc_stubs.cpp

# Core stubs
Expand Down
7 changes: 6 additions & 1 deletion src/CLR/Runtime.Native/nf_rt_native.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,18 @@ static const CLR_RT_MethodHandler method_lookup[] =
NULL,
NULL,
NULL,
Library_nf_rt_native_nanoFramework_Runtime_Native_ResourceUtility::GetObject___STATIC__OBJECT__mscorlibSystemResourcesResourceManager__mscorlibSystemEnum,
Library_nf_rt_native_nanoFramework_Runtime_Native_ResourceUtility::GetObject___STATIC__OBJECT__mscorlibSystemResourcesResourceManager__mscorlibSystemEnum__I4__I4,
NULL,
NULL,
NULL,
Library_nf_rt_native_nanoFramework_Runtime_Native_Rtc::Native_RTC_SetSystemTime___STATIC__BOOLEAN__I4__U1__U1__U1__U1__U1__U1,
};

const CLR_RT_NativeAssemblyData g_CLR_AssemblyNative_nanoFramework_Runtime_Native =
{
"nanoFramework.Runtime.Native",
0xA3593BC9,
0x1AD361FD,
method_lookup,
{ 1, 0, 0, 0 }
};
11 changes: 11 additions & 0 deletions src/CLR/Runtime.Native/nf_rt_native.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,17 @@ struct Library_nf_rt_native_nanoFramework_Runtime_Native_Power

};

struct Library_nf_rt_native_nanoFramework_Runtime_Native_ResourceUtility
{
static const int FIELD_STATIC__s_wr = 1;

NANOCLR_NATIVE_DECLARE(GetObject___STATIC__OBJECT__mscorlibSystemResourcesResourceManager__mscorlibSystemEnum);
NANOCLR_NATIVE_DECLARE(GetObject___STATIC__OBJECT__mscorlibSystemResourcesResourceManager__mscorlibSystemEnum__I4__I4);

//--//

};

struct Library_nf_rt_native_nanoFramework_Runtime_Native_Rtc
{
NANOCLR_NATIVE_DECLARE(Native_RTC_SetSystemTime___STATIC__BOOLEAN__I4__U1__U1__U1__U1__U1__U1);
Expand Down

0 comments on commit 9c390d4

Please sign in to comment.