Permalink
15981 lines (14548 sloc) 552 KB
// Accord Math Library
// The Accord.NET Framework
// http://accord-framework.net
//
// Copyright © César Souza, 2009-2017
// cesarsouza at gmail.com
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
//
// ======================================================================
// This code has been generated by a tool; do not edit manually. Instead,
// edit the T4 template Matrix.Elementwise.tt so this file can be regenerated.
// ======================================================================
namespace Accord.Math
{
using System;
using System.CodeDom.Compiler;
using Accord.Math;
using System.Runtime.CompilerServices;
// [GeneratedCode("Accord.NET T4 Templates", "3.1")]
public static partial class Matrix
{
/// <summary>
/// Converts a integer to a short integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[] ToInt16(this int[] value)
{
return ToInt16(value, new short[value.Length]);
}
/// <summary>
/// Converts a integer to a short integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[,] ToInt16(this int[,] value)
{
return ToInt16(value, Matrix.CreateAs<int, short>(value));
}
/// <summary>
/// Converts a integer to a short integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[][] ToInt16(this int[][] value)
{
return ToInt16(value, Jagged.CreateAs<int, short>(value));
}
/// <summary>
/// Converts a integer to a short integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[][][] ToInt16(this int[][][] value)
{
return ToInt16(value, Jagged.CreateAs<int, short>(value));
}
/// <summary>
/// Converts a integer array to a short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[] ToInt16(this int[] value, short[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Int16)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[,] ToInt16(this int[,] value, short[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (short* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Int16)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[][] ToInt16(this int[,] value, short[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Int16)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[][] ToInt16(this int[][] value, short[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Int16)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[][][] ToInt16(this int[][][] value, short[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Int16)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional short integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static short[,] ToInt16(this int[][] value, short[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Int16)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[] ToSingle(this int[] value)
{
return ToSingle(value, new float[value.Length]);
}
/// <summary>
/// Converts a integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this int[,] value)
{
return ToSingle(value, Matrix.CreateAs<int, float>(value));
}
/// <summary>
/// Converts a integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this int[][] value)
{
return ToSingle(value, Jagged.CreateAs<int, float>(value));
}
/// <summary>
/// Converts a integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][][] ToSingle(this int[][][] value)
{
return ToSingle(value, Jagged.CreateAs<int, float>(value));
}
/// <summary>
/// Converts a integer array to a single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[] ToSingle(this int[] value, float[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Single)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this int[,] value, float[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (float* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Single)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this int[,] value, float[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Single)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this int[][] value, float[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Single)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][][] ToSingle(this int[][][] value, float[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Single)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this int[][] value, float[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Single)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[] ToDouble(this int[] value)
{
return ToDouble(value, new double[value.Length]);
}
/// <summary>
/// Converts a integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this int[,] value)
{
return ToDouble(value, Matrix.CreateAs<int, double>(value));
}
/// <summary>
/// Converts a integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this int[][] value)
{
return ToDouble(value, Jagged.CreateAs<int, double>(value));
}
/// <summary>
/// Converts a integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][][] ToDouble(this int[][][] value)
{
return ToDouble(value, Jagged.CreateAs<int, double>(value));
}
/// <summary>
/// Converts a integer array to a double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[] ToDouble(this int[] value, double[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Double)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this int[,] value, double[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (double* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Double)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this int[,] value, double[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Double)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this int[][] value, double[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Double)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][][] ToDouble(this int[][][] value, double[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Double)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this int[][] value, double[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Double)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[] ToInt64(this int[] value)
{
return ToInt64(value, new long[value.Length]);
}
/// <summary>
/// Converts a integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this int[,] value)
{
return ToInt64(value, Matrix.CreateAs<int, long>(value));
}
/// <summary>
/// Converts a integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this int[][] value)
{
return ToInt64(value, Jagged.CreateAs<int, long>(value));
}
/// <summary>
/// Converts a integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][][] ToInt64(this int[][][] value)
{
return ToInt64(value, Jagged.CreateAs<int, long>(value));
}
/// <summary>
/// Converts a integer array to a long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[] ToInt64(this int[] value, long[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Int64)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this int[,] value, long[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (long* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Int64)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this int[,] value, long[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Int64)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this int[][] value, long[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Int64)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][][] ToInt64(this int[][][] value, long[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Int64)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this int[][] value, long[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Int64)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[] ToByte(this int[] value)
{
return ToByte(value, new byte[value.Length]);
}
/// <summary>
/// Converts a integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this int[,] value)
{
return ToByte(value, Matrix.CreateAs<int, byte>(value));
}
/// <summary>
/// Converts a integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this int[][] value)
{
return ToByte(value, Jagged.CreateAs<int, byte>(value));
}
/// <summary>
/// Converts a integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][][] ToByte(this int[][][] value)
{
return ToByte(value, Jagged.CreateAs<int, byte>(value));
}
/// <summary>
/// Converts a integer array to a 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[] ToByte(this int[] value, byte[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Byte)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this int[,] value, byte[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (byte* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Byte)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this int[,] value, byte[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Byte)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this int[][] value, byte[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Byte)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][][] ToByte(this int[][][] value, byte[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Byte)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this int[][] value, byte[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Byte)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[] ToSByte(this int[] value)
{
return ToSByte(value, new sbyte[value.Length]);
}
/// <summary>
/// Converts a integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this int[,] value)
{
return ToSByte(value, Matrix.CreateAs<int, sbyte>(value));
}
/// <summary>
/// Converts a integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this int[][] value)
{
return ToSByte(value, Jagged.CreateAs<int, sbyte>(value));
}
/// <summary>
/// Converts a integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][][] ToSByte(this int[][][] value)
{
return ToSByte(value, Jagged.CreateAs<int, sbyte>(value));
}
/// <summary>
/// Converts a integer array to a signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[] ToSByte(this int[] value, sbyte[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (SByte)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this int[,] value, sbyte[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (sbyte* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (SByte)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this int[,] value, sbyte[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (SByte)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this int[][] value, sbyte[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (SByte)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][][] ToSByte(this int[][][] value, sbyte[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (SByte)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this int[][] value, sbyte[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (SByte)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[] ToDecimal(this int[] value)
{
return ToDecimal(value, new decimal[value.Length]);
}
/// <summary>
/// Converts a integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this int[,] value)
{
return ToDecimal(value, Matrix.CreateAs<int, decimal>(value));
}
/// <summary>
/// Converts a integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this int[][] value)
{
return ToDecimal(value, Jagged.CreateAs<int, decimal>(value));
}
/// <summary>
/// Converts a integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][][] ToDecimal(this int[][][] value)
{
return ToDecimal(value, Jagged.CreateAs<int, decimal>(value));
}
/// <summary>
/// Converts a integer array to a decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[] ToDecimal(this int[] value, decimal[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Decimal)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this int[,] value, decimal[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (decimal* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Decimal)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this int[,] value, decimal[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Decimal)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this int[][] value, decimal[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Decimal)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][][] ToDecimal(this int[][][] value, decimal[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Decimal)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this int[][] value, decimal[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Decimal)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[] ToBoolean(this int[] value)
{
return ToBoolean(value, new bool[value.Length]);
}
/// <summary>
/// Converts a integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this int[,] value)
{
return ToBoolean(value, Matrix.CreateAs<int, bool>(value));
}
/// <summary>
/// Converts a integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this int[][] value)
{
return ToBoolean(value, Jagged.CreateAs<int, bool>(value));
}
/// <summary>
/// Converts a integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][][] ToBoolean(this int[][][] value)
{
return ToBoolean(value, Jagged.CreateAs<int, bool>(value));
}
/// <summary>
/// Converts a integer array to a boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[] ToBoolean(this int[] value, bool[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = value[i] != 0;
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this int[,] value, bool[,] result)
{
unsafe
{
fixed (int* src = value)
fixed (bool* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = src[i] != 0;
}
}
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this int[,] value, bool[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = value[i, j] != 0;
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this int[][] value, bool[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = value[i][j] != 0;
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][][] ToBoolean(this int[][][] value, bool[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = value[i][j][k] != 0;
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this int[][] value, bool[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = value[i][j] != 0;
return result;
}
/// <summary>
/// Converts a integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[] ToObject(this int[] value)
{
return ToObject(value, new object[value.Length]);
}
/// <summary>
/// Converts a integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this int[,] value)
{
return ToObject(value, Matrix.CreateAs<int, object>(value));
}
/// <summary>
/// Converts a integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this int[][] value)
{
return ToObject(value, Jagged.CreateAs<int, object>(value));
}
/// <summary>
/// Converts a integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][][] ToObject(this int[][][] value)
{
return ToObject(value, Jagged.CreateAs<int, object>(value));
}
/// <summary>
/// Converts a integer array to a object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[] ToObject(this int[] value, object[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Object)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this int[,] value, object[,] result)
{
for (int i = 0; i < value.Rows(); i++)
for (int j = 0; j < value.Columns(); j++)
result[i, j] = (Object)value[i, j];
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this int[,] value, object[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Object)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this int[][] value, object[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Object)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][][] ToObject(this int[][][] value, object[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Object)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this int[][] value, object[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Object)value[i][j];
return result;
}
/// <summary>
/// Converts a integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[] ToString(this int[] value)
{
return ToString(value, new string[value.Length]);
}
/// <summary>
/// Converts a integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this int[,] value)
{
return ToString(value, Matrix.CreateAs<int, string>(value));
}
/// <summary>
/// Converts a integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this int[][] value)
{
return ToString(value, Jagged.CreateAs<int, string>(value));
}
/// <summary>
/// Converts a integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][][] ToString(this int[][][] value)
{
return ToString(value, Jagged.CreateAs<int, string>(value));
}
/// <summary>
/// Converts a integer array to a string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[] ToString(this int[] value, string[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = value[i].ToString();;
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a multidimensional string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this int[,] value, string[,] result)
{
for (int i = 0; i < value.Rows(); i++)
for (int j = 0; j < value.Columns(); j++)
result[i, j] = value[i, j].ToString();;
return result;
}
/// <summary>
/// Converts a multidimensional integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this int[,] value, string[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = value[i, j].ToString();;
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this int[][] value, string[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = value[i][j].ToString();;
return result;
}
/// <summary>
/// Converts a jagged integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][][] ToString(this int[][][] value, string[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = value[i][j][k].ToString();;
return result;
}
/// <summary>
/// Converts a jagged integer array to a multidimensional string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this int[][] value, string[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = value[i][j].ToString();;
return result;
}
/// <summary>
/// Converts a short integer to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[] ToInt32(this short[] value)
{
return ToInt32(value, new int[value.Length]);
}
/// <summary>
/// Converts a short integer to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this short[,] value)
{
return ToInt32(value, Matrix.CreateAs<short, int>(value));
}
/// <summary>
/// Converts a short integer to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this short[][] value)
{
return ToInt32(value, Jagged.CreateAs<short, int>(value));
}
/// <summary>
/// Converts a short integer to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][][] ToInt32(this short[][][] value)
{
return ToInt32(value, Jagged.CreateAs<short, int>(value));
}
/// <summary>
/// Converts a short integer array to a integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[] ToInt32(this short[] value, int[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Int32)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this short[,] value, int[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (int* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Int32)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this short[,] value, int[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Int32)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this short[][] value, int[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Int32)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][][] ToInt32(this short[][][] value, int[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Int32)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this short[][] value, int[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Int32)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[] ToSingle(this short[] value)
{
return ToSingle(value, new float[value.Length]);
}
/// <summary>
/// Converts a short integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this short[,] value)
{
return ToSingle(value, Matrix.CreateAs<short, float>(value));
}
/// <summary>
/// Converts a short integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this short[][] value)
{
return ToSingle(value, Jagged.CreateAs<short, float>(value));
}
/// <summary>
/// Converts a short integer to a single-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][][] ToSingle(this short[][][] value)
{
return ToSingle(value, Jagged.CreateAs<short, float>(value));
}
/// <summary>
/// Converts a short integer array to a single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[] ToSingle(this short[] value, float[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Single)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this short[,] value, float[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (float* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Single)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this short[,] value, float[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Single)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][] ToSingle(this short[][] value, float[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Single)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[][][] ToSingle(this short[][][] value, float[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Single)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional single-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static float[,] ToSingle(this short[][] value, float[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Single)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[] ToDouble(this short[] value)
{
return ToDouble(value, new double[value.Length]);
}
/// <summary>
/// Converts a short integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this short[,] value)
{
return ToDouble(value, Matrix.CreateAs<short, double>(value));
}
/// <summary>
/// Converts a short integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this short[][] value)
{
return ToDouble(value, Jagged.CreateAs<short, double>(value));
}
/// <summary>
/// Converts a short integer to a double-precision floating point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][][] ToDouble(this short[][][] value)
{
return ToDouble(value, Jagged.CreateAs<short, double>(value));
}
/// <summary>
/// Converts a short integer array to a double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[] ToDouble(this short[] value, double[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Double)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this short[,] value, double[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (double* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Double)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this short[,] value, double[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Double)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][] ToDouble(this short[][] value, double[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Double)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[][][] ToDouble(this short[][][] value, double[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Double)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional double-precision floating point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static double[,] ToDouble(this short[][] value, double[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Double)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[] ToInt64(this short[] value)
{
return ToInt64(value, new long[value.Length]);
}
/// <summary>
/// Converts a short integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this short[,] value)
{
return ToInt64(value, Matrix.CreateAs<short, long>(value));
}
/// <summary>
/// Converts a short integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this short[][] value)
{
return ToInt64(value, Jagged.CreateAs<short, long>(value));
}
/// <summary>
/// Converts a short integer to a long integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][][] ToInt64(this short[][][] value)
{
return ToInt64(value, Jagged.CreateAs<short, long>(value));
}
/// <summary>
/// Converts a short integer array to a long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[] ToInt64(this short[] value, long[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Int64)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this short[,] value, long[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (long* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Int64)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this short[,] value, long[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Int64)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][] ToInt64(this short[][] value, long[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Int64)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[][][] ToInt64(this short[][][] value, long[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Int64)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional long integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static long[,] ToInt64(this short[][] value, long[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Int64)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[] ToByte(this short[] value)
{
return ToByte(value, new byte[value.Length]);
}
/// <summary>
/// Converts a short integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this short[,] value)
{
return ToByte(value, Matrix.CreateAs<short, byte>(value));
}
/// <summary>
/// Converts a short integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this short[][] value)
{
return ToByte(value, Jagged.CreateAs<short, byte>(value));
}
/// <summary>
/// Converts a short integer to a 8-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][][] ToByte(this short[][][] value)
{
return ToByte(value, Jagged.CreateAs<short, byte>(value));
}
/// <summary>
/// Converts a short integer array to a 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[] ToByte(this short[] value, byte[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Byte)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this short[,] value, byte[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (byte* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Byte)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this short[,] value, byte[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Byte)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][] ToByte(this short[][] value, byte[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Byte)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[][][] ToByte(this short[][][] value, byte[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Byte)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional 8-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static byte[,] ToByte(this short[][] value, byte[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Byte)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[] ToSByte(this short[] value)
{
return ToSByte(value, new sbyte[value.Length]);
}
/// <summary>
/// Converts a short integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this short[,] value)
{
return ToSByte(value, Matrix.CreateAs<short, sbyte>(value));
}
/// <summary>
/// Converts a short integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this short[][] value)
{
return ToSByte(value, Jagged.CreateAs<short, sbyte>(value));
}
/// <summary>
/// Converts a short integer to a signed 7-bit byte.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][][] ToSByte(this short[][][] value)
{
return ToSByte(value, Jagged.CreateAs<short, sbyte>(value));
}
/// <summary>
/// Converts a short integer array to a signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[] ToSByte(this short[] value, sbyte[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (SByte)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this short[,] value, sbyte[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (sbyte* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (SByte)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this short[,] value, sbyte[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (SByte)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][] ToSByte(this short[][] value, sbyte[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (SByte)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[][][] ToSByte(this short[][][] value, sbyte[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (SByte)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional signed 7-bit byte array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static sbyte[,] ToSByte(this short[][] value, sbyte[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (SByte)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[] ToDecimal(this short[] value)
{
return ToDecimal(value, new decimal[value.Length]);
}
/// <summary>
/// Converts a short integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this short[,] value)
{
return ToDecimal(value, Matrix.CreateAs<short, decimal>(value));
}
/// <summary>
/// Converts a short integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this short[][] value)
{
return ToDecimal(value, Jagged.CreateAs<short, decimal>(value));
}
/// <summary>
/// Converts a short integer to a decimal fixed-point.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][][] ToDecimal(this short[][][] value)
{
return ToDecimal(value, Jagged.CreateAs<short, decimal>(value));
}
/// <summary>
/// Converts a short integer array to a decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[] ToDecimal(this short[] value, decimal[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Decimal)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this short[,] value, decimal[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (decimal* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Decimal)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this short[,] value, decimal[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Decimal)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][] ToDecimal(this short[][] value, decimal[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Decimal)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[][][] ToDecimal(this short[][][] value, decimal[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Decimal)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional decimal fixed-point array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static decimal[,] ToDecimal(this short[][] value, decimal[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Decimal)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[] ToBoolean(this short[] value)
{
return ToBoolean(value, new bool[value.Length]);
}
/// <summary>
/// Converts a short integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this short[,] value)
{
return ToBoolean(value, Matrix.CreateAs<short, bool>(value));
}
/// <summary>
/// Converts a short integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this short[][] value)
{
return ToBoolean(value, Jagged.CreateAs<short, bool>(value));
}
/// <summary>
/// Converts a short integer to a boolean.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][][] ToBoolean(this short[][][] value)
{
return ToBoolean(value, Jagged.CreateAs<short, bool>(value));
}
/// <summary>
/// Converts a short integer array to a boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[] ToBoolean(this short[] value, bool[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = value[i] != 0;
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this short[,] value, bool[,] result)
{
unsafe
{
fixed (short* src = value)
fixed (bool* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = src[i] != 0;
}
}
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this short[,] value, bool[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = value[i, j] != 0;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][] ToBoolean(this short[][] value, bool[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = value[i][j] != 0;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[][][] ToBoolean(this short[][][] value, bool[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = value[i][j][k] != 0;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional boolean array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static bool[,] ToBoolean(this short[][] value, bool[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = value[i][j] != 0;
return result;
}
/// <summary>
/// Converts a short integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[] ToObject(this short[] value)
{
return ToObject(value, new object[value.Length]);
}
/// <summary>
/// Converts a short integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this short[,] value)
{
return ToObject(value, Matrix.CreateAs<short, object>(value));
}
/// <summary>
/// Converts a short integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this short[][] value)
{
return ToObject(value, Jagged.CreateAs<short, object>(value));
}
/// <summary>
/// Converts a short integer to a object.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][][] ToObject(this short[][][] value)
{
return ToObject(value, Jagged.CreateAs<short, object>(value));
}
/// <summary>
/// Converts a short integer array to a object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[] ToObject(this short[] value, object[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Object)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this short[,] value, object[,] result)
{
for (int i = 0; i < value.Rows(); i++)
for (int j = 0; j < value.Columns(); j++)
result[i, j] = (Object)value[i, j];
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this short[,] value, object[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Object)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][] ToObject(this short[][] value, object[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Object)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[][][] ToObject(this short[][][] value, object[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Object)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional object array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static object[,] ToObject(this short[][] value, object[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Object)value[i][j];
return result;
}
/// <summary>
/// Converts a short integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[] ToString(this short[] value)
{
return ToString(value, new string[value.Length]);
}
/// <summary>
/// Converts a short integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this short[,] value)
{
return ToString(value, Matrix.CreateAs<short, string>(value));
}
/// <summary>
/// Converts a short integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this short[][] value)
{
return ToString(value, Jagged.CreateAs<short, string>(value));
}
/// <summary>
/// Converts a short integer to a string.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][][] ToString(this short[][][] value)
{
return ToString(value, Jagged.CreateAs<short, string>(value));
}
/// <summary>
/// Converts a short integer array to a string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[] ToString(this short[] value, string[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = value[i].ToString();;
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a multidimensional string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this short[,] value, string[,] result)
{
for (int i = 0; i < value.Rows(); i++)
for (int j = 0; j < value.Columns(); j++)
result[i, j] = value[i, j].ToString();;
return result;
}
/// <summary>
/// Converts a multidimensional short integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this short[,] value, string[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = value[i, j].ToString();;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][] ToString(this short[][] value, string[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = value[i][j].ToString();;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a jagged string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[][][] ToString(this short[][][] value, string[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = value[i][j][k].ToString();;
return result;
}
/// <summary>
/// Converts a jagged short integer array to a multidimensional string array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static string[,] ToString(this short[][] value, string[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = value[i][j].ToString();;
return result;
}
/// <summary>
/// Converts a single-precision floating point to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[] ToInt32(this float[] value)
{
return ToInt32(value, new int[value.Length]);
}
/// <summary>
/// Converts a single-precision floating point to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this float[,] value)
{
return ToInt32(value, Matrix.CreateAs<float, int>(value));
}
/// <summary>
/// Converts a single-precision floating point to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this float[][] value)
{
return ToInt32(value, Jagged.CreateAs<float, int>(value));
}
/// <summary>
/// Converts a single-precision floating point to a integer.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][][] ToInt32(this float[][][] value)
{
return ToInt32(value, Jagged.CreateAs<float, int>(value));
}
/// <summary>
/// Converts a single-precision floating point array to a integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[] ToInt32(this float[] value, int[] result)
{
for (int i = 0; i < value.Length; i++)
result[i] = (Int32)value[i];
return result;
}
/// <summary>
/// Converts a multidimensional single-precision floating point array to a multidimensional integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this float[,] value, int[,] result)
{
unsafe
{
fixed (float* src = value)
fixed (int* dst = result)
{
for (int i = 0; i < value.Length; i++)
dst[i] = (Int32)src[i];
}
}
return result;
}
/// <summary>
/// Converts a multidimensional single-precision floating point array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this float[,] value, int[][] result)
{
for (int i = 0; i < result.Length; i++)
for (int j = 0; j < result[i].Length; j++)
result[i][j] = (Int32)value[i, j];
return result;
}
/// <summary>
/// Converts a jagged single-precision floating point array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][] ToInt32(this float[][] value, int[][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i][j] = (Int32)value[i][j];
return result;
}
/// <summary>
/// Converts a jagged single-precision floating point array to a jagged integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[][][] ToInt32(this float[][][] value, int[][][] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
for (int k = 0; k < value[i][j].Length; k++)
result[i][j][k] = (Int32)value[i][j][k];
return result;
}
/// <summary>
/// Converts a jagged single-precision floating point array to a multidimensional integer array.
/// </summary>
///
#if NET45 || NET46 || NET462 || NETSTANDARD2_0
[MethodImpl(MethodImplOptions.AggressiveInlining)]
#endif
public static int[,] ToInt32(this float[][] value, int[,] result)
{
for (int i = 0; i < value.Length; i++)
for (int j = 0; j < value[i].Length; j++)
result[i, j] = (Int32)value[i][j];
return result;