Options
All
  • Public
  • Public/Protected
  • All
Menu菜单

mongodb

Index索引

Classes BSONTypeBSONType类

Classes Error错误类

Classes Event事件类

Classes Other其它类

Interfaces接口

Type aliases类别名

Variables变量

Type aliases类型别名

AbstractCursorEvents: { close: any }

Type declaration类型声明

AcceptedFields<TSchema, FieldType, AssignableType>: { readonly [ key in KeysOfAType<TSchema, FieldType>]?: AssignableType }

Type parameters类型参数

  • TSchema

  • FieldType

  • AssignableType

AddToSetOperators<Type>: { $each?: Flatten<Type>[] }

Type parameters类型参数

  • Type

Type declaration类型声明

AlternativeType<T>: T extends ReadonlyArray<infer U> ? T | RegExpOrString<U> : RegExpOrString<T>

It is possible to search using alternative types in mongodb e.g. string types can be searched using a regex in mongo array types can be searched using their element type可以在mongodb中使用其他类型进行搜索,例如字符串类型可以使用mongo中的正则表达式进行搜索数组类型可以使用其元素类型进行搜索

Type parameters类型参数

  • T

AnyBulkWriteOperation<TSchema>: { insertOne: InsertOneModel<TSchema> } | { replaceOne: ReplaceOneModel<TSchema> } | { updateOne: UpdateOneModel<TSchema> } | { updateMany: UpdateManyModel<TSchema> } | { deleteOne: DeleteOneModel<TSchema> } | { deleteMany: DeleteManyModel<TSchema> }

Type parameters类型参数

AnyError: MongoError | Error
ArrayElement<Type>: Type extends ReadonlyArray<infer Item> ? Item : never

Type parameters类型参数

  • Type

ArrayOperator<Type>: { $each?: Flatten<Type>[]; $position?: number; $slice?: number; $sort?: Sort }

Type parameters类型参数

  • Type

Type declaration类型声明

  • Optional $each?: Flatten<Type>[]
  • Optional $position?: number
  • Optional $slice?: number
  • Optional $sort?: Sort
AuthMechanism: typeof AuthMechanism[keyof typeof AuthMechanism]
AutoEncryptionLoggerLevel: typeof AutoEncryptionLoggerLevel[keyof typeof AutoEncryptionLoggerLevel]
BSONType: typeof BSONType[keyof typeof BSONType]
BSONTypeAlias: keyof typeof BSONType
BatchType: typeof BatchType[keyof typeof BatchType]
BitwiseFilter: number | Binary | ReadonlyArray<number>
Callback<T>: (error?: AnyError, result?: T) => void

Type parameters类型参数

  • T = any

Type declaration类型声明

    • MongoDB Driver style callbackMongoDB驱动程序样式回调

      Parameters参数

      • Optional error: AnyError
      • Optional result: T

      Returns 返回 void

Type parameters类型参数

ChangeStreamEvents<TSchema, TChange>: { change: any; end: any; error: any; init: any; more: any; response: any; resumeTokenChanged: any } & AbstractCursorEvents

Type parameters类型参数

ClientSessionEvents: { ended: any }

Type declaration类型声明

CommonEvents: "newListener" | "removeListener"
Compressor: typeof Compressor[CompressorName]
CompressorName: keyof typeof Compressor

Type parameters类型参数

  • T

ConnectionEvents: { close: any; clusterTimeReceived: any; commandFailed: any; commandStarted: any; commandSucceeded: any; message: any; pinned: any; unpinned: any }

Type declaration类型声明

