/// <summary> /// Adds a field entity /// </summary> /// <param name="fd"></param> public void AddFieldEntity(TypeDefinition td, FieldDefinition fd) { if (!fieldEntities.ContainsKey(fd.FullName)) { var field = fd.Instantiate(MethodOrFieldAnalyzer.GetGenericTypeParameters(this.host, td)); DeclFieldEntity dfe = new DeclFieldEntity(field); fieldEntities[field.FullName] = dfe; } }
public bool TryGetFieldEntity(TypeDefinition td, FieldDefinition fd, out DeclFieldEntity dfe) { var field = fd.Instantiate(MethodOrFieldAnalyzer.GetGenericTypeParameters(this.host, td)); return fieldEntities.TryGetValue(fd.FullName, out dfe); }
public bool TryGetFieldEntity(TypeDefinition td, FieldDefinition fd, out DeclFieldEntity dfe) { var field = fd.Instantiate(MethodOrFieldAnalyzer.GetGenericTypeParameters(this.host, td)); return(fieldEntities.TryGetValue(fd.FullName, out dfe)); }