Method CreateTruncating
- Namespace
- Zyl.VectorTraits.ExTypes
- Assembly
- VectorTraits.dll
CreateTruncating<TOther>(TOther)
Creates an instance of the current type from a value, truncating any values that fall outside the representable range of the current type.
public static ExUInt128 CreateTruncating<TOther>(TOther value) where TOther : INumberBase<TOther>
Parameters
valueTOtherThe value which is used to create the instance of
TSelf.
Returns
- ExUInt128
An instance of
TSelfcreated fromvalue, truncating ifvaluefalls outside the representable range ofTSelf.
Type Parameters
TOtherThe type of
value.
Exceptions
- NotSupportedException
TOtheris not supported.