/**
 * Adopt Branch Use Case
 *
 * Imports an existing git branch into Shep's feature tracking system.
 * Creates a worktree (if needed), derives feature metadata from the branch name,
 * and persists a Feature entity. Branches with an open PR get lifecycle=Review
 * (shown as "REVIEW" in the UI); all others get lifecycle=Maintain (completed).
 *
 * This is a standalone use case — it does NOT extend or modify CreateFeatureUseCase.
 * It needs only three dependencies: IFeatureRepository, IRepositoryRepository, and IWorktreeService.
 */
import type { Feature } from '../../../domain/generated/output.js';
import type { IFeatureRepository } from '../../ports/output/repositories/feature-repository.interface.js';
import type { IRepositoryRepository } from '../../ports/output/repositories/repository-repository.interface.js';
import type { IWorktreeService } from '../../ports/output/services/worktree-service.interface.js';
import type { IGitPrService } from '../../ports/output/services/git-pr-service.interface.js';
export interface AdoptBranchInput {
    branchName: string;
    repositoryPath: string;
}
export interface AdoptBranchResult {
    feature: Feature;
}
export declare class AdoptBranchUseCase {
    private readonly featureRepo;
    private readonly repositoryRepo;
    private readonly worktreeService;
    private readonly gitPrService;
    constructor(featureRepo: IFeatureRepository, repositoryRepo: IRepositoryRepository, worktreeService: IWorktreeService, gitPrService: IGitPrService);
    execute(input: AdoptBranchInput): Promise<AdoptBranchResult>;
    /**
     * Resolve the git ref to use for worktree creation.
     * Returns the branch name for local branches, or "origin/<branch>" for remote-only.
     * Throws if branch does not exist anywhere.
     */
    private resolveBranchRef;
    /**
     * Detect if the branch has an open PR (or one whose closure we cannot confirm).
     * Returns PullRequest data if found, undefined otherwise.
     * Gracefully returns undefined if gh CLI is unavailable or the repo has no remote.
     */
    private detectPrForBranch;
    /**
     * Find or create a Repository entity for the given path.
     * Mirrors the pattern from CreateFeatureUseCase.
     */
    private resolveRepository;
}
//# sourceMappingURL=adopt-branch.use-case.d.ts.map