Uname: Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64
Software: LiteSpeed
PHP version: 8.1.31 [ PHP INFO ] PHP os: Linux
Server Ip: 162.213.251.212
Your Ip: 18.117.11.6
User: allssztx (535) | Group: allssztx (533)
Safe Mode: OFF
Disable Function:
NONE

name : sub-endpoint.php
<?php
namespace Elementor\Data\Base;

// TODO: Add test.

abstract class SubEndpoint extends Endpoint {

	/**
	 * @var Endpoint
	 */
	protected $parent_endpoint;

	/**
	 * @var string
	 */
	protected $parent_route = '';

	public function __construct( $parent_route, $parent_endpoint ) {
		$this->parent_endpoint = $parent_endpoint;
		$this->parent_route = $parent_route;

		parent::__construct( $this->parent_endpoint->controller );
	}

	/**
	 * Get parent route.
	 *
	 * @return \Elementor\Data\Base\Endpoint
	 */
	public function get_parent() {
		return $this->parent_endpoint;
	}

	public function get_base_route() {
		$controller_name = $this->controller->get_name();

		return $controller_name . '/' . $this->parent_route . $this->get_name();
	}
}
© 2025 GrazzMean-Shell