摘要: cdll.LoadLibrary(...) restype (default is c_int) argtypes (what's the default? c_int?) customized data structure how ctypes wrap c/c++ functions? 阅读全文
posted @ 2016-10-25 17:44 学思罔殆 阅读(293) 评论(0) 推荐(0) 编辑
摘要: 1. MRO: method resolution order lookup order: L(MyClass) = [MyClass, merged(L(Base1), L(Base2), Base1, Base2)] 2. super(...) 必须所有的父类都call super, 不然会有不 阅读全文
posted @ 2016-10-25 11:43 学思罔殆 阅读(147) 评论(0) 推荐(0) 编辑
摘要: 'type' 是 python built-in metaclass 其他继承自 ‘type’的class都可以是 Metaclass 子类可以继承父类的metaclass 然而 __metaclass__属性不能继承 __metaclass__可以定义成任何返回instance of 'type' 阅读全文
posted @ 2016-10-01 22:10 学思罔殆 阅读(162) 评论(0) 推荐(0) 编辑
摘要: 所有对model object的操作都会根据model的定义翻译成SQL。 Relationship 怎么定义: ManyToOne (和OneToMany是一样的): ForeignKey , One side access Many: one.many_set (relatedManager) 阅读全文
posted @ 2016-10-01 17:10 学思罔殆 阅读(247) 评论(0) 推荐(0) 编辑
摘要: dont create index on each column for multicolumn index, the column order matters for B-Tree index UNIQUE and PRIMARY KEY are constraints, not indexes. 阅读全文
posted @ 2016-07-14 19:46 学思罔殆 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 1. max_connections open_files_limit table_open_cache 如何配置 table_open_cache = max_connections * N (N is the maximun number of tables open in each conne 阅读全文
posted @ 2016-07-14 16:00 学思罔殆 阅读(232) 评论(0) 推荐(0) 编辑
摘要: re.match: match from the beginning of the string re.search: scan through the whole string to find a match dash '-' inside square '[]' means a range. p 阅读全文
posted @ 2016-07-02 21:48 学思罔殆 阅读(208) 评论(0) 推荐(0) 编辑
摘要: ssl http 阅读全文
posted @ 2016-05-06 10:27 学思罔殆 阅读(202) 评论(0) 推荐(0) 编辑
摘要: 1. why browser can only open .txt file directly, pop up open or save dialog for others? 2. html cannot open local files but only send the file to serv 阅读全文
posted @ 2016-04-28 15:09 学思罔殆 阅读(159) 评论(0) 推荐(0) 编辑
摘要: 1. C 中 头文件的作用? 2. difference between *.a and *.so? 3. object file and executable file 4. search path of linker system default search paths ldconfig to 阅读全文
posted @ 2016-04-14 18:33 学思罔殆 阅读(176) 评论(0) 推荐(0) 编辑