*/
    private static ArrayList<Vertex> readGraphFromFile()
    {
        ArrayList<Vertex> vertexArray = new ArrayList<Vertex>();

        FileInputStream fstream = null;
        try
        {
            fstream = new FileInputStream("dijkstraData.txt");

            // Get the object of DataInputStream
            DataInputStream in = new DataInputStream(fstream);
            BufferedReader br = new BufferedReader(new InputStreamReader(in));

            String line;
            while ((line = br.readLine()) != null)
            {
                // process the line
                StringTokenizer tokens = new StringTokenizer(line);

                Vertex vertex = new Vertex(Integer.valueOf(tokens.nextToken()), 100000);

                while(tokens.hasMoreTokens())
                {
                    String edgeStr = tokens.nextToken();

                    StringTokenizer edgeTokenizer = new StringTokenizer(edgeStr, ",");

                    // first item is the token
                    int node = new Integer(edgeTokenizer.nextToken()).intValue();
                    int distance = new Integer(edgeTokenizer.nextToken()).intValue();

                    Edge edge = new Edge(node, distance);
                    vertex.getEdgesArray().add(edge);
                }

                vertexArray.add(vertex);
            }

            br.close();
        }catch (FileNotFoundException ex) {
            Logger.getLogger(Djkastra.class.getName()).log(Level.SEVERE, null, ex);
        }catch (IOException ex) {
            Logger.getLogger(Djkastra.class.getName()).log(Level.SEVERE, null, ex);
        }finally {
            try {
                fstream.close();
            } catch (IOException ex) {
                Logger.getLogger(Djkastra.class.getName()).log(Level.SEVERE, null, ex);
            }
        }

        return vertexArray;
    }