1 | <?php |
||
22 | abstract class AbstractPostArchiveAction extends Controller |
||
23 | { |
||
24 | /** |
||
25 | * @var BlogInterface |
||
26 | */ |
||
27 | private $blog; |
||
28 | |||
29 | /** |
||
30 | * @var PostManagerInterface |
||
31 | */ |
||
32 | private $postManager; |
||
33 | |||
34 | /** |
||
35 | * @var TranslatorInterface |
||
36 | */ |
||
37 | private $translator; |
||
38 | |||
39 | /** |
||
40 | * @var SeoPageInterface|null |
||
41 | */ |
||
42 | private $seoPage; |
||
43 | |||
44 | public function __construct(BlogInterface $blog, PostManagerInterface $postManager, TranslatorInterface $translator) |
||
50 | |||
51 | /** |
||
52 | * @internal |
||
53 | * |
||
54 | * NEXT_MAJOR: make this method protected |
||
55 | * |
||
56 | * @return Response |
||
57 | */ |
||
58 | final public function renderArchive(Request $request, array $criteria = [], array $parameters = []) |
||
85 | |||
86 | /** |
||
87 | * @param null|SeoPageInterface $seoPage |
||
88 | */ |
||
89 | public function setSeoPage(SeoPageInterface $seoPage = null) |
||
93 | |||
94 | /** |
||
95 | * @param string $id |
||
96 | * @param string|null $domain |
||
97 | * @param string|null $locale |
||
98 | * |
||
99 | * @return string |
||
100 | */ |
||
101 | final protected function trans($id, array $parameters = [], $domain = 'SonataNewsBundle', $locale = null) |
||
105 | |||
106 | /** |
||
107 | * @return BlogInterface |
||
108 | */ |
||
109 | final protected function getBlog() |
||
113 | |||
114 | /** |
||
115 | * @return null|SeoPageInterface |
||
116 | */ |
||
117 | final protected function getSeoPage() |
||
121 | |||
122 | /** |
||
123 | * @return PostManagerInterface |
||
124 | */ |
||
125 | final protected function getPostManager() |
||
129 | } |
||
130 |