public Bittorrent(Object bo) {
            Logger.getInstance().debug("Creating Bittorrent with Obj: " + bo.toString());
            try {
                HashMap<String, Object> raw = (HashMap<String, Object>) bo;

                if (raw.containsKey("announceList")) {
                    Object[] announceArray = (Object[]) raw.get("announceList");
                    for (Object o : announceArray) {
                        Object[] n = (Object[]) o;
                        announceList.add((String) n[0]);
                    }
                }

                if (raw.containsKey("comment"))
                    comment = raw.get("comment").toString();

                if (raw.containsKey("creationDate"))
                    creationDate = new Date((Long) raw.get("creationDate"));

                if (raw.containsKey("mode"))
                    mode = getMode(raw.get("mode").toString());

                if (raw.containsKey("info")) {
                    try {
                        // TODO: if there would not be error, remake all
                        // raw-to-struct conversions
                        info = (HashMap<String, String>) raw.get("info");
                    } catch (Exception e) {
                        Logger.getInstance().error("Error parsing info while creating Bittorrent struct", e);
                    }
                }

            } catch (ClassCastException e) {
                throw new RuntimeException("Cannot parse download state", e);
            }
        }