// Path: AutofillFramework/Application/src/main/java/com/example/android/autofill/app/Util.java
// public static final boolean DEBUG = true;
// 
// Path: AutofillFramework/Application/src/main/java/com/example/android/autofill/app/Util.java
// public static final String TAG = "AutofillSample";


import static com.example.android.autofill.app.Util.DEBUG;
import static com.example.android.autofill.app.Util.TAG;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.view.ViewGroup;
import android.view.autofill.AutofillManager;
import android.widget.Button;
import android.widget.EditText;
import android.widget.LinearLayout;
import android.widget.TextView;
import com.example.android.autofill.app.R;
import java.util.Map;
        int i = 0;
        for (Map.Entry<Integer, String> entry : stepsMap.entrySet()) {
            int labelId = entry.getKey();
            String autofillHints = entry.getValue();
            if (DEBUG) debug("step %d: %s->%s", i, getString(labelId), autofillHints);
            mSteps[i++] = newStep(labelId, autofillHints);
        }
    }

    private LinearLayout newStep(int labelId, String autofillHints) {
        LinearLayout layout = new LinearLayout(this);
        layout.setOrientation(LinearLayout.HORIZONTAL);

        TextView label = new TextView(this);
        label.setText(labelId);
        layout.addView(label);

        EditText input = new EditText(this);
        input.setAutofillHints(autofillHints);
        input.setWidth(500); // TODO: proper size
        layout.addView(input);

        return layout;
    }

    protected void debug(String fmt, Object... args) {
        Log.d(TAG, getLocalClassName() + "." + String.format(fmt, args));
    }

    protected void warn(String fmt, Object... args) {
// Path: AutofillFramework/Application/src/main/java/com/example/android/autofill/app/Util.java
// public static final boolean DEBUG = true;
// 
// Path: AutofillFramework/Application/src/main/java/com/example/android/autofill/app/Util.java
// public static final String TAG = "AutofillSample";


// Path: AutofillFramework/Application/src/main/java/com/example/android/autofill/app/edgecases/AbstractMultipleStepsActivity.java
import static com.example.android.autofill.app.Util.DEBUG;
import static com.example.android.autofill.app.Util.TAG;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.view.ViewGroup;
import android.view.autofill.AutofillManager;
import android.widget.Button;
import android.widget.EditText;
import android.widget.LinearLayout;
import android.widget.TextView;
import com.example.android.autofill.app.R;
import java.util.Map;

        int i = 0;
        for (Map.Entry<Integer, String> entry : stepsMap.entrySet()) {
            int labelId = entry.getKey();
            String autofillHints = entry.getValue();
            if (DEBUG) debug("step %d: %s->%s", i, getString(labelId), autofillHints);
            mSteps[i++] = newStep(labelId, autofillHints);
        }
    }

    private LinearLayout newStep(int labelId, String autofillHints) {
        LinearLayout layout = new LinearLayout(this);
        layout.setOrientation(LinearLayout.HORIZONTAL);

        TextView label = new TextView(this);
        label.setText(labelId);
        layout.addView(label);

        EditText input = new EditText(this);
        input.setAutofillHints(autofillHints);
        input.setWidth(500); // TODO: proper size
        layout.addView(input);

        return layout;
    }

    protected void debug(String fmt, Object... args) {
        Log.d(TAG, getLocalClassName() + "." + String.format(fmt, args));
    }

    protected void warn(String fmt, Object... args) {
        Log.w(TAG, getLocalClassName() + "." + String.format(fmt, args));