Repository navigation
Commit 0c36a90
committed
[CBD-2146] Regenerate TypeIdRegistry from engine type list; add generator
TypeIdRegistry maps Unity ClassIDs (PersistentTypeID) to type names. It is
needed as a fallback when a serialized object's TypeTree is unavailable, and
when only an ID is known with no file to read at all (e.g. resolving the type
of a PackedAsset referenced from a BuildReport). In those cases the name cannot
be recovered from the data, so a static map in the tool is required.
The map was previously built by hand from the public ClassIDReference page and
pruned manually, with no repeatable way to refresh it as new types are added.
TypeIdRegistryGenerator (hosted in the UnityFileSystemTestData project) now
produces the entries from the live engine type list (UnityEditor.UnityType):
runtime types are kept, editor-only types are dropped via the isEditorOnly
flag, a small allowlist of BuildReporting types is force-included (needed for
BuildReport inspection), and test/fake types from development builds are
filtered out. Run it via Tools/Generate TypeIdRegistry or -executeMethod to
regenerate the block for a new Unity version.1 parent 9483aa6 commit 0c36a90
3 files changed
Lines changed: 151 additions & 57 deletions
File tree
- UnityFileSystemTestData/Assets/Editor
- UnityFileSystem
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
8 | 11 | | |
9 | 12 | | |
10 | 13 | | |
| |||
74 | 77 | | |
75 | 78 | | |
76 | 79 | | |
77 | | - | |
78 | | - | |
79 | 80 | | |
80 | 81 | | |
81 | 82 | | |
82 | 83 | | |
83 | 84 | | |
84 | | - | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
114 | | - | |
115 | | - | |
116 | 114 | | |
117 | 115 | | |
118 | 116 | | |
| |||
139 | 137 | | |
140 | 138 | | |
141 | 139 | | |
142 | | - | |
143 | 140 | | |
144 | 141 | | |
145 | 142 | | |
146 | 143 | | |
147 | 144 | | |
148 | | - | |
149 | 145 | | |
150 | 146 | | |
151 | 147 | | |
| |||
170 | 166 | | |
171 | 167 | | |
172 | 168 | | |
173 | | - | |
174 | 169 | | |
175 | 170 | | |
176 | 171 | | |
| |||
199 | 194 | | |
200 | 195 | | |
201 | 196 | | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | 197 | | |
223 | 198 | | |
224 | 199 | | |
| |||
234 | 209 | | |
235 | 210 | | |
236 | 211 | | |
237 | | - | |
238 | 212 | | |
239 | 213 | | |
240 | 214 | | |
241 | 215 | | |
242 | 216 | | |
243 | | - | |
| 217 | + | |
244 | 218 | | |
| 219 | + | |
245 | 220 | | |
246 | | - | |
247 | 221 | | |
248 | | - | |
249 | | - | |
| 222 | + | |
| 223 | + | |
250 | 224 | | |
251 | | - | |
252 | | - | |
253 | 225 | | |
254 | | - | |
255 | 226 | | |
256 | | - | |
257 | 227 | | |
258 | 228 | | |
259 | | - | |
260 | 229 | | |
261 | 230 | | |
262 | | - | |
263 | | - | |
264 | 231 | | |
265 | 232 | | |
266 | 233 | | |
267 | | - | |
268 | | - | |
269 | 234 | | |
270 | | - | |
271 | | - | |
272 | | - | |
273 | | - | |
274 | | - | |
275 | | - | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
276 | 240 | | |
277 | 241 | | |
278 | | - | |
279 | 242 | | |
280 | | - | |
281 | | - | |
282 | 243 | | |
283 | 244 | | |
284 | 245 | | |
285 | 246 | | |
286 | | - | |
287 | | - | |
288 | 247 | | |
289 | 248 | | |
290 | | - | |
291 | 249 | | |
292 | 250 | | |
293 | 251 | | |
| 252 | + | |
294 | 253 | | |
295 | 254 | | |
296 | 255 | | |
297 | 256 | | |
298 | | - | |
299 | 257 | | |
| 258 | + | |
300 | 259 | | |
301 | 260 | | |
302 | 261 | | |
303 | | - | |
304 | 262 | | |
305 | 263 | | |
306 | 264 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments