private static LinkedList createUsers(BufferedReader buf, LinkedList routers)
        throws Exception {
        String line;
        String name;
        String baudRate;
        String router_name;
        StringTokenizer str;
        LinkedList users = new LinkedList();

        while ((line = buf.readLine()) != null) {
            str = new StringTokenizer(line);
            name = str.nextToken();

            if (!name.startsWith("#")) {
                router_name = str.nextToken();

                String resource_name = str.nextToken(); //for the RC assignement
                baudRate = str.nextToken(); //baud rate is given in MB/s

                Router r = NetworkReader.getRouter(router_name, routers);

                if (r == null) {
                    System.out.println("Problem with ROUTER " + router_name);
                }

                SimUser dUser = new SimUser(name,
                        Double.parseDouble(baudRate) * 1000000, 10, 1500);
                dUser.setReplicaCatalogue(resource_name);

                r.attachHost(dUser, new FIFOScheduler(name+"_scheduler"));

                int index = 0;
                ArrayList tasks = new ArrayList();

                while (str.hasMoreTokens()) {
                    Object[] tempTask = parseTask(str);

                    if (tempTask != null) {
                        tasks.add(tempTask);
                    }
                }

                dUser.setTasks(tasks);
                users.add(dUser);
            }
        }

        return users;
    }