Before 2022/Android 46

Kotlin + Retrofit2 + Okhttp3을 활용한 REST API 기본 메소드 작성

Manifest build.gradle(app)에 아래와 같은 내용 추가 (*1.8 관련 내용 추가 안할 시, NoSuchMethodError 발생) android { ... compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } kotlinOptions { jvmTarget = "1.8" } ... } dependencies { ... //Retrofit2 implementation 'com.squareup.retrofit2:retrofit:2.9.0' implementation 'com.squareup.retrofit2:converter-gson:2.9.0' //Ok..

Before 2022/Android 2020.07.16

AndroidX의 Android Security를 활용한 SharedPreferences 암호화

build.gradle(app)에 아래와 같은 dependency 추가 dependencies { ... implementation 'androidx.security:security-crypto:1.1.0-alpha01' ... } import android.content.Context import android.content.SharedPreferences import android.security.keystore.KeyGenParameterSpec import android.security.keystore.KeyProperties import android.util.Log import androidx.security.crypto.EncryptedSharedPreferences import androi..

Before 2022/Android 2020.07.16