Open Model Railroad Network (OpenMRN)
Loading...
Searching...
No Matches
openlcb::MockSNIPUserFile Class Reference

Helper class for mock implementations. More...

#include <SimpleNodeInfoMockUserFile.hxx>

Public Member Functions

 MockSNIPUserFile (const char *user_name, const char *user_description)
 

Static Public Attributes

static char snip_user_file_path [128] = "/dev/zero"
 

Private Attributes

TempFile userFile_
 

Detailed Description

Helper class for mock implementations.

Creates a mock file with the SNIP user-modifiable data inside that can be used as SNIP_DYNAMIC_FILENAME.

Usage:

static MockSNIPUserFile g_snip_file(g_dir, "Default user name", "Default user description"); const char *const SNIP_DYNAMIC_FILENAME = MockSNIPUserFile::snip_user_file_path;

Definition at line 58 of file SimpleNodeInfoMockUserFile.hxx.

Constructor & Destructor Documentation

◆ MockSNIPUserFile()

openlcb::MockSNIPUserFile::MockSNIPUserFile ( const char *  user_name,
const char *  user_description 
)

Definition at line 61 of file SimpleNodeInfoMockUserFile.cxx.

◆ ~MockSNIPUserFile()

openlcb::MockSNIPUserFile::~MockSNIPUserFile ( )

Definition at line 72 of file SimpleNodeInfoMockUserFile.cxx.

Member Data Documentation

◆ snip_user_file_path

char openlcb::MockSNIPUserFile::snip_user_file_path = "/dev/zero"
static

Definition at line 64 of file SimpleNodeInfoMockUserFile.hxx.

◆ userFile_

TempFile openlcb::MockSNIPUserFile::userFile_
private

Definition at line 76 of file SimpleNodeInfoMockUserFile.hxx.


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