在我们的例子里,我们全部要关心的是引用计数—全局和对象计数—和“数据库”结构。
In our sample, all we have to worry about is the reference counters-both the global and the object counter-and the "database" structures.
当作了这些修改以后,我使用调试器证实:当执行相同的测试案例时,与被删除的窗体相关联的对象计数减小。
After I made these code changes, I used the debugger to verify that the object count associated with the deleted form decreased when the same test case was executed.
在引用计数系统,每个所引用的对象都会保留一个计数,以获悉有多少对象正在引用它。
In a reference counting system, each object referenced maintains a count of how many objects are referencing it.
应用推荐