return subLinks;
}
public long count(String type, Integer id)
{
Context context = null;
try
{
context = new Context();
ACrisObject cris = getApplicationService().get(getTarget(), id);
List<FacetResult> facetresults = search(context, cris, 0, 0, null, true).getFacetResult(type);
if(facetresults.isEmpty()) {
return 0;
}
return facetresults.get(0).getCount();
}
catch (Exception ex)
{
log.error(ex.getMessage(), ex);
}
finally
{
if (context != null && context.isValid())
{
context.abort();
}
}
return -1;
}