#include <elf-cache.h>
Classes | |
struct | ElfCachedFile |
struct | FileInfo |
struct | Overriden |
Public Member Functions | |
ElfCache (std::string directory, uint32_t uid) | |
struct ElfCachedFile | Add (std::string filename) |
Private Member Functions | |
void | CopyFile (std::string source, std::string destination) const |
struct FileInfo | EditBuffer (uint8_t *map, uint32_t selfId) const |
struct FileInfo | EditFile (std::string filename, uint32_t selfId) const |
std::string | EnsureCacheDirectory (void) const |
unsigned long | GetBaseAddress (ElfW(Phdr)*phdr, long phnum) const |
std::string | GetBasename (std::string filename) const |
uint32_t | GetDepId (std::string depname) const |
long | GetDtStrTab (ElfW(Dyn)*dyn, long baseAddress) const |
uint8_t | NumberToChar (uint8_t c) const |
void | WriteString (char *str, uint32_t uid) const |
Static Private Member Functions | |
static uint32_t | AllocateId (void) |
Private Attributes | |
std::string | m_directory |
std::vector< struct ElfCachedFile > | m_files |
std::vector< struct Overriden > | m_overriden |
uint32_t | m_uid |
Definition at line 12 of file elf-cache.h.
ns3::ElfCache::ElfCache | ( | std::string | directory, |
uint32_t | uid | ||
) |
Definition at line 18 of file elf-cache.cc.
References ns3::ElfCache::Overriden::from, m_overriden, and ns3::ElfCache::Overriden::to.
|
read |
Definition at line 322 of file elf-cache.cc.
References AllocateId(), ns3::ElfCache::ElfCachedFile::basename, ns3::ElfCache::ElfCachedFile::cachedFilename, CopyFile(), ns3::ElfCache::ElfCachedFile::data_p_memsz, ns3::ElfCache::ElfCachedFile::data_p_vaddr, ns3::ElfCache::ElfCachedFile::deps, ns3::ElfCache::FileInfo::deps, EditFile(), EnsureCacheDirectory(), ns3::ElfCache::Overriden::from, GetBasename(), ns3::ElfCache::ElfCachedFile::id, m_files, m_overriden, ns3::ElfCache::FileInfo::p_memsz, ns3::ElfCache::FileInfo::p_vaddr, and ns3::ElfCache::Overriden::to.
Referenced by ns3::CoojaLoader::LoadModule().
|
staticprivate |
Definition at line 272 of file elf-cache.cc.
Referenced by Add().
|
private |
Definition at line 49 of file elf-cache.cc.
Referenced by Add().
|
readprivate |
Definition at line 157 of file elf-cache.cc.
References ns3::ElfCache::FileInfo::deps, ns3::ElfW(), GetBaseAddress(), GetDepId(), GetDtStrTab(), ns3::ElfCache::FileInfo::p_memsz, ns3::ElfCache::FileInfo::p_vaddr, and WriteString().
Referenced by EditFile().
|
readprivate |
Definition at line 246 of file elf-cache.cc.
References EditBuffer(), and errno.
Referenced by Add().
|
private |
Definition at line 304 of file elf-cache.cc.
References m_directory, and m_uid.
Referenced by Add().
|
private |
Definition at line 96 of file elf-cache.cc.
Referenced by EditBuffer().
|
private |
Definition at line 38 of file elf-cache.cc.
Referenced by Add().
|
private |
Definition at line 280 of file elf-cache.cc.
References ns3::ElfCache::Overriden::from, m_files, m_overriden, and ns3::ElfCache::Overriden::to.
Referenced by EditBuffer().
|
private |
Definition at line 72 of file elf-cache.cc.
Referenced by EditBuffer().
|
private |
Definition at line 120 of file elf-cache.cc.
Referenced by WriteString().
|
private |
Definition at line 138 of file elf-cache.cc.
References NumberToChar().
Referenced by EditBuffer().
|
private |
Definition at line 53 of file elf-cache.h.
Referenced by EnsureCacheDirectory().
|
private |
Definition at line 55 of file elf-cache.h.
Referenced by Add(), and GetDepId().
|
private |
Definition at line 56 of file elf-cache.h.
Referenced by Add(), ElfCache(), and GetDepId().
|
private |
Definition at line 54 of file elf-cache.h.
Referenced by EnsureCacheDirectory().