public BFSearcher(Graph graph, String sourceVertex) {

		Queue queue = new Queue();
		queue.enqueue(sourceVertex);
		visited.put(sourceVertex, "");

		while (!queue.isEmpty()) {
			String v = (String) queue.dequeue();
			String[] neighbors = graph.neighbors(v);
			for (int i = 0; i < neighbors.length; i++) {
				String w = neighbors[i];
				if (visited.get(w) == null) {
					queue.enqueue(w);
					visited.put(w, v);
				}
			}
		}

	}