package com.meituan.sample.robusttest;

import android.util.Log;

import com.meituan.sample.robusttest.other.Hll;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by c_kunwu on 16/5/5.
 */
public class State<T> implements Cloneable, Comparable {
    public static int index = 0;
    public int index1 = 0;
    public String tag = "current";
    public Hll hll;

    public long getIndex() {
        getText(1, 2L, 1);
        return -100;
    }

    public String getText(int i, Long j, Integer x) {
        State state = new State(new Hll(true));
        state.index1 = 3;
        state.hll.needP();
        Hll h = state.hll;
        state.get();
        h.needP();
        state.setIndex(hll, 1, 2L, new Object());
        return tag + ": ";
    }


    public State(Hll hll) {
        this.hll = hll;
    }

    public void setIndex(Hll hll, int i, Long j, Object x) {
        this.hll = hll;
        hll.needP();
//        State.staticMethod();
    }

    public List<T> getT(Hll hll, int i, Long j, Object x) {
        List<T> list = new ArrayList<>();
        Integer p = Integer.reverse(index);
        list.add((T) p);
        return list;
    }

    public T get() {
        Log.d("robust", "in state.get()  ");
        return getT(hll, 0, 1L, new Object()).get(0);
    }

    @Override
    public int compareTo(Object another) {
        return 0;
    }

    public int getTime() {
        return 0;
    }

    public String getName() {
        return null;
    }

    public void setName(String name) {


    }
}


@@ -37,1508 +37,74 @@
 t;%0A%0A
-import android.util.Log;%0A%0Aimport com.meituan.sample.robusttest.other.Hll;%0A%0Aimport java.util.ArrayList;%0Aimport java.util.List;%0A%0A/**%0A * Created by c_kunwu on 16/5/5.%0A */%0Apublic class State%3CT%3E implements Cloneable, Comparable %7B%0A    public static int index = 0;%0A    public int index1 = 0;%0A    public String tag = %22current%22;%0A    public Hll hll;%0A%0A    public long getIndex() %7B%0A        getText(1, 2L, 1);%0A        return -100;%0A    %7D%0A%0A    public String getText(int i, Long j, Integer x) %7B%0A        State state = new State(new Hll(true));%0A        state.index1 = 3;%0A        state.hll.needP();%0A        Hll h = state.hll;%0A        state.get();%0A        h.needP();%0A        state.setIndex(hll, 1, 2L, new Object());%0A        return tag + %22: %22;%0A    %7D%0A%0A%0A    public State(Hll hll) %7B%0A        this.hll = hll;%0A    %7D%0A%0A    public void setIndex(Hll hll, int i, Long j, Object x) %7B%0A        this.hll = hll;%0A        hll.needP();%0A//        State.staticMethod();%0A    %7D%0A%0A    public List%3CT%3E getT(Hll hll, int i, Long j, Object x) %7B%0A        List%3CT%3E list = new ArrayList%3C%3E();%0A        Integer p = Integer.reverse(index);%0A        list.add((T) p);%0A        return list;%0A    %7D%0A%0A    public T get() %7B%0A        Log.d(%22robust%22, %22in state.get()  %22);%0A        return getT(hll, 0, 1L, new Object()).get(0);%0A    %7D%0A%0A    @Override%0A    public int compareTo(Object another) %7B%0A        return 0;%0A    %7D%0A%0A    public int getTime() %7B%0A        return 0;%0A    %7D%0A%0A    public String getName() %7B%0A        return null;%0A    %7D%0A%0A    public void setName(String name) %7B%0A%0A%0A    %7D
+/**%0A * Created by c_kunwu on 16/5/5.%0A */%0Apublic class State%3CT%3E  %7B%0A
 %0A%7D%0A%0A

remove state body