Move determination of related refIDs from merging phase (of BatchLoader) to sam file adaptation (of FileAdapter) and related modifications.