CPP – Neohope的网络笔记 https://www.neohope.com Learn and share. Thu, 26 Sep 2024 10:09:19 +0000 en-US hourly 1 https://wordpress.org/?v=6.6.2 浅谈CPP智能指针 https://www.neohope.com/2018/08/15/%e6%b5%85%e8%b0%88cpp%e6%99%ba%e8%83%bd%e6%8c%87%e9%92%88/ https://www.neohope.com/2018/08/15/%e6%b5%85%e8%b0%88cpp%e6%99%ba%e8%83%bd%e6%8c%87%e9%92%88/#respond Wed, 15 Aug 2018 06:17:16 +0000 http://www.neohope.com/?p=3337 ”(重载)。 访问智能指针本来的方法,使用操作符“.”。 我们常见的智能指针有以下几种: 下面给一个例子,说明一下std下的四种智能指针。 1、SmartPointerTest.cpp 2、MyTest.h 3、MyTest.cpp PS: 聪明的你有没有发下,CPP的智能指针,与JVM内存中的四种引用方式,强引用、软引用、弱引用,虚引用,有很多相似的地方呢?]]> https://www.neohope.com/2018/08/15/%e6%b5%85%e8%b0%88cpp%e6%99%ba%e8%83%bd%e6%8c%87%e9%92%88/feed/ 0 COM+简单示例(04) https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/ https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/#respond Sun, 12 Jun 2016 13:40:09 +0000 http://www.neohope.com/?p=2668 https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/feed/ 0 COM+简单示例(01) https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/ https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/#respond Sun, 12 Jun 2016 08:45:23 +0000 http://www.neohope.com/?p=2653 ATL Project(名称为ATLCOMP)->类型选择Dynamic Library(DLL)->勾选Support COM+ 1.0->Finish 2、工程视图,ATLCOMP工程,右键->Add->Class->ATL->ATL COM+ 1.0 Component->类名为JustATestCOMP,ProgID为ATLCOMP.JustATestCOMP 3、切换到类视图,ATLCOMP项目下的IJustATestCOMP接口上右键Add Method 名称:Add 参数1:[in]LONG a 参数2:[in]LONG b 参数3:[out,retval]LONG* c 4、类视图,ATLCOMP项目下的IJustATestCOMP接口上右键Add Method 名称:SayHiTo 参数1:[in]BSTR someOne 参数2:[out,retval]BSTR* retValue 5、打开JustATestCOMP.cpp完成两个函数 6、编译 7、注册 8、反注册 9、注册到COM+ 9.1打开组件管理器 9.2选择到“Components Services-》Computers-》My Computer->COM+ Applications” 9.3右键“New-》Application(ATLCOMP)” 9.4选择到“Components Services-》Computers-》My Computer->COM+ Continue reading COM+简单示例(01)]]> https://www.neohope.com/2016/06/12/com%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/feed/ 0 DCOM简单示例(04) https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/ https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/#respond Sat, 11 Jun 2016 14:10:32 +0000 http://www.neohope.com/?p=2644 https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8804%ef%bc%89/feed/ 0 DCOM简单示例(01) https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/ https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/#respond Sat, 11 Jun 2016 12:31:10 +0000 http://www.neohope.com/?p=2637 ATL Project(名称为ATLExe)->类型选择Executable(EXE)->Finish 2、工程视图,ATLExe工程,右键->Add->Class->ATL->ATL Simple Object->类名为JustATestExe,ProgID为ATLExe.JustATestExe 3、切换到类视图,ATLExe项目下的IJustATestExe接口上右键Add Method 名称:Add 参数1:[in]LONG a 参数2:[in]LONG b 参数3:[out,retval]LONG* c 4、类视图,ATLExe项目下的IJustATestExe接口上右键Add Method 名称:SayHiTo 参数1:[in]BSTR someOne 参数2:[out,retval]BSTR* retValue 5、打开JustATestExe.cpp完成两个函数 6、编译 7、注册 8、反注册]]> https://www.neohope.com/2016/06/11/dcom%e7%ae%80%e5%8d%95%e7%a4%ba%e4%be%8b%ef%bc%8801%ef%bc%89/feed/ 0 CPP实现CORBA静态绑定(四) https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e5%9b%9b%ef%bc%89/ https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e5%9b%9b%ef%bc%89/#respond Tue, 08 Dec 2015 07:03:50 +0000 http://www.neohope.com/?p=1945 https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e5%9b%9b%ef%bc%89/feed/ 0 CPP实现CORBA静态绑定(三) https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%89%ef%bc%89/ https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%89%ef%bc%89/#respond Tue, 08 Dec 2015 06:47:51 +0000 http://www.neohope.com/?p=1944 https://www.neohope.com/2015/12/08/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%89%ef%bc%89/feed/ 0 CPP实现CORBA静态绑定(二) https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%ba%8c%ef%bc%89/ https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%ba%8c%ef%bc%89/#respond Sun, 06 Dec 2015 10:56:51 +0000 http://www.neohope.com/?p=1939 Continue reading CPP实现CORBA静态绑定(二)]]> https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%ba%8c%ef%bc%89/feed/ 0 CPP实现CORBA静态绑定(一) https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%80%ef%bc%89/ https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%80%ef%bc%89/#respond Sun, 06 Dec 2015 10:54:13 +0000 http://www.neohope.com/?p=1936 Continue reading CPP实现CORBA静态绑定(一)]]> https://www.neohope.com/2015/12/06/cpp%e5%ae%9e%e7%8e%b0corba%e9%9d%99%e6%80%81%e7%bb%91%e5%ae%9a%ef%bc%88%e4%b8%80%ef%bc%89/feed/ 0 GetLastError返回值含义 https://www.neohope.com/2014/12/11/getlasterror%e8%bf%94%e5%9b%9e%e5%80%bc%e5%90%ab%e4%b9%89/ https://www.neohope.com/2014/12/11/getlasterror%e8%bf%94%e5%9b%9e%e5%80%bc%e5%90%ab%e4%b9%89/#respond Thu, 11 Dec 2014 15:12:43 +0000 http://www.neohope.com/?p=1179 Continue reading GetLastError返回值含义]]> https://www.neohope.com/2014/12/11/getlasterror%e8%bf%94%e5%9b%9e%e5%80%bc%e5%90%ab%e4%b9%89/feed/ 0