We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I use php-di make my framework , and i integration the Ray.Aop to get aop feature.
bose the php-di and ray.aop need call the function or method in the end.
php-di
ray.aop
the ray.aop produce new php souce code ,then call it.
so i use php-di call the new code.
code like
$bind = (new Bind())->bind($handler[0], $this->container->get('pointCut')); if ($bind->getBindings()) { $compiler = new Weaver($bind, TMP_DIR); $handler[0] = $compiler->weave($handler[0]); } // ray.aop need set bindings,but i don`t want edit the ray.aop source code to inject property $instance = $this->container->get($handler[0]); $instance->bindings = $bind->getBindings(); $body = call_user_func_array([$instance, $handler[1]], [$vars]); // so i get object use php-di container,and call it use call_user_func_array // $body = $this->container->call($handler, [$vars]); if ($body instanceof ServerResponse) { $response = $body; }
it seem work! but I don't know whether there are any problems. and is there any better way?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I use php-di make my framework , and i integration the Ray.Aop to get aop feature.
bose the
php-di
andray.aop
need call the function or method in the end.the
ray.aop
produce new php souce code ,then call it.so i use php-di call the new code.
code like
it seem work!
but I don't know whether there are any problems.
and is there any better way?
The text was updated successfully, but these errors were encountered: