mirror of
https://github.com/InsanusMokrassar/MicroUtils.git
synced 2024-11-26 03:58:45 +00:00
fixes
This commit is contained in:
parent
9132e216c9
commit
abbea906f1
@ -36,10 +36,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> ReadCRUDRepo<ToValue, ToKey>.wit
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> ReadCRUDRepo<ToValue, ToKey>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): ReadCRUDRepo<FromValue, FromKey> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
@ -88,12 +88,12 @@ inline fun <FromKey, FromValue, FromInput, ToKey, ToValue, ToInput> WriteCRUDRep
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified FromInput, reified ToKey, reified ToValue, reified ToInput> WriteCRUDRepo<ToValue, ToKey, ToInput>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline inputFromToTo: suspend FromInput.() -> ToInput = { this as ToInput },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
crossinline inputToToFrom: suspend ToInput.() -> FromInput = { this as FromInput },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline inputFromToTo: suspend FromInput.() -> ToInput = { this as ToInput },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline inputToToFrom: suspend ToInput.() -> FromInput = { this as FromInput },
|
||||
): WriteCRUDRepo<FromValue, FromKey, FromInput> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom),
|
||||
simpleSuspendableMapper({ inputToToFrom(it) }, { inputFromToTo(it) })
|
||||
@ -118,12 +118,12 @@ inline fun <FromKey, FromValue, FromInput, ToKey, ToValue, ToInput> CRUDRepo<ToV
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified FromInput, reified ToKey, reified ToValue, reified ToInput> CRUDRepo<ToValue, ToKey, ToInput>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline inputFromToTo: suspend FromInput.() -> ToInput = { this as ToInput },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
crossinline inputToToFrom: suspend ToInput.() -> FromInput = { this as FromInput },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline inputFromToTo: suspend FromInput.() -> ToInput = { this as ToInput },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline inputToToFrom: suspend ToInput.() -> FromInput = { this as FromInput },
|
||||
): CRUDRepo<FromValue, FromKey, FromInput> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom),
|
||||
simpleSuspendableMapper({ inputToToFrom(it) }, { inputFromToTo(it) })
|
||||
|
@ -77,10 +77,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> ReadKeyValueRepo<ToKey, ToValue>
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> ReadKeyValueRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): ReadKeyValueRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
@ -122,10 +122,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> WriteKeyValueRepo<ToKey, ToValue
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> WriteKeyValueRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): WriteKeyValueRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
@ -148,10 +148,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> KeyValueRepo<ToKey, ToValue>.wit
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> KeyValueRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): KeyValueRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
|
@ -75,10 +75,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> ReadKeyValuesRepo<ToKey, ToValue
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> ReadKeyValuesRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): ReadKeyValuesRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
@ -128,10 +128,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> WriteKeyValuesRepo<ToKey, ToValu
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> WriteKeyValuesRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): WriteKeyValuesRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
@ -154,10 +154,10 @@ inline fun <FromKey, FromValue, ToKey, ToValue> KeyValuesRepo<ToKey, ToValue>.wi
|
||||
|
||||
@Suppress("NOTHING_TO_INLINE")
|
||||
inline fun <reified FromKey, reified FromValue, reified ToKey, reified ToValue> KeyValuesRepo<ToKey, ToValue>.withMapper(
|
||||
crossinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
crossinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
crossinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
crossinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
noinline keyFromToTo: suspend FromKey.() -> ToKey = { this as ToKey },
|
||||
noinline valueFromToTo: suspend FromValue.() -> ToValue = { this as ToValue },
|
||||
noinline keyToToFrom: suspend ToKey.() -> FromKey = { this as FromKey },
|
||||
noinline valueToToFrom: suspend ToValue.() -> FromValue = { this as FromValue },
|
||||
): KeyValuesRepo<FromKey, FromValue> = withMapper(
|
||||
mapper(keyFromToTo, valueFromToTo, keyToToFrom, valueToToFrom)
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user