use of php.runtime.env.handler.TickHandler in project jphp by jphp-compiler.
the class Environment method __tick.
/**
*** UTILS ****
*/
public void __tick(TraceInfo trace, ArrayMemory locals) {
TickHandler tickHandler = scope.getTickHandler();
if (tickHandler != null) {
IObject $this = this.getLateObject();
if ($this != null) {
Memory value = ObjectMemory.valueOf($this);
if ($this instanceof Closure) {
value = ((Closure) $this).getSelf();
}
if (value.isObject()) {
locals.putAsKeyString("this", value);
}
}
tickHandler.onTick(this, trace, locals);
}
}
Aggregations