Problems encountered: Phalcon cannot be AOP
For a long while, found that the general PHP implementation of AOP There are 2 ways: 1, with PHP C AOP expansion 2, the existing AOP implementation
But now 2 of the Phalcon are not working,
1,phalcon and AOP expand conflict and give up decisively
2, the existing AOP implementation principle is hack autoloader to generate new classes to implement AOP, but Phalcon to write autoloader to his own C, but also how hack ah
Help!
Update May 20, 2015 12:45:36
There's no way to write an AOP yourself. Use the business layer: Https://github.com/zjsxwc/PhalconAOPForBusinessService
Reply content:
Problems encountered: Phalcon cannot be AOP
For a long while, found that the general PHP implementation of AOP There are 2 ways: 1, with PHP C AOP expansion 2, the existing AOP implementation
But now 2 of the Phalcon are not working,
1,phalcon and AOP expand conflict and give up decisively
2, the existing AOP implementation principle is hack autoloader to generate new classes to implement AOP, but Phalcon to write autoloader to his own C, but also how hack ah
Help!
Update May 20, 2015 12:45:36
There's no way to write an AOP yourself. Use the business layer: Https://github.com/zjsxwc/PhalconAOPForBusinessService
AOP
The so-called face plane?
Python
Genre is probably not used to this setup pattern. Python
There are roughly two ways to achieve similar approaches:
- Adorner (Decorator)
- Meta-Class (Metaclass)
You can use the event mechanism, and you need to bury the dots in the program.