ConnectionPoolEvents: { connectionCheckOutFailed: any; connectionCheckOutStarted: any; connectionCheckedIn: any; connectionCheckedOut: any; connectionClosed: any; connectionCreated: any; connectionPoolCleared: any; connectionPoolClosed: any; connectionPoolCreated: any; connectionPoolReady: any; connectionReady: any } & Omit<ConnectionEvents, "close" | "message">
CursorFlag: typeof CURSOR_FLAGS[number]
DistinctOptions: CommandOperationOptions
DropDatabaseOptions: CommandOperationOptions
DropIndexesOptions: CommandOperationOptions
EnhancedOmit<TRecordOrUnion, KeyUnion>: string extends keyof TRecordOrUnion ? TRecordOrUnion : TRecordOrUnion extends any ? Pick<TRecordOrUnion, Exclude<keyof TRecordOrUnion, KeyUnion>> : never

TypeScript Omit (Exclude to be specific) does not work for objects with an "any" indexed type, and breaks discriminated unions @publicTypeScript省略(具体排除)不适用于具有“任意”索引类型的对象,并且会打破受歧视的联合@public

Type parameters类型参数

  • TRecordOrUnion

  • KeyUnion

EventEmitterWithState: { }

Type declaration类型声明

EventsDescription: Record<string, GenericListener>

Event description type事件描述类型

ExplainVerbosity: string
ExplainVerbosityLike: ExplainVerbosity | boolean

For backwards compatibility, true is interpreted as "allPlansExecution" and false as "queryPlanner". 为了向后兼容,true解释为“allPlansExecution”,false解释为“queryPlanner”。Prior to server version 3.6, aggregate() ignores the verbosity parameter and executes in "queryPlanner".在服务器版本3.6之前,aggregate()忽略verbosity参数并在“queryPlanner”中执行。

Filter<TSchema>: Partial<TSchema> | ({ [ Property in Join<NestedPaths<WithId<TSchema>, []>, ".">]?: Condition<PropertyType<WithId<TSchema>, Property>> } & RootFilterOperators<WithId<TSchema>>)

A MongoDB filter can be some portion of the schema or a set of operators @publicMongoDB筛选器可以是架构的一部分,也可以是一组运算符@public

Type parameters类型参数

  • TSchema

FilterOperations<T>: T extends Record<string, any> ? { [ key in keyof T]?: FilterOperators<T[key]> } : FilterOperators<T>

Type parameters类型参数

  • T

FinalizeFunction<TKey, TValue>: (key: TKey, reducedValue: TValue) => TValue

Type parameters类型参数

Type declaration类型声明

    • (key: TKey, reducedValue: TValue): TValue
    • Parameters参数

      • key: TKey
      • reducedValue: TValue

      Returns 返回 TValue

Flatten<Type>: Type extends ReadonlyArray<infer Item> ? Item : Type

Type parameters类型参数

  • Type

GSSAPICanonicalizationValue: typeof GSSAPICanonicalizationValue[keyof typeof GSSAPICanonicalizationValue]
GenericListener: (...args: any[]) => void

Type declaration类型声明

    • (...args: any[]): void
    • Parameters参数

      • Rest ...args: any[]

      Returns 返回 void

GridFSBucketEvents: { index: any }

Type declaration类型声明

Hint: string | Document
IndexDirection: -1 | 1 | "2d" | "2dsphere" | "text" | "geoHaystack" | "hashed" | number
IndexSpecification: OneOrMore<string | [string, IndexDirection] | {} | Map<string, IndexDirection>>
InferIdType<TSchema>: TSchema extends { _id: infer IdType } ? Record<any, never> extends IdType ? never : IdType : TSchema extends { _id?: infer IdType } ? unknown extends IdType ? ObjectId : IdType : ObjectId

Given an object shaped type, return the type of the _id field or default to ObjectId @public给定对象形状的类型,将_id字段的类型或默认值返回到ObjectId@public

Type parameters类型参数

  • TSchema

IntegerType: number | Int32 | Long
IsAny<Type, ResultIfAny, ResultIfNotAny>: true extends false & Type ? ResultIfAny : ResultIfNotAny

Type parameters类型参数

  • Type

  • ResultIfAny

  • ResultIfNotAny

