阅读背景:

以允许响应更新的方式重载c++下标操作符[]

来源:互联网 

Consider the task of writing an indexable class which automatically synchronizes its state with some external data-store (e.g. a file). In order to do this the class would need to be made aware of changes to the indexed value which might occur. Unfortunately the usual approach to overloading operator[] does not allow for this, for example...Consider the task of writing an indexable class




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: