133 #ifndef OPENTXS_CORE_CRYPTO_OTASCIIARMOR_HPP
134 #define OPENTXS_CORE_CRYPTO_OTASCIIARMOR_HPP
136 #include "../OTString.hpp"
153 typedef std::map<int64_t, OTASCIIArmor*>
mapOfArmor;
186 EXPORT OTASCIIArmor&
operator=(
const char* szValue);
189 EXPORT OTASCIIArmor&
operator=(
const OTASCIIArmor& strValue);
208 OTASCIIArmor& ascArmor,
const OTString& strInput,
209 std::string str_bookend =
"-----BEGIN");
220 std::string str_override =
228 std::string str_type,
230 bool bEscaped =
false)
const;
237 std::string str_type,
240 bool bEscaped =
false)
const;
247 EXPORT
bool GetData(
OTData& theData,
bool bLineBreaks =
true)
const;
249 bool bLineBreaks =
true)
const;
254 EXPORT
bool SetData(
const OTData& theData,
bool bLineBreaks =
true);
262 bool bLineBreaks =
true)
const;
269 bool bLineBreaks =
true);
271 EXPORT
bool GetStringMap(std::map<std::string, std::string>& the_map,
272 bool bLineBreaks =
true)
const;
274 std::map<std::string, std::string>& the_map,
275 bool bLineBreaks =
true)
const;
277 EXPORT
bool SetStringMap(
const std::map<std::string, std::string>& the_map,
278 bool bLineBreaks =
true);
280 const std::map<std::string, std::string>& the_map,
281 bool bLineBreaks =
true);
284 static std::unique_ptr<OTDB::OTPacker> s_pPacker;
289 #endif // OPENTXS_CORE_CRYPTO_OTASCIIARMOR_HPP
EXPORT bool LoadFromExactPath(const std::string &filename)
EXPORT bool SetAndPackString(const OTString &theData, bool bLineBreaks=true)
const char * OT_BEGIN_ARMORED_escaped
const char * OT_BEGIN_SIGNED_escaped
EXPORT bool GetAndUnpackStringMap(std::map< std::string, std::string > &the_map, bool bLineBreaks=true) const
virtual EXPORT ~OTASCIIArmor()
const char * OT_END_ARMORED
EXPORT bool GetStringMap(std::map< std::string, std::string > &the_map, bool bLineBreaks=true) const
const char * OT_END_ARMORED_escaped
EXPORT bool WriteArmoredString(OTString &strOutput, const std::string str_type, bool bEscaped=false) const
EXPORT bool SetString(const OTString &theData, bool bLineBreaks=true)
static EXPORT bool LoadFromString(OTASCIIArmor &ascArmor, const OTString &strInput, std::string str_bookend="-----BEGIN")
EXPORT bool LoadFromFile(const OTString &foldername, const OTString &filename)
EXPORT bool SaveToExactPath(const std::string &filename)
EXPORT bool SetAndPackData(const OTData &theData, bool bLineBreaks=true)
EXPORT OTASCIIArmor & operator=(const char *szValue)
EXPORT bool SaveTo_ofstream(std::ofstream &fout)
EXPORT bool GetAndUnpackData(OTData &theData, bool bLineBreaks=true) const
const char * OT_BEGIN_SIGNED
EXPORT bool LoadFrom_ifstream(std::ifstream &fin)
static OTDB::OTPacker * GetPacker()
EXPORT bool GetData(OTData &theData, bool bLineBreaks=true) const
EXPORT bool WriteArmoredFile(const OTString &foldername, const OTString &filename, const std::string str_type, bool bEscaped=false) const
std::map< int64_t, OTASCIIArmor * > mapOfArmor
EXPORT bool SetData(const OTData &theData, bool bLineBreaks=true)
EXPORT bool GetString(OTString &theData, bool bLineBreaks=true) const
EXPORT bool SetStringMap(const std::map< std::string, std::string > &the_map, bool bLineBreaks=true)
EXPORT bool GetAndUnpackString(OTString &theData, bool bLineBreaks=true) const
const char * OT_BEGIN_ARMORED
EXPORT bool SetAndPackStringMap(const std::map< std::string, std::string > &the_map, bool bLineBreaks=true)