protected void AddDescription(Type attributeType, MemberDescription description) { Type type = attributeType; List <MemberDescription> result; if (!(_members ?? (_members = new Dictionary <Type, List <MemberDescription> >())).TryGetValue(type, out result)) { result = new List <MemberDescription>(_memberCapacity); (_members ?? (_members = new Dictionary <Type, List <MemberDescription> >())).Add(type, result); } result.Add(description); MapMemberAttribute(type); }
protected void AddDescription(Attribute attribute, MemberDescription description) { AddDescription(attribute.GetType(), description); }