1 | <?php namespace BestServedCold\PhalueObjects; |
||
3 | class File extends ValueObject |
||
4 | { |
||
5 | /** |
||
6 | * @return bool |
||
7 | */ |
||
8 | public function exists() |
||
12 | |||
13 | /** |
||
14 | * @return string |
||
15 | */ |
||
16 | public function getContents() |
||
20 | |||
21 | /** |
||
22 | * @return string |
||
23 | */ |
||
24 | public function getExtension() |
||
28 | |||
29 | /** |
||
30 | * @return string |
||
31 | */ |
||
32 | public function getDirectoryName() |
||
36 | |||
37 | /** |
||
38 | * @return string |
||
39 | */ |
||
40 | public function getFileName() |
||
44 | |||
45 | /** |
||
46 | * @param string $string |
||
47 | */ |
||
48 | public static function fromString($string) |
||
52 | |||
53 | public static function fromUrl($url) |
||
57 | } |
||
58 |
This check examines a number of code elements and verifies that they conform to the given naming conventions.
You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods.