using System; namespace MCPForUnity.Editor.Resources { /// /// Marks a class as an MCP resource handler for auto-discovery. /// The class must have a public static HandleCommand(JObject) method. /// [AttributeUsage(AttributeTargets.Class, AllowMultiple = false)] public class McpForUnityResourceAttribute : Attribute { /// /// The resource name used to route requests to this resource. /// If not specified, defaults to the PascalCase class name converted to snake_case. /// public string ResourceName { get; } /// /// Human-readable description of what this resource provides. /// public string Description { get; set; } /// /// Create an MCP resource attribute with auto-generated resource name. /// The resource name will be derived from the class name (PascalCase → snake_case). /// Example: ManageAsset → manage_asset /// public McpForUnityResourceAttribute() { ResourceName = null; // Will be auto-generated } /// /// Create an MCP resource attribute with explicit resource name. /// /// The resource name (e.g., "manage_asset") public McpForUnityResourceAttribute(string resourceName) { ResourceName = resourceName; } } }