Esempio n. 1
0
 public void Run()
 {
     if (_ioDeviceWrapper == null)
     {
         _ioDeviceWrapper = _wrapperFactory.Create();
         _ioDeviceWrapper.Create(_filePath, _options);
     }
     Write();
     Read();
 }
Esempio n. 2
0
        public void Clean()
        {
            EnterWriteLock();
            try
            {
                foreach (var h in _digValueHolders.Values)
                {
                    h.ClearValue();
                }
                foreach (var h in _numValueHolders.Values)
                {
                    h.ClearValue();
                }
            }
            finally
            {
                ExitWriteLock();
            }
            Exception thrownException = null;

            try
            {
                _ioDeviceWrapper.Dispose();
            }
            catch (Exception exception)
            {
                thrownException = exception;
            }
            _ioDeviceWrapper = null;
            try
            {
                _wrapperFactory.UnloadDomain();
            }
            catch (Exception exception)
            {
                if (thrownException == null)
                {
                    thrownException = exception;
                }
            }
            if (thrownException != null)
            {
                throw thrownException;
            }
        }
Esempio n. 3
0
 public void Clean()
 {
     EnterWriteLock();
     try
     {
         foreach (var h in _digValueHolders.Values)
         {
             h.ClearValue();
         }
         foreach (var h in _numValueHolders.Values)
         {
             h.ClearValue();
         }
     }
     finally
     {
         ExitWriteLock();
     }
     Exception thrownException = null;
     try
     {
         _ioDeviceWrapper.Dispose();
     }
     catch (Exception exception)
     {
         thrownException = exception;
     }
     _ioDeviceWrapper = null;
     try
     {
         _wrapperFactory.UnloadDomain();
     }
     catch (Exception exception)
     {
         if (thrownException == null)
             thrownException = exception;
     }
     if (thrownException != null)
         throw thrownException;
 }
Esempio n. 4
0
 public void Run()
 {
     if (_ioDeviceWrapper == null)
     {
         _ioDeviceWrapper = _wrapperFactory.Create();
         _ioDeviceWrapper.Create(_filePath, _options);
     }
     Write();
     Read();
 }
Esempio n. 5
0
 protected override void EstablishContext()
 {
     base.EstablishContext();
     IoDeviceWrapper = new IoDeviceWrapper();
 }
Esempio n. 6
0
 protected override void EstablishContext()
 {
     base.EstablishContext();
     IoDeviceWrapper = new IoDeviceWrapper();
 }