Join<T, D>: T extends [] ? "" : T extends [string | number] ? `${T[0]}` : T extends [string | number, ...infer R] ? `${T[0]}${D}${Join<R, D>}` : string

Type parameters类型参数

  • T: unknown[]

  • D: string

KeysOfAType<TSchema, Type>: { [ key in keyof TSchema]: NonNullable<TSchema[key]> extends Type ? key : never }[keyof TSchema]

Type parameters类型参数

  • TSchema

  • Type

KeysOfOtherType<TSchema, Type>: { [ key in keyof TSchema]: NonNullable<TSchema[key]> extends Type ? never : key }[keyof TSchema]

Type parameters类型参数

  • TSchema

  • Type

LoggerFunction: (message?: any, ...optionalParams: any[]) => void

Type declaration类型声明

    • (message?: any, ...optionalParams: any[]): void
    • Parameters参数

      • Optional message: any
      • Rest ...optionalParams: any[]

      Returns 返回 void

LoggerLevel: typeof LoggerLevel[keyof typeof LoggerLevel]
MapFunction<TSchema>: (this: TSchema) => void

Type parameters类型参数

Type declaration类型声明

    • (this: TSchema): void
    • Parameters参数

      • this: TSchema

      Returns 返回 void

MatchKeysAndValues<TSchema>: Readonly<{ [ Property in Join<NestedPaths<TSchema, []>, ".">]?: PropertyType<TSchema, Property> } & { [ Property in `${NestedPathsOfType<TSchema, any[]>}.$${`[${string}]` | ""}`]?: ArrayElement<PropertyType<TSchema, Property extends `${infer Key}.$${string}` ? Key : never>> } & { [ Property in `${NestedPathsOfType<TSchema, Record<string, any>[]>}.$${`[${string}]` | ""}.${string}`]?: any } & Document>

Type parameters类型参数

  • TSchema

MongoClientEvents: Pick<TopologyEvents, typeof MONGO_CLIENT_EVENTS[number]> & { open: any }
MongoErrorLabel: typeof MongoErrorLabel[keyof typeof MongoErrorLabel]
MonitorEvents: { close: any; resetConnectionPool: any; resetServer: any; serverHeartbeatFailed: any; serverHeartbeatStarted: any; serverHeartbeatSucceeded: any } & EventEmitterWithState
NestedPaths<Type, Depth>: Depth["length"] extends 8 ? [] : Type extends string | number | boolean | Date | RegExp | Buffer | Uint8Array | ((...args: any[]) => any) | { _bsontype: string } ? [] : Type extends ReadonlyArray<infer ArrayType> ? [] | [number, ...NestedPaths<ArrayType, [...Depth, 1]>] : Type extends Map<string, any> ? [string] : Type extends object ? { [ Key in Extract<keyof Type, string>]: Type[Key] extends Type ? [Key] : Type extends Type[Key] ? [Key] : Type[Key] extends ReadonlyArray<infer ArrayType> ? Type extends ArrayType ? [Key] : ArrayType extends Type ? [Key] : [Key, ...NestedPaths<Type[Key], [...Depth, 1]>] : [Key, ...NestedPaths<Type[Key], [...Depth, 1]>] | [Key] }[Extract<keyof Type, string>] : []
remarks

Through testing we determined that a depth of 8 is safe for the typescript compiler and provides reasonable compilation times. 通过测试,我们确定深度为8对于TypeScript编译器是安全的,并提供了合理的编译时间。This number is otherwise not special and should be changed if issues are found with this level of checking. 否则,这个数字并不特殊,如果在这一级别的检查中发现问题,应予以更改。Beyond this depth any helpers that make use of NestedPaths should devolve to not asserting any type safety on the input.超过这个深度,任何使用NestedPaths的助手都应该转变为不对输入断言任何类型安全。

Type parameters类型参数

  • Type

  • Depth: number[]

