Package com.sun.squawk.util

Examples of com.sun.squawk.util.StringTokenizer


     * @param filename The name of the file to read.
     * @return The array of values in the file.
     */
    public static double[] getArray(String filename) {
        String raw = getFileContents(filename);
        StringTokenizer st = new StringTokenizer(raw);
        double[] array = new double[st.countTokens()];
        int i = 0;
        while (st.hasMoreTokens()) {
            array[i++] = Double.parseDouble(st.nextToken());
        }
        return array;
    }
View Full Code Here

TOP

Related Classes of com.sun.squawk.util.StringTokenizer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.