TensorPrimitives.ConvertToIntegerNative<TFrom,TTo> メソッド

定義

sourcedestinationにコピーし、オーバーフロー時のプラットフォーム固有の動作を使用して、各TFrom値をTTo整数型に変換します。

public:
generic <typename TFrom, typename TTo>
 where TFrom : System::Numerics::IFloatingPoint<TFrom> where TTo : System::Numerics::IBinaryInteger<TTo> static void ConvertToIntegerNative(ReadOnlySpan<TFrom> source, Span<TTo> destination);
public static void ConvertToIntegerNative<TFrom,TTo>(ReadOnlySpan<TFrom> source, Span<TTo> destination) where TFrom : System.Numerics.IFloatingPoint<TFrom> where TTo : System.Numerics.IBinaryInteger<TTo>;
static member ConvertToIntegerNative : ReadOnlySpan<'From (requires 'From :> System.Numerics.IFloatingPoint<'From>)> * Span<'o (requires 'o :> System.Numerics.IBinaryInteger<'o>)> -> unit (requires 'From :> System.Numerics.IFloatingPoint<'From> and 'o :> System.Numerics.IBinaryInteger<'o>)
Public Shared Sub ConvertToIntegerNative(Of TFrom As IFloatingPoint(Of TFrom), TTo As IFloatingPoint(Of TFrom)) (source As ReadOnlySpan(Of TFrom), destination As Span(Of TTo))

型パラメーター

TFrom
TTo

パラメーター

source
ReadOnlySpan<TFrom>

値のコピー元のソース スパン。

destination
Span<TTo>

変換された値を書き込む宛先スパン。

例外

宛先が短すぎます。

注釈

このメソッドは、 destination[i] = TTo.ConvertToInteger(source[i])を効果的に計算します。

適用対象