用getnext获取的是成员的一个copy。如果获取成员的指针呢,我想改变Clist成员内部的值,我该怎么做?
解决方案 »
- 在校园网不登陆的情况下,是否可以通过自由获取IP方式获取到IP地址
- 快春节了,大家陆续回家了,散分!祝大家春节快乐!
- 无边透明对话框实现窗口拖拉改变大小?
- 请教:我该找什么样的工作
- 关于雪灾GIS预警系统
- 急,解决即散分,关于Activex控件串行化链表的问题
- 为什么我的App Wizard中没有 MFC AppWizard
- 一显示的问题!
- 折腾了一上午的诡异问题,VC
- datagrid使用出现问题?
- 二维数组名作为参数传给char** pcOutStr,然后在函数中为什么不能strcpy(pcOutStr,"abc",2)
- 嵌入到主对话框的CPropertySheet创建之后发生奇怪的问题!请指教
TYPE& GetNext( POSITION& rPosition );
改变Clist成员内部的值,用上面的引用就可以了!!
TYPE GetNext( POSITION& rPosition ) const;Return ValueIf the list is const, GetNext returns a copy of the element at the head of the list. This allows the function to be used only on the right side of an assignment statement and protects the list from modification.
看这里!!
If the list is not const, GetNext returns a reference to an element of the list. This allows the function to be used on either side of an assignment statement and thus allows the list entries to be modified.
Thank you very much!