protected function ensureAnnotationsAreValid(array $annotations, $annotation_name)
	{
		foreach ( $annotations as $annotation ) {
			if ( !$annotation->isValid() ) {
				throw new PageUrlMatcherException(
					'The "' . $annotation_name . '" annotation is not valid.',
					PageUrlMatcherException::TYPE_INVALID_ANNOTATION
				);
			}
		}
	}