AssetScope
此内容尚不支持你的语言。
Defined in: asset/AssetLease.ts:39
Everything one owner acquired, released together.
Details
Section titled “Details”Holds receipts rather than paths, so unloading releases what was actually acquired — not what the manifest says this owner would acquire if it loaded today. A failed acquisition produced no lease, so there is nothing to release and nothing to guess about.
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new AssetScope():
AssetScope
Returns
Section titled “Returns”AssetScope
Accessors
Section titled “Accessors”Get Signature
Section titled “Get Signature”get size():
number
Defined in: asset/AssetLease.ts:76
How many acquisitions this scope still owes. Diagnostics and tests.
Returns
Section titled “Returns”number
Methods
Section titled “Methods”absorb()
Section titled “absorb()”absorb(
other):void
Defined in: asset/AssetLease.ts:61
Take over every receipt other holds; it owes nothing afterwards.
The transfer an owner needs when the acquiring code is not the owning code: a loader acquires into a scope of its own and hands the whole thing to whoever will outlive it.
Parameters
Section titled “Parameters”AssetScope
Returns
Section titled “Returns”void
add<
T>(lease):AssetLease<T>
Defined in: asset/AssetLease.ts:42
Type Parameters
Section titled “Type Parameters”T
Parameters
Section titled “Parameters”AssetLease<T>
Returns
Section titled “Returns”AssetLease<T>
forget()
Section titled “forget()”forget(
lease):boolean
Defined in: asset/AssetLease.ts:68
Stop tracking one lease without releasing it — for an ownership transfer.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”boolean
releaseAll()
Section titled “releaseAll()”releaseAll():
void
Defined in: asset/AssetLease.ts:48
Hand back everything, in reverse acquisition order.
Returns
Section titled “Returns”void