BionicCode.Net
BionicCode.Net
BionicCode.Utilities.Net Namespaces
BionicCode.Utilities.Net.Standard Namespaces
BionicCode.Utilities.Net.Standard.ViewModel
ViewModel Class
ViewModel Methods
GetErrors Method
GetPropertyErrors Method
IsValueValid(TValue) Method
OnErrorsChanged Method
OnPropertyChanged Method
PropertyHasError Method
TrySetValue Method
TrySetValueSilent Method

| # ViewModel IsValueValid TValue Method

[Missing <summary> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

Namespace: BionicCode.Utilities.Net.Standard.ViewModel
Assembly: BionicCode.Utilities.Net.Standard (in BionicCode.Utilities.Net.Standard.dll) Version: 1.0.0
Syntax
C#
VB
C++
F#
J#
JScript
JavaScript
ASP.NET
X#
Copy

    protected virtual bool IsValueValid<TValue>(
    	TValue value,
    	Func<TValue, (bool IsValid, IEnumerable<string> ErrorMessages)> validationDelegate,
    	string propertyName = null
    )

    Protected Overridable Function IsValueValid(Of TValue) (
    	value As TValue,
    	validationDelegate As Func(Of TValue, (IsValid As Boolean, ErrorMessages As IEnumerable(Of String))),
    	Optional propertyName As String = Nothing
    ) As Boolean

    Dim value As TValue
    Dim validationDelegate As Func(Of TValue, (IsValid As Boolean, ErrorMessages As IEnumerable(Of String)))
    Dim propertyName As String
    Dim returnValue As Boolean

    returnValue = Me.IsValueValid(value,
    	validationDelegate, propertyName)

    protected:
    generic<typename TValue>
    virtual bool IsValueValid(
    	TValue value,
    	Func<TValue, ValueTuple<bool, IEnumerable<String^>^>>^ validationDelegate,
    	String^ propertyName = nullptr
    )

    abstract IsValueValid :
            value : 'TValue *
            validationDelegate : Func<'TValue, ValueTuple<bool, IEnumerable<string>>> *
            ?propertyName : string
    (* Defaults:
            let _propertyName = defaultArg propertyName null
    *)
    -> bool
    override IsValueValid :
            value : 'TValue *
            validationDelegate : Func<'TValue, ValueTuple<bool, IEnumerable<string>>> *
            ?propertyName : string
    (* Defaults:
            let _propertyName = defaultArg propertyName null
    *)
    -> bool

    J# supports the use of generic APIs, but not the declaration of new ones.

    JScript does not support generic types or methods.

    JavaScript does not support generic types or methods.

    PROTECTED VIRTUAL METHOD IsValueValid<TValue>(
    	value AS TValue,
    	validationDelegate AS Func<TValue, ValueTuple<LOGIC, IEnumerable<STRING>>>,
    	propertyName AS STRING := NULL
    )
     AS LOGIC

#### Parameters

value
  Type: TValue

  [Missing <param name="value"/> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

validationDelegate
  Type: System
  Func
  TValue, ValueTuple
  Boolean, IEnumerable
  String

  [Missing <param name="validationDelegate"/> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

propertyName (Optional)
  Type: System
  String

  [Missing <param name="propertyName"/> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

#### Type Parameters

TValue

  [Missing <typeparam name="TValue"/> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

#### Return Value

Type: Boolean

[Missing <returns> documentation for "M:BionicCode.Utilities.Net.Standard.ViewModel.ViewModel.IsValueValid``1(``0,System.Func{``0,System.ValueTuple{System.Boolean,System.Collections.Generic.IEnumerable{System.String}}},System.String)"]

See Also

#### Reference

ViewModel Class
BionicCode.Utilities.Net.Standard.ViewModel Namespace
Send comments on this topic to BionicCode@outlook.com
https://github.com/BionicCode/BionicCode.Net/blob/master/README.md