var Individual = {
name: "jana",
retrieveName: function(cb) {
cb();
console.log("** "+this.name);
}
}
var additionalIndividual = { name: "prabu"}
I possess 2 entities. I want to link "additionalIndividual" with the Individual
entity and also pass a function as an argument.
I have attempted the following approaches, but they have not produced the desired outcome
Individual.retrieveName.apply(additionalIndividual, function(){})
Individual.retrieveName.apply(additionalIndividual)(function(){})