Class ReactiveValidationObject
- Namespace
- ReactiveUI.Validation.Helpers
- Assembly
- ReactiveUI.Validation.dll
Base class for ReactiveObjects that support INotify
public abstract class ReactiveValidationObject : ReactiveObject, IReactiveNotifyPropertyChanged<IReactiveObject>, IHandleObservableErrors, IReactiveObject, INotifyPropertyChanged, INotifyPropertyChanging, IEnableLogger, IValidatableViewModel, INotifyDataErrorInfo, IDisposable
- Inheritance
-
Reactive
Validation Object
- Implements
-
IEnable
Logger
- Inherited Members
- Extension Methods
-
ValidatableViewModelExtensions.ValidationRule<TViewModel>(TViewModel, IObservable<IValidationState>)
Constructors
ReactiveValidationObject(IScheduler?, IValidationTextFormatter<string>?)
Initializes a new instance of the Reactive
[RequiresUnreferencedCode("WhenAnyValue may reference members that could be trimmed in AOT scenarios.")]
protected ReactiveValidationObject(IScheduler? scheduler = null, IValidationTextFormatter<string>? formatter = null)
Parameters
schedulerISchedulerScheduler for the Validation
Context . Uses System.Reactive. by default.Concurrency. Current Thread Scheduler formatterIValidationText <string>Formatter Validation formatter. Defaults to Single
Line . In order to override the global default value, implement IValidationTextFormatter<TOut> and register an instance of IValidationTextFormatter<string> into Splat.Locator.Formatter
Properties
HasErrors
Property Value
ValidationContext
Gets get the validation context.
Property Value
Methods
Dispose()
Releases unmanaged and - optionally - managed resources.
Dispose(bool)
Disposes the specified disposing.
Parameters
disposingboolif set to
true[disposing].
GetErrors(string?)
Returns a collection of error messages, required by the INotifyDataErrorInfo interface.
Parameters
propertyNamestringProperty to search error notifications for.
Returns
- IEnumerable
A list of error messages, usually strings.
RaiseErrorsChanged(string)
Raises the Errors
Parameters
propertyNamestringThe name of the validated property.