import { Access } from "./Access"; import { Annotation } from "./Annotation"; import { CodeBlock } from "./CodeBlock"; import { AstNode } from "../core/AstNode"; import { Writer } from "../core/Writer"; import { Type } from "./Type"; /** * Namespace containing interfaces for Field configuration. */ export declare namespace Field { /** * Interface defining the arguments required to create a new Field instance. * * @interface Args */ interface Args { /** The name of the Java field */ name: string; /** The type of the field (e.g., String, int, List) */ type: Type; /** The access level of the field (public, private, protected) */ access: Access; /** Whether the field is static */ static_?: boolean; /** Whether the field is final (immutable) */ final_?: boolean; /** Whether the field is transient (not serialized) */ transient_?: boolean; /** Whether the field is volatile (thread-safe) */ volatile_?: boolean; /** Field annotations like @JsonProperty, @Column, etc. */ annotations?: Annotation[]; /** The initializer expression for the field */ initializer?: CodeBlock; /** Documentation/JavaDoc for the field */ javadoc?: string; } } /** * Represents a Java field in the AST. * This class handles the generation of Java field declarations including type, * modifiers, annotations, and initialization. * * @class * @extends {AstNode} */ export declare class Field extends AstNode { /** The name of the field */ readonly name: string; /** The access level of the field */ readonly access: Access; /** The type of the field */ private type; /** Whether the field is static */ private static_; /** Whether the field is final */ private final_; /** Whether the field is transient */ private transient_; /** Whether the field is volatile */ private volatile_; /** The annotations applied to the field */ private annotations; /** The initializer expression for the field */ private initializer?; /** The JavaDoc documentation for the field */ private javadoc?; /** * Creates a new Field instance with the specified configuration. * * @param {Field.Args} args - The arguments for creating the field */ constructor({ name, type, access, static_, final_, transient_, volatile_, annotations, initializer, javadoc, }: Field.Args); /** * Writes the field declaration and its contents to the writer. * This includes JavaDoc, annotations, modifiers, type, name, and initializer. * * @param {Writer} writer - The writer to write to */ write(writer: Writer): void; }