Couchbase .NET SDK __CB_SDK_VERSION__

Show / Hide Table of Contents

Class MutateInResultExtensions

Extensions for IMutateInResult.

Inheritance
object
MutateInResultExtensions
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Couchbase.KeyValue
Assembly: Couchbase.NetClient.dll
Syntax
public static class MutateInResultExtensions

Methods

View Source

ContentAs<TDocument, TContent>(IMutateInResult<TDocument>, Expression<Func<TDocument, TContent>>)

Get the result type TContent from a document of type TDocument, using a given lambda expression path.

Declaration
public static TContent? ContentAs<TDocument, TContent>(this IMutateInResult<TDocument> result, Expression<Func<TDocument, TContent>> path)
Parameters
Type Name Description
IMutateInResult<TDocument> result

IMutateInResult<TDocument> where the the subdocument mutation result was returned.

Expression<Func<TDocument, TContent>> path

Lambda expression path that navigates to the subdocument from the parent document. This must be a path that was provided originally to the MutateInSpecBuilder<TDocument>.

Returns
Type Description
TContent

The subdocument content.

Type Parameters
Name Description
TDocument

Type of the parent document.

TContent

Type of the subdocument.

Exceptions
Type Condition
ArgumentNullException

result or path is null.

  • View Source
In this article
Back to top Copyright © 2020 Couchbase, Inc. All rights reserved.