NestedPathsOfType<TSchema, Type>: KeysOfAType<{ [ Property in Join<NestedPaths<TSchema, []>, ".">]: PropertyType<TSchema, Property> }, Type>

Type parameters类型参数

  • TSchema

  • Type

NonObjectIdLikeDocument: { [ key in keyof ObjectIdLike]?: never } & Document
NotAcceptedFields<TSchema, FieldType>: { readonly [ key in KeysOfOtherType<TSchema, FieldType>]?: never }

It avoids using fields with not acceptable types @public它避免使用不可接受类型的字段@public

Type parameters类型参数

  • TSchema

  • FieldType

NumericType: IntegerType | Decimal128 | Double
OneOrMore<T>: T | ReadonlyArray<T>

Type parameters类型参数

  • T

OnlyFieldsOfType<TSchema, FieldType, AssignableType>: IsAny<TSchema[keyof TSchema], Record<string, FieldType>, AcceptedFields<TSchema, FieldType, AssignableType> & NotAcceptedFields<TSchema, FieldType> & Record<string, AssignableType>>

Type parameters类型参数

  • TSchema

  • FieldType = any

  • AssignableType = FieldType

OperationTime: Timestamp

Represents a specific point in time on a server. 表示服务器上的特定时间点。Can be retrieved by using db.command()可以使用db.command()检索

see

https://docs.mongodb.com/manual/reference/method/db.runCommand/#response

OptionalId<TSchema>: EnhancedOmit<TSchema, "_id"> & { _id?: InferIdType<TSchema> }

Add an optional _id field to an object shaped type向对象形状类型添加可选的_id字段

Type parameters类型参数

  • TSchema

OptionalUnlessRequiredId<TSchema>: TSchema extends { _id: any } ? TSchema : OptionalId<TSchema>

Adds an optional _id field to an object shaped type, unless the _id field is required on that type. 将可选的_id字段添加到对象形状的类型,除非该类型需要_id字段。In the case _id is required, this method continues to require_id.在需要id的情况下,此方法继续使用require_id

privateremarks

ObjectId extends TSchema['_id'] is a confusing ordering at first glance. Rather than ask TSchema['_id'] extends ObjectId which translated to "Is the _id property ObjectId?" we instead ask "Does ObjectId look like (have the same shape) as the _id?"

Type parameters类型参数

  • TSchema

ProfilingLevel: typeof ProfilingLevel[keyof typeof ProfilingLevel]
ProfilingLevelOptions: CommandOperationOptions
Projection<TSchema>: Document
deprecated

since v4.1.0: Since projections support all aggregation operations we have no plans to narrow this type further自v4.1.0以来:由于预测支持所有聚合操作,我们没有计划进一步缩小这种类型

Type parameters类型参数

ProjectionOperators: Document
deprecated

since v4.1.0: Since projections support all aggregation operations we have no plans to narrow this type further自v4.1.0以来:由于预测支持所有聚合操作,我们没有计划进一步缩小这种类型

PropertyType<Type, Property>: string extends Property ? unknown : Property extends keyof Type ? Type[Property] : Property extends `${number}` ? Type extends ReadonlyArray<infer ArrayType> ? ArrayType : unknown : Property extends `${infer Key}.${infer Rest}` ? Key extends `${number}` ? Type extends ReadonlyArray<infer ArrayType> ? PropertyType<ArrayType, Rest> : unknown : Key extends keyof Type ? Type[Key] extends Map<string, infer MapType> ? MapType : PropertyType<Type[Key], Rest> : unknown : unknown

Type parameters类型参数

  • Type

  • Property: string

PullAllOperator<TSchema>: ({ readonly [ key in KeysOfAType<TSchema, ReadonlyArray<any>>]?: TSchema[key] } & NotAcceptedFields<TSchema, ReadonlyArray<any>>) & {}

Type parameters类型参数

  • TSchema

