Exemplo n.º 1
0
        public static ThermoGlobalParams GetAllGlobalStuff(IXRawfile5 _rawConnection, ManagedThermoHelperLayer.PrecursorInfo[] couldBePrecursor, string filePath)
        {
            int pnNumInstMethods = 0;

            _rawConnection.GetNumInstMethods(ref pnNumInstMethods);

            string[] instrumentMethods = new string[pnNumInstMethods];
            for (int nInstMethodItem = 0; nInstMethodItem < pnNumInstMethods; nInstMethodItem++)
            {
                string pbstrInstMethod = null;
                _rawConnection.GetInstMethod(nInstMethodItem, ref pbstrInstMethod);
                instrumentMethods[nInstMethodItem] = pbstrInstMethod;
            }

            string pbstrInstSoftwareVersion = null;

            _rawConnection.GetInstSoftwareVersion(ref pbstrInstSoftwareVersion);

            string pbstrInstName = null;

            _rawConnection.GetInstName(ref pbstrInstName);

            string pbstrInstModel = null;

            _rawConnection.GetInstModel(ref pbstrInstModel);

            int pnControllerNumber = 0;
            int pnControllerType   = 0;

            _rawConnection.GetCurrentController(ref pnControllerType, ref pnControllerNumber);

            int[] msOrderByScan = new int[couldBePrecursor.Length];
            for (int i = 0; i < couldBePrecursor.Length; i++)
            {
                _rawConnection.GetMSOrderForScanNum((i + 1), ref msOrderByScan[i]);
            }

            return(new ThermoGlobalParams(pnNumInstMethods, instrumentMethods, pbstrInstSoftwareVersion, pbstrInstName, pbstrInstModel, pnControllerType, pnControllerNumber, couldBePrecursor, filePath, msOrderByScan));
        }