Esempio n. 1
0
        private static object Union(MemberData thisMembers, MemberData thatMembers)
        {
            if (thatMembers == null)
            {
                return(thisMembers);
            }

            if (thisMembers == null)
            {
                return(thatMembers.Clone());
            }

            thisMembers.Indexers = ArrayUnion(thisMembers.Indexers, thatMembers.Indexers);

            thisMembers.Constructors = ParameterUnion(thisMembers.Constructors, thatMembers.Constructors);

            thisMembers.Events      = DictionaryUnion(thisMembers.Events, thatMembers.Events);
            thisMembers.Fields      = DictionaryUnion(thisMembers.Fields, thatMembers.Fields);
            thisMembers.Methods     = DictionaryUnion(thisMembers.Methods, thatMembers.Methods, Union);
            thisMembers.NestedTypes = DictionaryUnion(thisMembers.NestedTypes, thatMembers.NestedTypes, Union);
            thisMembers.Properties  = DictionaryUnion(thisMembers.Properties, thatMembers.Properties, Union);

            return(thisMembers);
        }