1 | <?php |
||
29 | class Route extends FieldPluginBase implements ContainerFactoryPluginInterface { |
||
30 | |||
31 | /** |
||
32 | * The path validator service. |
||
33 | * |
||
34 | * @var \Drupal\Core\Path\PathValidatorInterface |
||
35 | */ |
||
36 | protected $pathValidator; |
||
37 | |||
38 | /** |
||
39 | * The language negotiator service. |
||
40 | * |
||
41 | * @var \Drupal\language\LanguageNegotiator |
||
42 | */ |
||
43 | protected $languageNegotiator; |
||
44 | |||
45 | /** |
||
46 | * {@inheritdoc} |
||
47 | */ |
||
48 | public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { |
||
49 | return new static( |
||
50 | $configuration, |
||
51 | $plugin_id, |
||
52 | $plugin_definition, |
||
53 | $container->get('path.validator'), |
||
54 | $container->has('language_negotiator') ? $container->get('language_negotiator') : NULL |
||
55 | ); |
||
56 | } |
||
57 | |||
58 | /** |
||
59 | * Route constructor. |
||
60 | * |
||
61 | * @param array $configuration |
||
62 | * The plugin configuration. |
||
63 | * @param string $pluginId |
||
64 | * The plugin id. |
||
65 | * @param mixed $pluginDefinition |
||
66 | * The plugin definition. |
||
67 | * @param \Drupal\Core\Path\PathValidatorInterface $pathValidator |
||
68 | * The path validator service. |
||
69 | * @param \Drupal\language\LanguageNegotiator|null $languageNegotiator |
||
70 | * The language negotiator. |
||
71 | */ |
||
72 | public function __construct( |
||
83 | |||
84 | /** |
||
85 | * {@inheritdoc} |
||
86 | */ |
||
87 | public function resolveValues($value, array $args, ResolveContext $context, ResolveInfo $info) { |
||
104 | |||
105 | } |
||
106 |