Show / Hide Table of Contents

Class ValidationSeverityToVisibilityConverter

Convert ValidationSeverity to visibility.

Inheritance
object
ValidationSeverityToVisibilityConverter
Implements
IValueConverter
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Sartorius.SAF.Presentation.Converter
Assembly: Sartorius.SAF.Presentation.dll
Syntax
public class ValidationSeverityToVisibilityConverter : IValueConverter

Methods

View Source

Convert(object, Type, object, CultureInfo)

Convert ValidationSeverity to visibility.

Declaration
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
Parameters
Type Name Description
object value

ValidationSeverity value.

Type targetType
object parameter

Defined default value : 0 or 1 or 2.

CultureInfo culture

The current culture.

Returns
Type Description
object

A visible or collapsed.

View Source

ConvertBack(object, Type, object, CultureInfo)

Convert back a value. Called when moving a value from target to source. This should implement the inverse of Convert.

Declaration
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
Parameters
Type Name Description
object value

value, as produced by target

Type targetType

target type

object parameter

converter parameter

CultureInfo culture

culture information

Returns
Type Description
object

Converted back value.

Binding.DoNothing may be returned to indicate that no value should be set on the source property.

System.Windows.DependencyProperty.UnsetValue may be returned to indicate that the converter is unable to provide a value for the source property, and no value will be set to it.

Remarks

The data binding engine does not catch exceptions thrown by a user-supplied converter. Thus any exception thrown by ConvertBack, or thrown by methods it calls and not caught by the ConvertBack, will be treated as a runtime error (i.e. a crash). ConvertBack should handle anticipated problems by returning DependencyProperty.UnsetValue.

Implements

IValueConverter

Extension Methods

CollectionExtensions.AddRange<T, TCollection>(TCollection, IEnumerable<T>)
SerializableObjectCloneExtension.Clone<T>(T)
  • View Source
Back to top Generated by DocFX