示例#1
0
 /// <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);
 }
 /// <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;
     }
 }
示例#4
0
        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));
        }