@gby/destroyable 3.6.1 → 3.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/DestroyableEventEmitter.d.ts +0 -1
- package/dist/DestroyableEventEmitter.d.ts.map +1 -1
- package/package.json +3 -3
- package/doc/api/destroyable.createdestroyablesubclass.md +0 -82
- package/doc/api/destroyable.destroyable._destroyers.md +0 -13
- package/doc/api/destroyable.destroyable._isdestroyed.md +0 -11
- package/doc/api/destroyable.destroyable.canceldispose.md +0 -49
- package/doc/api/destroyable.destroyable.canceldispose_1.md +0 -49
- package/doc/api/destroyable.destroyable.canceldispose_2.md +0 -49
- package/doc/api/destroyable.destroyable.canceldisposefun.md +0 -52
- package/doc/api/destroyable.destroyable.canceldisposeobj.md +0 -52
- package/doc/api/destroyable.destroyable.destroy.md +0 -17
- package/doc/api/destroyable.destroyable.destroyasync.md +0 -21
- package/doc/api/destroyable.destroyable.destroythis.md +0 -21
- package/doc/api/destroyable.destroyable.dispose.md +0 -51
- package/doc/api/destroyable.destroyable.dispose_1.md +0 -65
- package/doc/api/destroyable.destroyable.dispose_2.md +0 -65
- package/doc/api/destroyable.destroyable.disposefun.md +0 -53
- package/doc/api/destroyable.destroyable.disposeobj.md +0 -68
- package/doc/api/destroyable.destroyable.isdestroyed.md +0 -13
- package/doc/api/destroyable.destroyable.md +0 -287
- package/doc/api/destroyable.destroyablesub.md +0 -15
- package/doc/api/destroyable.destroyablesubclass.md +0 -13
- package/doc/api/destroyable.destroydestroyable.md +0 -52
- package/doc/api/destroyable.destroyobject.md +0 -52
- package/doc/api/destroyable.fundestroyer.md +0 -13
- package/doc/api/destroyable.md +0 -225
- package/doc/api/destroyable.nodedestroyable.md +0 -39
- package/doc/api/destroyable.nodedestroyableclass.md +0 -15
- package/doc/api/destroyable.throwondestroyed.md +0 -17
- package/doc/api/destroyable.webdestroyable.md +0 -39
- package/doc/api/destroyable.webdestroyableclass.md +0 -15
- package/doc/api/index.md +0 -31
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [Destroyable](./destroyable.destroyable.md) > [disposeFun](./destroyable.destroyable.disposefun.md)
|
|
4
|
-
|
|
5
|
-
## Destroyable.disposeFun() method
|
|
6
|
-
|
|
7
|
-
添加销毁者
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
disposeFun<T extends FunDestroyer>(fun: T): T;
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Parameters
|
|
16
|
-
|
|
17
|
-
<table><thead><tr><th>
|
|
18
|
-
|
|
19
|
-
Parameter
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</th><th>
|
|
23
|
-
|
|
24
|
-
Type
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
</th><th>
|
|
28
|
-
|
|
29
|
-
Description
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</th></tr></thead>
|
|
33
|
-
<tbody><tr><td>
|
|
34
|
-
|
|
35
|
-
fun
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
</td><td>
|
|
39
|
-
|
|
40
|
-
T
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
</td></tr>
|
|
47
|
-
</tbody></table>
|
|
48
|
-
**Returns:**
|
|
49
|
-
|
|
50
|
-
T
|
|
51
|
-
|
|
52
|
-
返回销毁者的顺序
|
|
53
|
-
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [Destroyable](./destroyable.destroyable.md) > [disposeObj](./destroyable.destroyable.disposeobj.md)
|
|
4
|
-
|
|
5
|
-
## Destroyable.disposeObj() method
|
|
6
|
-
|
|
7
|
-
添加销毁对象
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
disposeObj<T extends Destroyable>(obj: T, sync?: boolean): T;
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Parameters
|
|
16
|
-
|
|
17
|
-
<table><thead><tr><th>
|
|
18
|
-
|
|
19
|
-
Parameter
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</th><th>
|
|
23
|
-
|
|
24
|
-
Type
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
</th><th>
|
|
28
|
-
|
|
29
|
-
Description
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</th></tr></thead>
|
|
33
|
-
<tbody><tr><td>
|
|
34
|
-
|
|
35
|
-
obj
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
</td><td>
|
|
39
|
-
|
|
40
|
-
T
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
</td></tr>
|
|
47
|
-
<tr><td>
|
|
48
|
-
|
|
49
|
-
sync
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
</td><td>
|
|
53
|
-
|
|
54
|
-
boolean
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
</td><td>
|
|
58
|
-
|
|
59
|
-
_(Optional)_ 表示是否使用 `obj.destroy()` 方法进行销毁;默认使用 `obj.destroyAsync()` 方法进行销毁
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
</td></tr>
|
|
63
|
-
</tbody></table>
|
|
64
|
-
**Returns:**
|
|
65
|
-
|
|
66
|
-
T
|
|
67
|
-
|
|
68
|
-
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [Destroyable](./destroyable.destroyable.md) > [isDestroyed](./destroyable.destroyable.isdestroyed.md)
|
|
4
|
-
|
|
5
|
-
## Destroyable.isDestroyed property
|
|
6
|
-
|
|
7
|
-
是否已经销毁
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
get isDestroyed(): boolean;
|
|
13
|
-
```
|
|
@@ -1,287 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [Destroyable](./destroyable.destroyable.md)
|
|
4
|
-
|
|
5
|
-
## Destroyable class
|
|
6
|
-
|
|
7
|
-
可销毁的对象
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export declare class Destroyable
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Properties
|
|
16
|
-
|
|
17
|
-
<table><thead><tr><th>
|
|
18
|
-
|
|
19
|
-
Property
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</th><th>
|
|
23
|
-
|
|
24
|
-
Modifiers
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
</th><th>
|
|
28
|
-
|
|
29
|
-
Type
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</th><th>
|
|
33
|
-
|
|
34
|
-
Description
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
</th></tr></thead>
|
|
38
|
-
<tbody><tr><td>
|
|
39
|
-
|
|
40
|
-
[\_destroyers](./destroyable.destroyable._destroyers.md)
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
</td><td>
|
|
47
|
-
|
|
48
|
-
[FunDestroyer](./destroyable.fundestroyer.md)<!-- -->\[\]
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
</td><td>
|
|
52
|
-
|
|
53
|
-
销毁者
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
</td></tr>
|
|
57
|
-
<tr><td>
|
|
58
|
-
|
|
59
|
-
[\_isDestroyed](./destroyable.destroyable._isdestroyed.md)
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
</td><td>
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
</td><td>
|
|
66
|
-
|
|
67
|
-
boolean
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
</td><td>
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
</td></tr>
|
|
74
|
-
<tr><td>
|
|
75
|
-
|
|
76
|
-
[isDestroyed](./destroyable.destroyable.isdestroyed.md)
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
</td><td>
|
|
80
|
-
|
|
81
|
-
`readonly`
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
</td><td>
|
|
85
|
-
|
|
86
|
-
boolean
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
</td><td>
|
|
90
|
-
|
|
91
|
-
是否已经销毁
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
</td></tr>
|
|
95
|
-
</tbody></table>
|
|
96
|
-
|
|
97
|
-
## Methods
|
|
98
|
-
|
|
99
|
-
<table><thead><tr><th>
|
|
100
|
-
|
|
101
|
-
Method
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
</th><th>
|
|
105
|
-
|
|
106
|
-
Modifiers
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
</th><th>
|
|
110
|
-
|
|
111
|
-
Description
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
</th></tr></thead>
|
|
115
|
-
<tbody><tr><td>
|
|
116
|
-
|
|
117
|
-
[cancelDispose(fun)](./destroyable.destroyable.canceldispose.md)
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
</td><td>
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
</td><td>
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
</td></tr>
|
|
127
|
-
<tr><td>
|
|
128
|
-
|
|
129
|
-
[cancelDispose(obj)](./destroyable.destroyable.canceldispose_1.md)
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
</td><td>
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
</td><td>
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
</td></tr>
|
|
139
|
-
<tr><td>
|
|
140
|
-
|
|
141
|
-
[cancelDispose(objOrFun)](./destroyable.destroyable.canceldispose_2.md)
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
</td><td>
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
</td><td>
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
</td></tr>
|
|
151
|
-
<tr><td>
|
|
152
|
-
|
|
153
|
-
[cancelDisposeFun(fun)](./destroyable.destroyable.canceldisposefun.md)
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
</td><td>
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
</td><td>
|
|
160
|
-
|
|
161
|
-
取消销毁者函数
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
</td></tr>
|
|
165
|
-
<tr><td>
|
|
166
|
-
|
|
167
|
-
[cancelDisposeObj(obj)](./destroyable.destroyable.canceldisposeobj.md)
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
</td><td>
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
</td><td>
|
|
174
|
-
|
|
175
|
-
取消销毁者函数
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
</td></tr>
|
|
179
|
-
<tr><td>
|
|
180
|
-
|
|
181
|
-
[destroy()](./destroyable.destroyable.destroy.md)
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
</td><td>
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
</td><td>
|
|
188
|
-
|
|
189
|
-
销毁
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
</td></tr>
|
|
193
|
-
<tr><td>
|
|
194
|
-
|
|
195
|
-
[destroyAsync()](./destroyable.destroyable.destroyasync.md)
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
</td><td>
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
</td><td>
|
|
202
|
-
|
|
203
|
-
异步销毁
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
</td></tr>
|
|
207
|
-
<tr><td>
|
|
208
|
-
|
|
209
|
-
[destroyThis()](./destroyable.destroyable.destroythis.md)
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
</td><td>
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
</td><td>
|
|
216
|
-
|
|
217
|
-
自己的销毁方法
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
</td></tr>
|
|
221
|
-
<tr><td>
|
|
222
|
-
|
|
223
|
-
[dispose(fun)](./destroyable.destroyable.dispose.md)
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
</td><td>
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
</td><td>
|
|
230
|
-
|
|
231
|
-
添加销毁函数或销毁对象
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
</td></tr>
|
|
235
|
-
<tr><td>
|
|
236
|
-
|
|
237
|
-
[dispose(obj, asyncDestroy)](./destroyable.destroyable.dispose_1.md)
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
</td><td>
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
</td><td>
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
</td></tr>
|
|
247
|
-
<tr><td>
|
|
248
|
-
|
|
249
|
-
[dispose(objOrFun, asyncDestroy)](./destroyable.destroyable.dispose_2.md)
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
</td><td>
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
</td><td>
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
</td></tr>
|
|
259
|
-
<tr><td>
|
|
260
|
-
|
|
261
|
-
[disposeFun(fun)](./destroyable.destroyable.disposefun.md)
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
</td><td>
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
</td><td>
|
|
268
|
-
|
|
269
|
-
添加销毁者
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
</td></tr>
|
|
273
|
-
<tr><td>
|
|
274
|
-
|
|
275
|
-
[disposeObj(obj, sync)](./destroyable.destroyable.disposeobj.md)
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
</td><td>
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
</td><td>
|
|
282
|
-
|
|
283
|
-
添加销毁对象
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
</td></tr>
|
|
287
|
-
</tbody></table>
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [DestroyableSub](./destroyable.destroyablesub.md)
|
|
4
|
-
|
|
5
|
-
## DestroyableSub type
|
|
6
|
-
|
|
7
|
-
createDestroyableSubClass 创建的类的实例类型
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export type DestroyableSub<ParentClass extends new (...args: any) => Object> = InstanceType<DestroyableSubClass<ParentClass>>;
|
|
13
|
-
```
|
|
14
|
-
**References:** [DestroyableSubClass](./destroyable.destroyablesubclass.md)
|
|
15
|
-
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [DestroyableSubClass](./destroyable.destroyablesubclass.md)
|
|
4
|
-
|
|
5
|
-
## DestroyableSubClass type
|
|
6
|
-
|
|
7
|
-
createDestroyableSubClass 创建的类的类型
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export type DestroyableSubClass<ParentClass extends new (...args: any) => Object> = ReturnType<typeof createDestroyableSubClass<ParentClass>>;
|
|
13
|
-
```
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [destroyDestroyable](./destroyable.destroydestroyable.md)
|
|
4
|
-
|
|
5
|
-
## destroyDestroyable() function
|
|
6
|
-
|
|
7
|
-
销毁 Destroyable 对象
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export declare function destroyDestroyable(object: Destroyable): boolean;
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Parameters
|
|
16
|
-
|
|
17
|
-
<table><thead><tr><th>
|
|
18
|
-
|
|
19
|
-
Parameter
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</th><th>
|
|
23
|
-
|
|
24
|
-
Type
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
</th><th>
|
|
28
|
-
|
|
29
|
-
Description
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</th></tr></thead>
|
|
33
|
-
<tbody><tr><td>
|
|
34
|
-
|
|
35
|
-
object
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
</td><td>
|
|
39
|
-
|
|
40
|
-
[Destroyable](./destroyable.destroyable.md)
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
</td></tr>
|
|
47
|
-
</tbody></table>
|
|
48
|
-
**Returns:**
|
|
49
|
-
|
|
50
|
-
boolean
|
|
51
|
-
|
|
52
|
-
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [destroyObject](./destroyable.destroyobject.md)
|
|
4
|
-
|
|
5
|
-
## destroyObject() function
|
|
6
|
-
|
|
7
|
-
销毁对象
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export declare function destroyObject(object: any): boolean;
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Parameters
|
|
16
|
-
|
|
17
|
-
<table><thead><tr><th>
|
|
18
|
-
|
|
19
|
-
Parameter
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</th><th>
|
|
23
|
-
|
|
24
|
-
Type
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
</th><th>
|
|
28
|
-
|
|
29
|
-
Description
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</th></tr></thead>
|
|
33
|
-
<tbody><tr><td>
|
|
34
|
-
|
|
35
|
-
object
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
</td><td>
|
|
39
|
-
|
|
40
|
-
any
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
</td></tr>
|
|
47
|
-
</tbody></table>
|
|
48
|
-
**Returns:**
|
|
49
|
-
|
|
50
|
-
boolean
|
|
51
|
-
|
|
52
|
-
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@gby/destroyable](./destroyable.md) > [FunDestroyer](./destroyable.fundestroyer.md)
|
|
4
|
-
|
|
5
|
-
## FunDestroyer type
|
|
6
|
-
|
|
7
|
-
函数销毁者
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
export type FunDestroyer = () => void;
|
|
13
|
-
```
|