示例#1
0
        private void OnHostInitialized(IApplication app, IServiceContainer svcProvider, IModule[] modules)
        {
            m_MacroRunnerSvc = svcProvider.GetService <IMacroExecutor>();
            m_Msg            = svcProvider.GetService <IMessageService>();
            m_Logger         = svcProvider.GetService <IXLogger>();

            m_CadDesc = svcProvider.GetService <ICadDescriptor>();

            m_Data = new AssemblyBatchData(m_CadDesc);
        }
示例#2
0
 public MacroRunner(IXApplication app, IMacroExecutor runner, IMessageService msgSvc, IXLogger logger,
                    IToolbarModuleProxy toolbarModuleProxy, IFilePathResolver filePathResolver)
 {
     m_App                = app;
     m_Runner             = runner;
     m_ToolbarModuleProxy = toolbarModuleProxy;
     m_MsgSvc             = msgSvc;
     m_Logger             = logger;
     m_FilePathResolver   = filePathResolver;
 }
示例#3
0
        public SwApplicationProvider(IXLogger logger, IMacroExecutor svc, ICadDescriptor entDesc)
        {
            m_Logger = logger;

            MacroRunnerService = svc;
            Descriptor         = entDesc;
            m_CustomServices   = new ServiceCollection();
            m_CustomServices.AddOrReplace <IXLogger>(() => m_Logger);

            m_ForceDisabledAddIns = new Dictionary <Process, List <string> >();
        }
示例#4
0
        internal AssemblyBatchRunJobExecutor(IXApplication app, IMacroExecutor macroRunnerSvc,
                                             IXDocument[] documents, IXLogger logger, IEnumerable <MacroData> macros,
                                             bool activateDocs, bool allowReadOnly, bool allowRapid, bool autoSaveDocs)
        {
            m_App    = app;
            m_Logger = logger;

            m_MacroRunner = macroRunnerSvc;
            m_Docs        = documents;
            m_Macros      = macros;

            m_ActivateDocs  = activateDocs;
            m_AllowReadOnly = allowReadOnly;
            m_AllowRapid    = allowRapid;
            m_AutoSaveDocs  = autoSaveDocs;
        }
示例#5
0
        public BatchRunner(BatchJob job, ICadApplicationInstanceProvider[] appProviders,
                           TextWriter journalWriter, IProgressHandler progressHandler,
                           IBatchApplicationProxy batchAppProxy,
                           IJobManager jobMgr, IXLogger logger,
                           Func <TimeSpan?, IResilientWorker <BatchJobContext> > workerFact, IPopupKiller popupKiller)
        {
            m_Job             = job;
            m_JournalWriter   = journalWriter;
            m_ProgressHandler = progressHandler;
            m_AppProvider     = job.FindApplicationProvider(appProviders);
            m_MacroRunnerSvc  = m_AppProvider.MacroRunnerService;

            m_WorkerFact    = workerFact;
            m_BatchAppProxy = batchAppProxy;

            m_PopupKiller = popupKiller;
            m_PopupKiller.PopupNotClosed += OnPopupNotClosed;

            m_Logger = logger;

            m_JobMgr = jobMgr;
        }