MongoCursorType

public enum MongoCursorType

The possible types of MongoCursor or MongoCursor an operation can return.

  • The default value. A vast majority of cursors will be of this type.

    Declaration

    Swift

    case nonTailable
  • Tailable means the cursor is not closed when the last data is retrieved. Rather, the cursor marks the final object’s position. You can resume using the cursor later, from where it was located, if more data were received. Like any “latent cursor”, the cursor may become invalid at some point (CursorNotFound) – for example if the final object it references were deleted.

    Declaration

    Swift

    case tailable
  • A tailable cursor that will wait for more data for a configurable amount of time before returning an empty batch.

    Declaration

    Swift

    case tailableAwait