2012年7月22日

Windows 8 C++/CX命名空间

摘要: 如何使用命名空间在标准C++里面命名空间是为了防止类型的冲突,但在Windows运行时中,使用C++编程需要给所有的程序类型添加上命名空间,这是Windows运行时的一种语法规范。命名空间可以嵌套着使用。看下面的例子:namespace Test{ public ref class MyClass{}; public delegate void MyDelegate(); namespace NestedNamespace { public ref class MyClass2 { event Test::MyDelegate^ Notify; }; }}在MyClass2里面来使用Test空 阅读全文

posted @ 2012-07-22 19:32 linzheng 阅读(1096) 评论(0) 推荐(0) 编辑

导航