大约有 24,980 项符合查询结果(耗时:0.0365秒) [XML]

https://www.tsingfun.com/it/cpp/2432.html 

C++ 智能指针shared_ptr,weak_ptr,shared_from_this实践 - C/C++ - 清泛网 - 专注C/C++及内核技术

C++ 智能指针shared_ptr,weak_ptr,shared_from_this实践new XXX(shared_from_this()) 如果用强指针去接,则增加引用计数;弱引用去接,不增加引用计数。auto去接等同强指针。weak_ptr 传给thread、timer回调,不能使用expired()判断 new XXX(shared_from_thi...
https://www.tsingfun.com/it/cpp/2435.html 

windows C++ gbk转为utf-8 - C/C++ - 清泛网 - 专注C/C++及内核技术

windows C++ gbk转为utf-8在windows与linux系统通过socket的传输数据里,如果传输中文字符,因为windows和linux使用的编码不同,所以需要将windows下的中文编码转换为 在windows与linux系统通过socket的传输数据里,如果传输中文字符,因为windo...
https://www.tsingfun.com/it/cp... 

Eclipse C++启用pretty printing,更直观显示stl变量内容 - C/C++ - 清泛网...

Eclipse C++启用pretty printing,更直观显示stl变量内容enable-pretty-printing-in-eclipse-cdt使用Eclipse CDT调试stl变量时,我们关注的变量内容往往需要查看好几层的变量后才能看到,非常的不直观。这里提供一种更优雅地打印stl变量的方法,...
https://www.tsingfun.com/it/tech/1757.html 

Win7禁用休眠 减少C盘容量占用 - 更多技术 - 清泛网 - 专注C/C++及内核技术

Win7禁用休眠 减少C盘容量占用开始菜单 → 运行 → cmd.exe → 右键以管理员身份运行 → 命令:powercfg -h off回车即可,C盘容量占用减少立...开始菜单 → 运行 → cmd.exe → 右键“以管理员身份运行” → 命令:power...
https://www.tsingfun.com/it/cp... 

Linux C++ 单元测试与gcov代码覆盖率统计 - C/C++ - 清泛网 - 专注C/C++及内核技术

Linux C++ 单元测试与gcov代码覆盖率统计gtest-and-coverage本文主要介绍Linux下C++单元测试下的代码覆盖率统计的方法,测试框架采用gtest,当然也可以使用其他的,这里不做过多的说明,主要介绍代码的覆盖率统计方法。一、什么是gco...
https://www.tsingfun.com/it/cp... 

‘std::tr1’ does not name a template type - C/C++ - 清泛网 - 专注C/C++及内核技术

...does-not-name-a-template-type解决方法:添加头文件 if !defined(_MSC_VER) include <tr1 memory> endifC++ Technical Report 1 (TR1)是ISO IEC TR 19768, C++ Library Extensions(函式库扩充)的 解决方法:添加头文件 #if !defined(_MSC_VER) #include <tr1/memory> #endif C+...
https://stackoverflow.com/ques... 

What is the difference between ? and Object in Java generics?

I'm using Eclipse to help me clean up some code to use Java generics properly. Most of the time it's doing an excellent job of inferring types, but there are some cases where the inferred type has to be as generic as possible: Object. But Eclipse seems to be giving me an option to choose between a...
https://stackoverflow.com/ques... 

to drawRect or not to drawRect (when should one use drawRect/Core Graphics vs subviews/images and wh

To clarify the purpose of this question: I know HOW to create complicated views with both subviews and using drawRect. I'm trying to fully understand the when's and why's to use one over the other. ...
https://stackoverflow.com/ques... 

Regex replace uppercase with lowercase letters

I'm trying to replace uppercase letters with corresponding lowercase letters using regex. So that 6 Answers ...
https://www.tsingfun.com/it/cp... 

各编程语言读写文件汇总 - C/C++ - 清泛网 - 专注C/C++及内核技术

...即文件原先的内容会被保留。 导航: 一、PHP 二、C# 三、C 3.1、fgets、fputs文本读写 3.2、fread、fwrite二进制读写 四、C++ 五、Java PHP读写文件: // 写文件 $fp = fopen("log.txt", "a"); fwrite($fp, $str); fclose($fp); // ...