This means that no subclass of that class can declare a finalizer.
这意味着该类的任何子类都无法声明终结器。
An empty finalizer (which negates the effect of the superclass finalizer).
空的finalizer(它抵消超类finalizer的作用)。
There is no guarantee when a finalizer will be run, or even if it will be run at all.
无法保证终结器将在何时运行,或者甚至它是否会运行。
The exploit is a variation of the well-known technique of using a finalizer for resurrecting an object.
该漏洞是使用终结器来恢复对象的著名技术的一种变体。
When the zombie finalizer is called, it takes the object being finalized - referenced by this - and stores it in the static zombie variable.
在调用zombie终结器时,它获取被终结的对象(由this引用)并将它存储在静态zombie变量中。
This prevents the finalizer from reclaiming other objects.
这会阻止终结器回收其他对象。
An empty finalizer incurs this added overhead without any benefit.
空的终结器只会徒增这种系统开销,而没有一点好处。
If a destructor is present, rewrite that to be the class finalizer.
如果存在析构函数,则将其重写为类终结器。
For example, a new slot cannot be requested on a destructor or finalizer.
例如,无法在析构函数或终结器上请求一个新的槽。
A finalizer can use this method to resurrect itself or an object that it references.
终结器可以使用此方法使自己或引用的对象重新起用。
As a consequence, you should never depend on a finalizer to update critical persistent state.
结论就是:你从不该依赖终结方法来更新重要的持续状态。
Providing a finalizer for a class can, under rare conditions, arbitrarily delay reclamation of its instances.
在很少的情况下,为一个类提供终结方法可能会随意地延迟它实例的回收。
A finalizer is an appropriate vehicle for performing this task, assuming the native peer holds no critical resources.
假设本地对等体不拥有重要的资源,终结方法是执行这个任务的合适工具。
It can take arbitrarily long between the time that an object becomes unreachable and the time that its finalizer is executed.
从对象变得不可访问开始到它的终结方法被执行结束,这中间的时间可以任意长。
If you are considering writing such a safety-net finalizer, think long and hard about whether the extra protection is worth the extra cost.
如果你正在考虑写这样一个安全网终结方法,要仔细思考这种额外的保护是否值得额外的代价。
The disadvantage of this approach is that the existence of the finalizer means that the object is kept alive longer than it otherwise would be.
此方法的缺点是,终结器的存在意味着对象的存活期比其他情况下更长。
The ability of a finalizer to revive an object destined for garbage collection is clearly an unintended consequence of the way that the finalization mechanism works.
终结器恢复即将被垃圾收集的能力无疑是终结机制工作方式的一种意外后果。
Analysis revealed that at the time of its death, the application had thousands of graphics objects on its finalizer queue just waiting to be finalized and reclaimed.
分析表明在程序死亡时,应用中的终结方法队列中有成千上万的图形对象在等待被终结并回收。
When a finalizer throws an exception that it does not handle, the runtime prints the exception stack trace to the console and then allows the finalizer thread to resume running finalizers.
当终结器引发它无法处理的异常时,运行时将把异常堆栈跟踪打印至控制台,然后允许终结器线程继续运行终结器。
When a finalizer throws an exception that it does not handle, the runtime prints the exception stack trace to the console and then allows the finalizer thread to resume running finalizers.
当终结器引发它无法处理的异常时,运行时将把异常堆栈跟踪打印至控制台,然后允许终结器线程继续运行终结器。
应用推荐