}
//bookmark
else
{
nc.setType("bookmark");
BookmarkNode bn = new BookmarkNode();
ResourceWrapper bookRes = new ResourceWrapper(resource,serviceAddr,true);
bn.setId(resource.getResource().toString());
if (bookRes.getAuthors() != null && bookRes.getTitle() != null) {
bn.setLabel("<i>[" + bookRes.getAuthors() + "]</i> " + bookRes.getTitle());
} else {
//TODO: temporarly switched of to get some efficiency - will be substituted with - "fetch details" button
if(resource.getLabel().contains("\"")||resource.getLabel().contains("'"))
bn.setLabel(resource.getLabel().replace("\"", "\\\"").replace("'", "\\'"));
else
bn.setLabel(resource.getLabel()!=null&&!"".equals(resource.getLabel())?resource.getLabel(): resource.getResource().toString());
}
//check if this bookmark is selected this directory
if(isSelected)
{
bn.setSelected(true);
}
else bn.setSelected(false);
bn.setHits(resource.getResourceHits());
bn.setLevel(level);
bn.setOwn(parentIsOwner);
bn.setStandalone(standalone);
nc.setContent(bn);
}
//add created nodes to the buffer
if(reachable)