I'm confused. Is displayHeaders() static? If so, why can you access non-static members? If not, Why is the call static-like?
And your comments don't make sense. Why are you calling an object1 function in an overloaded operator<< that takes an object_2?
Data passed by reference can't go out of scope in a single-threaded program. If you passed a reference to something, that something will be there for the duration of the function unless you do something very stupid like delete &reference (it's stupid because the reference could point to stack data).