Castle.Components.DictionaryAdapter.DictionaryAdapterBase.Invalidate C# (CSharp) Method

Invalidate() protected method

protected Invalidate ( ) : void
return void
		protected internal void Invalidate()
		{
			if (CanValidate)
			{
				if (validators != null) foreach (var validator in validators)
				{
					validator.Invalidate(this);
				}

				NotifyPropertyChanged("IsValid");
			}
		}
	}

Usage Example

            private bool NotifyReadonly()
            {
                bool changed = false;

                foreach (var readonlyProperty in readonlyProperties)
                {
                    var descriptor   = readonlyProperty.Key;
                    var currentValue = GetEffectivePropertyValue(descriptor);
                    changed |= NotifyIfChanged(descriptor, readonlyProperty.Value, currentValue);
                }
                adapter.Invalidate();
                return(changed);
            }