My boss regards himself as a OOP Guru where as I consider him as a hobbyist programmer. He handles our Sage development, adding custom requirements to our clients Sage installations. He recently has got very excited by reflection, he is reflecting on Sage's assemblies in code and changing private members and event handlers. I thought this was not a good idea but he shot me down stating that Sage thought he was amazing that he could do it. I believed that this was bad practice because it was inefficient and because if they change their implementation at any point our code could collapse. I mean usually a developer has made something private for a reason right?
What's the general rule regarding this?
Many Thanks and apologies if this seems like a stupid question.
Paul
You are right. If you depend on implementation details of 3rd party library, you better be ready to rewrite everything when 3rd party library is updated and for the unexpected side effects when you change some private variable with some "innocent" value.
The answer is do it only if you 100% sure in what you are doing and you a ready to face the consequences.