class-event-grouped.php
4 years ago
class-event-single.php
1 year ago
class-event.php
4 years ago
class-events-automatic.php
4 years ago
class-events-custom.php
1 year ago
class-events-edd.php
1 year ago
class-events-fdp.php
4 years ago
class-events-woo.php
1 year ago
interface-events.php
1 year ago
class-event.php
37 lines
| 1 | <?php |
| 2 | namespace PixelYourSite; |
| 3 | class EventTypes { |
| 4 | static public $DYNAMIC = "dyn"; |
| 5 | static public $STATIC = "static"; |
| 6 | static public $TRIGGER = "trigger"; |
| 7 | } |
| 8 | |
| 9 | abstract class PYSEvent { |
| 10 | protected $id; |
| 11 | protected $type; |
| 12 | protected $category; |
| 13 | public $args = null; |
| 14 | /** |
| 15 | * GroupedEvent constructor. |
| 16 | * @param String $id // unique id use in js object like key |
| 17 | * @param String $type // can be static(fire when open page) or dynamic (fire when some event did) |
| 18 | * @param String $category // event category like woo, edd signal etc |
| 19 | */ |
| 20 | public function __construct($id,$type,$category=''){ |
| 21 | $this->id = $id; |
| 22 | $this->type = $type; |
| 23 | $this->category = $category; |
| 24 | } |
| 25 | |
| 26 | function getId() { |
| 27 | return $this->id; |
| 28 | } |
| 29 | |
| 30 | function getType() { |
| 31 | return $this->type; |
| 32 | } |
| 33 | |
| 34 | function getCategory() { |
| 35 | return $this->category; |
| 36 | } |
| 37 | } |