Storage class for all the strings of the DEX file.
More...
#include <strings.hpp>
|
| Strings ()=default |
| Constructor of string class.
|
|
| Strings (Strings &str) |
| Copy constructors of strings.
|
|
| ~Strings ()=default |
| destructor of the strings.
|
|
void | parse_strings (std::uint32_t strings_offset, std::uint32_t number_of_strings, stream::KunaiStream *stream) |
| Parse the strings from the DEX file.
|
|
const ordered_strings_t & | get_ordered_strings () const |
|
const offset_string_t & | get_offset_strings () const |
| Return the offset strings map as constant.
|
|
std::string * | get_string_from_offset (std::uint32_t offset) |
| Return a pointer to an string giving an offset.
|
|
std::string & | get_string_by_id (std::uint32_t id) |
| Get reference to string by a given id.
|
|
std::uint32_t | get_number_of_strings () const |
| Get the number of the strings stored.
|
|
void | to_xml (std::ofstream &fos) |
| Dump the Strings to an XML.
|
|
|
std::ostream & | operator<< (std::ostream &os, const Strings &entry) |
| pretty print the list of strings.
|
|
Storage class for all the strings of the DEX file.
◆ Strings()
KUNAI::DEX::Strings::Strings |
( |
Strings & |
str | ) |
|
Copy constructors of strings.
- Parameters
-
str | another strings object |
◆ get_number_of_strings()
std::uint32_t KUNAI::DEX::Strings::get_number_of_strings |
( |
| ) |
const |
|
inline |
Get the number of the strings stored.
- Returns
- uint32_t with number of strings
◆ get_offset_strings()
const offset_string_t & KUNAI::DEX::Strings::get_offset_strings |
( |
| ) |
const |
|
inline |
Return the offset strings map as constant.
- Returns
- offset-strings map
◆ get_string_by_id()
std::string & KUNAI::DEX::Strings::get_string_by_id |
( |
std::uint32_t |
id | ) |
|
Get reference to string by a given id.
- Parameters
-
id | id commonly refers to position |
- Returns
- reference to string
◆ get_string_from_offset()
std::string * KUNAI::DEX::Strings::get_string_from_offset |
( |
std::uint32_t |
offset | ) |
|
Return a pointer to an string giving an offset.
- Parameters
-
offset | offset where string is |
- Returns
- pointer to string in the offset
◆ parse_strings()
void KUNAI::DEX::Strings::parse_strings |
( |
std::uint32_t |
strings_offset, |
|
|
std::uint32_t |
number_of_strings, |
|
|
stream::KunaiStream * |
stream |
|
) |
| |
Parse the strings from the DEX file.
- Parameters
-
strings_offset | offset where to read the strings |
number_of_strings | number of strings to read |
stream | stream with file |
◆ to_xml()
void KUNAI::DEX::Strings::to_xml |
( |
std::ofstream & |
fos | ) |
|
Dump the Strings to an XML.
- Parameters
-
◆ operator<<
std::ostream & operator<< |
( |
std::ostream & |
os, |
|
|
const Strings & |
entry |
|
) |
| |
|
friend |
pretty print the list of strings.
- Parameters
-
os | stream where to print to |
entry | entry with the strings |
- Returns
The documentation for this class was generated from the following file: