Android 4대 컴포넌트 ● 안드로이드 4대 컴포넌트 1. Activity - UI 화면을 담당하는 컴포넌트 - 자바 소스에서 Activity 클래스를 상속 받아야 함 - 안드로이드 앱은 반드시 하나 이상의 Acitivity를 포함해야 함 - 두 개의 액티비티를 동시에 display할 수 없음 - 다른 앱의 액티비티 호출도 가능 2. Service - Background에서 동작하는 컴포넌트- Activity가 종료되어 있는 상태에서도 동작시키기 위함 (ex. MP3 Player)- 사용법① startService() - stopService() Intent intent = new Intent("test.test.com.startService"); intent.putExtra("count", "1"); startService(i.. 이전 1 다음