Converts a sequence of booleans and returns Visible or Collapsed according to the logical result.
You can make this and AND gate, or an OR gate, by setting the LogicalAnd boolean property. If you make it an AND gate, then we respect parameter ordering so that an effective null check can be introduced earlier that will result in a later, possibly invalid argument being skipped. This is similar to:
if(null != ref AND ref.SomeProperty) {
Similarly, a true result on an OR will always result in an early exit.
Public Member Functions |
|
MultiBooleanToVisibilityConverter () | |
object | Convert (object[] values, Type targetType, object parameter, System.Globalization.CultureInfo culture) |
Converts from a sequence of boolean values
to a visibility value. |
|
object[] | ConvertBack (object value, Type[] targetTypes, object parameter, System.Globalization.CultureInfo culture) |
Not used. |
|
Properties |
|
bool |
LogicalAnd [get, set] |
If true, this converter will perform a
logical and on the parameters. |
WPFCustomControls::Converters::MultiBooleanToVisibilityConverter::MultiBooleanToVisibilityConverter | ( | ) | [inline] |
object WPFCustomControls::Converters::MultiBooleanToVisibilityConverter::Convert | ( | object[] | values, |
Type | targetType, | ||
object | parameter, | ||
System.Globalization.CultureInfo | culture | ||
) | [inline] |
Converts from a sequence of boolean values to a visibility value.
See Class description remarks for comments regarding parameter precedence.
values | series of booleans to evaluate |
targetType | standard |
parameter | not used |
culture | not used |
object [] WPFCustomControls::Converters::MultiBooleanToVisibilityConverter::ConvertBack | ( | object | value, |
Type[] | targetTypes, | ||
object | parameter, | ||
System.Globalization.CultureInfo | culture | ||
) | [inline] |
Not used.
value | standard |
targetTypes | standard |
parameter | standard |
culture | standard |
bool
WPFCustomControls::Converters::MultiBooleanToVisibilityConverter::LogicalAnd
[get, set] |
If true, this converter will perform a logical and on the parameters.
Otherwise