Bolt\Storage\Query\ContentQueryParser::getOperation PHP Method

getOperation() public method

Returns the parsed operation.
public getOperation ( ) : string
return string
    public function getOperation()
    {
        return $this->operation;
    }

Usage Example

Example #1
0
 public function testDirectiveParsing()
 {
     $app = $this->getApp();
     $qb = new ContentQueryParser($app['storage'], $app['query.select']);
     $qb->setQuery('entries');
     $qb->setParameters(['order' => '-datepublish', 'id' => '!1']);
     $qb->parse();
     $this->assertEquals(['entries'], $qb->getContentTypes());
     $this->assertEquals('select', $qb->getOperation());
     $this->assertEquals('-datepublish', $qb->getDirective('order'));
     $this->assertEquals('!1', $qb->getParameter('id'));
     $this->assertEquals(1, count($qb->getParameters()));
 }
All Usage Examples Of Bolt\Storage\Query\ContentQueryParser::getOperation