help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Passing some values to the parent class


From: address@hidden
Subject: Passing some values to the parent class
Date: Thu, 21 Jun 2007 13:23:20 -0700
User-agent: G2/1.0

class Base{
   private:
      int i;
      char* c;
   public:
      Base(const int, const char*);
      ...
};
class Derive : virtual public Base{
   private:
      ...
   public:
      Derive(const int x, const char* y){ pass_vars_to_base_class

(x,y);}
   ...
};

The class above shows something I want to do, to pass some values to
the parent class. Can someone please tell me how to do this?

Thanks folks!



reply via email to

[Prev in Thread] Current Thread [Next in Thread]