for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Drupal\graphql\GraphQL\Visitors;
use Drupal\Core\Cache\RefinableCacheableDependencyInterface;
use GraphQL\Language\AST\OperationDefinition;
use GraphQL\Validator\ValidationContext;
class CacheMetadataCalculator {
/**
* @var \Drupal\Core\Cache\RefinableCacheableDependencyInterface
*/
protected $metadata;
* CacheMetadataCalculator constructor.
*
* @param \Drupal\Core\Cache\RefinableCacheableDependencyInterface $metadata
public function __construct(RefinableCacheableDependencyInterface $metadata) {
$this->metadata = $metadata;
}
* {@inheritdoc}
public function calculate(OperationDefinition $definition, ValidationContext $context, \ArrayObject $variables, \ArrayObject $structure) {
$definition
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.
$context
$variables
$structure
// TODO: Calculate cache metadata.
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.