본문 바로가기
반응형

Development80

[kotlin] also, let, apply, run, with 언제 무엇을 사용해야 할까요? 우선 with 는 다른 항목들과 사용법이 다릅니다. 인자를 받고 블록의 수행된 결과를 반환합니다. 재밋는 점은 마지막 줄의 결과값이 리턴되는데 어떠한 타입도 리턴이 가능합니다. /** * Calls the specified function [block] with the given [receiver] as its receiver and returns its result. * * For detailed usage information see the documentation for [scope functions](https://kotlinlang.org/docs/reference/scope-functions.html#with). */ @kotlin.internal.InlineOn.. 2021. 4. 8.
[android] bundle 빌드하기, 설치 준비물 Android Studio 3.2 bundletool(github.com/google/bundletool/releases) 상단메뉴 중 Build -> Build Bundle(s) / APK(s) -> Build Bundle(s) 결과물 확인 번들 확인하기 bundletool 설치 bundletool 을 다운받아 사용해도 되지만 한번하고 끝낼게 아니니 설치해 줍니다. brew install bundletool 에러가 발생한 경우(Error: The following directories are not writable by your user: /usr/local/share/man/man7) sudo chown -R $(whoami) $(brew --prefix)/* brew install bundl.. 2021. 4. 7.
[android] System WebView 앱 강제종료 23일 오전부터 대부분 안드로이드 단말에서 웹뷰를 사용하는 하이브리드 앱들이 비정상 종료되는 문제가 발생했습니다. 당일 삼성전자 서비스센터에서 "특정 어플(카카오톡, 증권, 네이버 등) 실행 시 바로 꺼지는 현상"란 조치방법이 올라왔습니다. www.samsungsvc.co.kr/solution/111654 특정 어플(카카오톡, 증권, 네이버 등) 실행 시 바로 꺼지는 현상 특정 어플(카카오톡, 증권, 네이버 등) 실행 시 바로 꺼지는 현상 www.samsungsvc.co.kr 시스템 웹뷰 업데이트 및 크롬 앱 업데이트 방법이 적혀있습니다. 2021. 4. 6.
[android] 전화번호 파싱하기(PhoneNumberUtil) 안드로이드에서 기본적으로 제공되는 클래스를 사용해 봅니다 val phoneNum = PhoneNumberUtils.formatNumber(number, Locale.getDefault().country) val result = PhoneNumberUtils.normalizeNumber(phoneNum) 생각보다 간단합니다... 그런데 국가번호(+82)가 추가되면 country 설정에 따라 변경이 되지 않는 경우도 발생합니다. 폰번호 관련 라이브러리 찾아 사용하니 country 값이 다른나라가 설정되도 National 데이터는 동일하게 노출되어 라이브러리를 사용하기로 했습니다. (github.com/google/libphonenumber) 그리고 데이터를 받는 쪽에서 +82다음에 0 이 있어야 폰넘버로 인.. 2021. 4. 6.
반응형