ドキュメント

Unity Engine

Download Unity

Unity Engine

ClearCacheBetweenCodeLoadsAttribute

Marks a static method as a callback that clears cached data between code loads.
読み終わるまでの所要時間 3 分最終更新 21日前

Definition

[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]public sealed class ClearCacheBetweenCodeLoadsAttribute : LifecycleAttributeBase

Remarks

Unity invokes methods marked with this attribute after all OnCodeUnloadingAttribute callbacks have run and before OnCodeLoadedAttribute callbacks run. Use it to discard caches that hold data from the previous code load.
This is a method attribute that can only be applied to
static
methods with no parameters and return type
void
.

Constructors

Constructor

Description

ClearCacheBetweenCodeLoadsAttribute()Marks the decorated static method to be invoked to clear caches between code loads.

Inheritance

Inherited Members