Esempio n. 1
0
        /// <summary>
        /// intialization for the user to be able to start using the instrument.
        /// It's common part. And also it's could be override by derived class.
        /// </summary>
        /// <param name="options">This object array can be used to define instrument dependant
        /// options.  The user should refer to the documentation for the specific
        /// implementation for a description of what this parameter is expected to contain.</param>
        /// <remarks> It's better to be called before overrided method.</remarks>
        public virtual void Initialize(Dictionary <string, object> Options)
        {
            if (IsInitialized == true)
            {
                return;
            }
            ComponentOptions = Options;


            //string position = SessionName.Substring(SessionName.LastIndexOf('_') + 1);
            dlgtLogSend += new delegateLogSend(ILogSession.OnLogReceived);
        }
Esempio n. 2
0
        public TestClassBase(Hashtable TestParams)
        {
            Init();

            //import core data
            CoreData = TestParams;

            try
            {
                pISessionManagement = GetCoreInterface(CommonTags.CoreData_SessionManage) as ISessionManagement;
                pILog       = pISessionManagement.GetSessionByName("ILog", Position) as ILog;
                pIDataTable = GetCoreInterface(CommonTags.CoreData_DataTable) as IDataTable;

                dlgtLogSend += new delegateLogSend(pILog.OnLogReceived);
            }
            catch (Exception ex)
            {
            }
        }