code: @Override
  	public boolean process(ContentEvent event) {
  
      	InstanceContentEvent inEvent = (InstanceContentEvent) event;
  		Instance instance = inEvent.getInstance();
  
  		if (inEvent.getInstanceIndex() < 0) {
  			//end learning
  			ResultContentEvent outContentEvent = new ResultContentEvent(-1, instance, 0,
  					new double[0], inEvent.isLastEvent());
  			outContentEvent.setClassifierIndex(this.modelId);
  			outContentEvent.setEvaluationIndex(inEvent.getEvaluationIndex());
  			outputStream.put(outContentEvent);
  			return false;
  		}
  		
  		if (inEvent.isTesting()){
  			double[] dist = model.getVotesForInstance(instance);
  			ResultContentEvent outContentEvent = new ResultContentEvent(inEvent.getInstanceIndex(),
  					instance, inEvent.getClassId(), dist, inEvent.isLastEvent());
  			outContentEvent.setClassifierIndex(this.modelId);
  			outContentEvent.setEvaluationIndex(inEvent.getEvaluationIndex());
  			logger.trace(inEvent.getInstanceIndex() + " {} {}", modelId, dist);
  			outputStream.put(outContentEvent);
  		}
  		
  		if (inEvent.isTraining()) {
  			updateStats(inEvent);
  		} 
  		return false;
  	}
docs: On event.
  
  @param event the event
  @return true, if successful