Table of Contents

Class AkavacheBuilderExtensions

Namespace
Akavache.NewtonsoftJson
Assembly
Akavache.NewtonsoftJson.dll

Provides extension methods for configuring Akavache to use Newtonsoft.Json serialization.

public static class AkavacheBuilderExtensions
Inheritance
AkavacheBuilderExtensions

Methods

WithSerializerNewtonsoftBson(IAkavacheBuilder)

Configures the builder to use Newtonsoft.Json BSON serialization with default settings.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftBson(this IAkavacheBuilder builder)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder is null.

WithSerializerNewtonsoftBson(IAkavacheBuilder, JsonSerializerSettings)

Configures the builder to use Newtonsoft.Json BSON serialization with custom settings.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftBson(this IAkavacheBuilder builder, JsonSerializerSettings settings)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

settings JsonSerializerSettings

The JSON serializer settings to use for customizing BSON serialization behavior.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder or settings is null.

WithSerializerNewtonsoftBson(IAkavacheBuilder, Action<JsonSerializerSettings>)

Configures the builder to use Newtonsoft.Json BSON serialization with settings configured through a delegate.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftBson(this IAkavacheBuilder builder, Action<JsonSerializerSettings> configure)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

configure Action<JsonSerializerSettings>

Action to configure the JSON serializer settings for BSON serialization.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder or configure is null.

WithSerializerNewtonsoftJson(IAkavacheBuilder)

Configures the builder to use Newtonsoft.Json serialization with default settings.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftJson(this IAkavacheBuilder builder)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder is null.

WithSerializerNewtonsoftJson(IAkavacheBuilder, JsonSerializerSettings)

Configures the builder to use Newtonsoft.Json serialization with custom settings.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftJson(this IAkavacheBuilder builder, JsonSerializerSettings settings)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

settings JsonSerializerSettings

The JSON serializer settings to use for customizing serialization behavior.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder or settings is null.

WithSerializerNewtonsoftJson(IAkavacheBuilder, Action<JsonSerializerSettings>)

Configures the builder to use Newtonsoft.Json serialization with settings configured through a delegate.

[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
public static IAkavacheBuilder WithSerializerNewtonsoftJson(this IAkavacheBuilder builder, Action<JsonSerializerSettings> configure)

Parameters

builder IAkavacheBuilder

The Akavache builder to configure.

configure Action<JsonSerializerSettings>

Action to configure the JSON serializer settings.

Returns

IAkavacheBuilder

The builder instance for fluent configuration.

Exceptions

ArgumentNullException

Thrown when builder or configure is null.