How to access parent class/object?

From: Adrian Hoe (byhoe_at_greenlime.com)
Date: 03/25/05


Date: 24 Mar 2005 22:57:10 -0800

Hi,

I have the following codes (abbreviated):

package A is
   type A_Object is tagged private;
...
end A;

package B is
   type B_Object is new A_Object with private;
...
end B;

package C is
   type C_Object is new B_Object with private;
...
end C;

package D is
   type D_Object is new C_Object with private;
...
end D;

Now, I have the following declaration:

My_D_Object is D.D_Object;

How can I reference the parent objects?

procedure Process_C (C_Obj : access C_Object);
procedure Process_D (D_Obj : access D_Object);

How can I pass C_Object and D_Object into Process_C and Process_D
respectively given only My_D_Object is D.D_Object?

Thanks.

--
Adrian Hoe


Relevant Pages

  • Re: call java from c++: where to put class
    ... I removed "package Jni.test;" in the Demo.java and ... compile it again, and it works. ... When the c++ codes run, a DOS console poped up, and the words like this ... We have created an error report that you can send to us...." ...
    (comp.lang.java.programmer)
  • Re: Providing a limited telephone service to tenants?
    ... geographic and 0800 numbers (which would be included in any package we ... codes and look like USA areas... ... If they were willing to pay say 2p ... so you could maybe provide those at cost, or ask what they want to do ...
    (uk.telecom)
  • Re: Up2date return codes [Summary]
    ... > I'm looking for an exhaustive list of return codes for up2date. ... "There was a package gpg verification error. ... "There was a package gpg verification error." ...
    (RedHat)
  • Re: Http redirects
    ... Then I'd suggest either use Tcllib's htmlparse package or one of the XML DOM ... That will handle 30* redirect codes correctly. ...
    (comp.lang.tcl)
  • Re: Is there any library in common lisp that similar the "telnetlib" in Python.
    ... Telnetlib. ... I am a common lisp newbie and the codes are not ... Why not release it as an ASDF-Install'able package with ...
    (comp.lang.lisp)