(
filter: Filter<TSchema>,
replacement: WithoutId<TSchema>,
options?: FindOneAndReplaceOptions
)
| 984 | replacement: WithoutId<TSchema> |
| 985 | ): Promise<WithId<TSchema> | null>; |
| 986 | async findOneAndReplace( |
| 987 | filter: Filter<TSchema>, |
| 988 | replacement: WithoutId<TSchema>, |
| 989 | options?: FindOneAndReplaceOptions |
| 990 | ): Promise<WithId<TSchema> | ModifyResult<TSchema> | null> { |
| 991 | return await executeOperation( |
| 992 | this.client, |
| 993 | new FindOneAndReplaceOperation( |
| 994 | this as TODO_NODE_3286, |
| 995 | filter, |
| 996 | replacement, |
| 997 | resolveOptions(this, options) |
| 998 | ) as TODO_NODE_3286 |
| 999 | ); |
| 1000 | } |
| 1001 | |
| 1002 | /** |
| 1003 | * Find a document and update it in one atomic operation. Requires a write lock for the duration of the operation. |
no test coverage detected