04-19 01:07
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- 예금
- Andorid
- RETROFIT
- CHAT GPT
- 3rd framework
- ChatGPT
- Mac
- Data Binding
- Android
- Swift
- arm-linux-androideabi
- java
- ndk r24
- MG더뱅킹정기예금
- 청약
- ios
- 고금리
- audio record
- gradle
- kotlin
- KB
- BindingAdapter
- JetPack
- 달러예금
- Android Studio
- 용산 호반써밋 에이디션
- ndkVersion
- 새마을금고
- 사전청약
- EditText
Archives
- Today
- Total
pear
[android] Life Cycle 본문
Life Cycle
액티비티
액티비티가 시작하는 순간부터 종료되는 순간까지의 주기를 말한다.
onCreate(): 액티비티가 시작될 때 레이아웃을 구성하면서 한 번 실행
onStart(): 액티비티가 사용자에게 보이기 직전에 실행. BroadcastReceiver 실행
onResume(): 사용자가 액티비티와 상호작용하는 기능을 넣는 곳으로, 무조건 실행되어야 하는 기능이 들어감
onPause(): 포커스를 잃어 화면이 부분적으로는 보이지만 곧 사라질 때 실행
onStop(): 사용자에게서 화면이 완전히 사라지고, 다른 액티비티가 보여질 때 호출
onDestroy(): (화면회전 혹은)화면이 완전히 종료되기 직전에 호출
프래그먼트
onCreate(), onStart(), onResume(), onPause(), onStop(), onDestroy(). |
onCreate onCreateView onViewCreated onViewStateResotred onStart onResume onPause onStop onSaveInstanceState onDestoryView onDestory |
onAttach(Activity) called once the fragment is associated with its activity. onCreate(Bundle) called to do initial creation of the fragment. onCreateView(LayoutInflater, ViewGroup, Bundle) creates and returns the view hierarchy associated with the fragment. onActivityCreated(Bundle) tells the fragment that its activity has completed its own Activity.onCreate(). onViewStateRestored(Bundle) tells the fragment that all of the saved state of its view hierarchy has been restored. onStart() makes the fragment visible to the user (based on its containing activity being started). onResume() makes the fragment begin interacting with the user (based on its containing activity being resumed). onPause() fragment is no longer interacting with the user either because its activity is being paused or a fragment operation is modifying it in the activity. onStop() fragment is no longer visible to the user either because its activity is being stopped or a fragment operation is modifying it in the activity. onSaveInstanceState() onDestroyView() allows the fragment to clean up resources associated with its View. onDestroy() called to do final cleanup of the fragment's state. onDetach() called immediately prior to the fragment no longer being associated with its activity. |


'android' 카테고리의 다른 글
[android] Thread와 Handler (0) | 2023.08.09 |
---|---|
[android] List View and Recycler View (0) | 2023.08.09 |
[android] DataBinderMapperImpl.java:9: error: cannot find symbol (0) | 2023.07.20 |
[android][ViualStudio Xamarin] 환경 설정. (0) | 2023.06.16 |
[android] android studio build setting issue - Unsupported Java. Your build is currently configured to use Java 17.0.6 and Gradle (0) | 2023.06.16 |