PullOperator<TSchema>: ({ readonly [ key in KeysOfAType<TSchema, ReadonlyArray<any>>]?: Partial<Flatten<TSchema[key]>> | FilterOperations<Flatten<TSchema[key]>> } & NotAcceptedFields<TSchema, ReadonlyArray<any>>) & {}

Type parameters类型参数

  • TSchema

PushOperator<TSchema>: ({ readonly [ key in KeysOfAType<TSchema, ReadonlyArray<any>>]?: Flatten<TSchema[key]> | ArrayOperator<Flatten<TSchema[key]>[]> } & NotAcceptedFields<TSchema, ReadonlyArray<any>>) & {}

Type parameters类型参数

  • TSchema

ReadConcernLevel: typeof ReadConcernLevel[keyof typeof ReadConcernLevel]
ReadConcernLike: ReadConcern | { level: ReadConcernLevel } | ReadConcernLevel
ReadPreferenceLike: ReadPreference | ReadPreferenceMode
ReadPreferenceMode: typeof ReadPreferenceMode[keyof typeof ReadPreferenceMode]
ReduceFunction<TKey, TValue>: (key: TKey, values: TValue[]) => TValue

Type parameters类型参数

Type declaration类型声明

    • (key: TKey, values: TValue[]): TValue
    • Parameters参数

      • key: TKey
      • values: TValue[]

      Returns 返回 TValue

RegExpOrString<T>: T extends string ? BSONRegExp | RegExp | T : T

Type parameters类型参数

  • T

RemoveUserOptions: CommandOperationOptions
ResumeToken: unknown

Represents the logical starting point for a new ChangeStream or resuming a ChangeStream on the server.表示新ChangeStream或在服务器上恢复ChangeStreet的逻辑起点。

see

http://mongodb.asprain.cn/v5.3/changeStreams/#std-label-change-stream-resume

ReturnDocument: typeof ReturnDocument[keyof typeof ReturnDocument]
RunCommandOptions: CommandOperationOptions
SchemaMember<T, V>: { [ P in keyof T]?: V } | {}

Type parameters类型参数

  • T

  • V

ServerApiVersion: typeof ServerApiVersion[keyof typeof ServerApiVersion]
ServerEvents: { closed: any; connect: any; descriptionReceived: any; ended: any; serverHeartbeatFailed: any; serverHeartbeatStarted: any; serverHeartbeatSucceeded: any } & ConnectionPoolEvents & EventEmitterWithState
ServerOptions: Omit<ConnectionPoolOptions, "id" | "generation" | "hostAddress"> & MonitorOptions
ServerSelector: (topologyDescription: TopologyDescription, servers: ServerDescription[]) => ServerDescription[]

Type declaration类型声明

ServerSessionId: { id: Binary }

Type declaration类型声明

ServerType: typeof ServerType[keyof typeof ServerType]
SetFields<TSchema>: ({ readonly [ key in KeysOfAType<TSchema, ReadonlyArray<any> | undefined>]?: OptionalId<Flatten<TSchema[key]>> | AddToSetOperators<OptionalId<Flatten<TSchema[key]>>[]> } & NotAcceptedFields<TSchema, ReadonlyArray<any> | undefined>) & {}

Type parameters类型参数

  • TSchema

SetProfilingLevelOptions: CommandOperationOptions
Sort: string | Exclude<SortDirection, { $meta: string }> | string[] | {} | Map<string, SortDirection> | [string, SortDirection][] | [string, SortDirection]
SortDirection: 1 | -1 | "asc" | "desc" | "ascending" | "descending" | { $meta: string }
Stream: Socket | TLSSocket
SupportedSocketOptions: Pick<TcpNetConnectOpts, typeof LEGAL_TCP_SOCKET_OPTIONS[number]>
SupportedTLSConnectionOptions: Pick<TLSConnectionOptions, Extract<keyof TLSConnectionOptions, typeof LEGAL_TLS_SOCKET_OPTIONS[number]>>
SupportedTLSSocketOptions: Pick<TLSSocketOptions, Extract<keyof TLSSocketOptions, typeof LEGAL_TLS_SOCKET_OPTIONS[number]>>
TagSet: {}

