Class Print
java.lang.Object
jcuda.utils.Print
Utility methods for creating formatted String representations
of 1D- 2D- and 3D arrays
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringtoString1D(float[] a) Creates a String representation of the given array, using the default format string for its elements.static StringtoString1D(float[] a, String format) Creates a String representation of the given array, using the given format string for its elements.static StringtoString2D(float[][] a) Creates a String representation of the given array, using the default format string for its elements.static StringtoString2D(float[][] a, String format) Creates a String representation of the given array, using the given format string for its elements.static StringtoString2D(float[] a, int columns) Creates a String representation of the given array, using the default format string for its elements.static StringtoString2D(float[] a, int columns, String format) Creates a String representation of the given array, using the given format string for its elements.static StringtoString3D(float[][][] a) Creates a String representation of the given array, using the default format string for its elements.static StringtoString3D(float[][][] a, String format) Creates a String representation of the given array, using the given format string for its elements.
-
Method Details
-
toString1D
Creates a String representation of the given array, using the default format string for its elements.- Parameters:
a- The array- Returns:
- The String representation
-
toString1D
-
toString2D
Creates a String representation of the given array, using the default format string for its elements. The String will be formatted as a rectangular matrix with the given number of columns.- Parameters:
a- The arraycolumns- The number of columns- Returns:
- The String representation
-
toString2D
Creates a String representation of the given array, using the given format string for its elements. The String will be formatted as a rectangular matrix with the given number of columns.- Parameters:
a- The arraycolumns- The number of columnsformat- The format string- Returns:
- The String representation
-
toString2D
Creates a String representation of the given array, using the default format string for its elements. The String will be formatted as a rectangular matrix.- Parameters:
a- The array- Returns:
- The String representation
-
toString2D
Creates a String representation of the given array, using the given format string for its elements. The String will be formatted as a rectangular matrix.- Parameters:
a- The arrayformat- The format string- Returns:
- The String representation
-
toString3D
Creates a String representation of the given array, using the default format string for its elements. The String will be formatted as a sequence of rectangular matrices.- Parameters:
a- The array- Returns:
- The String representation
-
toString3D
Creates a String representation of the given array, using the given format string for its elements. The String will be formatted as a sequence of rectangular matrices.- Parameters:
a- The arrayformat- The format string- Returns:
- The String representation
-