# MapperRepo

interface MapperRepo < FromKey , FromValue , ToKey , ToValue >(source)

Interface for repositories that provide bidirectional mapping between two sets of key-value types. This is useful for adapting repositories to work with different key and value types.

#### Type Parameters

FromKey

The original key type (inner/source)

FromValue

The original value type (inner/source)

ToKey

The target key type (outer/destination)

ToValue

The target value type (outer/destination)

#### Inheritors

SimpleMapperRepo
MapperReadCRUDRepo
MapperWriteCRUDRepo
MapperCRUDRepo
MapperReadKeyValueRepo
MapperWriteKeyValueRepo
MapperKeyValueRepo
MapperReadKeyValuesRepo
MapperWriteKeyValuesRepo
MapperKeyValuesRepo

## Types

Companion
Link copied to clipboard
object Companion

## Properties

keyMapper
Link copied to clipboard
open val keyMapper : SimpleSuspendableMapper < FromKey , ToKey >

Provides a mapper for converting keys between inner and outer types.

valueMapper
Link copied to clipboard
open val valueMapper : SimpleSuspendableMapper < FromValue , ToValue >

Provides a mapper for converting values between inner and outer types.

## Functions

toInnerKey
Link copied to clipboard
open suspend fun ToKey . toInnerKey (): FromKey

Converts a key from the outer type to the inner type.

toInnerValue
Link copied to clipboard
open suspend fun ToValue . toInnerValue (): FromValue

Converts a value from the outer type to the inner type.

toOutKey
Link copied to clipboard
open suspend fun FromKey . toOutKey (): ToKey

Converts a key from the inner type to the outer type.

toOutValue
Link copied to clipboard
open suspend fun FromValue . toOutValue (): ToValue

Converts a value from the inner type to the outer type.