XS Framework
A 3DS homebrew development framework.
 
Loading...
Searching...
No Matches
xs::fs Namespace Reference

Filesystem-related utilities. More...

Functions

void AppendFile (const std::string &path, const std::string &data)
 Appends data to a file (creates the file if it doesn't exist).
 
std::string ReadFile (const std::string &path)
 Reads the entire contents of a file into a string.
 
void WriteFile (const std::string &path, const std::string &data)
 Writes data to a file, overwriting any existing contents.
 

Detailed Description

Filesystem-related utilities.

Function Documentation

◆ AppendFile()

void xs::fs::AppendFile ( const std::string & path,
const std::string & data )

Appends data to a file (creates the file if it doesn't exist).

Parameters
pathPath
dataData to append to the file.

◆ ReadFile()

std::string xs::fs::ReadFile ( const std::string & path)

Reads the entire contents of a file into a string.

Parameters
pathPath
Returns
std::string File contents (empty on error or if file missing).

◆ WriteFile()

void xs::fs::WriteFile ( const std::string & path,
const std::string & data )

Writes data to a file, overwriting any existing contents.

Parameters
pathPath
dataData to write to the file.