| Total Complexity | 5 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 7 | class Globals |
||
| 8 | { |
||
| 9 | /** |
||
| 10 | * @var ContainerInterface |
||
| 11 | */ |
||
| 12 | private $container; |
||
| 13 | |||
| 14 | public function __construct(ContainerInterface $container) |
||
| 17 | } |
||
| 18 | |||
| 19 | /** |
||
| 20 | * this method send path on dev mode to correct write package name |
||
| 21 | * @param string $package |
||
| 22 | * @return string |
||
| 23 | */ |
||
| 24 | private function getPackageDevName(string $package) { |
||
| 25 | $bundle = explode("/", $package)[1]; |
||
| 26 | $explode = explode("-", $bundle); |
||
| 27 | |||
| 28 | $package_name = ""; |
||
| 29 | |||
| 30 | foreach ($explode as $string) { |
||
| 31 | $package_name .= ucfirst($string); |
||
| 32 | } |
||
| 33 | |||
| 34 | return $package_name; |
||
| 35 | } |
||
| 36 | |||
| 37 | /** |
||
| 38 | * this method send base bundle path related to ribs-admin |
||
| 39 | * @param string|null $package |
||
| 40 | * @return string |
||
| 41 | */ |
||
| 42 | public function getBaseBundlePath(string $package = "piou-piou/ribs-admin-bundle"): string |
||
| 54 | } |
||
| 55 | } |