code: public static long count_filtered(nitro_service service, String id, String filter) throws Exception{
  		linkset_channel_binding obj = new linkset_channel_binding();
  		obj.set_id(id);
  		options option = new options();
  		option.set_count(true);
  		option.set_filter(filter);
  		linkset_channel_binding[] response = (linkset_channel_binding[]) obj.getfiltered(service, option);
  		if (response != null) {
  			return response[0].__count;
  		}
  		return 0;
  	}
docs: Use this API to count the filtered set of linkset_channel_binding resources.
  filter string should be in JSON format.eg: "port:80,servicetype:HTTP".