import { Access } from "./Access"; import { Annotation } from "./Annotation"; import { ClassReference } from "./ClassReference"; import { AstNode } from "../core/AstNode"; import { Writer } from "../core/Writer"; import { Method } from "./Method"; import { Field } from "./Field"; /** * Namespace containing interfaces for Interface configuration. */ export declare namespace Interface { /** * Interface defining the arguments required to create a new Interface instance. * * @interface Args */ interface Args { /** The name of the Java interface */ name: string; /** The package of the Java interface */ packageName: string; /** The access level of the Java interface */ access: Access; /** Any interfaces extended by this interface */ extends_?: ClassReference[]; /** Whether this is a nested interface */ isNestedInterface?: boolean; /** Interface annotations */ annotations?: Annotation[]; /** Documentation/JavaDoc for the interface */ javadoc?: string; /** Generic type parameters for this interface */ typeParameters?: string[]; } } /** * Represents a Java interface in the AST. * This class handles the generation of Java interface declarations including methods, * constants, and other interface-related elements. * * @class * @extends {AstNode} */ export declare class Interface extends AstNode { /** The name of the interface */ readonly name: string; /** The package name of the interface */ readonly packageName: string; /** The access level of the interface */ readonly access: Access; /** The class reference for this interface */ readonly reference: ClassReference; /** Whether this is a nested interface */ readonly isNestedInterface: boolean; /** The interfaces extended by this interface */ readonly extends_: ClassReference[]; /** The annotations applied to the interface */ private annotations; /** The JavaDoc documentation for the interface */ private javadoc?; /** The generic type parameters for this interface */ private typeParameters; /** The methods declared in this interface */ private methods; /** The constants (public static final fields) in this interface */ private constants; /** * Creates a new Interface instance with the specified configuration. * * @param {Interface.Args} args - The arguments for creating the interface */ constructor({ name, packageName, access, extends_, isNestedInterface, annotations, javadoc, typeParameters, }: Interface.Args); /** * Adds a method to the interface. * Interface methods are implicitly public and abstract. * * @param {Method} method - The method to add */ addMethod(method: Method): void; /** * Adds a constant to the interface. * Interface constants are implicitly public static final. * * @param {Field} constant - The field to add as a constant */ addConstant(constant: Field): void; /** * Writes the interface declaration and its contents to the writer. * This includes JavaDoc, annotations, methods, and constants. * * @param {Writer} writer - The writer to write to */ write(writer: Writer): void; }