Safeheron-SGX-Native-Development-Framework v1.2.0
Loading...
Searching...
No Matches
ssgx::filesystem_t::PlainFileWriter Class Reference

Write a plaintext file (file size <= 100 KB) More...

#include <ssgx_filesystem_t.h>

Public Member Functions

 PlainFileWriter (std::string filepath)
 Construct a PlainFileWriter and initialized it.
 
void WriteAllBytes (const std::vector< uint8_t > &data)
 Write data to a binary file in plaintext.
 
void WriteAllText (const std::string &str)
 Write data to a text file in plaintext.
 

Detailed Description

Write a plaintext file (file size <= 100 KB)

Constructor & Destructor Documentation

◆ PlainFileWriter()

ssgx::filesystem_t::PlainFileWriter::PlainFileWriter ( std::string filepath)
inlineexplicit

Construct a PlainFileWriter and initialized it.

Parameters
[in]filepathFile path

Member Function Documentation

◆ WriteAllBytes()

void ssgx::filesystem_t::PlainFileWriter::WriteAllBytes ( const std::vector< uint8_t > & data)

Write data to a binary file in plaintext.

Parameters
[in]datadata will be written to file, in bytes, the max size is 100KB.
Exceptions
FileSystemExceptionIf the file is not open or a read error occurs.

◆ WriteAllText()

void ssgx::filesystem_t::PlainFileWriter::WriteAllText ( const std::string & str)

Write data to a text file in plaintext.

Parameters
[in]strdata will be written to file, in string, the max size is 100KB.
Exceptions
FileSystemExceptionIf the file is not open or a read error occurs.

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