Skip to content
This repository has been archived by the owner on Aug 5, 2022. It is now read-only.

Commit

Permalink
Merge pull request #151 from krocard/document_XmlSerializingContext
Browse files Browse the repository at this point in the history
Clarify XmlSerializingContext usage.

The XmlSerializingContext usage was not very clear.

Add a doxygen for the class XmlSerializingContext and remove an unused
function that contradict with the recommended usage.
  • Loading branch information
dawagner committed Jul 22, 2015
2 parents 9c54ad6 + 33365d2 commit e077acf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
5 changes: 0 additions & 5 deletions xmlserializer/XmlSerializingContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,6 @@ void CXmlSerializingContext::appendLineToError(const std::string& strAppend)
_strError += "\n" + strAppend;
}

const std::string& CXmlSerializingContext::getError() const
{
return _strError;
}

void CXmlSerializingContext::genericErrorHandler(void* userData, const char* format, ...)
{
char *buffer = NULL;
Expand Down
11 changes: 10 additions & 1 deletion xmlserializer/XmlSerializingContext.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,16 @@

#include <string>

/** Class that gather errors during serialization.
*
* Provided with an initial empty buffer (strError), an instance of this class
* can describe an error.
*
* This error will be accessible formated in the aforementioned buffer
* _after_ destruction.
* Ie. the provided buffer (strError) is in an undefined state between
* construction and destruction and should not be accessed in between.
*/
class CXmlSerializingContext
{
public:
Expand All @@ -40,7 +50,6 @@ class CXmlSerializingContext
// Error
void setError(const std::string& strError);
void appendLineToError(const std::string& strAppend);
const std::string& getError() const;
/** XML error handler
*
* @param[in] userData pointer to the serializing context
Expand Down

0 comments on commit e077acf

Please sign in to comment.