/*!
 * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
 * Licensed under the MIT License.
 */
import { FieldKey, TreeNavigationResult, ITreeSubscriptionCursor, FieldSchema, FieldAnchor, ITreeCursor, FieldUpPath } from "../../core";
import { arrayLikeMarkerSymbol } from "../contextuallyTyped";
import { ProxyContext } from "./editableTreeContext";
import { EditableField, EditableTree, UnwrappedEditableField, UnwrappedEditableTree, proxyTargetSymbol } from "./editableTreeTypes";
import { ProxyTarget } from "./ProxyTarget";
export declare function makeField(context: ProxyContext, fieldSchema: FieldSchema, cursor: ITreeSubscriptionCursor): EditableField;
/**
 * A Proxy target, which together with a `fieldProxyHandler` implements a basic access to
 * the nodes of {@link EditableField} by means of the cursors.
 */
export declare class FieldProxyTarget extends ProxyTarget<FieldAnchor> implements EditableField {
    readonly fieldSchema: FieldSchema;
    readonly fieldKey: FieldKey;
    readonly [arrayLikeMarkerSymbol]: true;
    constructor(context: ProxyContext, fieldSchema: FieldSchema, cursor: ITreeSubscriptionCursor);
    get [proxyTargetSymbol](): FieldProxyTarget;
    get parent(): EditableTree | undefined;
    protected buildAnchor(): FieldAnchor;
    protected tryMoveCursorToAnchor(anchor: FieldAnchor, cursor: ITreeSubscriptionCursor): TreeNavigationResult;
    protected forgetAnchor(anchor: FieldAnchor): void;
    [index: number]: UnwrappedEditableTree;
    get length(): number;
    /**
     * Returns a node (unwrapped by default, see {@link UnwrappedEditableTree}) by its index.
     */
    unwrappedTree(index: number): UnwrappedEditableTree;
    /**
     * Gets a node by its index without unwrapping.
     */
    getNode(index: number): EditableTree;
    /**
     * Gets array of unwrapped nodes.
     */
    private asArray;
    [Symbol.iterator](): IterableIterator<UnwrappedEditableTree>;
    insertNodes(index: number, newContent: ITreeCursor | ITreeCursor[]): void;
    moveNodes(sourceIndex: number, count: number, destinationIndex: number, destinationField?: EditableField): void;
    getfieldPath(): FieldUpPath;
    deleteNodes(index: number, count?: number): void;
    replaceNodes(index: number, newContent: ITreeCursor | ITreeCursor[], count?: number): void;
}
/**
 * @param context - the common context of the field.
 * @param fieldSchema - the FieldSchema of the field.
 * @param cursor - the cursor, which must point to the field being proxified.
 */
export declare function unwrappedField(context: ProxyContext, fieldSchema: FieldSchema, cursor: ITreeSubscriptionCursor): UnwrappedEditableField;
/**
 * Checks the type of an UnwrappedEditableField.
 * @alpha
 */
export declare function isEditableField(field: UnwrappedEditableField): field is EditableField;
//# sourceMappingURL=editableField.d.ts.map