2 instantiations of CY
System.Private.Windows.Core (2)
Windows\Win32\System\Com\CY.cs (2)
18
public static explicit operator CY(decimal value) =>
new
() { int64 = decimal.ToOACurrency(value) };
21
public static explicit operator CY(float value) =>
new
() { int64 = (long)(value * 10000) };
13 references to CY
System.Private.Windows.Core (13)
Windows\Win32\System\Com\CY.cs (11)
6
internal partial struct CY : IEquatable<
CY
>
8
public readonly bool Equals(
CY
other) => int64 == other.int64;
9
public override readonly bool Equals(object? obj) => obj is
CY
cy && Equals(cy);
12
public static bool operator ==(
CY
left,
CY
right) => left.Equals(right);
13
public static bool operator !=(
CY
left,
CY
right) => !left.Equals(right);
17
public static explicit operator decimal(
CY
value) => decimal.FromOACurrency(value.int64);
18
public static explicit operator
CY
(decimal value) => new() { int64 = decimal.ToOACurrency(value) };
20
public static explicit operator float(
CY
value) => (float)(value.int64 / 10000f);
21
public static explicit operator
CY
(float value) => new() { int64 = (long)(value * 10000) };
Windows\Win32\System\Variant\VARIANT.cs (2)
939
public static explicit operator
CY
(VARIANT value)
940
=> value.vt == VT_CY ? value.data.cyVal : ThrowInvalidCast<
CY
>();