public function appliesToContext(ContextInterface $context) { if (!$context instanceof PropertyContext) { return false; } $property = $context->getProperty(); if (!preg_match($this->regex, $property->getName())) { return false; } return $this->subRule->appliesToContext($context); }