public MmsParameter(String name, int width, Dimension[] dimensions, Class type, Object vals) {
        this.name = name;
        this.width = width;
        this.dimensions = dimensions;
        this.type = type;
        this.vals = vals;

        size = new int[dimensions.length];
        for (int i = 0; i < dimensions.length; i++) {
            size[i] = dimensions[i].getSize();
            if (i == 0) {
                total_size = size[0];
            } else {
                total_size = total_size * size[i];
            }
        }

        if (type == Integer.class) {
            int[] temp = new int[total_size];
            for (int i = 0; i < total_size; i++) {
                temp[i] = ((int[])(vals))[i];
            }
            origVals = temp;
        } else {
            double[] temp = new double[total_size];
            for (int i = 0; i < total_size; i++) {
                temp[i] = ((double[])(vals))[i];
            }
            origVals = temp;
        }
    }