class
MdfDocument
- Module
- MDF
- Header
#include "mdf/mdf_document.h"- Namespace
MDF
Constructors
| Signature | Name | Description |
|---|---|---|
MdfDocument() = default | MdfDocument |
Public functions
| Returns | Name | Description |
|---|---|---|
MdfNode& | CreateRoot | |
MdfNode& | Root | |
const MdfNode& | Root | |
bool | HasRoot | |
std::vector<MdfNode>& | Roots | |
const std::vector<MdfNode>& | Roots | |
const std::vector<std::string>& | GetTrailingComments | Comments after the last root node, text encoding only. |
void | SetTrailingComments | |
bool | ParseFromString | Implemented in mdf.h, once parser and writer are available. |
bool | ParseFromFile | |
std::string | WriteToString | |
bool | WriteToFile |
Function details
MdfDocument
C++
MdfDocument() = defaultCreateRoot
C++
inline MdfNode& CreateRoot(const std::string& type, const std::string& name = "")Root
C++
inline MdfNode& Root()Root
C++
inline const MdfNode& Root() constHasRoot
C++
bool HasRoot() constRoots
C++
std::vector<MdfNode>& Roots()Roots
C++
const std::vector<MdfNode>& Roots() constGetTrailingComments
C++
const std::vector<std::string>& GetTrailingComments() constComments after the last root node, text encoding only.
SetTrailingComments
C++
void SetTrailingComments(std::vector<std::string> comments)ParseFromString
C++
static inline bool ParseFromString(const std::string& source, MdfDocument& outDoc, std::string* outError = nullptr)Implemented in mdf.h, once parser and writer are available.
ParseFromFile
C++
static inline bool ParseFromFile(const std::string& filepath, MdfDocument& outDoc, std::string* outError = nullptr)WriteToString
C++
inline std::string WriteToString(int indentSize = 4) constWriteToFile
C++
inline bool WriteToFile(const std::string& filepath, int indentSize = 4) constGenerated from mdf/mdf_document.h via mdf.json · Oct 26, 2026Version 1.0.0