Table of Contents

Struct ValueConversion

Namespace
RDCore.Forms.Porting
Assembly
RDCore.Forms.dll

The result of Convert(object?): the RDForms value of a legacy value, or the fact that it has none.

public readonly record struct ValueConversion : IEquatable<ValueConversion>
Implements
Inherited Members

Constructors

ValueConversion(bool, object?, object?)

The result of Convert(object?): the RDForms value of a legacy value, or the fact that it has none.

public ValueConversion(bool IsConvertible, object? Legacy, object? Value)

Parameters

IsConvertible bool

Whether the legacy value is one the member's values convert from.

Legacy object

The legacy value that was converted.

Value object

The RDForms value, or null when IsConvertible is false.

Properties

Diagnostic

What the code port reports at a value that is not convertible: ValueNotConvertible, naming the legacy value. It is null when the value converts.

public PortDiagnostic? Diagnostic { get; }

Property Value

PortDiagnostic

IsConvertible

Whether the legacy value is one the member's values convert from.

public bool IsConvertible { get; init; }

Property Value

bool

Legacy

The legacy value that was converted.

public object? Legacy { get; init; }

Property Value

object

Value

The RDForms value, or null when IsConvertible is false.

public object? Value { get; init; }

Property Value

object