public class FragmentLifecycleCallbacksImpl
extends android.support.v4.app.FragmentManager.FragmentLifecycleCallbacks
FragmentLifecycleCallbacksImpl 可用来代替在 BaseFragment 中加入适配代码的传统方式
FragmentLifecycleCallbacksImpl 这种方案类似于 AOP, 面向接口, 侵入性低, 方便统一管理, 扩展性强, 并且也支持适配三方库的 Fragment
Created by JessYan on 2018/8/25 13:52 Contact me Follow me ================================================
| Constructor and Description |
|---|
FragmentLifecycleCallbacksImpl(AutoAdaptStrategy autoAdaptStrategy) |
| Modifier and Type | Method and Description |
|---|---|
void |
onFragmentCreated(android.support.v4.app.FragmentManager fm,
android.support.v4.app.Fragment f,
android.os.Bundle savedInstanceState) |
void |
setAutoAdaptStrategy(AutoAdaptStrategy autoAdaptStrategy)
设置屏幕适配逻辑策略类
|
onFragmentActivityCreated, onFragmentAttached, onFragmentDestroyed, onFragmentDetached, onFragmentPaused, onFragmentPreAttached, onFragmentPreCreated, onFragmentResumed, onFragmentSaveInstanceState, onFragmentStarted, onFragmentStopped, onFragmentViewCreated, onFragmentViewDestroyedpublic FragmentLifecycleCallbacksImpl(AutoAdaptStrategy autoAdaptStrategy)
public void onFragmentCreated(android.support.v4.app.FragmentManager fm,
android.support.v4.app.Fragment f,
android.os.Bundle savedInstanceState)
onFragmentCreated in class android.support.v4.app.FragmentManager.FragmentLifecycleCallbackspublic void setAutoAdaptStrategy(AutoAdaptStrategy autoAdaptStrategy)
autoAdaptStrategy - AutoAdaptStrategy