nndeploy C++ API  0.2.0
nndeploy C++ API
Public Member Functions | Static Public Member Functions | List of all members
nndeploy::base::FileLoader Class Reference

#include <file_loader.h>

Inheritance diagram for nndeploy::base::FileLoader:
[legend]
Collaboration diagram for nndeploy::base::FileLoader:
[legend]

Public Member Functions

 FileLoader (const char *file, bool init=false)
 
int offset (int64_t offset)
 
std::string path () const
 
bool read ()
 
bool read (char *buffer, int64_t size)
 
size_t size () const
 
bool valid () const
 
 ~FileLoader ()
 
- Public Member Functions inherited from nndeploy::base::BaseLoader
 BaseLoader ()=default
 
virtual ~BaseLoader ()=default
 

Static Public Member Functions

static bool write (const char *filePath, std::pair< const void *, size_t > cacheInfo)
 

Detailed Description

Definition at line 25 of file file_loader.h.

Constructor & Destructor Documentation

◆ FileLoader()

nndeploy::base::FileLoader::FileLoader ( const char *  file,
bool  init = false 
)

◆ ~FileLoader()

nndeploy::base::FileLoader::~FileLoader ( )

Member Function Documentation

◆ offset()

int nndeploy::base::FileLoader::offset ( int64_t  offset)

◆ path()

std::string nndeploy::base::FileLoader::path ( ) const
inline

Definition at line 38 of file file_loader.h.

◆ read() [1/2]

bool nndeploy::base::FileLoader::read ( )

◆ read() [2/2]

bool nndeploy::base::FileLoader::read ( char *  buffer,
int64_t  size 
)
virtual

◆ size()

size_t nndeploy::base::FileLoader::size ( ) const
inline

Definition at line 37 of file file_loader.h.

◆ valid()

bool nndeploy::base::FileLoader::valid ( ) const
inline

Definition at line 36 of file file_loader.h.

◆ write()

static bool nndeploy::base::FileLoader::write ( const char *  filePath,
std::pair< const void *, size_t >  cacheInfo 
)
static

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