[Li Jingshan php] every day laravel-20160904| Dispatcher-4

Source: Internet
Author: User

   /**    * Resolve the subscriber instance.     *    *  @param   object|string   $subscriber      *  @return  mixed    */   protected function  resolvesubscriber ($subscriber)    {       if  (is_ String ($subscriber))  {// check string            return  $this->container->make ($subscriber);// make it        }       return  $subscriber;// then  Subscriber return   }   /**    * fire an  event until the first non-null response is returned.     *    *  @param   string|object   $event     *  @param   array    $payload     *  @return  mixed    */    public function until ($event,  $payload  = [])    {        return  $this->fire ($event,  $payload,  true);// fire  start by event and payload   }   /**     * flush a set of pushed events.    *     *  @param   string   $event     *  @return  void     */   public function flush ($event)    {         $this->fire ($event. ' _pushed ');// fire a string like we want  $event _pushed   }// flush a set of pushed events// flush a  way   /**    * get the event that is  currently firing.    *    *  @return  string     */   public function firing ()    {        return last ($this->firing);    }// use last function


This article is from the "Focus on PHP" blog, please be sure to keep this source http://jingshanls.blog.51cto.com/3357095/1791231

[Li Jingshan php] every day laravel-20160904| Dispatcher-4

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.