public void SaveState( IDataGridContextVisitable dataGridContextVisitable )
    {
      if( m_status != SaveRestoreStateVisitorStatus.Ready )
        throw new InvalidOperationException( "An attempt was made to save the state of a visitor that is not ready." );

      m_status = SaveRestoreStateVisitorStatus.Saving;
      try
      {
        this.SaveStateCore( dataGridContextVisitable );
        m_status = SaveRestoreStateVisitorStatus.RestorePending;
      }
      catch
      {
        m_status = SaveRestoreStateVisitorStatus.Error;
        throw;
      }
    }
        public void RestoreState(IDataGridContextVisitable dataGridContextVisitable)
        {
            if (m_status != SaveRestoreStateVisitorStatus.RestorePending)
            {
                throw new InvalidOperationException("An attempt was made to restore the state of a visitor that does not have a pending restorable state.");
            }

            m_status = SaveRestoreStateVisitorStatus.Restoring;
            try
            {
                this.RestoreStateCore(dataGridContextVisitable);
                m_status = SaveRestoreStateVisitorStatus.Restored;
            }
            catch
            {
                m_status = SaveRestoreStateVisitorStatus.Error;
                throw;
            }
        }
        public void SaveState(IDataGridContextVisitable dataGridContextVisitable)
        {
            if (m_status != SaveRestoreStateVisitorStatus.Ready)
            {
                throw new InvalidOperationException("An attempt was made to save the state of a visitor that is not ready.");
            }

            m_status = SaveRestoreStateVisitorStatus.Saving;
            try
            {
                this.SaveStateCore(dataGridContextVisitable);
                m_status = SaveRestoreStateVisitorStatus.RestorePending;
            }
            catch
            {
                m_status = SaveRestoreStateVisitorStatus.Error;
                throw;
            }
        }
 public void Initialize()
 {
     this.InitializeCore();
     m_status = SaveRestoreStateVisitorStatus.Ready;
 }
    public void RestoreState( IDataGridContextVisitable dataGridContextVisitable )
    {
      if( m_status != SaveRestoreStateVisitorStatus.RestorePending )
        throw new InvalidOperationException( "An attempt was made to restore the state of a visitor that does not have a pending restorable state." );

      m_status = SaveRestoreStateVisitorStatus.Restoring;
      try
      {
        this.RestoreStateCore( dataGridContextVisitable );
        m_status = SaveRestoreStateVisitorStatus.Restored;
      }
      catch
      {
        m_status = SaveRestoreStateVisitorStatus.Error;
        throw;
      }
    }
 public void Initialize()
 {
   this.InitializeCore();
   m_status = SaveRestoreStateVisitorStatus.Ready;
 }