PluginProbe
Import WP – CSV & XML Import Export for WordPress / trunk
Import WP – CSV & XML Import Export for WordPress vtrunk
2.14.24 2.14.23 2.7.0 2.7.1 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.9.0 2.9.1 trunk 0.1.6 All 142 releases
jc-importer / class / Common / AddonAPI / Exporter / ExporterData.php

ExporterData.php in Import WP – CSV & XML Import Export for WordPress trunk, at class/Common/AddonAPI/Exporter/ExporterData.php

55 lines 999 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace ImportWP\Common\AddonAPI\Exporter;
4
5 class ExporterData
6 {
7 private $_template_type;
8 private $_args = [];
9 private $_record = [];
10
11 /**
12 * @var GroupData[]
13 */
14 private $_groups = [];
15
16 public function __construct($template_type, $args = [])
17 {
18 $this->_template_type = $template_type;
19 $this->_args = $args;
20 }
21
22 public function get_type()
23 {
24 return $this->_template_type;
25 }
26
27 public function get_args()
28 {
29 return $this->_args;
30 }
31
32 public function get_record()
33 {
34 return $this->_record;
35 }
36
37 public function get_group($group_id)
38 {
39 if (!isset($this->_groups[$group_id])) {
40 $this->_groups[$group_id] = new GroupData($group_id, []);
41 }
42 return $this->_groups[$group_id];
43 }
44
45 public function load_record($record)
46 {
47 $this->_record = $record;
48 }
49
50 public function get_groups()
51 {
52 return $this->_groups;
53 }
54 }
55