// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/component/AppComponent.java
// @Singleton
// @Component(modules = AppModule.class)
// public abstract class AppComponent {
//     private static AppComponent mComponent;
// 
//     public static AppComponent getInstance() {
//         if (mComponent == null) {
//             synchronized (AppComponent.class) {
//                 if (mComponent == null) {
//                     mComponent = DaggerAppComponent.builder().appModule(new AppModule(FourFun.getInstance
//                             ())).build();
//                 }
//             }
//         }
// 
//         return mComponent;
//     }
// 
//     public abstract FourFun fourFun();
// 
//     public abstract RetrofitUtil retrofitUtil();
// }
// 
// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/component/FragmentComponent.java
// @PerFragment
// @Component(dependencies = AppComponent.class, modules = FragmentModule.class)
// public interface FragmentComponent {
//     SupportFragment fragment();
// 
//     void inject(ReadFragment fragment);
// 
//     void inject(PictureFragment fragment);
// 
//     void inject(PictureChildFragment fragment);
// 
//     void inject(MediaFragment fragment);
// 
//     void inject(MineFragment fragment);
// }
// 
// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/module/FragmentModule.java
// @Module
// public class FragmentModule {
//     private SupportFragment mFragment;
// 
//     public FragmentModule(SupportFragment fragment) {
//         mFragment = fragment;
//     }
// 
//     @Provides
//     @PerFragment
//     SupportFragment provideSupportFragment() {
//         return mFragment;
//     }
// }


import android.app.Activity;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.joker.fourfun.di.component.AppComponent;
import com.joker.fourfun.di.component.DaggerFragmentComponent;
import com.joker.fourfun.di.component.FragmentComponent;
import com.joker.fourfun.di.module.FragmentModule;
import javax.inject.Inject;
import me.yokeyword.fragmentation.SupportActivity;
import me.yokeyword.fragmentation.SupportFragment;
package com.joker.fourfun.base;





public abstract class BaseMvpFragment<V extends BaseView, T extends BaseMvpPresenter<V>> extends
        SupportFragment implements
        BaseView {
    @Inject
    protected T mPresenter;
    protected SupportActivity mActivity;

    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle
            savedInstanceState) {
        return createView(inflater, container, savedInstanceState);
    }

    protected abstract View createView(LayoutInflater inflater, ViewGroup container, Bundle
            savedInstanceState);

    @Override
    @SuppressWarnings("unchecked")
    public void onAttach(Activity activity) {
        super.onAttach(activity);
        initInject();
        mActivity = _mActivity;
        mPresenter.attach((V) this);
    }

    protected FragmentComponent getComponent() {
// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/component/AppComponent.java
// @Singleton
// @Component(modules = AppModule.class)
// public abstract class AppComponent {
//     private static AppComponent mComponent;
// 
//     public static AppComponent getInstance() {
//         if (mComponent == null) {
//             synchronized (AppComponent.class) {
//                 if (mComponent == null) {
//                     mComponent = DaggerAppComponent.builder().appModule(new AppModule(FourFun.getInstance
//                             ())).build();
//                 }
//             }
//         }
// 
//         return mComponent;
//     }
// 
//     public abstract FourFun fourFun();
// 
//     public abstract RetrofitUtil retrofitUtil();
// }
// 
// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/component/FragmentComponent.java
// @PerFragment
// @Component(dependencies = AppComponent.class, modules = FragmentModule.class)
// public interface FragmentComponent {
//     SupportFragment fragment();
// 
//     void inject(ReadFragment fragment);
// 
//     void inject(PictureFragment fragment);
// 
//     void inject(PictureChildFragment fragment);
// 
//     void inject(MediaFragment fragment);
// 
//     void inject(MineFragment fragment);
// }
// 
// Path: client/FourFun/app/src/main/java/com/joker/fourfun/di/module/FragmentModule.java
// @Module
// public class FragmentModule {
//     private SupportFragment mFragment;
// 
//     public FragmentModule(SupportFragment fragment) {
//         mFragment = fragment;
//     }
// 
//     @Provides
//     @PerFragment
//     SupportFragment provideSupportFragment() {
//         return mFragment;
//     }
// }


// Path: client/FourFun/app/src/main/java/com/joker/fourfun/base/BaseMvpFragment.java
import android.app.Activity;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.joker.fourfun.di.component.AppComponent;
import com.joker.fourfun.di.component.DaggerFragmentComponent;
import com.joker.fourfun.di.component.FragmentComponent;
import com.joker.fourfun.di.module.FragmentModule;
import javax.inject.Inject;
import me.yokeyword.fragmentation.SupportActivity;
import me.yokeyword.fragmentation.SupportFragment;

package com.joker.fourfun.base;





public abstract class BaseMvpFragment<V extends BaseView, T extends BaseMvpPresenter<V>> extends
        SupportFragment implements
        BaseView {
    @Inject
    protected T mPresenter;
    protected SupportActivity mActivity;

    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle
            savedInstanceState) {
        return createView(inflater, container, savedInstanceState);
    }

    protected abstract View createView(LayoutInflater inflater, ViewGroup container, Bundle
            savedInstanceState);

    @Override
    @SuppressWarnings("unchecked")
    public void onAttach(Activity activity) {
        super.onAttach(activity);
        initInject();
        mActivity = _mActivity;
        mPresenter.attach((V) this);
    }

    protected FragmentComponent getComponent() {
        return DaggerFragmentComponent.builder().appComponent(AppComponent.getInstance()).fragmentModule