1 | <?php |
||
15 | class ShipButler |
||
16 | { |
||
17 | |||
18 | /** |
||
19 | * Get the containers namespace value from the containers config file |
||
20 | * |
||
21 | * @return string |
||
22 | */ |
||
23 | public function getContainersNamespace() |
||
27 | |||
28 | /** |
||
29 | * Get the containers names |
||
30 | * |
||
31 | * @return array |
||
32 | */ |
||
33 | public function getContainersNames() |
||
43 | |||
44 | /** |
||
45 | * Get the port folders names |
||
46 | * |
||
47 | * @return array |
||
48 | */ |
||
49 | public function getShipFoldersNames() |
||
59 | |||
60 | /** |
||
61 | * get containers directories paths |
||
62 | * |
||
63 | * @return mixed |
||
64 | */ |
||
65 | public function getContainersPaths() |
||
69 | |||
70 | /** |
||
71 | * @return mixed |
||
72 | */ |
||
73 | public function getShipPath() |
||
77 | |||
78 | /** |
||
79 | * build and return an object of a class from its file path |
||
80 | * |
||
81 | * @param $filePathName |
||
82 | * |
||
83 | * @return mixed |
||
84 | */ |
||
85 | public function getClassObjectFromFile($filePathName) |
||
93 | |||
94 | /** |
||
95 | * get the full name (name \ namespace) of a class from its file path |
||
96 | * result example: (string) "I\Am\The\Namespace\Of\This\Class" |
||
97 | * |
||
98 | * @param $filePathName |
||
99 | * |
||
100 | * @return string |
||
101 | */ |
||
102 | public function getClassFullNameFromFile($filePathName) |
||
106 | |||
107 | /** |
||
108 | * get the class namespace form file path using token |
||
109 | * |
||
110 | * @param $filePathName |
||
111 | * |
||
112 | * @return null|string |
||
113 | */ |
||
114 | protected function getClassNamespaceFromFile($filePathName) |
||
145 | |||
146 | /** |
||
147 | * get the class name form file path using token |
||
148 | * |
||
149 | * @param $filePathName |
||
150 | * |
||
151 | * @return mixed |
||
152 | */ |
||
153 | protected function getClassNameFromFile($filePathName) |
||
173 | |||
174 | /** |
||
175 | * check if a word starts with another word |
||
176 | * |
||
177 | * @param $word |
||
178 | * @param $startsWith |
||
179 | * |
||
180 | * @return bool |
||
181 | */ |
||
182 | public function stringStartsWith($word, $startsWith) |
||
186 | |||
187 | } |
||
188 |