void loadMarkers(String title, List<MemoryMatch> matches) {
		if (service == null) {
			return;
		}

		if (matches.isEmpty()) {
			deleteMarkerSet();
			return;
		}

		// If the title of the provider changes, we need to re-create the marker set as the 
		// provider's title is what is used as the marker set's name. The name is what shows up in
		// the marker set gui for turning markers on and off - if they don't match the provider's
		// title, it isn't obvious what provider the markers represent. (And currently, there is
		// no way to change a marker set's name once it is created.)
		if (markerSet != null && !markerSet.getName().equals(title)) {
			deleteMarkerSet();
		}

		if (markerSet == null) {
			markerSet = createMarkerSet(title);
		}

		markerSet.clearAll();
		for (MemoryMatch match : matches) {
			markerSet.add(match.getAddress());
		}
		service.setMarkerForGroup(MarkerService.HIGHLIGHT_GROUP, markerSet, program);
	}
Manages the {@link MarkerSet} for a given {@link MemorySearchProvider} window.
Ghidra/Features/Base/src/main/java/ghidra/features/base/memsearch/gui/SearchMarkers.java