Overloading stream insertion without violating information hiding?
- by Chris
I'm using yaml-cpp for a project. I want to overload the << and >> operators for some classes, but I'm having an issue grappling with how to "properly" do this. Take the Note class, for example. It's fairly boring:
class Note {
public:
// constructors
Note( void );
~Note( void );
// public accessor methods
void…