public static string GetAttributeName(NameIdentifier name) { string res = name.HashString(); AttributeNames.TryGetValue(name.HashString(), out res); if (res == null) { res = name.HashString(); } return(res); }
internal AttributeInfo(Reader reader) { Name = new NameIdentifier(reader); Type = (AttributeTypes)reader.ReadByte(); string attribute = Objects.GetAttributeName(Name); if (attribute != null) { // Type mismatch //if (attribute.Type != Type) return; Name.Name = attribute; } else { var everyAttribute = Objects.AttributeNames; string hashString = Name.HashString(); foreach (System.Collections.Generic.KeyValuePair <string, string> s in everyAttribute) { NameIdentifier currentName = new NameIdentifier(s.Value); String currentHashedName = currentName.HashString(); if (currentHashedName == hashString) { Name = currentName; break; } } } }
public static ObjectInfo GetObjectInfo(NameIdentifier name) { ObjectInfo res = null; hashToObject.TryGetValue(name.HashString(), out res); return(res); }
public AttributeInfo GetAttributeInfo(NameIdentifier name) { AttributeInfo res = null; hashToAttribute.TryGetValue(name.HashString(), out res); return(res); }