public function getResource($identifier)
    {
        /** @var ClientEntity $client */
        $client = $this->getRepository()->findOneBy(array('id' => $identifier));
        if (!$client) {
            throw new NotFoundHttpException(
                $this->translator->trans('error.client_not_found', array('%id%' => $identifier))
            );
        }

        return $this->createResourceFromClient($client);
    }
public function getResource($identifier)
    {
        /** @var ClientEntity $client */
        $client = $this->getRepository()->findOneBy(array('id' => $identifier));
        if (!$client) {
            throw new NotFoundHttpException(
                $this->translator->trans('error.client_not_found', array('%id%' => $identifier))
            );
        }

        return $this->createResourceFromClient($client);
    }
public function getResource ( $ identifier ) { /** @var ClientEntity $client */ $ client = $ this -> getRepository ( ) -> findOneBy ( array ( 'id' => $ identifier ) ) ; if ( ! $ client ) { throw new NotFoundHttpException ( $ this -> translator -> trans ( 'error.client_not_found' , array ( '%id%' => $ identifier ) ) ) ; } return $ this -> createResourceFromClient ( $ client ) ; }
Returns the oAuth2 Client with the given identifier.

@param string|integer $identifier

@throws NotFoundHttpException if the client could not be found.

@return Resource
Returns the oAuth2 Client with the given identifier .