forked from focus-creative-games/il2cpp_plus
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMemoryMappedFile.cpp
More file actions
31 lines (24 loc) · 782 Bytes
/
MemoryMappedFile.cpp
File metadata and controls
31 lines (24 loc) · 782 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include "os/c-api/il2cpp-config-platforms.h"
#if !RUNTIME_TINY
#include "os/c-api/MemoryMappedFile-c-api.h"
#include "utils/MemoryMappedFile.h"
extern "C"
{
void* UnityPalMemoryMappedFileMap(UnityPalFileHandle* file)
{
return il2cpp::utils::MemoryMappedFile::Map(file);
}
void UnityPalMemoryMappedFileUnmap(void* address)
{
il2cpp::utils::MemoryMappedFile::Unmap(address);
}
void* UnityPalMemoryMappedFileMapWithParams(UnityPalFileHandle* file, int64_t length, int64_t offset)
{
return il2cpp::utils::MemoryMappedFile::Map(file, length, offset);
}
void UnityPalMemoryMappedFileUnmapWithParams(void* address, int64_t length)
{
il2cpp::utils::MemoryMappedFile::Unmap(address, length);
}
}
#endif