admin wrote:
Jochem Maas wrote:
...
the 'callback' type has a number of forms:
'myFunc'
array('className', 'myMeth')
array(self, 'myMeth')
array(parent, 'myMeth')
array($object, 'myMeth')
self and parent adhere to the same 'context' rules when used in
call_user_func*()
as when you
Jochem Maas wrote:
admin wrote:
Jochem Maas wrote:
...
the 'callback' type has a number of forms:
'myFunc'
array('className', 'myMeth')
array(self, 'myMeth')
array(parent, 'myMeth')
array($object, 'myMeth')
self and parent adhere to the same 'context' rules when used in
call_user_func*()
Inside the body of method foo() you can of course use syntax like
parent::foo(). But is there a way to call the parent version of
obj-foo() outside the class? That kind of syntax is allowed in C++, for
example: Aclass a; if (a.Aparent::foo()) ...;
Some contrived example to illustrate the point:
admin wrote:
Inside the body of method foo() you can of course use syntax like
parent::foo(). But is there a way to call the parent version of
obj-foo() outside the class? That kind of syntax is allowed in C++, for
example: Aclass a; if (a.Aparent::foo()) ...;
there is nothing in the language
admin wrote:
Inside the body of method foo() you can of course use syntax like
parent::foo(). But is there a way to call the parent version of
obj-foo() outside the class? That kind of syntax is allowed in C++, for
example: Aclass a; if (a.Aparent::foo()) ...;
Not sure I get your requirement
admin wrote:
Inside the body of method foo() you can of course use syntax like
parent::foo(). But is there a way to call the parent version of
obj-foo() outside the class? That kind of syntax is allowed in C++, for
example: Aclass a; if (a.Aparent::foo()) ...;
Some contrived example to
Jim Lucas wrote:
admin wrote:
Inside the body of method foo() you can of course use syntax like
parent::foo(). But is there a way to call the parent version of
obj-foo() outside the class? That kind of syntax is allowed in C++, for
example: Aclass a; if (a.Aparent::foo()) ...;
Some
Jochem Maas wrote:
another solution for the OP might be (although I think it goes against all
design principles):
class A {
function foo() {
echo achoo\n;
}
}
class B extends A {
function foo() {
echo cough\n;
}
function __call($meth, $args) {
$func = array(parent,
admin wrote:
Jochem Maas wrote:
another solution for the OP might be (although I think it goes against
all
design principles):
class A {
function foo() {
echo achoo\n;
}
}
class B extends A {
function foo() {
echo cough\n;
}
function __call($meth, $args) {
Jochem Maas wrote:
admin wrote:
Jochem Maas wrote:
another solution for the OP might be (although I think it goes against
all
design principles):
class A {
function foo() {
echo achoo\n;
}
}
class B extends A {
function foo() {
echo cough\n;
}
function __call($meth, $args)
10 matches
Mail list logo