org.eclipse.jgit.notes

## Class NoteMapMerger

- java.lang.Object
- - org.eclipse.jgit.notes.NoteMapMerger

    public class NoteMapMerger
    extends Object

Three-way note tree merge.

Direct implementation of NoteMap merger without using `TreeWalk` and `AbstractTreeIterator`

### Constructor Summary

Constructors
Constructor and Description
`NoteMapMerger(Repository db)` Constructs a NoteMapMerger with `DefaultNoteMerger` as the merger for notes and the `MergeStrategy.RESOLVE` as the strategy for resolving conflicts on non-notes
`NoteMapMerger(Repository db, NoteMerger noteMerger, MergeStrategy nonNotesMergeStrategy)` Constructs a NoteMapMerger with custom `NoteMerger` and custom `MergeStrategy`.

### Method Summary

Methods
`NoteMap` `merge(NoteMap base, NoteMap ours, NoteMap theirs)` Performs the merge.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### NoteMapMerger

    public NoteMapMerger(Repository db,
                 NoteMerger noteMerger,
                 MergeStrategy nonNotesMergeStrategy)

Constructs a NoteMapMerger with custom `NoteMerger` and custom `MergeStrategy`.

Parameters:
  `db` - Git repository
  `noteMerger` - note merger for merging conflicting changes on a note
  `nonNotesMergeStrategy` - merge strategy for merging non-note entries

#### NoteMapMerger

    public NoteMapMerger(Repository db)

Constructs a NoteMapMerger with `DefaultNoteMerger` as the merger for notes and the `MergeStrategy.RESOLVE` as the strategy for resolving conflicts on non-notes

Parameters:
  `db` - Git repository

### Method Detail

#### merge

    public NoteMap merge(NoteMap base,
                NoteMap ours,
                NoteMap theirs)
                  throws IOException

Performs the merge.

Parameters:
  `base` - base version of the note tree
  `ours` - ours version of the note tree
  `theirs` - theirs version of the note tree
Returns:
  merge result as a new NoteMap
Throws:
  `IOException`