Skip to content
Snippets Groups Projects
Commit 420c955d authored by Jan Trávníček's avatar Jan Trávníček
Browse files

add const ref in compose argument

parent 4c5bd818
No related branches found
No related tags found
No related merge requests found
......@@ -68,7 +68,7 @@ void String::compose(ext::deque<sax::Token>& out) const {
compose(out, this->getData());
}
 
void String::compose(ext::deque<sax::Token>& out, std::string primitive) {
void String::compose(ext::deque<sax::Token>& out, const std::string & primitive) {
out.emplace_back(primitive::String::getXmlTagName(), sax::Token::TokenType::START_ELEMENT);
out.emplace_back(primitive, sax::Token::TokenType::CHARACTER);
out.emplace_back(primitive::String::getXmlTagName(), sax::Token::TokenType::END_ELEMENT);
......@@ -95,7 +95,7 @@ std::string xmlApi<std::string>::xmlTagName() {
return primitive::String::getXmlTagName();
}
 
void xmlApi<std::string>::compose(ext::deque<sax::Token>& output, std::string data) {
void xmlApi<std::string>::compose(ext::deque<sax::Token>& output, const std::string & data) {
primitive::String::compose(output, data);
}
 
......
......@@ -66,7 +66,7 @@ public:
static std::string parseRaw ( ext::deque < sax::Token >::iterator & input );
 
void compose ( ext::deque < sax::Token > & out ) const;
static void compose ( ext::deque < sax::Token > & out, std::string primitive );
static void compose ( ext::deque < sax::Token > & out, const std::string & primitive );
 
virtual PrimitiveBase * inc ( ) &&;
 
......@@ -86,7 +86,7 @@ struct xmlApi < std::string > {
static std::string parse ( ext::deque < sax::Token >::iterator & input );
static bool first ( const ext::deque < sax::Token >::const_iterator & input );
static std::string xmlTagName ( );
static void compose ( ext::deque < sax::Token > & output, std::string data );
static void compose ( ext::deque < sax::Token > & output, const std::string & data );
};
 
} /* namespace alib */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment