import type { BetterSqlite3Database, ChildNodeRow, ListFunctionOpts, NativeDatabase, NodeIdRow, NodeRow, NodeRowWithFanIn, QueryOpts, TriageNodeRow, TriageQueryOpts } from '../../types.js';
/**
 * Find nodes matching a name pattern, with fan-in count.
 */
export declare function findNodesWithFanIn(db: BetterSqlite3Database, namePattern: string, opts?: QueryOpts, nativeDb?: NativeDatabase): NodeRowWithFanIn[];
/**
 * Fetch nodes for triage scoring: fan-in + complexity + churn.
 */
export declare function findNodesForTriage(db: BetterSqlite3Database, opts?: TriageQueryOpts, nativeDb?: NativeDatabase): TriageNodeRow[];
/**
 * List function/method/class nodes with basic info.
 */
export declare function listFunctionNodes(db: BetterSqlite3Database, opts?: ListFunctionOpts, nativeDb?: NativeDatabase): NodeRow[];
/**
 * Iterator version of listFunctionNodes for memory efficiency.
 */
export declare function iterateFunctionNodes(db: BetterSqlite3Database, opts?: ListFunctionOpts): IterableIterator<NodeRow>;
/**
 * Count total nodes.
 */
export declare function countNodes(db: BetterSqlite3Database): number;
/**
 * Count total edges.
 */
export declare function countEdges(db: BetterSqlite3Database): number;
/**
 * Count distinct files.
 */
export declare function countFiles(db: BetterSqlite3Database): number;
/**
 * Find a single node by ID.
 */
export declare function findNodeById(db: BetterSqlite3Database, id: number): NodeRow | undefined;
/**
 * Find non-file nodes for a given file path (exact match), ordered by line.
 */
export declare function findNodesByFile(db: BetterSqlite3Database, file: string): NodeRow[];
/**
 * Find file-kind nodes matching a LIKE pattern.
 */
export declare function findFileNodes(db: BetterSqlite3Database, fileLike: string): NodeRow[];
/**
 * Look up a node's ID by its unique (name, kind, file, line) tuple.
 */
export declare function getNodeId(db: BetterSqlite3Database, name: string, kind: string, file: string, line: number): number | undefined;
/**
 * Look up a function/method node's ID (kind-restricted variant of getNodeId).
 */
export declare function getFunctionNodeId(db: BetterSqlite3Database, name: string, file: string, line: number): number | undefined;
/**
 * Bulk-fetch all node IDs for a file in one query.
 */
export declare function bulkNodeIdsByFile(db: BetterSqlite3Database, file: string): NodeIdRow[];
/**
 * Find child nodes (parameters, properties, constants) of a parent.
 */
export declare function findNodeChildren(db: BetterSqlite3Database, parentId: number): ChildNodeRow[];
/**
 * Find all nodes that belong to a given scope (by scope column).
 */
export declare function findNodesByScope(db: BetterSqlite3Database, scopeName: string, opts?: QueryOpts): NodeRow[];
/**
 * Find nodes by qualified name.
 */
export declare function findNodeByQualifiedName(db: BetterSqlite3Database, qualifiedName: string, opts?: {
    file?: string;
}): NodeRow[];
/**
 * Get line_count from node_metrics for a given node.
 * @param {object} db
 * @param {number} nodeId
 * @returns {{ line_count: number } | undefined}
 */
export declare function getLineCountForNode(db: BetterSqlite3Database, nodeId: number): {
    line_count: number;
} | undefined;
/**
 * Get the maximum end_line across all nodes in a file.
 * @param {object} db
 * @param {string} file
 * @returns {{ max_end: number | null } | undefined}
 */
export declare function getMaxEndLineForFile(db: BetterSqlite3Database, file: string): {
    max_end: number | null;
} | undefined;
//# sourceMappingURL=nodes.d.ts.map