Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
accessing data of a class from a method of another class
I am facing a problem in C++......not facing the same problem when I use C.
In my project there is a class VoiceChannel....there is a variable
In a class EventHandler, an object of VoiceChannel,say, VC has been created and by calling some built-in functions VC->ani has been set some value.
Now,what I want is to use that value(VC->ani) from a method of InboundChannel Class which is a subclass of VoiceChannel.
If I use C then it is possible to store that value in a stucture
and use it as needed.But what can I do in the context of C++?
Thanks in advance
0 · ·