1
This commit is contained in:
parent
923b076d57
commit
64b7d5ad26
@ -298,6 +298,13 @@ namespace a8
|
|||||||
return ReadFromJsonString(sl.Text());
|
return ReadFromJsonString(sl.Text());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool XObject::ReadFromJsonFile(const std::string& filename)
|
||||||
|
{
|
||||||
|
a8::StringList sl;
|
||||||
|
sl.LoadFromFile(filename.c_str());
|
||||||
|
return ReadFromJsonString(sl.Text());
|
||||||
|
}
|
||||||
|
|
||||||
bool XObject::ReadFromJsonString(const std::string& json_data)
|
bool XObject::ReadFromJsonString(const std::string& json_data)
|
||||||
{
|
{
|
||||||
Json::Reader reader;
|
Json::Reader reader;
|
||||||
|
@ -44,6 +44,7 @@ namespace a8
|
|||||||
a8::XObject& Move(a8::XObject& a);
|
a8::XObject& Move(a8::XObject& a);
|
||||||
|
|
||||||
bool ReadFromFile(const std::string& filename);
|
bool ReadFromFile(const std::string& filename);
|
||||||
|
bool ReadFromJsonFile(const std::string& filename);
|
||||||
bool ReadFromJsonString(const std::string& jsondata);
|
bool ReadFromJsonString(const std::string& jsondata);
|
||||||
bool ReadFromXmlFile(const std::string& filename);
|
bool ReadFromXmlFile(const std::string& filename);
|
||||||
bool ReadFromXmlString(const std::string& xmldata);
|
bool ReadFromXmlString(const std::string& xmldata);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user