public static List<String> depthFirstSearch(Graph graph, String startName, String goalName)
	{		
		if(!graph.getVertices().containsKey(startName) || !graph.getVertices().containsKey(goalName))
			throw new UnsupportedOperationException();
		
		//CLEAR GRAPH
		for(Vertex v : graph.getVertices().values()){
			v.setCameFrom(null); 
			v.setVisited(false);
		}

		LinkedList<Vertex> stack = new LinkedList<Vertex>();
		LinkedList<String> result = new LinkedList<String>();
		stack.addLast(graph.getVertices().get(startName));

		Vertex end = null;
		
		while(stack.size() != 0){
		
			Vertex n = stack.removeLast();
			if(n.getName().equals(goalName))
				end = n;
			if(!n.getVisited()){
			n.setVisited(true);
			
				for(Edge e : n.getEdges()){
					Vertex neighbor = e.getOtherVertex();
					if(!neighbor.getVisited()){
						neighbor.setCameFrom(n);
						stack.addLast(neighbor);
					}
				}
			}
		}
		
		while(end != null)
		{
			result.addFirst(end.getName());
			end = end.getCameFrom();			
		}
		return result;
	}