// Path: compiler/src/test/resources/mock/function/BiConsumer.java
// @FunctionalInterface
// public interface BiConsumer<T, U> {
// 
//     /**
//      * Performs this operation on the given arguments.
//      *
//      * @param t the first input argument
//      * @param u the second input argument
//      */
//     void accept(T t, U u);
// 
// }
// 
// Path: library/src/main/java/info/dourok/esactivity/function/Consumer.java
// @FunctionalInterface
// public interface Consumer<T> {
// 
//   /**
//    * Performs this operation on the given argument.
//    *
//    * @param t the input argument
//    */
//   void accept(T t);
// }
// 
// Path: library/src/main/java/info/dourok/esactivity/MessengerFragment.java
// public static MessengerFragment fragmentFor(Activity activity) {
//   FragmentManager fm = activity.getFragmentManager();
//   if (fm.isDestroyed()) {
//     throw new IllegalStateException("Activity already destroyed");
//   }
//   Fragment fragmentByTag = fm.findFragmentByTag(FRAGMENT_TAG);
//   if (fragmentByTag != null && !(fragmentByTag instanceof MessengerFragment)) {
//     throw new IllegalStateException(
//         "Unexpected " + "fragment instance was returned by FRAGMENT_TAG");
//   }
//   MessengerFragment fragment = (MessengerFragment) fragmentByTag;
//   if (fragment == null) {
//     fragment = new MessengerFragment();
//     fm.beginTransaction().add(fragment, FRAGMENT_TAG).commitAllowingStateLoss();
//     // 接下来需要立刻通过这个 Fragment 来启动 Activity，所以需要立刻添加到 Activity 中
//     fm.executePendingTransactions();
//   }
//   return fragment;
// }


import android.app.Activity;
import android.app.Fragment;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.RequiresApi;
import info.dourok.esactivity.function.BiConsumer;
import info.dourok.esactivity.function.Consumer;
import java.util.Map;
import static info.dourok.esactivity.MessengerFragment.fragmentFor;
package info.dourok.esactivity;



/**
 * @author tiaolins
 * @date 2017/8/15
 */
public abstract class BaseActivityBuilder<T extends BaseActivityBuilder<T, A>, A extends Activity>
    implements BaseBuilder {
  A context;
// Path: compiler/src/test/resources/mock/function/BiConsumer.java
// @FunctionalInterface
// public interface BiConsumer<T, U> {
// 
//     /**
//      * Performs this operation on the given arguments.
//      *
//      * @param t the first input argument
//      * @param u the second input argument
//      */
//     void accept(T t, U u);
// 
// }
// 
// Path: library/src/main/java/info/dourok/esactivity/function/Consumer.java
// @FunctionalInterface
// public interface Consumer<T> {
// 
//   /**
//    * Performs this operation on the given argument.
//    *
//    * @param t the input argument
//    */
//   void accept(T t);
// }
// 
// Path: library/src/main/java/info/dourok/esactivity/MessengerFragment.java
// public static MessengerFragment fragmentFor(Activity activity) {
//   FragmentManager fm = activity.getFragmentManager();
//   if (fm.isDestroyed()) {
//     throw new IllegalStateException("Activity already destroyed");
//   }
//   Fragment fragmentByTag = fm.findFragmentByTag(FRAGMENT_TAG);
//   if (fragmentByTag != null && !(fragmentByTag instanceof MessengerFragment)) {
//     throw new IllegalStateException(
//         "Unexpected " + "fragment instance was returned by FRAGMENT_TAG");
//   }
//   MessengerFragment fragment = (MessengerFragment) fragmentByTag;
//   if (fragment == null) {
//     fragment = new MessengerFragment();
//     fm.beginTransaction().add(fragment, FRAGMENT_TAG).commitAllowingStateLoss();
//     // 接下来需要立刻通过这个 Fragment 来启动 Activity，所以需要立刻添加到 Activity 中
//     fm.executePendingTransactions();
//   }
//   return fragment;
// }


// Path: library/src/main/java/info/dourok/esactivity/BaseActivityBuilder.java
import android.app.Activity;
import android.app.Fragment;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.RequiresApi;
import info.dourok.esactivity.function.BiConsumer;
import info.dourok.esactivity.function.Consumer;
import java.util.Map;
import static info.dourok.esactivity.MessengerFragment.fragmentFor;

package info.dourok.esactivity;



/**
 * @author tiaolins
 * @date 2017/8/15
 */
public abstract class BaseActivityBuilder<T extends BaseActivityBuilder<T, A>, A extends Activity>
    implements BaseBuilder {
  A context;
  private MessengerFragment fragment;