LLDB  mainline
Public Member Functions | Static Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
lldb_private::FileCache Class Reference

#include <FileCache.h>

Collaboration diagram for lldb_private::FileCache:
Collaboration graph
[legend]

Public Member Functions

lldb::user_id_t OpenFile (const FileSpec &file_spec, File::OpenOptions flags, uint32_t mode, Status &error)
 
bool CloseFile (lldb::user_id_t fd, Status &error)
 
uint64_t WriteFile (lldb::user_id_t fd, uint64_t offset, const void *src, uint64_t src_len, Status &error)
 
uint64_t ReadFile (lldb::user_id_t fd, uint64_t offset, void *dst, uint64_t dst_len, Status &error)
 

Static Public Member Functions

static FileCacheGetInstance ()
 

Private Types

typedef std::map< lldb::user_id_t, lldb::FileUP > FDToFileMap
 

Private Member Functions

 FileCache ()=default
 

Private Attributes

FDToFileMap m_cache
 

Static Private Attributes

static FileCachem_instance = nullptr
 

Detailed Description

Definition at line 22 of file FileCache.h.

Member Typedef Documentation

◆ FDToFileMap

typedef std::map<lldb::user_id_t, lldb::FileUP> lldb_private::FileCache::FDToFileMap
private

Definition at line 26 of file FileCache.h.

Constructor & Destructor Documentation

◆ FileCache()

lldb_private::FileCache::FileCache ( )
privatedefault

Member Function Documentation

◆ CloseFile()

bool FileCache::CloseFile ( lldb::user_id_t  fd,
Status error 
)

Definition at line 43 of file FileCache.cpp.

References error(), and UINT64_MAX.

Referenced by lldb_private::RemoteAwarePlatform::CloseFile().

◆ GetInstance()

FileCache & FileCache::GetInstance ( )
static

◆ OpenFile()

lldb::user_id_t FileCache::OpenFile ( const FileSpec file_spec,
File::OpenOptions  flags,
uint32_t  mode,
Status error 
)

Definition at line 26 of file FileCache.cpp.

References error(), and UINT64_MAX.

Referenced by lldb_private::RemoteAwarePlatform::OpenFile().

◆ ReadFile()

uint64_t FileCache::ReadFile ( lldb::user_id_t  fd,
uint64_t  offset,
void *  dst,
uint64_t  dst_len,
Status error 
)

Definition at line 90 of file FileCache.cpp.

References error(), and UINT64_MAX.

Referenced by lldb_private::RemoteAwarePlatform::ReadFile().

◆ WriteFile()

uint64_t FileCache::WriteFile ( lldb::user_id_t  fd,
uint64_t  offset,
const void *  src,
uint64_t  src_len,
Status error 
)

Definition at line 63 of file FileCache.cpp.

References error(), and UINT64_MAX.

Referenced by lldb_private::RemoteAwarePlatform::WriteFile().

Member Data Documentation

◆ m_cache

FDToFileMap lldb_private::FileCache::m_cache
private

Definition at line 43 of file FileCache.h.

◆ m_instance

FileCache * FileCache::m_instance = nullptr
staticprivate

Definition at line 41 of file FileCache.h.


The documentation for this class was generated from the following files: