blob: d66bd0289746df37e0603c63415e607049d727f7 [file] [log] [blame]
Mickhail M2d288922015-03-20 16:01:26 +03001<?php
2
3namespace deka6pb\autoparser;
4
5class Module extends \yii\base\Module
6{
7 public $controllerNamespace = 'deka6pb\autoparser\controllers';
8 public $tmpDir = "@runtime/tmp";
9 public $postingCount = 1;
10 public $collectionCount = 1;
11 public $consumers = [];
12 public $providers = [];
13
14 public $collectorService;
15 public $postingService;
16
17 public function init()
18 {
19 parent::init();
20
21 $handler = new components\ApiErrorHandler;
22 \Yii::$app->set('errorHandler', $handler);
23 $handler->register();
24 }
25
26 public function getMaxCountPosting() {
27 return $this->postingCount;
28 }
29
30 public function getMaxCountCollecting() {
31 return $this->collectionCount;
32 }
33
34 public function getConsumers() {
35 return $this->consumers;
36 }
37
38 public function getProviders() {
39 return $this->providers;
40 }
41
42 public function getTmpDir() {
43 return $this->tmpDir;
44 }
45}