Exemplo n.º 1
0
        public ChangeSet CreateChangeSet(AssemblyNode assemblyNode)
        {
            try
            {
                var visitor = new ChangeSetNodeVisitor(ignoreChangeSet, true);
                assemblyNode.Accept(visitor);

                return(visitor.AsChangeSet());
            }
            catch (Exception ex)
            {
                Console.WriteLine("Could not decompiler: \r\n" + ex);
                throw ex;
            }
        }
Exemplo n.º 2
0
        public string CreateXMLDiff(AssemblyNode assemblyNode)
        {
            try
            {
                var visitor = new ChangeSetNodeVisitor(ignoreChangeSet, true);
                assemblyNode.Accept(visitor);

                var changeSet = visitor.AsChangeSet();

                var xmlSerializer = new XmlSerializer(typeof(ChangeSet));
                using (var stringWriter = new StringWriter())
                {
                    xmlSerializer.Serialize(stringWriter, changeSet);
                    return(stringWriter.ToString());
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Could not decompiler: \r\n" + ex);
                throw ex;
            }
        }