<?php

namespace Limb_Chatbot\Includes\Data_Objects;

/**
 * Class Role_Limit
 *
 * Represents a WordPress-role-specific usage limit extending the base Limit class.
 * Each instance is bound to a single WP role key (e.g. 'subscriber', 'administrator').
 *
 * @since 1.0.0
 */
class Role_Limit extends Limit {

	/**
	 * The chatbot user associated with this limit.
	 *
	 * @var Chatbot_User|null
	 * @since 1.0.0
	 */
	public ?Chatbot_User $chatbot_user = null;

	/**
	 * The WordPress role key this limit applies to (e.g. 'subscriber', 'editor').
	 *
	 * @var string
	 * @since 1.0.0
	 */
	public string $role = '';

	/**
	 * Get the chatbot user associated with this limit.
	 *
	 * @return Chatbot_User|null
	 * @since 1.0.0
	 */
	public function get_chatbot_user(): ?Chatbot_User {
		return $this->chatbot_user;
	}

	/**
	 * Get the WordPress role key for this limit.
	 *
	 * @return string
	 * @since 1.0.0
	 */
	public function get_role(): string {
		return $this->role;
	}
}

