|
fastdo
0.6.16
|
引用计数共享句柄,管理各种资源的自动释放,赋值则引用计数加一。 更多...
#include <smartptr.hpp>

类 | |
| struct | SharedHandleData |
| 句柄数据结构体 更多... | |
Public 类型 | |
| typedef _HTy | HType |
| 句柄类型 更多... | |
Public 成员函数 | |
| SharedHandle () | |
| 构造函数0 更多... | |
| SharedHandle (_HTy h, _HTy failVal) | |
| 构造函数1_1 更多... | |
| template<typename _Dt > | |
| SharedHandle (_HTy h, _HTy failVal, _Dt dt) | |
| 构造函数1_2 更多... | |
| template<typename _HTy2 > | |
| SharedHandle (_HTy2 h, _HTy2 failVal) | |
构造函数2_1。_HTy2为可直接转为_HTy的类型 更多... | |
| template<typename _HTy2 , typename _Dt > | |
| SharedHandle (_HTy2 h, _HTy2 failVal, _Dt dt) | |
构造函数2_2。_HTy2为可直接转为_HTy的类型 更多... | |
| template<typename _HTy2 > | |
| SharedHandle (WeakHandle< _HTy2 > const &other) | |
| 构造函数3。从弱句柄构建共享句柄 更多... | |
| ~SharedHandle () | |
| 析构函数 更多... | |
| SharedHandle (SharedHandle const &other) | |
| 拷贝构造函数1 更多... | |
| SharedHandle & | operator= (SharedHandle const &other) |
| 拷贝赋值函数1 更多... | |
| template<typename _HTy2 > | |
| SharedHandle (SharedHandle< _HTy2 > const &other) | |
拷贝构造函数2。_HTy2为可直接转为_HTy的类型 更多... | |
| template<typename _HTy2 > | |
| SharedHandle & | operator= (SharedHandle< _HTy2 > const &other) |
拷贝赋值函数2。_HTy2为可直接转为_HTy的类型 更多... | |
| void | attachNew (_HTy h, _HTy failVal) |
| 附加新句柄,管理新资源 更多... | |
| template<typename _Dt > | |
| void | attachNew (_HTy h, _HTy failVal, _Dt dt) |
| 附加新句柄,管理新资源 更多... | |
| template<typename _HTy2 > | |
| void | attachNew (_HTy2 h, _HTy2 failVal) |
附加新句柄,管理新资源。_HTy2为可直接转为_HTy的类型 更多... | |
| template<typename _HTy2 , typename _Dt > | |
| void | attachNew (_HTy2 h, _HTy2 failVal, _Dt dt) |
附加新句柄,管理新资源。_HTy2为可直接转为_HTy的类型 更多... | |
| void | attach (SharedHandleData const &data, bool isIncRef) |
附加其他SharedHandle对象detach()出的句柄数据 更多... | |
| template<typename _HTy2 > | |
| void | attach (typename SharedHandle< _HTy2 >::SharedHandleData const &data, bool isIncRef) |
附加其他SharedHandle对象detach()出的句柄数据。_HTy2为可直接转为_HTy的类型 更多... | |
| template<typename _HTy2 > | |
| void | attach (_HTy2 h, SharedDeleterContext *ctx, bool isIncRef) |
附加其他SharedHandle对象detach()出的句柄和删除器场景。_HTy2为可直接转为_HTy的类型 更多... | |
| SharedHandleData | detach () |
| 资源脱离管理,返回句柄数据 更多... | |
| SharedHandleData | peek () const |
| 窥视句柄数据 更多... | |
| void | reset () |
| 释放资源并重置 更多... | |
| _HTy | get () const |
| 获取句柄 更多... | |
| SharedDeleterContext * | getContext () const |
| operator bool () const | |
| 判断是否在管理资源 更多... | |
| bool | operator< (SharedHandle const &other) const |
| less,给MAP使用 更多... | |
| _HTy | operator-> () |
| _HTy | operator-> () const |
Protected 成员函数 | |
| template<typename _HTy2 > | |
| void | _reset0 (_HTy2 newH, SharedDeleterContext *newCtx) |
| 减少自身引用计数,管理新资源 更多... | |
| template<typename _HTy2 > | |
| void | _reset (_HTy2 otherH, SharedDeleterContext *otherCtx) |
增加另一个SharedHandle的资源引用计数,减少自身计数。管理另一个SharedHandle的资源 更多... | |
| template<typename _HTy2 > | |
| void | _reset (SharedHandle< _HTy2 > const &other) |
增加另一个SharedHandle的资源引用计数,减少自身计数。管理另一个SharedHandle的资源 更多... | |
Protected 属性 | |
| SharedHandleData | _self |
友元 | |
| template<typename _HTy0 > | |
| class | SharedHandle |
| template<typename _HTy0 > | |
| class | WeakHandle |
引用计数共享句柄,管理各种资源的自动释放,赋值则引用计数加一。
还能指定一个failVal指示资源分配失败后的句柄值,当不等于这个值时才会创建删除器场景释放资源
在文件 smartptr.hpp 第 599 行定义.
| typedef _HTy winux::SharedHandle< _HTy >::HType |
句柄类型
在文件 smartptr.hpp 第 603 行定义.
|
inline |
构造函数0
在文件 smartptr.hpp 第 615 行定义.
|
inline |
|
inline |
|
inline |
|
inline |
构造函数2_2。_HTy2为可直接转为_HTy的类型
| [in] | h | 新资源的句柄 |
| [in] | failVal | 分配资源失败的句柄值 |
| [in] | dt | 可调用删除器 |
在文件 smartptr.hpp 第 644 行定义.
|
inlineexplicit |
构造函数3。从弱句柄构建共享句柄
在文件 smartptr.hpp 第 648 行定义.
|
inline |
析构函数
在文件 smartptr.hpp 第 657 行定义.
|
inline |
拷贝构造函数1
在文件 smartptr.hpp 第 663 行定义.
|
inline |
拷贝构造函数2。_HTy2为可直接转为_HTy的类型
在文件 smartptr.hpp 第 677 行定义.
|
inline |
拷贝赋值函数1
在文件 smartptr.hpp 第 669 行定义.
|
inline |
拷贝赋值函数2。_HTy2为可直接转为_HTy的类型
在文件 smartptr.hpp 第 684 行定义.
|
inline |
|
inline |
|
inline |
|
inline |
附加新句柄,管理新资源。_HTy2为可直接转为_HTy的类型
| [in] | h | 新资源的句柄 |
| [in] | failVal | 分配资源失败的句柄值 |
| [in] | dt | 可调用删除器 |
在文件 smartptr.hpp 第 726 行定义.
|
inline |
附加其他SharedHandle对象detach()出的句柄数据
若资源是新建而来,则isIncRef应设为false;
若资源是从另一个SharedHandle::detach()而来,则isIncRef应设为false;
若资源是从另一个SharedHandle窥视而来,则isIncRef应设为true。
在文件 smartptr.hpp 第 736 行定义.
|
inline |
附加其他SharedHandle对象detach()出的句柄数据。_HTy2为可直接转为_HTy的类型
若资源是新建而来,则isIncRef应设为false;
若资源是从另一个SharedHandle::detach()而来,则isIncRef应设为false;
若资源是从另一个SharedHandle窥视而来,则isIncRef应设为true。
在文件 smartptr.hpp 第 754 行定义.
|
inline |
附加其他SharedHandle对象detach()出的句柄和删除器场景。_HTy2为可直接转为_HTy的类型
若资源是新建而来,则isIncRef应设为false;
若资源是从另一个SharedHandle::detach()而来,则isIncRef应设为false;
若资源是从另一个SharedHandle窥视而来,则isIncRef应设为true。
在文件 smartptr.hpp 第 772 行定义.
|
inline |
资源脱离管理,返回句柄数据
在文件 smartptr.hpp 第 785 行定义.
|
inline |
窥视句柄数据
在文件 smartptr.hpp 第 794 行定义.
|
inline |
释放资源并重置
在文件 smartptr.hpp 第 800 行定义.
|
inline |
获取句柄
在文件 smartptr.hpp 第 806 行定义.
|
inline |
在文件 smartptr.hpp 第 807 行定义.
|
inline |
判断是否在管理资源
在文件 smartptr.hpp 第 810 行定义.
|
inline |
less,给MAP使用
在文件 smartptr.hpp 第 813 行定义.
|
inline |
在文件 smartptr.hpp 第 815 行定义.
|
inline |
在文件 smartptr.hpp 第 820 行定义.
|
inlineprotected |
减少自身引用计数,管理新资源
在文件 smartptr.hpp 第 828 行定义.
|
inlineprotected |
增加另一个SharedHandle的资源引用计数,减少自身计数。管理另一个SharedHandle的资源
在文件 smartptr.hpp 第 838 行定义.
|
inlineprotected |
增加另一个SharedHandle的资源引用计数,减少自身计数。管理另一个SharedHandle的资源
在文件 smartptr.hpp 第 847 行定义.
在文件 smartptr.hpp 第 856 行定义.
在文件 smartptr.hpp 第 858 行定义.
|
protected |
在文件 smartptr.hpp 第 852 行定义.