Packages > @fluidframework/merge-tree > IMoveInfo

IMoveInfo Interface

Tracks information about when and where this segment was moved to.

Note that merge-tree does not currently support moving and only supports obliterate. The fields below include “move” in their names to avoid renaming in the future, when moves _are_ supported.

This API is provided for existing users, but is not recommended for new users.

To use, import via @fluidframework/merge-tree/legacy.

For more information about our API support guarantees, see here .

Signature

export interface IMoveInfo

Properties

Property Alerts Modifiers Type Description
localMovedSeq Alpha optional number Local seq at which this segment was moved if the move is yet-to-be acked.
movedClientIds Alpha number[]

List of client IDs that have moved this segment.

The client that actually moved the segment (i.e. whose move op was sequenced first) is stored as the first client in this list. Other clients in the list have all issued concurrent ops to move the segment.

movedSeq Alpha number The first seq at which this segment was moved.
movedSeqs Alpha number[]

All seqs at which this segment was moved. In the case of overlapping, concurrent moves this array will contain multiple seqs.

The seq at movedSeqs[i] corresponds to the client id at movedClientIds[i].

The first element corresponds to the seq of the first move

moveDst Alpha optional ReferencePosition

A reference to the inserted destination segment corresponding to this segment's move.

If undefined, the move was an obliterate.

Currently this field is unused, as we only support obliterate operations

wasMovedOnInsert Alpha boolean

If this segment was inserted into a concurrently moved range and the move op was sequenced before the insertion op. In this case, the segment is visible only to the inserting client

wasMovedOnInsert only applies for acked obliterates. That is, if a segment inserted by a remote client is moved on insertion by a local and unacked obliterate, we do not consider it as having been moved on insert

If a segment is moved on insertion, its length is only ever visible to the client that inserted the segment. This is relevant in partial length calculations

Property Details

localMovedSeq

Local seq at which this segment was moved if the move is yet-to-be acked.

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

localMovedSeq?: number;

Type: number

movedClientIds

List of client IDs that have moved this segment.

The client that actually moved the segment (i.e. whose move op was sequenced first) is stored as the first client in this list. Other clients in the list have all issued concurrent ops to move the segment.

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

movedClientIds: number[];

Type: number[]

movedSeq

The first seq at which this segment was moved.

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

movedSeq: number;

Type: number

movedSeqs

All seqs at which this segment was moved. In the case of overlapping, concurrent moves this array will contain multiple seqs.

The seq at movedSeqs[i] corresponds to the client id at movedClientIds[i].

The first element corresponds to the seq of the first move

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

movedSeqs: number[];

Type: number[]

moveDst

A reference to the inserted destination segment corresponding to this segment’s move.

If undefined, the move was an obliterate.

Currently this field is unused, as we only support obliterate operations

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

moveDst?: ReferencePosition;

Type: ReferencePosition

wasMovedOnInsert

If this segment was inserted into a concurrently moved range and the move op was sequenced before the insertion op. In this case, the segment is visible only to the inserting client

wasMovedOnInsert only applies for acked obliterates. That is, if a segment inserted by a remote client is moved on insertion by a local and unacked obliterate, we do not consider it as having been moved on insert

If a segment is moved on insertion, its length is only ever visible to the client that inserted the segment. This is relevant in partial length calculations

This API is provided as an alpha preview and may change without notice.

To use, import via @fluidframework/merge-tree/alpha.

For more information about our API support guarantees, see here .

Signature

wasMovedOnInsert: boolean;

Type: boolean