Specify the type but not number of function arguments in an interface?

2009-07-03 Thread Doctor J
I want to write an interface that expresses the following idea: "classes implementing this interface must have a void function named update, with a fixed but indeterminate number of parameters of the same (template parameter) type." In other words, some implementing classes will have void updat

Re: Specify the type but not number of function arguments in an interface?

2009-07-03 Thread Jarrett Billingsley
On Fri, Jul 3, 2009 at 2:54 PM, Doctor J wrote: > I want to write an interface that expresses the following idea: "classes > implementing this interface must have a void function named update, with a > fixed but indeterminate number of parameters of the same (template parameter) > type."  In oth

Re: Specify the type but not number of function arguments in an interface?

2009-07-05 Thread downs
Doctor J wrote: > I want to write an interface that expresses the following idea: "classes > implementing this interface must have a void function named update, with a > fixed but indeterminate number of parameters of the same (template parameter) > type." Use a typesafe variadic function, i.e

Re: Specify the type but not number of function arguments in an interface?

2009-07-05 Thread Jarrett Billingsley
On Sun, Jul 5, 2009 at 5:44 AM, downs wrote: > Doctor J wrote: >> I want to write an interface that expresses the following idea: "classes >> implementing this interface must have a void function named update, with a >> fixed but indeterminate number of parameters of the same (template >> parame

Re: Specify the type but not number of function arguments in an interface?

2009-07-07 Thread downs
Jarrett Billingsley wrote: > On Sun, Jul 5, 2009 at 5:44 AM, downs wrote: >> Doctor J wrote: >>> I want to write an interface that expresses the following idea: "classes >>> implementing this interface must have a void function named update, with a >>> fixed but indeterminate number of parameters

Re: Specify the type but not number of function arguments in an interface?

2009-07-07 Thread downs
downs wrote: > Jarrett Billingsley wrote: >> On Sun, Jul 5, 2009 at 5:44 AM, downs wrote: >>> Doctor J wrote: I want to write an interface that expresses the following idea: "classes implementing this interface must have a void function named update, with a fixed but indeterminate

Re: Specify the type but not number of function arguments in an interface?

2009-07-07 Thread Jarrett Billingsley
On Tue, Jul 7, 2009 at 8:29 AM, downs wrote: > > But then isn't what he asks for kinda impossible by design? I mean, > interfaces are bound at runtime. That's what they _do_. > Now read *my* post, downs. ;)

Re: Specify the type but not number of function arguments in an interface?

2009-07-08 Thread downs
Jarrett Billingsley wrote: > On Tue, Jul 7, 2009 at 8:29 AM, downs wrote: >> But then isn't what he asks for kinda impossible by design? I mean, >> interfaces are bound at runtime. That's what they _do_. >> > > Now read *my* post, downs. ;) :blushes: