Exceptions in PHP - Try/Catch or set_exception_handler?

后端 未结 3 1240
刺人心
刺人心 2020-12-23 10:29

I\'m developing some lower end code in my system that uses multiple child classes of the php exception class. Essentially I have the exceptions broken up to a few categorie

3条回答
  •  天命终不由人
    2020-12-23 11:16

    There's more specific information about PHP's "callbacks" here. To use a static method, the callback is something like

    
    

    To use a method from an instantiated object, it's:

    
    

    And to use a global function, it's just:

    
    

提交回复
热议问题