04 2012 档案

摘要:@interface TestObject : NSObject-(void)printFirstName:(NSString*)firstName thenSecondName:(NSString*)secondName;-(void)printName:(NSString*)name;-(int)addLeft:(int)left withRight:(int)right;@end@implementation TestObject-(SEL)oriSelector:(SEL)aSelector{ NSString* v2String=NSStringFromSelector(aSe... 阅读全文
posted @ 2012-04-10 20:50 eeeyes 阅读(1067) 评论(1) 推荐(1)
摘要:static pthread_mutex_t dbMutex=PTHREAD_MUTEX_INITIALIZER;static sem_t* dbSem[10];static sqlite3* db;static sqlite3_stmt* insertStmt=NULL;static sqlite3_stmt* queryStmt=NULL;void createAndOpenDB(void);void* insertIntoDB(void*);void queryFromDB(void);void readFromDB();void createInsertThread(sem_t* se 阅读全文
posted @ 2012-04-06 13:51 eeeyes 阅读(729) 评论(0) 推荐(2)
摘要:static CFRunLoopRef backgroundRunLoop;static pthread_cond_t cond=PTHREAD_COND_INITIALIZER;static pthread_mutex_t mutex=PTHREAD_MUTEX_INITIALIZER;void releaseContext(void* infoPtr){ CFRelease(infoPtr);}void* retainContext(void* infoPtr){ CFRetain(infoPtr); return infoPtr;}void cancelTheStre... 阅读全文
posted @ 2012-04-05 14:41 eeeyes 阅读(1666) 评论(0) 推荐(0)