PluginProbe ʕ •ᴥ•ʔ
Admin Columns / 7.0.13
Admin Columns v7.0.13
7.0.19 2.3.5 2.4 2.4.1 2.4.10 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 2.4.7 2.4.8 2.4.9 2.5.2 2.5.3 2.5.4 2.5.5 2.5.6 2.5.6.1 2.5.6.2 2.5.6.3 2.5.6.4 3.0 3.0.1 3.0.2 3.0.3 3.0.5 3.0.7 3.1 3.1.1 3.1.10 3.1.2 3.1.3 3.1.5 3.2.3 3.2.7 3.3.1 3.4.1 3.4.6 3.4.8 4.0.1 4.0.3 4.1.6 4.2.2 4.2.5 4.3 4.3.2 4.4.1 4.4.4 4.4.5 4.5.5 4.6.1 4.7.18 4.7.19 4.7.20 4.7.7 7.0.13 7.0.14 7.0.16 trunk 1.0 1.1 1.1.3 1.2 1.2.1 1.3 1.3.1 1.4 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.5.1 1.4.6 1.4.6.1 1.4.6.2 1.4.6.3 1.4.6.4 1.4.7 1.4.8 1.4.9 2.0.0 2.0.1 2.0.2 2.0.3 2.1.0 2.1.1 2.1.2 2.1.3 2.1.4 2.1.5 2.2 2.2.1 2.2.1.1 2.2.2 2.2.3 2.2.4 2.2.5 2.2.5.1 2.2.6 2.2.6.1 2.2.6.2 2.2.6.3 2.2.6.4 2.2.7 2.2.8 2.2.8.1 2.2.9 2.3.1 2.3.2 2.3.3
codepress-admin-columns / classes / Column / Base.php
codepress-admin-columns / classes / Column Last commit date
Base.php 3 months ago BaseColumnFactory.php 3 months ago ColumnFactory.php 3 months ago ColumnIdGenerator.php 3 months ago ColumnLabelTrait.php 3 months ago Context.php 3 months ago CustomFieldContext.php 3 months ago GroupTrait.php 3 months ago LabelEncoder.php 3 months ago SettingUpdater.php 3 months ago
Base.php
97 lines
1 <?php
2
3 declare(strict_types=1);
4
5 namespace AC\Column;
6
7 use AC\Column;
8 use AC\FormatterCollection;
9 use AC\Setting\Component;
10 use AC\Setting\ComponentCollection;
11 use AC\Type\ColumnId;
12
13 class Base implements Column
14 {
15
16 protected string $type;
17
18 protected string $label;
19
20 protected ComponentCollection $settings;
21
22 private ColumnId $id;
23
24 private Context $context;
25
26 private FormatterCollection $formatters;
27
28 protected string $group;
29
30 protected ?string $description;
31
32 public function __construct(
33 string $type,
34 string $label,
35 ComponentCollection $settings,
36 ColumnId $id,
37 Context $context,
38 ?FormatterCollection $formatters = null,
39 ?string $group = null,
40 ?string $description = null
41 ) {
42 $this->type = $type;
43 $this->label = $label;
44 $this->settings = $settings;
45 $this->context = $context;
46 $this->id = $id;
47 $this->formatters = $formatters ?? new FormatterCollection();
48 $this->group = $group ?? 'custom';
49 $this->description = $description;
50 }
51
52 public function get_type(): string
53 {
54 return $this->type;
55 }
56
57 public function get_id(): ColumnId
58 {
59 return $this->id;
60 }
61
62 public function get_label(): string
63 {
64 return $this->label;
65 }
66
67 public function get_group(): string
68 {
69 return $this->group;
70 }
71
72 public function get_description(): ?string
73 {
74 return $this->description;
75 }
76
77 public function get_settings(): ComponentCollection
78 {
79 return $this->settings;
80 }
81
82 public function get_formatters(): FormatterCollection
83 {
84 return $this->formatters;
85 }
86
87 public function get_setting(string $name): ?Component
88 {
89 return $this->settings->find($name);
90 }
91
92 public function get_context(): Context
93 {
94 return $this->context;
95 }
96
97 }