private static UTinyType.Reference GetType(this IRegistry registry, string name) { if (null == registry) { return(UTinyType.Reference.None); } UTinyId id; if (!s_IDCache.TryGetValue(name, out id)) { s_IDCache[name] = id = UTinyId.Generate(name); } var type = registry.FindById <UTinyType>(id); if (null == type) { return(UTinyType.Reference.None); } return((UTinyType.Reference)type); }