code: private int decrementReferenceCounter(final JobID jobID) {
  
  		final AtomicInteger ai = this.libraryReferenceCounter.get(jobID);
  
  		if (ai == null) {
  			throw new IllegalStateException("Cannot find reference counter entry for job " + jobID);
  		}
  
  		int retVal = ai.decrementAndGet();
  
  		if (retVal == 0) {
  			this.libraryReferenceCounter.remove(jobID);
  		}
  
  		return retVal;
  	}
docs: Decrements the reference counter for the library manager entry with the given job ID.
  
  @param jobID
  the job ID identifying the library manager entry
  @return the decremented reference counter