Type declaration类型声明

  • [key: string]: string
TopologyEvents: { close: any; connect: any; error: any; serverClosed: any; serverDescriptionChanged: any; serverOpening: any; timeout: any; topologyClosed: any; topologyDescriptionChanged: any; topologyOpening: any } & Omit<ServerEvents, "connect"> & ConnectionPoolEvents & ConnectionEvents & EventEmitterWithState
TopologyType: typeof TopologyType[keyof typeof TopologyType]
UpdateFilter<TSchema>: { $addToSet?: SetFields<TSchema>; $bit?: OnlyFieldsOfType<TSchema, NumericType | undefined, { and: IntegerType } | { or: IntegerType } | { xor: IntegerType }>; $currentDate?: OnlyFieldsOfType<TSchema, Date | Timestamp, true | { $type: "date" | "timestamp" }>; $inc?: OnlyFieldsOfType<TSchema, NumericType | undefined>; $max?: MatchKeysAndValues<TSchema>; $min?: MatchKeysAndValues<TSchema>; $mul?: OnlyFieldsOfType<TSchema, NumericType | undefined>; $pop?: OnlyFieldsOfType<TSchema, ReadonlyArray<any>, 1 | -1>; $pull?: PullOperator<TSchema>; $pullAll?: PullAllOperator<TSchema>; $push?: PushOperator<TSchema>; $rename?: Record<string, string>; $set?: MatchKeysAndValues<TSchema>; $setOnInsert?: MatchKeysAndValues<TSchema>; $unset?: OnlyFieldsOfType<TSchema, any, "" | true | 1> } & Document

Type parameters类型参数

  • TSchema

W: number | "majority"
WithId<TSchema>: EnhancedOmit<TSchema, "_id"> & { _id: InferIdType<TSchema> }

Add an _id field to an object shaped type @public将id字段添加到对象形状类型@public

Type parameters类型参数

  • TSchema

WithSessionCallback: (session: ClientSession) => Promise<any>

Type declaration类型声明

WithTransactionCallback<T>: (session: ClientSession) => Promise<T>

Type parameters类型参数

  • T = void

Type declaration类型声明

WithoutId<TSchema>: Omit<TSchema, "_id">

Remove the _id field from an object shaped type @public从对象形状类型@public中删除_id字段

Type parameters类型参数

  • TSchema

Variables

