|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectfi.helsinki.cs.ohtu.mpeg2.util.ArrayRoller
public class ArrayRoller
Utility class for changing arrays from 2d -> 1d and 1d -> 2d.
| Constructor Summary | |
|---|---|
private |
ArrayRoller()
ArrayRoller constructor. |
| Method Summary | |
|---|---|
static int[] |
as1D(int[][] values)
Changes 2d array to one dimensional array. |
static int[][] |
as2D(int[] values,
int height,
int width)
Changes one dimensional array to two dimensional array. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
private ArrayRoller()
| Method Detail |
|---|
public static int[][] as2D(int[] values,
int height,
int width)
values - -> one dimensional array to be changedheight - -> length of column in resulting 2d arraywidth - -> length of row in resulting 2d array
public static int[] as1D(int[][] values)
values - -> 2d array to be changed
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||