[안드로이드] <application>의 android:name

프로그래밍/Android 관련2017. 12. 4. 19:32

안녕하세요. 개발자 드리머즈입니다.


    <application
        android:name=".common.GlobalApplication"
        android:allowBackup="false"
        android:icon="@drawable/kakaolink_sample_icon"
        android:label="@string/app_name"
        android:supportsRtl="false"
        android:theme="@android:style/Theme.Holo.Light.NoActionBar"> 



안드로이드에서 카카오 계정으로 로그인하기를 공부중인데,

AndroidManifest.xml에 <application> 내에 android:name으로 된 attribute가 있어서 정확하게 뭔지 궁금해서

안드로이드 디벨로퍼 사이트에서 찾아봤습니다.


출처 : https://developer.android.com/guide/topics/manifest/application-element.html#nm

android:name
The fully qualified name of an Application subclass implemented for the application. When the application process is started, this class is instantiated before any of the application's components.

The subclass is optional; most applications won't need one. In the absence of a subclass, Android uses an instance of the base Application class.  


번역

어플리케이션을 위해 구현된 어플리케이션 서브클래스의 이름. 어플리케이션 프로세스가 시작될 때, 어플리케이션의 다른 어떤 컴포넌트보다 먼저 객체화된다(실행된다). 서브클래스는 없어도 된다(대부분의 어플리케이션은 서브클래스를 사용하지 않는다). 서브클래스가 없으면, 안드로이드는 베이스 어플리케이션 클래스의 객체를 사용한다.


라고 합니다.

어플리케이션이 시작될 때 가장 먼저 실행되는.. 클래스가 필요할 때 쓰면 되겠습니다.



작성자

Posted by 드리머즈

관련 글

댓글 영역