Android Open Source - campus Dao Session






From Project

Back to project page campus.

License

The source code is released under:

GNU General Public License

If you think the Android project campus listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package lecho.app.campus.dao;
/*from w w  w. j av a 2s.  c  o m*/
import android.database.sqlite.SQLiteDatabase;

import java.util.Map;

import de.greenrobot.dao.AbstractDao;
import de.greenrobot.dao.AbstractDaoSession;
import de.greenrobot.dao.identityscope.IdentityScopeType;
import de.greenrobot.dao.internal.DaoConfig;

import lecho.app.campus.dao.PlaceFaculty;
import lecho.app.campus.dao.PlaceCategory;
import lecho.app.campus.dao.PlaceUnit;
import lecho.app.campus.dao.Faculty;
import lecho.app.campus.dao.Unit;
import lecho.app.campus.dao.Category;
import lecho.app.campus.dao.Place;

import lecho.app.campus.dao.PlaceFacultyDao;
import lecho.app.campus.dao.PlaceCategoryDao;
import lecho.app.campus.dao.PlaceUnitDao;
import lecho.app.campus.dao.FacultyDao;
import lecho.app.campus.dao.UnitDao;
import lecho.app.campus.dao.CategoryDao;
import lecho.app.campus.dao.PlaceDao;

// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.

/**
 * {@inheritDoc}
 * 
 * @see de.greenrobot.dao.AbstractDaoSession
 */
public class DaoSession extends AbstractDaoSession {

    private final DaoConfig placeFacultyDaoConfig;
    private final DaoConfig placeCategoryDaoConfig;
    private final DaoConfig placeUnitDaoConfig;
    private final DaoConfig facultyDaoConfig;
    private final DaoConfig unitDaoConfig;
    private final DaoConfig categoryDaoConfig;
    private final DaoConfig placeDaoConfig;

    private final PlaceFacultyDao placeFacultyDao;
    private final PlaceCategoryDao placeCategoryDao;
    private final PlaceUnitDao placeUnitDao;
    private final FacultyDao facultyDao;
    private final UnitDao unitDao;
    private final CategoryDao categoryDao;
    private final PlaceDao placeDao;

    public DaoSession(SQLiteDatabase db, IdentityScopeType type, Map<Class<? extends AbstractDao<?, ?>>, DaoConfig>
            daoConfigMap) {
        super(db);

        placeFacultyDaoConfig = daoConfigMap.get(PlaceFacultyDao.class).clone();
        placeFacultyDaoConfig.initIdentityScope(type);

        placeCategoryDaoConfig = daoConfigMap.get(PlaceCategoryDao.class).clone();
        placeCategoryDaoConfig.initIdentityScope(type);

        placeUnitDaoConfig = daoConfigMap.get(PlaceUnitDao.class).clone();
        placeUnitDaoConfig.initIdentityScope(type);

        facultyDaoConfig = daoConfigMap.get(FacultyDao.class).clone();
        facultyDaoConfig.initIdentityScope(type);

        unitDaoConfig = daoConfigMap.get(UnitDao.class).clone();
        unitDaoConfig.initIdentityScope(type);

        categoryDaoConfig = daoConfigMap.get(CategoryDao.class).clone();
        categoryDaoConfig.initIdentityScope(type);

        placeDaoConfig = daoConfigMap.get(PlaceDao.class).clone();
        placeDaoConfig.initIdentityScope(type);

        placeFacultyDao = new PlaceFacultyDao(placeFacultyDaoConfig, this);
        placeCategoryDao = new PlaceCategoryDao(placeCategoryDaoConfig, this);
        placeUnitDao = new PlaceUnitDao(placeUnitDaoConfig, this);
        facultyDao = new FacultyDao(facultyDaoConfig, this);
        unitDao = new UnitDao(unitDaoConfig, this);
        categoryDao = new CategoryDao(categoryDaoConfig, this);
        placeDao = new PlaceDao(placeDaoConfig, this);

        registerDao(PlaceFaculty.class, placeFacultyDao);
        registerDao(PlaceCategory.class, placeCategoryDao);
        registerDao(PlaceUnit.class, placeUnitDao);
        registerDao(Faculty.class, facultyDao);
        registerDao(Unit.class, unitDao);
        registerDao(Category.class, categoryDao);
        registerDao(Place.class, placeDao);
    }
    
    public void clear() {
        placeFacultyDaoConfig.getIdentityScope().clear();
        placeCategoryDaoConfig.getIdentityScope().clear();
        placeUnitDaoConfig.getIdentityScope().clear();
        facultyDaoConfig.getIdentityScope().clear();
        unitDaoConfig.getIdentityScope().clear();
        categoryDaoConfig.getIdentityScope().clear();
        placeDaoConfig.getIdentityScope().clear();
    }

    public PlaceFacultyDao getPlaceFacultyDao() {
        return placeFacultyDao;
    }

    public PlaceCategoryDao getPlaceCategoryDao() {
        return placeCategoryDao;
    }

    public PlaceUnitDao getPlaceUnitDao() {
        return placeUnitDao;
    }

    public FacultyDao getFacultyDao() {
        return facultyDao;
    }

    public UnitDao getUnitDao() {
        return unitDao;
    }

    public CategoryDao getCategoryDao() {
        return categoryDao;
    }

    public PlaceDao getPlaceDao() {
        return placeDao;
    }

}




Java Source Code List

lecho.app.campus.activity.AboutAppActivity.java
lecho.app.campus.activity.CampusMapActivity.java
lecho.app.campus.activity.GalleryActivity.java
lecho.app.campus.activity.LegalInfoActivity.java
lecho.app.campus.activity.PlaceDetailsActivity.java
lecho.app.campus.adapter.GalleryPagesFragmentAdapter.java
lecho.app.campus.adapter.MarkerInfoWindowAdapter.java
lecho.app.campus.adapter.NavigationDrawerAdapter.java
lecho.app.campus.adapter.PlaceDetailsFragmentAdapter.java
lecho.app.campus.adapter.SearchResultViewAdapter.java
lecho.app.campus.adapter.SearchSuggestionAdapter.java
lecho.app.campus.dao.CategoryDao.java
lecho.app.campus.dao.CategoryDao.java
lecho.app.campus.dao.Category.java
lecho.app.campus.dao.Category.java
lecho.app.campus.dao.DaoMaster.java
lecho.app.campus.dao.DaoMaster.java
lecho.app.campus.dao.DaoSession.java
lecho.app.campus.dao.DaoSession.java
lecho.app.campus.dao.FacultyDao.java
lecho.app.campus.dao.FacultyDao.java
lecho.app.campus.dao.Faculty.java
lecho.app.campus.dao.Faculty.java
lecho.app.campus.dao.Main.java
lecho.app.campus.dao.PlaceCategoryDao.java
lecho.app.campus.dao.PlaceCategoryDao.java
lecho.app.campus.dao.PlaceCategory.java
lecho.app.campus.dao.PlaceCategory.java
lecho.app.campus.dao.PlaceDao.java
lecho.app.campus.dao.PlaceDao.java
lecho.app.campus.dao.PlaceFacultyDao.java
lecho.app.campus.dao.PlaceFacultyDao.java
lecho.app.campus.dao.PlaceFaculty.java
lecho.app.campus.dao.PlaceFaculty.java
lecho.app.campus.dao.PlaceUnitDao.java
lecho.app.campus.dao.PlaceUnitDao.java
lecho.app.campus.dao.PlaceUnit.java
lecho.app.campus.dao.PlaceUnit.java
lecho.app.campus.dao.Place.java
lecho.app.campus.dao.Place.java
lecho.app.campus.dao.UnitDao.java
lecho.app.campus.dao.UnitDao.java
lecho.app.campus.dao.Unit.java
lecho.app.campus.dao.Unit.java
lecho.app.campus.fragment.GalleryPageFragment.java
lecho.app.campus.fragment.PlaceDetailsFragment.java
lecho.app.campus.fragment.dialog.NoInternetConnectionDialogFragment.java
lecho.app.campus.fragment.dialog.PlayServicesErrorDialogFragment.java
lecho.app.campus.loader.PlaceDetailsLoader.java
lecho.app.campus.loader.PlacesLoader.java
lecho.app.campus.provider.SearchSuggestionProvider.java
lecho.app.campus.service.PopulateDBIntentService.java
lecho.app.campus.utils.ABSMenuItemConverter.java
lecho.app.campus.utils.BitmapAsyncTask.java
lecho.app.campus.utils.Config.java
lecho.app.campus.utils.DataParser.java
lecho.app.campus.utils.DatabaseHelper.java
lecho.app.campus.utils.ImagesDirAsyncTask.java
lecho.app.campus.utils.NavigationDrawerItem.java
lecho.app.campus.utils.PlaceDetails.java
lecho.app.campus.utils.PlacesList.java
lecho.app.campus.utils.UnitsGroup.java
lecho.app.campus.utils.Utils.java
lecho.app.campus.view.CheckableDrawerItem.java
lecho.app.campus.view.UnitsGroupLayout.java
lecho.app.campus.view.ZoomImageView.java
lecho.app.campus.view.ZoomViewPager.java