1: <?php
2:
3: namespace PHPixie\Route\Translator;
4:
5: class Target
6: {
7: protected $translator;
8: protected $resolverPath;
9:
10: public function __construct($translator, $resolverPath)
11: {
12: $this->translator = $translator;
13: $this->resolverPath = $resolverPath;
14: }
15:
16: public function resolverPath()
17: {
18: return $this->resolverPath;
19: }
20:
21: public function path($attributes = array())
22: {
23: return $this->translator->generatePath($this->resolverPath, $attributes);
24: }
25:
26: public function uri($attributes = array(), $withHost = false, $serverRequest = null)
27: {
28: return $this->translator->generateUri($this->resolverPath, $attributes, $withHost, $serverRequest);
29: }
30: }