"""Shared AppAdapter result types (DSL v0.1)."""

from __future__ import annotations

from dataclasses import dataclass, field
from typing import Any

InstalledAppEntry = dict[str, Any]


@dataclass
class LaunchResult:
    success: bool
    pid: int = 0
    launch_command: list[str] = field(default_factory=list)
    error: str = ""


@dataclass
class FocusResult:
    success: bool
    detail: str = ""
    evidence: dict[str, Any] = field(default_factory=dict)
    degraded: bool = False


@dataclass
class TypeResult:
    success: bool
    execution_result: str = ""
    evidence: dict[str, Any] = field(default_factory=dict)
    error: str = ""


@dataclass
class EmptyTrashResult:
    success: bool
    execution_result: str = ""
    evidence: dict[str, Any] = field(default_factory=dict)
    error: str = ""
