PluginProbe
Elementor Website Builder – more than just a page builder / 3.5.1
Elementor Website Builder – more than just a page builder v3.5.1
4.3.0-beta2 4.3.0-beta1 4.2.4 4.2.3 4.2.2 4.2.1 4.2.0 4.1.5 4.2.0-beta2 4.2.0-dev2 4.2.0-beta1 4.1.4 4.1.3 4.1.2 4.1.1 4.1.0 4.1.0-beta3 4.1.0-dev3 4.0.9 4.1.0-beta2 4.1.0-dev2 4.0.8 4.1.0-beta1 4.1.0-dev1 4.0.7 All 451 releases
elementor / core / base / elements-iteration-actions / base.php

base.php in Elementor Website Builder – more than just a page builder 3.5.1, at core/base/elements-iteration-actions/base.php

81 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace Elementor\Core\Base\Elements_Iteration_Actions;
3
4 use Elementor\Element_Base;
5
6 if ( ! defined( 'ABSPATH' ) ) {
7 exit; // Exit if accessed directly
8 }
9
10 abstract class Base {
11 /**
12 * The current document that the Base class instance was created from.
13 */
14 protected $document;
15
16 /**
17 * Indicates if the methods are being triggered on page save or at render time (value will be either 'save' or 'render').
18 *
19 * @var string
20 */
21 protected $mode = '';
22
23 /**
24 * Is Action Needed.
25 *
26 * Runs only at runtime and used as a flag to determine if all methods should run on page render.
27 * If returns false, all methods will run only on page save.
28 * If returns true, all methods will run on both page render and on save.
29 *
30 * @since 3.3.0
31 * @access public
32 *
33 * @return bool
34 */
35 abstract public function is_action_needed();
36
37 /**
38 * Unique Element Action.
39 *
40 * Will be triggered for each unique page element - section / column / widget unique type (heading, icon etc.).
41 *
42 * @since 3.3.0
43 * @access public
44 *
45 * @return void
46 */
47 public function unique_element_action( Element_Base $element_data ) {}
48
49 /**
50 * Element Action.
51 *
52 * Will be triggered for each page element - section / column / widget.
53 *
54 * @since 3.3.0
55 * @access public
56 *
57 * @return void
58 */
59 public function element_action( Element_Base $element_data ) {}
60
61 /**
62 * After Elements Iteration.
63 *
64 * Will be triggered after all page elements iteration has ended.
65 *
66 * @since 3.3.0
67 * @access public
68 *
69 * @return void
70 */
71 public function after_elements_iteration() {}
72
73 public function set_mode( $mode ) {
74 $this->mode = $mode;
75 }
76
77 public function __construct( $document ) {
78 $this->document = $document;
79 }
80 }
81