@Override
	public void actionPerformed(ActionContext context) {
		AddressSet selection = new AddressSet();
		for (AddressRangeInfo rangeInfo : model.getLastSelectedObjects()) {
			if (endpoint.equals(RangeEndpoint.MIN)) {
				selection.add(rangeInfo.min());
			}
			else {
				selection.add(rangeInfo.max());
			}
		}
		plugin.getTool()
				.firePluginEvent(new ProgramSelectionPluginEvent(plugin.getName(),
					new ProgramSelection(selection), program));
	}
Creates an action which selects the endpoint of a range based on {@code RangeEndpoint}
@param plugin plugin
@param program program
@param model model 
@param endpoint left or right endpoint
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/codebrowser/SelectEndpointsAction.java