<?php
/**
 * Unified Mapping Hooks – wires AJAX actions to controller static endpoints.
 *
 * @package    MOMCS_Sync
 * @subpackage MOMCS_Sync\includes\common\hooks
 * @author     miniOrange
 */

declare(strict_types=1);

namespace MOMCS_Sync\Includes\Common\Hooks;

use MOMCS_Sync\Includes\Common\Controllers\Template_Mapping\Unified_Mapping_Controller;

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 * Unified Mapping Hooks.
 */
class Unified_Mapping_Hooks {
	/**
	 * Constructor.
	 */
	public function __construct() {
		$this->register_hooks();
	}

	/**
	 * Register AJAX hooks for unified mapping feature.
	 */
	private function register_hooks(): void {
		add_action( 'wp_ajax_momcs_sync_save_unified_mapping', array( Unified_Mapping_Controller::class, 'handle_save_unified_mapping' ) );
		add_action( 'wp_ajax_momcs_sync_get_unified_mapping', array( Unified_Mapping_Controller::class, 'handle_get_unified_mapping' ) );
	}
}
