From 43b0dd4eed79241ea32d0dac6c4a2fcaf2736bda Mon Sep 17 00:00:00 2001 From: r-ca Date: Sat, 16 Dec 2023 14:20:26 +0900 Subject: [PATCH] =?UTF-8?q?Logger=E3=81=AEModule=E4=BD=9C=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lacerta/utils/module/LacertaLoggerModule.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/utils/src/main/java/one/nem/lacerta/utils/module/LacertaLoggerModule.java b/utils/src/main/java/one/nem/lacerta/utils/module/LacertaLoggerModule.java index 1dedeee6..38e0abd9 100644 --- a/utils/src/main/java/one/nem/lacerta/utils/module/LacertaLoggerModule.java +++ b/utils/src/main/java/one/nem/lacerta/utils/module/LacertaLoggerModule.java @@ -1,4 +1,17 @@ package one.nem.lacerta.utils.module; -public class LacertaLoggerModule { +import dagger.Binds; +import dagger.Module; +import dagger.hilt.InstallIn; +import dagger.hilt.components.SingletonComponent; + +import one.nem.lacerta.utils.LacertaLogger; +import one.nem.lacerta.utils.impl.LacertaLoggerImpl; + +@Module +@InstallIn(SingletonComponent.class) // ログの取得であまり負荷をかけたくないので +abstract public class LacertaLoggerModule { + + @Binds + public abstract LacertaLogger bindLacertaLogger(LacertaLoggerImpl lacertaLoggerImpl); }