Ejemplo n.º 1
0
 public static ApkDAO GetInstance() {
   if (self == null) {
     self = new ApkDAO();
     self.init();
     if (!instance_flag) self = null;
   }
   return self;
 }
Ejemplo n.º 2
0
  public static void main(String[] argv) throws InterruptedException {
    // String[] rt = ApkDAO.GetInstance().getPackageNames();
    // System.out.println(rt.length);

    /*
     * for (int i = 0; i < 10; i++) { ApkBean apk = new ApkBean();
     * apk.marketBean.marketName = "TEST"; apk.searchKeyword = "TEST";
     * apk.searchResultNum = i; apk.searchResult = "TEST";
     * ApkDAO.GetInstance().insertSearchHistory(apk); Thread.sleep(1000); }
     */
    /*
     * ApkBean apk=new ApkBean(); apk.packageName="com.TEST.TEST";
     * apk.marketBean.marketName="Gfan"; apk.versionCode="-1";
     *
     * ApkDAO.GetInstance().insertApk(apk);
     */
    ApkBean[] apks = ApkDAO.GetInstance().getDiffApks();
    System.out.println(apks.length);
  }