AuthMechanism: Readonly<{ MONGODB_AWS: "MONGODB-AWS"; MONGODB_CR: "MONGODB-CR"; MONGODB_DEFAULT: "DEFAULT"; MONGODB_GSSAPI: "GSSAPI"; MONGODB_PLAIN: "PLAIN"; MONGODB_SCRAM_SHA1: "SCRAM-SHA-1"; MONGODB_SCRAM_SHA256: "SCRAM-SHA-256"; MONGODB_X509: "MONGODB-X509" }> = ...
AutoEncryptionLoggerLevel: Readonly<{ Error: 1; FatalError: 0; Info: 3; Trace: 4; Warning: 2 }> = ...
BSONType: Readonly<{ array: 4; binData: 5; bool: 8; date: 9; dbPointer: 12; decimal: 19; double: 1; int: 16; javascript: 13; javascriptWithScope: 15; long: 18; maxKey: 127; minKey: -1; null: 10; object: 3; objectId: 7; regex: 11; string: 2; symbol: 14; timestamp: 17; undefined: 6 }> = ...
BatchType: Readonly<{ DELETE: 3; INSERT: 1; UPDATE: 2 }> = ...
CURSOR_FLAGS: readonly ["tailable", "oplogReplay", "noCursorTimeout", "awaitData", "exhaust", "partial"] = ...
Compressor: Readonly<{ none: 0; snappy: 1; zlib: 2; zstd: 3 }> = ...
ExplainVerbosity: Readonly<{ allPlansExecution: "allPlansExecution"; executionStats: "executionStats"; queryPlanner: "queryPlanner"; queryPlannerExtended: "queryPlannerExtended" }> = ...
GSSAPICanonicalizationValue: Readonly<{ forward: "forward"; forwardAndReverse: "forwardAndReverse"; none: "none"; off: false; on: true }> = ...
LEGAL_TCP_SOCKET_OPTIONS: readonly ["family", "hints", "localAddress", "localPort", "lookup"] = ...
LEGAL_TLS_SOCKET_OPTIONS: readonly ["ALPNProtocols", "ca", "cert", "checkServerIdentity", "ciphers", "crl", "ecdhCurve", "key", "minDHSize", "passphrase", "pfx", "rejectUnauthorized", "secureContext", "secureProtocol", "servername", "session"] = ...
LoggerLevel: Readonly<{ DEBUG: "debug"; ERROR: "error"; INFO: "info"; WARN: "warn"; debug: "debug"; error: "error"; info: "info"; warn: "warn" }> = ...
MONGO_CLIENT_EVENTS: readonly ["connectionPoolCreated", "connectionPoolReady", "connectionPoolCleared", "connectionPoolClosed", "connectionCreated", "connectionReady", "connectionClosed", "connectionCheckOutStarted", "connectionCheckOutFailed", "connectionCheckedOut", "connectionCheckedIn", "commandStarted", "commandSucceeded", "commandFailed", "serverOpening", "serverClosed", "serverDescriptionChanged", "topologyOpening", "topologyClosed", "topologyDescriptionChanged", "error", "timeout", "close", "serverHeartbeatStarted", "serverHeartbeatSucceeded", "serverHeartbeatFailed"] = ...
Map: MapConstructor
MongoErrorLabel: Readonly<{ HandshakeError: "HandshakeError"; NoWritesPerformed: "NoWritesPerformed"; ResetPool: "ResetPool"; ResumableChangeStreamError: "ResumableChangeStreamError"; RetryableWriteError: "RetryableWriteError"; TransientTransactionError: "TransientTransactionError"; UnknownTransactionCommitResult: "UnknownTransactionCommitResult" }> = ...
ObjectID: typeof ObjectId = ObjectId
deprecated

Please use ObjectId

ProfilingLevel: Readonly<{ all: "all"; off: "off"; slowOnly: "slow_only" }> = ...
ReadConcernLevel: Readonly<{ available: "available"; linearizable: "linearizable"; local: "local"; majority: "majority"; snapshot: "snapshot" }> = ...
ReadPreferenceMode: Readonly<{ nearest: "nearest"; primary: "primary"; primaryPreferred: "primaryPreferred"; secondary: "secondary"; secondaryPreferred: "secondaryPreferred" }> = ...
ReturnDocument: Readonly<{ AFTER: "after"; BEFORE: "before" }> = ...
ServerApiVersion: Readonly<{ v1: "1" }> = ...
ServerType: Readonly<{ LoadBalancer: "LoadBalancer"; Mongos: "Mongos"; PossiblePrimary: "PossiblePrimary"; RSArbiter: "RSArbiter"; RSGhost: "RSGhost"; RSOther: "RSOther"; RSPrimary: "RSPrimary"; RSSecondary: "RSSecondary"; Standalone: "Standalone"; Unknown: "Unknown" }> = ...

An enumeration of server types we know about我们知道的服务器类型的枚举

TopologyType: Readonly<{ LoadBalanced: "LoadBalanced"; ReplicaSetNoPrimary: "ReplicaSetNoPrimary"; ReplicaSetWithPrimary: "ReplicaSetWithPrimary"; Sharded: "Sharded"; Single: "Single"; Unknown: "Unknown" }> = ...

An enumeration of topology types we know about我们知道的拓扑类型的枚举

Generated using TypeDoc