예제 #1
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            IDeviceModel deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.Pump);

            // Create gradient page for TimeTableDriver.
            //Information like flow symbol and solvent symbols are stored in IPumpDescription.
            //See CM7 DDK V2 help for further information.
            IPumpDescription pumpDescription = plugIn.System.PumpSubsystem.CreatePumpDescription(plugIn.Symbol as IDevice);

            plugIn.System.PumpSubsystem.Pumps.Add(pumpDescription);
            IPage iGradientPage = deviceModel.CreatePage(new PumpGradientPage(pumpDescription), "Gradient Settings", plugIn.Symbol);

            //Add iGradientPage to Wizard page collection. Set order to OvenPages .
            deviceModel.WizardPages.Add(iGradientPage, WizardPageOrder.PumpPages);
            //Add iGradientPage page to Editor page collection.
            IEditorDeviceView deviceEditorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.PumpViews);

            deviceEditorView.Pages.Add(iGradientPage);

            // Create time grid page for TimeTableDriver.
            IPage iValvePage = deviceModel.CreatePage(new TimeGridPage(), "Valve Settings", plugIn.Symbol);

            //Add iTempCtrlPage to Wizard page collection. Set order to OvenPages .
            deviceModel.WizardPages.Add(iValvePage, WizardPageOrder.PumpPages);
            //Add TempCtrl page to Editor page collection.
            deviceEditorView.Pages.Add(iValvePage);
        }
예제 #2
0
        private static void InitializePump(IEditorPlugIn plugIn, IDevice deviceSymbol)
        {
            IPage        gradientPage;
            IDeviceModel deviceModel = plugIn.DeviceModels.Add(deviceSymbol, DeviceIcon.Pump);

            IPumpDescription description = plugIn.System.PumpSubsystem.CreatePumpDescription(deviceSymbol);

            plugIn.System.PumpSubsystem.Pumps.Add(description);

            ISymbol curveSymbol = deviceSymbol.Children["Curve"];

            if (curveSymbol != null)
            {
                PumpGradientPage gradientPageControl = new PumpGradientPage(description);
                gradientPageControl.AllowEmptyGradientCells = false;
                gradientPage = deviceModel.CreatePage(gradientPageControl, "Gradient", deviceSymbol);
            }
            else
            {
                gradientPage = deviceModel.CreatePage(new PumpGradientPlotPage(description), "Gradient", deviceSymbol);
            }

            gradientPage.Description = deviceSymbol.Name + " Gradient";
            IPage pumpPage = deviceModel.CreatePage(new PumpFlowPage(gradientPage, description), "Flow", deviceSymbol);

            pumpPage.Description = deviceSymbol.Name + " Flow";

            IEditorDeviceView view = deviceModel.EditorDeviceViews.Add(EditorViewOrder.PumpViews);

            view.Pages.Add(pumpPage);
            view.Pages.Add(gradientPage);

            deviceModel.WizardPages.Add(pumpPage, WizardPageOrder.PumpPages);
            deviceModel.WizardPages.Add(gradientPage, WizardPageOrder.PumpPages);
        }
예제 #3
0
        void IInitEditorPlugIn.Initialize(IEditorPlugIn plugIn)
        {
            IDeviceModel      deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, Resources.Heater);
            IPage             page        = deviceModel.CreatePage(new HeaterPage(), plugIn.Symbol.Name, plugIn.Symbol);
            IEditorDeviceView view        = deviceModel.EditorDeviceViews.Add(EditorViewOrder.MiscDetectorViews);

            view.Pages.Add(page);
            deviceModel.WizardPages.Add(page, WizardPageOrder.MiscDetectorPages);

            DemoCode(plugIn, page);  // Code just for demo - not necessary for this plug-in
        }
예제 #4
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            IDeviceModel deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.LcSystem);
            //Create page for Simple Driver.
            var   simpleDriverPage  = new SimpleDriverPage();
            IPage iSimpleDriverPage = deviceModel.CreatePage(simpleDriverPage, "Simple Driver Settings", plugIn.Symbol);

            //Add iSimpleDriverPage to Wizard page collection. Set order to LcSystemPages .
            deviceModel.WizardPages.Add(iSimpleDriverPage, WizardPageOrder.LCSystemPages);
            //Add Simple Driver page to Editor page collection.
            IEditorDeviceView editorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.LCSystemViews);

            editorView.Pages.Add(iSimpleDriverPage);
        }
예제 #5
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            IDeviceModel deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.LcSystem);
            //Create page for Simple Driver.
            var   tempCtrlPage  = new TempCtrlPage();
            IPage iTempCtrlPage = deviceModel.CreatePage(tempCtrlPage, "Temperature Control Settings", plugIn.Symbol);

            //Add iTempCtrlPage to Wizard page collection. Set order to OvenPages .
            deviceModel.WizardPages.Add(iTempCtrlPage, WizardPageOrder.OvenPages);
            //Add TempCtrl page to Editor page collection.
            IEditorDeviceView editorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.OvenViews);

            editorView.Pages.Add(iTempCtrlPage);
        }
예제 #6
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            // Register the .Ready property of the device.
            // It will be added to condition clause of the wait command before injection.
            plugIn.System.InjectorSubsystem.ReadyForInjectDevices.Add(plugIn.Symbol);

            IDeviceModel deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.LcSystem);

            //Create page for detector device.
            var   detectorPage  = new DetectorPage(plugIn);
            IPage iDetectorPage = deviceModel.CreatePage(detectorPage, "ChannelTest Detector Settings", plugIn.Symbol);

            //Add iDetectorPage to Wizard page collection.
            deviceModel.WizardPages.Add(iDetectorPage, WizardPageOrder.MiscDetectorPages);
            //Add detector page to Editor page collection.
            IEditorDeviceView editorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.MiscDetectorViews);

            editorView.Pages.Add(iDetectorPage);
        }
