public static void Chain(Set<Route> routes, Route route, SootMethod start, SootMethod last) 
    {
        //if no path found..ie exit statement encountered!
    	if(start==null)
    		return;
    	if(graph.getTails().contains(start)){
        	return;
        }
    	
    	//List l = graph.getTails();
    	
    	if (start.equals(last)) 
        {
            if(route != null){
            //	route.insert(last);
            	routes.add(route);
            }
           // System.out.println("Reached");
           // System.out.println("Routes "+routes);
            return ;
        }
        List<SootMethod> rights = graph.getSuccsOf(start);//left_map_rights.get(right2);
        if (rights != null) 
        {
            if(route == null)
            	route = new Route();
        	for (SootMethod right : rights) 
            {
        		//Route new_route = new Route();
                if (!route.contains(right)) 
                {
                    Route new_route = new Route(route);
                	
                //	new_route.insert(start);
                    new_route.insert(right);
                //    System.out.println(new_route);
                    Chain(routes, new_route, right, last);
                }
            }
        }
    }