示例#1
0
        private bool IsTakeOverScan(IMsScan scan)
        {
            object massRanges;

            ThermoFisher.Foundation.IO.Range[] x = new ThermoFisher.Foundation.IO.Range[] { };

            if (scan.CommonInformation.TryGetRawValue("MassRanges", out massRanges))
            {
                x = (ThermoFisher.Foundation.IO.Range[])massRanges;
                Console.WriteLine("Take Over scan: {0}, {1}", x.First().Low, x.First().High);

                if (x.First().Low == 374.0 && x.First().High == 1751.0)
                {
                    return(true);
                }
            }
            return(false);
        }
示例#2
0
        private bool IsBoxCarScan(IMsScan scan)
        {
            string value;
            string valueHigh;

            if (scan.CommonInformation.TryGetValue("LowMass", out value) && scan.CommonInformation.TryGetValue("HighMass", out valueHigh))
            {
                Console.WriteLine("Scan LowMass: " + value);
            }

            object massRanges;

            ThermoFisher.Foundation.IO.Range[] x = new ThermoFisher.Foundation.IO.Range[] { };
            if (scan.CommonInformation.TryGetRawValue("MassRanges", out massRanges))
            {
                x = (ThermoFisher.Foundation.IO.Range[])massRanges;
                Console.WriteLine("MassRanges:  {0}, {1}", x.First().Low, x.First().High);

                Console.WriteLine("Mass Ranges count: {0}", x.Count());
            }

            string msorder;

            if (scan.CommonInformation.TryGetValue("MSOrder", out msorder))
            {
                Console.WriteLine("Mass Order: " + msorder);
            }


            string massRangeCount;

            if (scan.CommonInformation.TryGetValue("MassRangeCount", out massRangeCount))
            {
                Console.WriteLine("BoxCar Scan Boxes: {0}.", int.Parse(massRangeCount));

                if (int.Parse(massRangeCount) > 1)
                {
                    return(true);
                }
            }

            return(false);
        }
示例#3
0
        private void Dump(IMsScan scan)
        {
            Console.WriteLine("----------------------------");
            object massRanges;

            ThermoFisher.Foundation.IO.Range[] x = new ThermoFisher.Foundation.IO.Range[] { };
            try
            {
                if (scan.CommonInformation.TryGetRawValue("MassRanges", out massRanges))
                {
                    Console.WriteLine("MassRanges:");
                    x = (ThermoFisher.Foundation.IO.Range[])massRanges;
                    Console.WriteLine("     {0}, {1}", x.First().Low, x.First().High);
                }
            }
            catch { }

            object a;

            try
            {
                if (scan.CommonInformation.TryGetRawValue("SourceFragmentationInfo", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("SourceFragmentationInfo     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("MultipleActivations", out a))
                {
                    var b = (Boolean[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("MultipleActivations     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("Activations", out a))
                {
                    var b = (ThermoFisher.Foundation.IO.ScanEventBase.ActivationType[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("Activations     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("EnergiesValid", out a))
                {
                    var b = (ThermoFisher.Foundation.IO.ScanEventBase.EnergyType[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("EnergiesValid     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("IsolationWidthOffset", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("IsolationWidthOffset     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("LastPrecursorMasses", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("LastPrecursorMasses     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("FirstPrecursorMasses", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("FirstPrecursorMasses     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("PrecursorRangeValidities", out a))
                {
                    var b = (Boolean[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("PrecursorRangeValidities     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("Energies", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("Energies     {0},", ib);
                    }
                }
            }
            catch { }

            try
            {
                if (scan.CommonInformation.TryGetRawValue("Masses", out a))
                {
                    var b = (double[])a;
                    foreach (var ib in b)
                    {
                        Console.WriteLine("Masses     {0},", ib);
                    }
                }
            }
            catch { }

            Console.WriteLine("----------------------------");
        }