import { Tree } from '@nx/devkit';
import { CallExpression, ClassDeclaration, ConstructorDeclaration, ObjectLiteralExpression, Project, SourceFile } from 'ts-morph';
/**
 * Reads the content of a file from the Nx Tree.
 * Throws an error if the file cannot be read.
 */
export declare function readTreeFile(tree: Tree, filePath: string): string;
/**
 * Loads a file from the Nx Tree into a ts-morph Project.
 * Uses `readTreeFile` to get content.
 */
export declare function loadSourceFile(tree: Tree, filePath: string, project: Project): SourceFile;
/**
 * Saves the updated source file content back to the Nx Tree.
 */
export declare function saveSourceFile(tree: Tree, filePath: string, sourceFileContent: string): void;
/**
 * Throws an error if the provided item is null or undefined.
 * Returns the item with a non-null/undefined type assertion.
 */
export declare function throwIfNotFound<T>(item: T | null | undefined, message: string): T;
/**
 * Checks if a property exists in an ObjectLiteralExpression, handling quoted keys.
 */
export declare function propertyExists(objectLiteral: ObjectLiteralExpression, propName: string): boolean;
/**
 * Finds the first ClassDeclaration in a SourceFile.
 */
export declare function findFirstClass(sourceFile: SourceFile): ClassDeclaration;
/**
 * Finds the first ConstructorDeclaration in a ClassDeclaration.
 */
export declare function findFirstConstructor(clazz: ClassDeclaration): ConstructorDeclaration;
/**
 * Finds the `super()` CallExpression within a ConstructorDeclaration.
 */
export declare function findSuperCall(constructor: ConstructorDeclaration): CallExpression;
/**
 * Gets the first argument of a CallExpression, asserting it's an ObjectLiteralExpression.
 */
export declare function getObjectLiteralFromFirstArg(callExpression: CallExpression): ObjectLiteralExpression;
//# sourceMappingURL=visual-utils.d.ts.map