Share via


IObjectAdapterWithTest.Test(Operation, Object) Method

Definition

Using the "test" operation a value at the target location is compared for equality to a specified value.

The operation object MUST contain a "value" member that specifies value to be compared to the target location's value.

The target location MUST be equal to the "value" value for the operation to be considered successful.

For example: { "op": "test", "path": "/a/b/c", "value": "foo" }

See RFC 6902 https://tools.ietf.org/html/rfc6902#page-7

public:
 void Test(Microsoft::AspNetCore::JsonPatch::Operations::Operation ^ operation, System::Object ^ objectToApplyTo);
public void Test (Microsoft.AspNetCore.JsonPatch.Operations.Operation operation, object objectToApplyTo);
abstract member Test : Microsoft.AspNetCore.JsonPatch.Operations.Operation * obj -> unit
Public Sub Test (operation As Operation, objectToApplyTo As Object)

Parameters

operation
Operation

The test operation.

objectToApplyTo
Object

Object to apply the operation to.

Applies to