Table of Contents

Class KEFCoreEntityTypeRocksDbExtensions

Namespace
MASES.EntityFrameworkCore.KNet.Extensions
Assembly
MASES.EntityFrameworkCore.KNet.dll

Extension methods for KEFCore RocksDB lifecycle metadata associated to entity types.

public static class KEFCoreEntityTypeRocksDbExtensions
Inheritance
KEFCoreEntityTypeRocksDbExtensions
Inherited Members

Methods

GetRocksDbLifecycleHandler(IReadOnlyEntityType)

Gets the RocksDB lifecycle handler instance associated to the entity type.

public static IRocksDbLifecycleHandler? GetRocksDbLifecycleHandler(this IReadOnlyEntityType entityType)

Parameters

entityType IReadOnlyEntityType

The entity type.

Returns

IRocksDbLifecycleHandler

The configured handler instance, or null if no handler instance was configured.

GetRocksDbLifecycleHandlerType(IReadOnlyEntityType)

Gets the RocksDB lifecycle handler type associated to the entity type.

public static Type? GetRocksDbLifecycleHandlerType(this IReadOnlyEntityType entityType)

Parameters

entityType IReadOnlyEntityType

The entity type.

Returns

Type

The handler type implementing IRocksDbLifecycleHandler, or null if no handler type was configured.

SetRocksDbLifecycleHandler(IConventionEntityType, IRocksDbLifecycleHandler?, bool)

Sets the RocksDB lifecycle handler instance associated to the entity type.

public static IRocksDbLifecycleHandler? SetRocksDbLifecycleHandler(this IConventionEntityType entityType, IRocksDbLifecycleHandler? handler, bool fromDataAnnotation = false)

Parameters

entityType IConventionEntityType

The convention entity type.

handler IRocksDbLifecycleHandler

The handler instance implementing IRocksDbLifecycleHandler, or null to remove the annotation.

fromDataAnnotation bool

Indicates whether the configuration was specified using a data annotation.

Returns

IRocksDbLifecycleHandler

The configured handler instance.

SetRocksDbLifecycleHandler(IMutableEntityType, IRocksDbLifecycleHandler?)

Sets the RocksDB lifecycle handler instance associated to the entity type.

public static void SetRocksDbLifecycleHandler(this IMutableEntityType entityType, IRocksDbLifecycleHandler? handler)

Parameters

entityType IMutableEntityType

The mutable entity type.

handler IRocksDbLifecycleHandler

The handler instance implementing IRocksDbLifecycleHandler, or null to remove the annotation.

SetRocksDbLifecycleHandlerType(IConventionEntityType, Type?, bool)

Sets the RocksDB lifecycle handler type associated to the entity type.

public static Type? SetRocksDbLifecycleHandlerType(this IConventionEntityType entityType, Type? handlerType, bool fromDataAnnotation = false)

Parameters

entityType IConventionEntityType

The convention entity type.

handlerType Type

The handler type implementing IRocksDbLifecycleHandler, or null to remove the annotation.

fromDataAnnotation bool

Indicates whether the configuration was specified using a data annotation.

Returns

Type

The configured handler type.

Exceptions

ArgumentException

Thrown when handlerType does not implement IRocksDbLifecycleHandler.

SetRocksDbLifecycleHandlerType(IMutableEntityType, Type?)

Sets the RocksDB lifecycle handler type associated to the entity type.

public static void SetRocksDbLifecycleHandlerType(this IMutableEntityType entityType, Type? handlerType)

Parameters

entityType IMutableEntityType

The mutable entity type.

handlerType Type

The handler type implementing IRocksDbLifecycleHandler, or null to remove the annotation.

Exceptions

ArgumentException

Thrown when handlerType does not implement IRocksDbLifecycleHandler.