Guava 是一个 Google 的基于java1.6的类库集合的扩展项目,包括 collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, 等等. 这些高质量的 API 可以...
分类:
其他好文 时间:
2014-07-21 10:14:58
阅读次数:
180
1. 热键的使用 热键不用了的话一定要卸载,否则下次启动时会被占用。 函数原型 注册函数 BOOL RegisterHotKey(
HWND hWnd, // handle to window
int id, // hot key identifier
UINT fsModifiers, // key-...
分类:
其他好文 时间:
2014-07-21 10:13:27
阅读次数:
387
HANDLE WINAPI CreateRemoteThread(__in HANDLE hProcess,__in LPSECURITY_ATTRIBUTES lpThreadAttributes,__in SIZE_T dwStackSize,__in LPTHREAD_STAR...
分类:
编程语言 时间:
2014-07-20 21:31:14
阅读次数:
355
句柄(HANDLE)是Windows程序中一个重要的概念,使用也非常频繁。在Windows程序中,有各种各样的资源(窗口、图标、光标等),系统在创建这些资源时会为它们分配内存,并返回标识这些资源的标识号,即句柄。窗口句柄是windows句柄的一种,且是重要的一种句柄。在Windows应用程序中,窗口...
分类:
其他好文 时间:
2014-07-19 19:38:43
阅读次数:
252
转载请包含网址:http://blog.csdn.net/pathuang68/article/details/7351317一、SurfaceSurface就是“表面”的意思。在SDK的文档中,对Surface的描述是这样的:“Handle onto a raw buffer that is be...
分类:
其他好文 时间:
2014-07-19 17:22:55
阅读次数:
288
Description
The game “The Pilots Brothers: following the stripy elephant” has a quest where a player needs to open a refrigerator.
There are 16 handles on the refrigerator door. Every handle can b...
分类:
其他好文 时间:
2014-07-18 12:21:12
阅读次数:
253
这是个提醒,算是吧!如果详细原理过程,可能会有一个大篇幅。但这里不想多加赘述,只说说它的破坏力!最近写了个图像处理框架,要做个基类来handle众多子类,写之前一直申称:要注意内存管理,写好析构函数。谁知最后还是偏偏忘记了将基类析构函数virtual化,结果在操控基类释放内存的一段程序中,发现基类释...
分类:
编程语言 时间:
2014-07-18 12:03:57
阅读次数:
261
先写下这个问题的模式
def preorderTraversal(self, root):
if root == None: return []
re = []
insert root to stack s
while s not empty:
cur_root = top of stack s
s.pop()
how to handle cur_root
how to ...
分类:
其他好文 时间:
2014-07-15 10:17:43
阅读次数:
274
//判断文件是否存在
bool FileExistsW(const wstring &fn)
{
WIN32_FIND_DATAW fd;
HANDLE hFile = FindFirstFileW(fn.c_str(),&fd);
if (hFile != INVALID_HANDLE_VALUE)
{
::FindClose(hFile);...
经验:支持”编译依存性最小化“的一般构想是:相依于声明式,不要相依于定义式。
基于此构想的两个手段是 Handle classes 和 Interface classes.
示例:相依于定义式
#include
#include "date.h"
#include "address.h"
class Person{
public:
Person(const std::string &name, const Data &birthday, const Address &addr);
st...
分类:
编程语言 时间:
2014-07-12 19:39:46
阅读次数:
347