2013年9月5日 星期四

some shit


http://stackoverflow.com/questions/16483175/why-is-nsclassfromstring-returning-nil-or-not-in-these-two-cases

NSString* theClassName = /* assume this exists */
Class theClass = NSClassFromString(theClassName);
NSObject* myObject = [[theClass performSelector:@selector(alloc)] init];


grep -Rl ": GPUImageFilter" * | sed -e s/framework\\/Source\\///g | sed -e s/\\.h//g | awk '{printf "@\""; printf $0 ; printf "\"," ; printf "\n" ;}' > ha.txt

http://hi.baidu.com/hh20040410/item/d1eda629421d97cdddf69a6d

第一次安裝時間 android
if (Build.VERSION.SDK_INT >= 9)
     try {
          long installed = context.getPackageManager().getPackageInfo(context.getPackageName(), 0).firstInstallTime;
           params.put("installDate", dateFormat.format(new Date(installed)));
         }
        catch (Exception e)
        {

       }

沒有留言:

張貼留言