public function instantiate($provider)
    {
        if (!$this->supported($provider)) {
            throw new ProviderNotSupportedException($provider);
        }

        $class = $this->providerClass($provider);

        switch ($provider) {
            case 'facebook':
                return new $class($this->config,
                        $this->redirector,
                        $this->http,
                        $this->store,
                        $this->profile,
                        $this->access_token);
            break;

            case 'twitter':
                return new $class($this->config,
                                $this->http,
                                $this->redirector,
                                $this->store,
                                $this->profile,
                                $this->signature,
                                $this->consumer,
                                $this->token,
                                $this->oauth);
            break;
        }
    }
public function instantiate($provider)
    {
        if (!$this->supported($provider)) {
            throw new ProviderNotSupportedException($provider);
        }

        $class = $this->providerClass($provider);

        switch ($provider) {
            case 'facebook':
                return new $class($this->config,
                        $this->redirector,
                        $this->http,
                        $this->store,
                        $this->profile,
                        $this->access_token);
            break;

            case 'twitter':
                return new $class($this->config,
                                $this->http,
                                $this->redirector,
                                $this->store,
                                $this->profile,
                                $this->signature,
                                $this->consumer,
                                $this->token,
                                $this->oauth);
            break;
        }
    }
public function instantiate ( $ provider ) { if ( ! $ this -> supported ( $ provider ) ) { throw new ProviderNotSupportedException ( $ provider ) ; } $ class = $ this -> providerClass ( $ provider ) ; switch ( $ provider ) { case 'facebook' : return new $ class ( $ this -> config , $ this -> redirector , $ this -> http , $ this -> store , $ this -> profile , $ this -> access_token ) ; break ; case 'twitter' : return new $ class ( $ this -> config , $ this -> http , $ this -> redirector , $ this -> store , $ this -> profile , $ this -> signature , $ this -> consumer , $ this -> token , $ this -> oauth ) ; break ; } }
Instantiates and returns a
social provider instance.

@param string $provider

@return Vinelab\Auth\Contracts\ProviderInterface
Instantiates and returns a social provider instance .