use of com.biglybt.pif.torrent.TorrentAttribute in project BiglyBT by BiglySoftware.
the class ShareResourceImpl method serialiseResource.
protected void serialiseResource(Map map) {
Iterator it = attributes.keySet().iterator();
Map attrs = new HashMap();
map.put("attributes", attrs);
while (it.hasNext()) {
TorrentAttribute ta = (TorrentAttribute) it.next();
String value = (String) attributes.get(ta);
try {
if (value != null) {
attrs.put(ta.getName(), value.getBytes(Constants.DEFAULT_ENCODING));
}
} catch (Throwable e) {
Debug.printStackTrace(e);
}
}
}
Aggregations