libigl v2.5.0
Loading...
Searching...
No Matches
igl::xml::serialization_xml Namespace Reference

Classes

struct  is_eigen_type
 
struct  is_eigen_type< Eigen::Matrix< T, R, C, P, MR, MC > >
 
struct  is_eigen_type< Eigen::SparseMatrix< T, P, I > >
 
struct  is_serializable
 
struct  is_stl_container
 
struct  is_stl_container< std::map< T1, T2 > >
 
struct  is_stl_container< std::pair< T1, T2 > >
 
struct  is_stl_container< std::set< T > >
 
struct  is_stl_container< std::vector< T1, T2 > >
 

Functions

template<typename T >
std::enable_if< std::is_fundamental< T >::value >::type serialize (const T &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
std::enable_if< std::is_fundamental< T >::value >::type deserialize (T &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
void serialize (const std::string &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
void deserialize (std::string &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
std::enable_if< std::is_base_of< XMLSerializableBase, T >::value >::type serialize (const T &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
std::enable_if< std::is_base_of< XMLSerializableBase, T >::value >::type deserialize (T &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void serialize (const std::pair< T1, T2 > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void deserialize (std::pair< T1, T2 > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void serialize (const std::vector< T1, T2 > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void deserialize (std::vector< T1, T2 > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
void serialize (const std::set< T > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
void deserialize (std::set< T > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void serialize (const std::map< T1, T2 > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T1 , typename T2 >
void deserialize (std::map< T1, T2 > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T , int R, int C, int P, int MR, int MC>
void serialize (const Eigen::Matrix< T, R, C, P, MR, MC > &obj, const std::string &name, const std::function< std::string(const T &) > &to_string, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element)
 
template<typename T , int R, int C, int P, int MR, int MC>
void deserialize (const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name, const std::function< void(const std::string &, T &)> &from_string, Eigen::Matrix< T, R, C, P, MR, MC > &obj)
 
template<typename T , int R, int C, int P, int MR, int MC>
void serialize (const Eigen::Matrix< T, R, C, P, MR, MC > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T , int R, int C, int P, int MR, int MC>
void deserialize (Eigen::Matrix< T, R, C, P, MR, MC > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T , int P, typename I >
void serialize (const Eigen::SparseMatrix< T, P, I > &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T , int P, typename I >
void deserialize (Eigen::SparseMatrix< T, P, I > &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
std::enable_if< std::is_pointer< T >::value >::type serialize (const T &obj, tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
template<typename T >
std::enable_if< std::is_pointer< T >::value >::type deserialize (T &obj, const tinyxml2::XMLDocument *doc, const tinyxml2::XMLElement *element, const std::string &name)
 
tinyxml2::XMLElement * getElement (tinyxml2::XMLDocument *doc, tinyxml2::XMLElement *element, const std::string &name)
 
void getAttribute (const char *src, bool &dest)
 
void getAttribute (const char *scr, char &dest)
 
void getAttribute (const char *src, std::string &dest)
 
void getAttribute (const char *src, float &dest)
 
void getAttribute (const char *src, double &dest)
 
template<typename T >
std::enable_if< std::is_integral< T >::value &&std::is_unsigned< T >::value >::type getAttribute (const char *src, T &dest)
 
template<typename T >
std::enable_if< std::is_integral< T >::value &&!std::is_unsigned< T >::value >::type getAttribute (const char *src, T &dest)
 
void replaceSubString (std::string &str, const std::string &search, const std::string &replace)
 
void encodeXMLElementName (std::string &name)
 
void decodeXMLElementName (std::string &name)
 
std::string base64_encode (unsigned char const *bytes_to_encode, unsigned int in_len)
 
std::string base64_decode (std::string const &encoded_string)
 

Function Documentation

◆ serialize() [1/11]

template<typename T >
std::enable_if< std::is_fundamental< T >::value >::type igl::xml::serialization_xml::serialize ( const T &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [1/11]

template<typename T >
std::enable_if< std::is_fundamental< T >::value >::type igl::xml::serialization_xml::deserialize ( T &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [2/11]

void igl::xml::serialization_xml::serialize ( const std::string &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [2/11]

void igl::xml::serialization_xml::deserialize ( std::string &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [3/11]

template<typename T >
std::enable_if< std::is_base_of< XMLSerializableBase, T >::value >::type igl::xml::serialization_xml::serialize ( const T &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [3/11]

template<typename T >
std::enable_if< std::is_base_of< XMLSerializableBase, T >::value >::type igl::xml::serialization_xml::deserialize ( T &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [4/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::serialize ( const std::pair< T1, T2 > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [4/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::deserialize ( std::pair< T1, T2 > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [5/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::serialize ( const std::vector< T1, T2 > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [5/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::deserialize ( std::vector< T1, T2 > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [6/11]

template<typename T >
void igl::xml::serialization_xml::serialize ( const std::set< T > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [6/11]

template<typename T >
void igl::xml::serialization_xml::deserialize ( std::set< T > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [7/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::serialize ( const std::map< T1, T2 > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [7/11]

template<typename T1 , typename T2 >
void igl::xml::serialization_xml::deserialize ( std::map< T1, T2 > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [8/11]

template<typename T , int R, int C, int P, int MR, int MC>
void igl::xml::serialization_xml::serialize ( const Eigen::Matrix< T, R, C, P, MR, MC > &  obj,
const std::string &  name,
const std::function< std::string(const T &) > &  to_string,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element 
)

◆ deserialize() [8/11]

template<typename T , int R, int C, int P, int MR, int MC>
void igl::xml::serialization_xml::deserialize ( const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name,
const std::function< void(const std::string &, T &)> &  from_string,
Eigen::Matrix< T, R, C, P, MR, MC > &  obj 
)

◆ serialize() [9/11]

template<typename T , int R, int C, int P, int MR, int MC>
void igl::xml::serialization_xml::serialize ( const Eigen::Matrix< T, R, C, P, MR, MC > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [9/11]

template<typename T , int R, int C, int P, int MR, int MC>
void igl::xml::serialization_xml::deserialize ( Eigen::Matrix< T, R, C, P, MR, MC > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [10/11]

template<typename T , int P, typename I >
void igl::xml::serialization_xml::serialize ( const Eigen::SparseMatrix< T, P, I > &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [10/11]

template<typename T , int P, typename I >
void igl::xml::serialization_xml::deserialize ( Eigen::SparseMatrix< T, P, I > &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ serialize() [11/11]

template<typename T >
std::enable_if< std::is_pointer< T >::value >::type igl::xml::serialization_xml::serialize ( const T &  obj,
tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ deserialize() [11/11]

template<typename T >
std::enable_if< std::is_pointer< T >::value >::type igl::xml::serialization_xml::deserialize ( T &  obj,
const tinyxml2::XMLDocument *  doc,
const tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ getElement()

tinyxml2::XMLElement * igl::xml::serialization_xml::getElement ( tinyxml2::XMLDocument *  doc,
tinyxml2::XMLElement *  element,
const std::string &  name 
)

◆ getAttribute() [1/7]

void igl::xml::serialization_xml::getAttribute ( const char *  src,
bool &  dest 
)

◆ getAttribute() [2/7]

void igl::xml::serialization_xml::getAttribute ( const char *  scr,
char &  dest 
)

◆ getAttribute() [3/7]

void igl::xml::serialization_xml::getAttribute ( const char *  src,
std::string &  dest 
)

◆ getAttribute() [4/7]

void igl::xml::serialization_xml::getAttribute ( const char *  src,
float &  dest 
)

◆ getAttribute() [5/7]

void igl::xml::serialization_xml::getAttribute ( const char *  src,
double &  dest 
)

◆ getAttribute() [6/7]

template<typename T >
std::enable_if< std::is_integral< T >::value &&std::is_unsigned< T >::value >::type igl::xml::serialization_xml::getAttribute ( const char *  src,
T &  dest 
)

◆ getAttribute() [7/7]

template<typename T >
std::enable_if< std::is_integral< T >::value &&!std::is_unsigned< T >::value >::type igl::xml::serialization_xml::getAttribute ( const char *  src,
T &  dest 
)

◆ replaceSubString()

void igl::xml::serialization_xml::replaceSubString ( std::string &  str,
const std::string &  search,
const std::string &  replace 
)

◆ encodeXMLElementName()

void igl::xml::serialization_xml::encodeXMLElementName ( std::string &  name)

◆ decodeXMLElementName()

void igl::xml::serialization_xml::decodeXMLElementName ( std::string &  name)

◆ base64_encode()

std::string igl::xml::serialization_xml::base64_encode ( unsigned char const *  bytes_to_encode,
unsigned int  in_len 
)

◆ base64_decode()

std::string igl::xml::serialization_xml::base64_decode ( std::string const &  encoded_string)