예제 #7
0
        void IInitEditorPlugIn.Initialize(IEditorPlugIn plugIn)
        {
            m_Detector = plugIn.System.DataAcquisition.Detectors.Add(plugIn.Symbol, true);

            foreach (ISymbol symbol in plugIn.Symbol.ChildrenOfType(SymbolType.Channel))
            {
                //if (symbol.AuditLevel <= AuditLevel.Advanced)
                //{
                //    continue;
                //}

                m_Detector.Channels.Add(symbol);
            }

            IDeviceModel      deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.GenericDetector);
            IPage             page        = deviceModel.CreatePage(new DetectorPage(m_Detector), plugIn.Symbol.Name, plugIn.Symbol);
            IEditorDeviceView view        = deviceModel.EditorDeviceViews.Add(EditorViewOrder.CDDetectorViews);

            view.Pages.Add(page);
            deviceModel.WizardPages.Add(page, WizardPageOrder.CDDetectorPages);
        }
예제 #8
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            // Create an ID for the embedded binary data blocks
            var dataBlockId = new PlugInDataBlockId(plugIn.DriverID, plugIn.Symbol.Name, "MyBlobDataType");

            //Create new device model.
            var ddkDeviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.LcSystem);

            var myDeviceModel = new DataBlockDeviceModel(ddkDeviceModel, dataBlockId);

            // Create a new page control.
            var plugInPage = new DataBlockPage(myDeviceModel);

            // Create a new DDK page object
            IPage ddkPage = ddkDeviceModel.CreatePage(plugInPage, "Settings stored in an embedded data block", plugIn.Symbol);

            // Add page to Wizard page collection.
            ddkDeviceModel.WizardPages.Add(ddkPage, WizardPageOrder.LCSystemPages);

            // Create a new view and add the page to view's tab control.
            IEditorDeviceView editorView = ddkDeviceModel.EditorDeviceViews.Add(EditorViewOrder.LCSystemViews);

            editorView.Pages.Add(ddkPage);
        }
예제 #9
0
        /// <seealso cref="IInitEditorPlugIn.Initialize"/>
        public void Initialize(IEditorPlugIn plugIn)
        {
            IDeviceModel deviceModel = plugIn.DeviceModels.Add(plugIn.Symbol, DeviceIcon.LcSystem);

            IEditorDeviceView editorView = null;

            // We would like to have a page for each device. Therefore the symbol for each device needs
            // to be identified.

            //Find the pump device symbol
            var pumpDeviceSymbol = FindPump(plugIn.Symbol);

            if (pumpDeviceSymbol != null)
            {
                //Create pages for pump device.
                var   pumpPage  = new PumpGeneralPage();
                IPage iPumpPage = deviceModel.CreatePage(pumpPage, "LC System Pump Settings", pumpDeviceSymbol);
                //Add iPumpPage to Wizard page collection. Set order for pump.
                deviceModel.WizardPages.Add(iPumpPage, WizardPageOrder.PumpPages);
                //Create and add pump page to Editor page collection.
                editorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.LCSystemViews);
                editorView.Pages.Add(iPumpPage);

                //Add pump gradient page.

                //The IPumpDescription object holds all relevant information of the pump which are needed by the component PumpGradientPage.
                //Information like flow symbol and solvent symbols are stored in IPumpDescription.
                //Notice: for using the IPumpDescription the pump symbol and its child need a defined structure.
                //See CM7 DDK V2 help for further information.
                IPumpDescription pumpDescription = plugIn.System.PumpSubsystem.CreatePumpDescription(pumpDeviceSymbol as IDevice);
                //Inform the system that this page handles a pump.
                plugIn.System.PumpSubsystem.Pumps.Add(pumpDescription);
                //Now create the gradient page which consists of a plot component for displaying the flow and solvent gradients
                //and a grid for defining time actions.

                iPumpPage = deviceModel.CreatePage(new PumpGradientPage(pumpDescription), "LC System Pump Gradient Settings", pumpDeviceSymbol);
                //Add iPumpPage to Wizard page collection. Set order for pump.
                deviceModel.WizardPages.Add(iPumpPage, WizardPageOrder.PumpPages);
                //Add pump page to Editor page collection.
                editorView.Pages.Add(iPumpPage);
            }

            //Find the detector device symbol
            var detectorDeviceSymbol = FindDetector(plugIn.Symbol);

            if (detectorDeviceSymbol != null)
            {
                //Create page for detector device.
                var   detectorPage  = new DetectorPage(detectorDeviceSymbol, plugIn);
                IPage iDetectorPage = deviceModel.CreatePage(detectorPage, "LC System Detector Settings", detectorDeviceSymbol);
                //Add iDetectorPage to Wizard page collection. Set order for UV VIS detectors.
                deviceModel.WizardPages.Add(iDetectorPage, WizardPageOrder.UVDetectorPages);
                //Create and add detector page to Editor page collection.
                if (editorView == null)
                {
                    editorView = deviceModel.EditorDeviceViews.Add(EditorViewOrder.LCSystemViews);
                }
                editorView.Pages.Add(iDetectorPage);
            }

            //Since there are no settings for the sampler, we do not create a dedicated page.
            //Nevertheless an inject command and a Wait.Ready statement must be created.
            //This will be done by using the BasicInjectorComponent.
            var samplerDevice = FindSampler(plugIn.Symbol);

            if (samplerDevice != null)
            {
                new BasicInjectorComponent(deviceModel, samplerDevice);
            }
        }