Source:
<code>private void goTo(final PlaceRequest place, final PanelDefinition panel, final Command doWhenFinished) { if (place == null || place.equals(DefaultPlaceRequest.NOWHERE)) { return; } final ResolvedRequest resolved = resolveActivity(place); if (resolved.getActivity() != null) { final Activity activity = resolved.getActivity(); if (activity.isType(ActivityResourceType.SCREEN.name()) || activity.isType(ActivityResourceType.EDITOR.name())) { final WorkbenchActivity workbenchActivity = (WorkbenchActivity) activity; if (workbenchActivity.getOwningPlace() != null && getStatus(workbenchActivity.getOwningPlace()) == PlaceStatus.CLOSE) { goTo(workbenchActivity.getOwningPlace(), null, new Command() { @Override public void execute() { goTo(place, panel, doWhenFinished); } }); return; } launchWorkbenchActivityAtPosition(resolved.getPlaceRequest(), workbenchActivity, workbenchActivity.getDefaultPosition(), panel); doWhenFinished.execute(); } else if (activity.isType(ActivityResourceType.POPUP.name())) { launchPopupActivity(resolved.getPlaceRequest(), (PopupActivity) activity); doWhenFinished.execute(); } else if (activity.isType(ActivityResourceType.PERSPECTIVE.name())) { final Command launchPerspectiveCommand = () -> { placeHistoryHandler.flush(); launchPerspectiveActivity(place, (PerspectiveActivity) activity, doWhenFinished); }; final PerspectiveActivity currentPerspective = perspectiveManager.getCurrentPerspective(); if (currentPerspective != null) { <START> final BiParameterizedCommand<Command, PlaceRequest> closeChain = this.perspectiveCloseChain.get(currentPerspective.getIdentifier()); <END> if (closeChain != null) { closeChain.execute(launchPerspectiveCommand, currentPerspective.getPlace()); } else { launchPerspectiveCommand.execute(); } } else { launchPerspectiveCommand.execute(); } } } else { goTo(resolved.getPlaceRequest(), panel, doWhenFinished); } }</code><technical_language>@paulovmr please add docs chain interface</technical_language>

Target:
private void goTo(final PlaceRequest place, final PanelDefinition panel, final Command doWhenFinished) { if (place == null || place.equals(DefaultPlaceRequest.NOWHERE)) { return; } final ResolvedRequest resolved = resolveActivity(place); if (resolved.getActivity() != null) { final Activity activity = resolved.getActivity(); if (activity.isType(ActivityResourceType.SCREEN.name()) || activity.isType(ActivityResourceType.EDITOR.name())) { final WorkbenchActivity workbenchActivity = (WorkbenchActivity) activity; if (workbenchActivity.getOwningPlace() != null && getStatus(workbenchActivity.getOwningPlace()) == PlaceStatus.CLOSE) { goTo(workbenchActivity.getOwningPlace(), null, new Command() { @Override public void execute() { goTo(place, panel, doWhenFinished); } }); return; } launchWorkbenchActivityAtPosition(resolved.getPlaceRequest(), workbenchActivity, workbenchActivity.getDefaultPosition(), panel); doWhenFinished.execute(); } else if (activity.isType(ActivityResourceType.POPUP.name())) { launchPopupActivity(resolved.getPlaceRequest(), (PopupActivity) activity); doWhenFinished.execute(); } else if (activity.isType(ActivityResourceType.PERSPECTIVE.name())) { launchPerspectiveActivity(place, doWhenFinished, (PerspectiveActivity) activity); } } else { goTo(resolved.getPlaceRequest(), panel, doWhenFinished); } }