コード例 #1
0
        private void btnLoadDocumentXML_Click(object sender, EventArgs e)
        {
            this.lblFileSizeXML.Text = "Deserializing the XML file";
            AbortRequested           = false;
            ObjectEnabling(false);

            MassiveReadXML = ObjectXMLSerializer <SerializableDictionary <int, SerializableDictionary <int, string> > > .LoadDocumentFormat(this.lblFileNameXML.Text);

            this.lblFileSizeXML.Text = "Comparing deserialized XML file content against original";
            this.lblFileSizeXML.Refresh();
            if (!CompareMassiveXMLs())
            {
                MessageBox.Show("The XML deserialized object does not match the original.");
            }
            MassiveReadXML           = null;
            this.lblFileSizeXML.Text = "Deserializing the XML GZ file";
            this.lblFileSizeXML.Refresh();
            MassiveReadXML = ObjectXMLSerializer <SerializableDictionary <int, SerializableDictionary <int, string> > > .LoadCompressedDocumentFormat(this.lblFileNameXML.Text + ".gz");

            this.lblFileSizeXML.Text = "Comparing deserialized XML GZ file content against original";
            this.lblFileSizeXML.Refresh();
            if (!CompareMassiveXMLs())
            {
                MessageBox.Show("The XML GZ deserialized object does not match the original.");
            }
            this.lblFileSizeXML.Text = "Forcing garbage collection";
            this.lblFileSizeXML.Refresh();
            MassiveReadXML           = null;
            this.lblFileSizeXML.Text = "Idle";
            ObjectEnabling(true);
        }