private void ClearFilter()
 {
     filterContext.RemoveFilter(ColumnName);
     filterIsApplied        = false;
     filterDefinitionOpened = false;
     StateCache.RemoveStateValue(ColumnName);
     state = null;
 }
        private void CacheActualState()
        {
            var filterState = new ColumnFilterState(actualFilterValue, selectedFilterOperation);

            if (!stateCache.ContainsKey(ColumnName))
            {
                stateCache.Add(ColumnName, filterState);
            }
            else
            {
                stateCache[ColumnName] = filterState;
            }
        }
        private void LoadStateIfExists()
        {
            if (state != null)
            {
                selectedFilterOperation = state.FilterOperation;
                actualFilterValue       = (TValue)state.FilterValue;
                filterIsApplied         = true;

                return;
            }

            if (CascadeFlexGridContext.GridConfiguration.PreserveFiltering &&
                StateCache.TryGetStateValue <ColumnFilterState>(ColumnName, out var cachedState))
            {
                state = cachedState;
                selectedFilterOperation = state.FilterOperation;
                actualFilterValue       = (TValue)state.FilterValue;
                filterIsApplied         = true;

                filterContext.AddOrUpdateFilterDefinition(new ExpressionFilterDefinition(
                                                              ColumnName, selectedFilterOperation, actualFilterValue, TextComparison), false);
            }
        }
 private void CacheActualState()
 {
     state = new ColumnFilterState(actualFilterValue, selectedFilterOperation);
     StateCache.SetStateValue(ColumnName, new ColumnFilterState(actualFilterValue, selectedFilterOperation));
 }