Handles the.
More...
#include <FieldTextWriter.h>
|
void | Begin (std::string file_name) |
| Initializes the text file. More...
|
|
void | Write (const std::vector< u8 > &script_section_buffer, std::string field_name, bool english=true) |
| Writes text to the XML file. More...
|
|
void | End () |
| Finalizes the text file. More...
|
|
◆ AddText()
void FieldTextWriter::AddText |
( |
std::vector< unsigned char > & |
text | ) |
|
|
private |
◆ Begin()
void FieldTextWriter::Begin |
( |
std::string |
file_name | ) |
|
Initializes the text file.
Writes the XML text section opening tag.
- Parameters
-
[in] | file_name | Path to the file to write te text to. |
◆ End()
void FieldTextWriter::End |
( |
| ) |
|
Finalizes the text file.
Writes the XML text section closing tag.
◆ GetU16LE()
u16 FieldTextWriter::GetU16LE |
( |
u32 |
offset | ) |
|
|
private |
Reads 16 bytes of data from the data (little endian).
- Parameters
-
[in] | offset | Offset at which to read. |
- Returns
- 16 bytes of data at the specified offset.
- Exceptions
-
std::out_of_range | If the offset is out of the data. |
◆ GetU8()
u8 FieldTextWriter::GetU8 |
( |
u32 |
offset | ) |
|
|
private |
Reads 8 bytes of data from the data.
- Parameters
-
[in] | offset | Offset at which to read. |
- Returns
- 8 bytes of data at the specified offset.
- Exceptions
-
std::out_of_range | If the offset is out of the data. |
◆ Write()
void FieldTextWriter::Write |
( |
const std::vector< u8 > & |
script_section_buffer, |
|
|
std::string |
field_name, |
|
|
bool |
english = true |
|
) |
| |
Writes text to the XML file.
- Parameters
-
[in] | script_section_buffer | The text data to write. |
[in] | field_name | The field of the text. |
[in] | english | True if the language to write is english. |
◆ data_
std::vector<u8> FieldTextWriter::data_ |
|
private |
◆ logger_
std::unique_ptr<Logger> FieldTextWriter::logger_ |
|
private |
The logger used to write text.
◆ tag_open_
bool FieldTextWriter::tag_open_ = false |
|
private |
Indicates if the text XML tag has been opened and not closed.
The documentation for this class was generated from the following files: