package com.ping.greendao.gen; import android.database.Cursor; import android.database.sqlite.SQLiteStatement; import org.greenrobot.greendao.AbstractDao; import org.greenrobot.greendao.Property; import org.greenrobot.greendao.internal.DaoConfig; import org.greenrobot.greendao.database.Database; import org.greenrobot.greendao.database.DatabaseStatement; import cn.flightfeather.thirdapp.bean.Gitlist; // THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT. /** * DAO for table "GITLIST". */ public class GitlistDao extends AbstractDao { public static final String TABLENAME = "GITLIST"; /** * Properties of entity Gitlist.
* Can be used for QueryBuilder and for referencing column names. */ public static class Properties { public final static Property Guid = new Property(0, String.class, "guid", true, "GUID"); public final static Property Iguid = new Property(1, String.class, "iguid", false, "IGUID"); public final static Property Stguid = new Property(2, String.class, "stguid", false, "STGUID"); public final static Property Sguid = new Property(3, String.class, "sguid", false, "SGUID"); public final static Property Scensename = new Property(4, String.class, "scensename", false, "SCENSENAME"); public final static Property Scenseaddress = new Property(5, String.class, "scenseaddress", false, "SCENSEADDRESS"); public final static Property Gtguid = new Property(6, String.class, "gtguid", false, "GTGUID"); public final static Property Name = new Property(7, String.class, "name", false, "NAME"); public final static Property Type = new Property(8, String.class, "type", false, "TYPE"); public final static Property Desc = new Property(9, String.class, "desc", false, "DESC"); public final static Property Createdate = new Property(10, java.util.Date.class, "createdate", false, "CREATEDATE"); public final static Property Updatedate = new Property(11, java.util.Date.class, "updatedate", false, "UPDATEDATE"); public final static Property Extension1 = new Property(12, String.class, "extension1", false, "EXTENSION1"); public final static Property Extension2 = new Property(13, String.class, "extension2", false, "EXTENSION2"); public final static Property Extension3 = new Property(14, String.class, "extension3", false, "EXTENSION3"); public final static Property Remark = new Property(15, String.class, "remark", false, "REMARK"); } public GitlistDao(DaoConfig config) { super(config); } public GitlistDao(DaoConfig config, DaoSession daoSession) { super(config, daoSession); } /** Creates the underlying database table. */ public static void createTable(Database db, boolean ifNotExists) { String constraint = ifNotExists? "IF NOT EXISTS ": ""; db.execSQL("CREATE TABLE " + constraint + "\"GITLIST\" (" + // "\"GUID\" TEXT PRIMARY KEY NOT NULL ," + // 0: guid "\"IGUID\" TEXT," + // 1: iguid "\"STGUID\" TEXT," + // 2: stguid "\"SGUID\" TEXT," + // 3: sguid "\"SCENSENAME\" TEXT," + // 4: scensename "\"SCENSEADDRESS\" TEXT," + // 5: scenseaddress "\"GTGUID\" TEXT," + // 6: gtguid "\"NAME\" TEXT," + // 7: name "\"TYPE\" TEXT," + // 8: type "\"DESC\" TEXT," + // 9: desc "\"CREATEDATE\" INTEGER," + // 10: createdate "\"UPDATEDATE\" INTEGER," + // 11: updatedate "\"EXTENSION1\" TEXT," + // 12: extension1 "\"EXTENSION2\" TEXT," + // 13: extension2 "\"EXTENSION3\" TEXT," + // 14: extension3 "\"REMARK\" TEXT);"); // 15: remark } /** Drops the underlying database table. */ public static void dropTable(Database db, boolean ifExists) { String sql = "DROP TABLE " + (ifExists ? "IF EXISTS " : "") + "\"GITLIST\""; db.execSQL(sql); } @Override protected final void bindValues(DatabaseStatement stmt, Gitlist entity) { stmt.clearBindings(); String guid = entity.getGuid(); if (guid != null) { stmt.bindString(1, guid); } String iguid = entity.getIguid(); if (iguid != null) { stmt.bindString(2, iguid); } String stguid = entity.getStguid(); if (stguid != null) { stmt.bindString(3, stguid); } String sguid = entity.getSguid(); if (sguid != null) { stmt.bindString(4, sguid); } String scensename = entity.getScensename(); if (scensename != null) { stmt.bindString(5, scensename); } String scenseaddress = entity.getScenseaddress(); if (scenseaddress != null) { stmt.bindString(6, scenseaddress); } String gtguid = entity.getGtguid(); if (gtguid != null) { stmt.bindString(7, gtguid); } String name = entity.getName(); if (name != null) { stmt.bindString(8, name); } String type = entity.getType(); if (type != null) { stmt.bindString(9, type); } String desc = entity.getDesc(); if (desc != null) { stmt.bindString(10, desc); } java.util.Date createdate = entity.getCreatedate(); if (createdate != null) { stmt.bindLong(11, createdate.getTime()); } java.util.Date updatedate = entity.getUpdatedate(); if (updatedate != null) { stmt.bindLong(12, updatedate.getTime()); } String extension1 = entity.getExtension1(); if (extension1 != null) { stmt.bindString(13, extension1); } String extension2 = entity.getExtension2(); if (extension2 != null) { stmt.bindString(14, extension2); } String extension3 = entity.getExtension3(); if (extension3 != null) { stmt.bindString(15, extension3); } String remark = entity.getRemark(); if (remark != null) { stmt.bindString(16, remark); } } @Override protected final void bindValues(SQLiteStatement stmt, Gitlist entity) { stmt.clearBindings(); String guid = entity.getGuid(); if (guid != null) { stmt.bindString(1, guid); } String iguid = entity.getIguid(); if (iguid != null) { stmt.bindString(2, iguid); } String stguid = entity.getStguid(); if (stguid != null) { stmt.bindString(3, stguid); } String sguid = entity.getSguid(); if (sguid != null) { stmt.bindString(4, sguid); } String scensename = entity.getScensename(); if (scensename != null) { stmt.bindString(5, scensename); } String scenseaddress = entity.getScenseaddress(); if (scenseaddress != null) { stmt.bindString(6, scenseaddress); } String gtguid = entity.getGtguid(); if (gtguid != null) { stmt.bindString(7, gtguid); } String name = entity.getName(); if (name != null) { stmt.bindString(8, name); } String type = entity.getType(); if (type != null) { stmt.bindString(9, type); } String desc = entity.getDesc(); if (desc != null) { stmt.bindString(10, desc); } java.util.Date createdate = entity.getCreatedate(); if (createdate != null) { stmt.bindLong(11, createdate.getTime()); } java.util.Date updatedate = entity.getUpdatedate(); if (updatedate != null) { stmt.bindLong(12, updatedate.getTime()); } String extension1 = entity.getExtension1(); if (extension1 != null) { stmt.bindString(13, extension1); } String extension2 = entity.getExtension2(); if (extension2 != null) { stmt.bindString(14, extension2); } String extension3 = entity.getExtension3(); if (extension3 != null) { stmt.bindString(15, extension3); } String remark = entity.getRemark(); if (remark != null) { stmt.bindString(16, remark); } } @Override public String readKey(Cursor cursor, int offset) { return cursor.isNull(offset + 0) ? null : cursor.getString(offset + 0); } @Override public Gitlist readEntity(Cursor cursor, int offset) { Gitlist entity = new Gitlist( // cursor.isNull(offset + 0) ? null : cursor.getString(offset + 0), // guid cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1), // iguid cursor.isNull(offset + 2) ? null : cursor.getString(offset + 2), // stguid cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3), // sguid cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4), // scensename cursor.isNull(offset + 5) ? null : cursor.getString(offset + 5), // scenseaddress cursor.isNull(offset + 6) ? null : cursor.getString(offset + 6), // gtguid cursor.isNull(offset + 7) ? null : cursor.getString(offset + 7), // name cursor.isNull(offset + 8) ? null : cursor.getString(offset + 8), // type cursor.isNull(offset + 9) ? null : cursor.getString(offset + 9), // desc cursor.isNull(offset + 10) ? null : new java.util.Date(cursor.getLong(offset + 10)), // createdate cursor.isNull(offset + 11) ? null : new java.util.Date(cursor.getLong(offset + 11)), // updatedate cursor.isNull(offset + 12) ? null : cursor.getString(offset + 12), // extension1 cursor.isNull(offset + 13) ? null : cursor.getString(offset + 13), // extension2 cursor.isNull(offset + 14) ? null : cursor.getString(offset + 14), // extension3 cursor.isNull(offset + 15) ? null : cursor.getString(offset + 15) // remark ); return entity; } @Override public void readEntity(Cursor cursor, Gitlist entity, int offset) { entity.setGuid(cursor.isNull(offset + 0) ? null : cursor.getString(offset + 0)); entity.setIguid(cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1)); entity.setStguid(cursor.isNull(offset + 2) ? null : cursor.getString(offset + 2)); entity.setSguid(cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3)); entity.setScensename(cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4)); entity.setScenseaddress(cursor.isNull(offset + 5) ? null : cursor.getString(offset + 5)); entity.setGtguid(cursor.isNull(offset + 6) ? null : cursor.getString(offset + 6)); entity.setName(cursor.isNull(offset + 7) ? null : cursor.getString(offset + 7)); entity.setType(cursor.isNull(offset + 8) ? null : cursor.getString(offset + 8)); entity.setDesc(cursor.isNull(offset + 9) ? null : cursor.getString(offset + 9)); entity.setCreatedate(cursor.isNull(offset + 10) ? null : new java.util.Date(cursor.getLong(offset + 10))); entity.setUpdatedate(cursor.isNull(offset + 11) ? null : new java.util.Date(cursor.getLong(offset + 11))); entity.setExtension1(cursor.isNull(offset + 12) ? null : cursor.getString(offset + 12)); entity.setExtension2(cursor.isNull(offset + 13) ? null : cursor.getString(offset + 13)); entity.setExtension3(cursor.isNull(offset + 14) ? null : cursor.getString(offset + 14)); entity.setRemark(cursor.isNull(offset + 15) ? null : cursor.getString(offset + 15)); } @Override protected final String updateKeyAfterInsert(Gitlist entity, long rowId) { return entity.getGuid(); } @Override public String getKey(Gitlist entity) { if(entity != null) { return entity.getGuid(); } else { return null; } } @Override public boolean hasKey(Gitlist entity) { return entity.getGuid() != null; } @Override protected final boolean isEntityUpdateable() { return true; } }