code: private <T> void registerProcessor(T processor, String model,
  			boolean onlyCurrentRevisions,
  			Map<ListenerRegistration, List<T>> processors) {
  		this.preferCurrent = this.preferCurrent && onlyCurrentRevisions;
  
  		ListenerRegistration listenerRegistration = new ListenerRegistration(
  				model, onlyCurrentRevisions);
  		if (!processors.containsKey(listenerRegistration)) {
  			processors.put(listenerRegistration, new ArrayList<>());
  		}
  
  		processors.get(listenerRegistration).add(processor);
  	}
docs: Stores a registered processor object in a map of processors. Used
  internally to keep {@link EntityDocumentProcessor} and
  {@link MwRevisionProcessor} objects.
  
  @param processor
  the processor object to register
  @param model
  the content model that the processor is registered for; it
  will only be notified of revisions in that model; if null is
  given, all revisions will be processed whatever their model
  @param onlyCurrentRevisions
  if true, then the subscriber is only notified of the most
  current revisions; if false, then it will receive all
  revisions, current or not
  @param processors
  the map of lists of processors to store the processor in