1234567891011121314151617181920212223242526272829303132333435363738394041 |
- package com.rthoni.camotion.ui.fragments;
-
- import android.content.Context;
- import android.os.Bundle;
- import android.view.View;
-
- import com.luticate.auth.dbo.LuFullLoginDbo;
- import com.luticate.utils.dbo.LuDbo;
- import com.luticate.utils.ui.fragments.ViewPaginationFragment;
- import com.rthoni.camotion.dbo.LocationDbo;
-
- import org.json.JSONException;
-
- /**
- * Created by robin on 12/3/15.
- */
- public abstract class CamotionFragment<Dbo extends LuDbo, DboView extends View> extends ViewPaginationFragment<Dbo, DboView> {
- protected LuFullLoginDbo _fullLoginDbo = null;
- protected LocationDbo _currentLocation = null;
-
- @Override
- public void onAttach(Context context) {
- super.onAttach(context);
- try {
- _fullLoginDbo = new LuFullLoginDbo();
- _fullLoginDbo.fromString(getArguments().getString("CAMOTION_LOGIN_DBO"));
-
- _currentLocation = new LocationDbo();
- _currentLocation.fromString(getArguments().getString("CAMOTION_LOCATION_DBO"));
- } catch (JSONException e) {
- e.printStackTrace();
- }
- }
-
- @Override
- public void onDetach() {
- super.onDetach();
- _fullLoginDbo = null;
- _currentLocation = null;
- }
- }
|