uri: add an ostream operator
This commit is contained in:
parent
76842f18ba
commit
1181291852
@ -207,3 +207,11 @@ cruft::operator<< (std::ostream &os, cruft::uri::component c)
|
|||||||
|
|
||||||
unreachable ();
|
unreachable ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
std::ostream&
|
||||||
|
cruft::operator<< (std::ostream &os, cruft::uri const &val)
|
||||||
|
{
|
||||||
|
return os << val.value ();
|
||||||
|
}
|
2
uri.hpp
2
uri.hpp
@ -15,6 +15,7 @@
|
|||||||
#include <array>
|
#include <array>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
|
#include <iosfwd>
|
||||||
|
|
||||||
|
|
||||||
namespace cruft {
|
namespace cruft {
|
||||||
@ -95,6 +96,7 @@ namespace cruft {
|
|||||||
std::string m_value;
|
std::string m_value;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
std::ostream& operator<< (std::ostream&, uri const&);
|
||||||
std::ostream& operator<< (std::ostream&, uri::component);
|
std::ostream& operator<< (std::ostream&, uri::component);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user