Iām trying to understand about the closure class, the manual is, Everything is in the manual Link ,
Closing :: __ The construct is a constructor that prohibits instantiation. If I understand correctly, the only instance of this class is to assign an anonymous function variable.
But I did not understand a few lines:
Closure :: bind . Duplicates a closure with a specific related object and class scope.
Closure :: bindTo . Duplicates a closure using a new related object and scope.
And the last in the guide, I did not understand this sentence:
Besides the methods listed here, this class also has an __invoke method. This is to match other classes that implement calling magic, since this method is not used to call a function.
If someone tries to explain to me what it is, I will be very grateful, Good day.
source
share