/**
 * Metadata Resolver
 *
 * Resolves Live Dev metadata from CloudFormation outputs or local cache.
 * Integrates StackNameResolver, CloudFormationLoader, CacheManager, and
 * ResourceValidator to provide a complete metadata resolution flow.
 *
 * Resolution flow:
 * 1. Check --local-resources flag → use pattern-based names
 * 2. Check cache (unless --refresh-metadata) → use cached metadata
 * 3. Query CloudFormation → cache result
 * 4. Validate resources (unless --skip-validation)
 *
 * @module bin/commands/dev/metadata-resolver
 *
 * @see Requirements 1.1, 2.2, 2.3, 5.1, 6.4, 6.5
 */
import type { RuntimeAwakeMetadata } from '../../../lib/runtime-web/runtime-awake';
import { type ICacheManager } from './cache-manager';
import { type MetadataResolutionResult, type MetadataResolverConfig, type MetadataResolverOptions, type MetadataSource } from './metadata-resolver.types';
/**
 * Default suffix for Live Dev session table names in local resources mode.
 */
export declare const LOCAL_SESSION_TABLE_SUFFIX = "runtime-awake-sessions";
/**
 * Default suffix for Live Dev payload bucket names in local resources mode.
 */
export declare const LOCAL_PAYLOAD_BUCKET_SUFFIX = "runtime-awake-payloads";
/**
 * Placeholder IoT endpoint for local resources mode.
 * This will need to be configured manually or obtained from AWS IoT.
 */
export declare const LOCAL_IOT_ENDPOINT_PLACEHOLDER = "local-iot-endpoint-not-configured";
/**
 * Interface for MetadataResolver.
 *
 * @see Requirements 1.1, 2.2, 2.3, 5.1, 6.4, 6.5
 */
export interface IMetadataResolver {
    /**
     * Resolve Live Dev metadata.
     *
     * @param options - Resolution options
     * @returns Resolution result with metadata and source
     * @throws MetadataResolutionError if resolution fails
     */
    resolve(options?: MetadataResolverOptions): Promise<MetadataResolutionResult>;
}
/**
 * MetadataResolver - Resolves Live Dev metadata from CloudFormation or cache.
 *
 * Integrates all metadata resolution components:
 * - StackNameResolver: Derives the CloudFormation stack name
 * - CacheManager: Manages local metadata cache
 * - CloudFormationLoader: Queries CloudFormation for metadata
 * - ResourceValidator: Validates AWS resources exist
 *
 * @see Requirements 1.1, 2.2, 2.3, 5.1, 6.4, 6.5
 *
 * @example
 * ```typescript
 * const resolver = new MetadataResolver({
 *   appName: 'my-app',
 *   stage: 'dev',
 *   region: 'us-east-1',
 *   projectRoot: process.cwd(),
 * });
 *
 * const result = await resolver.resolve();
 * console.log(result.metadata.iotEndpoint);
 * ```
 */
export declare class MetadataResolver implements IMetadataResolver {
    private readonly config;
    private readonly cacheManager;
    private readonly cloudFormationLoader;
    private readonly stackName;
    /**
     * Create a new MetadataResolver.
     *
     * @param config - Resolver configuration
     */
    constructor(config: MetadataResolverConfig);
    /**
     * Resolve Live Dev metadata.
     *
     * Resolution flow:
     * 1. If localResources=true: Generate pattern-based names
     * 2. If cache exists and fresh (and not refreshMetadata): Use cache
     * 3. Query CloudFormation and cache result
     * 4. If not skipValidation: Validate resources
     *
     * @param options - Resolution options
     * @returns Resolution result with metadata and source
     * @throws MetadataResolutionError if resolution fails
     *
     * @see Requirements 1.1, 2.2, 2.3, 5.1, 6.4, 6.5
     */
    resolve(options?: MetadataResolverOptions): Promise<MetadataResolutionResult>;
    /**
     * Get the resolved stack name.
     *
     * @returns Stack name
     */
    getStackName(): string;
    /**
     * Get the cache manager instance.
     *
     * @returns Cache manager
     */
    getCacheManager(): ICacheManager;
    /**
     * Resolve metadata using pattern-based local resource names.
     *
     * @param skipValidation - Whether to skip resource validation
     * @returns Resolution result with local metadata
     *
     * @see Requirements 5.1, 5.2
     */
    private resolveLocalResources;
    /**
     * Try to resolve metadata from cache.
     *
     * @param skipValidation - Whether to skip resource validation
     * @returns Resolution result if cache is valid and fresh, null otherwise
     *
     * @see Requirements 2.2, 2.5
     */
    private tryResolveFromCache;
    /**
     * Load metadata from CloudFormation.
     *
     * @returns Live Dev metadata
     * @throws StackNotFoundError if stack doesn't exist
     * @throws PermissionError if access denied
     * @throws MetadataParseError if metadata is invalid
     *
     * @see Requirements 1.1, 1.2, 1.3, 1.5
     */
    private loadFromCloudFormation;
    /**
     * Validate AWS resources exist.
     *
     * @param metadata - Metadata containing resource names
     * @returns Validation result
     *
     * @see Requirements 6.1, 6.2, 6.3, 6.4
     */
    private validateResources;
}
/**
 * Generate pattern-based local resource names.
 *
 * Used when --local-resources flag is provided.
 *
 * @param appName - Application name
 * @param stage - Deployment stage
 * @returns Local metadata with pattern-based names
 *
 * @see Requirements 5.1, 5.2
 */
export declare function generateLocalMetadata(appName: string, stage: string): RuntimeAwakeMetadata;
/**
 * Check if metadata source is from CloudFormation.
 *
 * @param source - Metadata source
 * @returns True if source is CloudFormation
 */
export declare function isCloudFormationSource(source: MetadataSource): boolean;
/**
 * Check if metadata source is from cache.
 *
 * @param source - Metadata source
 * @returns True if source is cache
 */
export declare function isCacheSource(source: MetadataSource): boolean;
/**
 * Check if metadata source is local (pattern-based).
 *
 * @param source - Metadata source
 * @returns True if source is local
 */
export declare function isLocalSource(source: MetadataSource): boolean;
/**
 * Create a MetadataResolver instance.
 *
 * @param config - Resolver configuration
 * @returns MetadataResolver instance
 *
 * @example
 * ```typescript
 * const resolver = createMetadataResolver({
 *   appName: 'my-app',
 *   stage: 'dev',
 *   region: 'us-east-1',
 *   projectRoot: process.cwd(),
 * });
 *
 * const result = await resolver.resolve();
 * ```
 */
export declare function createMetadataResolver(config: MetadataResolverConfig): MetadataResolver;
/**
 * Resolve metadata with a single function call.
 *
 * Convenience function that creates a resolver and resolves metadata.
 *
 * @param config - Resolver configuration
 * @param options - Resolution options
 * @returns Resolution result
 *
 * @example
 * ```typescript
 * const result = await resolveMetadata(
 *   { appName: 'my-app', stage: 'dev', region: 'us-east-1', projectRoot: '.' },
 *   { refreshMetadata: true }
 * );
 * ```
 */
export declare function resolveMetadata(config: MetadataResolverConfig, options?: MetadataResolverOptions): Promise<MetadataResolutionResult>;
