文件名称:ch03_android_sample_for_basic
文件大小:113B
文件格式:RAR
更新时间:2018-03-24 07:39:59
android
The initInstance method lets the internal instance be initialized only once and this is done in the MyApplication class as we saw earlier. The getInstance method allows to access the instance from every part of our application and the MySingleton constructor is kept private because we don’t want to allow the creation of multiple instances.