1<?php
2
3
4namespace ComboStrap\Meta\Field;
5
6
7use ComboStrap\DataType;
8use ComboStrap\Meta\Api\MetadataWikiPath;
9use ComboStrap\WikiPath;
10
11class AliasPath extends MetadataWikiPath
12{
13
14    public const PERSISTENT_NAME = "path";
15    const PROPERTY_NAME = "alias-path";
16
17    static public function getDescription(): string
18    {
19        return "The path of the alias";
20    }
21
22    static public function getLabel(): string
23    {
24        return "Alias Path";
25    }
26
27    public static function getName(): string
28    {
29        return self::PROPERTY_NAME;
30    }
31
32    public static function getPersistentName(): string
33    {
34        return self::PERSISTENT_NAME;
35    }
36
37
38    static public function getPersistenceType(): string
39    {
40        return DataType::TEXT_TYPE_VALUE;
41    }
42
43    static public function isMutable(): bool
44    {
45        return true;
46    }
47
48    static public function getDrive(): string
49    {
50        return WikiPath::MARKUP_DRIVE;
51    }
52
53
54    public static function createForParent(Aliases $parent): AliasPath
55    {
56        return new AliasPath($parent);
57    }
58}
59