Beispiel #1
0
 public static com.miui.yellowpage.base.model.YellowPage i(Context context, String str) {
   com.miui.yellowpage.base.model.YellowPage yellowPage = null;
   Cursor query =
       context
           .getContentResolver()
           .query(
               YellowPage.CONTENT_URI,
               new String[] {MiniDefine.at},
               "yid = ?",
               new String[] {str},
               null);
   if (query != null) {
     try {
       if (query.moveToFirst()) {
         yellowPage = com.miui.yellowpage.base.model.YellowPage.fromJson(query.getString(0));
       } else {
         query.close();
       }
     } finally {
       query.close();
     }
   }
   return yellowPage;
 }