public static class ReflectedTypesA TypeDescriptor built by reflection, for a type no generator saw.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
What lets a project's Editor/ folder declare an asset importer. An importer is *named* by its settings type's [DataContract] alias, which TypeRegistry answers and Vixen.Core.Reflection.Generator normally writes — and an editor script is compiled with no generator driver. Everything else follows from the descriptor: YamlSerializer reads and writes a .meta's settings through TypeRegistry, and ArtifactKey hashes them as the YAML it emitted. One registration, and the rest of the pipeline never knows the difference.
⚠ Here rather than in Vixen.Core.Reflection, and that is the whole point of the file. The engine is published NativeAOT and ADR-002 is why the generator exists at all; the editor is not, which is what makes this permissible — but only in the editor. A reflection describer sitting in Core would be one a runtime could reach, and the first person to reach it would get a trimmed publish that works on their machine and not in a build.
⚠ It must agree with the generated one, member for member. A settings type moved from a script into a plugin would otherwise change what its .meta says — the same file read as a different set of values, which is a content bug with no error. The rules below are the generator's, and a test builds both for one type and compares them.
⚠ Narrow on purpose: it describes what an importer's settings need and nothing else. Describing every [DataContract] a script declares would put components one short step away, and a component that exists only when the editor compiled a script is a scene a game build cannot load.
Methods (2)
public static int Register(Type type)Describes a type and everything its members need, and registers the lot.
public static TypeDescriptor Describe(Type type)Describes one type without registering it or anything it references.
Used by (2)
- ReflectedTypeTestsVixen.Editor.Scripts.Tests
- ScriptModuleVixen.Editor.Scripts