protected function createRequestObject($objectType)
    {
        $repository = $this->getRepository();

        switch ($objectType) {
            case 'SessionInput':
                $this->requestObject = new SessionInput();
                break;
            case 'ContentTypeGroupCreateStruct':
                $this->requestObject = $repository
                    ->getContentTypeService()
                    ->newContentTypeGroupCreateStruct('identifier');
                break;

            case 'ContentTypeGroupUpdateStruct':
                $this->requestObject = $repository
                    ->getContentTypeService()
                    ->newContentTypeGroupUpdateStruct();
                break;

            case 'ViewInput':
                $this->requestObject = new ViewInput();
                break;

            default:
                throw new InvalidArgumentException($objectType, 'type is not defined yet');
        }
    }
protected function createRequestObject($objectType)
    {
        $repository = $this->getRepository();

        switch ($objectType) {
            case 'SessionInput':
                $this->requestObject = new SessionInput();
                break;
            case 'ContentTypeGroupCreateStruct':
                $this->requestObject = $repository
                    ->getContentTypeService()
                    ->newContentTypeGroupCreateStruct('identifier');
                break;

            case 'ContentTypeGroupUpdateStruct':
                $this->requestObject = $repository
                    ->getContentTypeService()
                    ->newContentTypeGroupUpdateStruct();
                break;

            case 'ViewInput':
                $this->requestObject = new ViewInput();
                break;

            default:
                throw new InvalidArgumentException($objectType, 'type is not defined yet');
        }
    }
protected function createRequestObject ( $ objectType ) { $ repository = $ this -> getRepository ( ) ; switch ( $ objectType ) { case 'SessionInput' : $ this -> requestObject = new SessionInput ( ) ; break ; case 'ContentTypeGroupCreateStruct' : $ this -> requestObject = $ repository -> getContentTypeService ( ) -> newContentTypeGroupCreateStruct ( 'identifier' ) ; break ; case 'ContentTypeGroupUpdateStruct' : $ this -> requestObject = $ repository -> getContentTypeService ( ) -> newContentTypeGroupUpdateStruct ( ) ; break ; case 'ViewInput' : $ this -> requestObject = new ViewInput ( ) ; break ; default : throw new InvalidArgumentException ( $ objectType , 'type is not defined yet' ) ; } }
Create an object of the specified type.

@param string $objectType the name of the object to be created

@throws \Behat\Behat\Exception\PendingException When the object requested is not implemented yet
Create an object of the specified type .