Example usage for android.app Activity toString

List of usage examples for android.app Activity toString

Introduction

In this page you can find the example usage for android.app Activity toString.

Prototype

@Override
    public String toString() 

Source Link

Usage

From source file:com.nbplus.vbroadlauncher.fragment.AppGridFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    try {/*from  w w w  . j  a v a2s . com*/
        ((ShowApplicationActivity) activity).setOnActivityInteractionListener(this);
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnFragmentInteractionListener");
    }
}

From source file:com.morlunk.mumbleclient.servers.ServerEditFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    try {/*ww  w .j  a va  2s .  co  m*/
        mListener = (ServerEditListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement ServerEditListener!");
    }
}

From source file:org.sensapp.android.sensappdroid.fragments.SensorListFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    try {//w w  w .j a v a 2  s. co m
        sensorSelectedListener = (OnSensorSelectedListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnSensorSelectedListener");
    }
}

From source file:br.com.expressobits.test.fragmentsui.HeadLinesFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);

    // This makes sure that the container activity has implemented
    // the callback interface. If not, it throws an exception.
    try {//from   w  w w.j a  va2s.com
        mCallback = (OnHeadlineSelectedListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnHeadlineSelectedListener");
    }
}

From source file:loonyb.in.posmachine.CustomersFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);

    // This makes sure that the container activity has implemented
    // the callback interface. If not, it throws an exception.
    try {/*  ww w  .j  a  va 2  s.  c  o  m*/
        mCallback = (OnCustomerSelectedListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnCustomerSelectedListener");
    }
}

From source file:com.lambdasoup.quickfit.ui.TimeDialogFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    if (activity instanceof OnFragmentInteractionListenerProvider) {
        listener = ((OnFragmentInteractionListenerProvider) activity)
                .getOnTimeDialogFragmentInteractionListener();
    } else {/*  w  w w .j av a 2  s  . co m*/
        throw new RuntimeException(
                activity.toString() + " must implement OnFragmentInteractionListenerProvider");
    }
}

From source file:com.zapek.android.workerfragment.WorkerFragment.java

private void handleResult(Activity activity, int resultCode, Bundle resultData) {
    WorkerFragmentReceiver receiver = null;
    try {//from w  ww  . j av  a 2s.c o m
        receiver = (WorkerFragmentReceiver) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement WorkerFragmentReceiver");
    }
    receiver.onReceiveResult(resultCode, resultData);
}

From source file:com.inovex.zabbixmobile.activities.fragments.BaseSeverityFilterListFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);

    try {//from   w ww . j a  v a 2  s  .  c  o m
        mCallbackMain = (OnSeveritySelectedListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnSeveritySelectedListener.");
    }
}

From source file:com.cerema.cloud2.ui.fragment.SearchShareesFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    try {/*from w w w  .  ja  v  a  2 s . co  m*/
        mListener = (ShareFragmentListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(activity.toString() + " must implement OnFragmentInteractionListener");
    }
}

From source file:com.pdftron.pdf.controls.UserCropSelectionDialogFragment.java

@Override
public void onAttach(Activity activity) {
    super.onAttach(activity);
    try {//from  ww  w.java2 s  . co m
        mListener = (UserCropSelectionDialogFragmentListener) activity;
    } catch (ClassCastException e) {
        throw new ClassCastException(
                activity.toString() + " must implement UserCropSelectionDialogFragmentListener");
    }
}