I´ve defined a class like this:
function Class1(){
function Func1(){
/* Methods and vars */
};
Funcs = new Array();
this.appendAction = new function(ArgFunc){
Funcs.push(ArgFunc);
};
};
Object1 = new Class1();
function OutFunc(){
/* Defining commands here */
};
Object1.appendAction(OutFunc);
My question is whether is there a way or not to access the private members of Object1, say Func1(), in the scope of the function OutFunc(), for the sake that this function is now an element of the array Funcs of Object1.
It’s kind of weird, but with minimal change to your code I will do something like that :
But really it’s probably not a good way to solve your problem.