Called when site and or project have been changed.<p>

@param sitePath the site path to the resource to display
@param serverLink the server link to the resource to display
777990
public void onSiteOrProjectChange(String sitePath, String serverLink) {

        if (m_frame != null) {
            m_frame.removeFromParent();
            m_frame = null;
        }
        if (m_handler != null) {
            m_handler.onSiteOrProjectChange(sitePath, serverLink);
        } else {
            Window.Location.assign(serverLink);
        }
    }
1080213
private void updateProjectResources() throws CmsException {

        CmsObject cms = A_CmsUI.getCmsObject();
        Set<String> resourceRootPaths = getResourcePaths();
        // write the edited project resources
        CmsProject currentProject = cms.getRequestContext().getCurrentProject();
        // change the current project
        cms.getRequestContext().setCurrentProject(m_project);
        // store the current site root
        String currentSite = cms.getRequestContext().getSiteRoot();
        // copy the resources to the current project
        try {
            // switch to the root site
            cms.getRequestContext().setSiteRoot("");
            // remove deleted resources
            for (String resName : cms.readProjectResources(m_project)) {
                if (!resourceRootPaths.contains(resName)) {
                    cms.removeResourceFromProject(resName);
                }
            }
            // read project resources again!
            List<String> currentResNames = cms.readProjectResources(m_project);
            // copy missing resources
            for (String resName : resourceRootPaths) {
                if (!currentResNames.contains(resName)) {
                    cms.copyResourceToProject(resName);
                }
            }
        } finally {
            // switch back to current site and project
            cms.getRequestContext().setSiteRoot(currentSite);
            cms.getRequestContext().setCurrentProject(currentProject);
        }
    }
985325
public void selectResource(String resourcePath, CmsUUID structureId, String title, String resourceType) {

        m_controller.selectResource(resourcePath, structureId, title, resourceType);
    }
154751
public synchronized SiteNode addPath(HistoryReference ref) {
    	if (Constant.isLowMemoryOptionSet()) {
    		throw new InvalidParameterException("SiteMap should not be accessed when the low memory option is set");
    	}

        HttpMessage msg = null;
        try {
            msg = ref.getHttpMessage();
        } catch (Exception e) {
            // ZAP: Added error
            log.error(e.getMessage(), e);
            return null;
        }
        
        return addPath(ref, msg);
    }
1093483
public void setSiteParam(String siteRoot, String key, String value) {

        CmsSite site = OpenCms.getSiteManager().getSiteForRootPath(siteRoot);
        if (site == null) {
            throw new IllegalArgumentException("No site found for path: " + siteRoot);
        } else {
            site.getParameters().put(key, value);
            OpenCms.writeConfiguration(CmsSitesConfiguration.class);
        }
    }
777298
public void addProjectResource(String resourceName) {

        if ((m_throwable != null) || (m_projectName == null)) {
            return;
        }
        if (m_projectResources == null) {
            m_projectResources = new ArrayList<String>();
        }
        m_projectResources.add(resourceName);
    }
1359051
public void setProcessPath(java.util.Collection<StringFilter> processPath) {
        if (processPath == null) {
            this.processPath = null;
            return;
        }

        this.processPath = new java.util.ArrayList<StringFilter>(processPath);
    }
852803
protected void addResource(String path) {

        CmsPathSelectField field = new CmsPathSelectField();
        field.setCmsObject(m_cms);
        field.setUseRootPaths(true);
        field.setValue(path);
        field.addValueChangeListener(new ValueChangeListener() {

            private static final long serialVersionUID = 8646438704383992571L;

            public void valueChange(ValueChangeEvent event) {

                setOkButtonEnabled(true);

            }
        });
        m_componentsToValidate.add(field);
        CmsRemovableFormRow<CmsPathSelectField> row = new CmsRemovableFormRow<CmsPathSelectField>(
            field,
            CmsVaadinUtils.getMessageText(Messages.GUI_DATABASEAPP_SYNC_REMOVE_RESOURCE_0));
        row.setCaption(CmsVaadinUtils.getMessageText(Messages.GUI_DATABASEAPP_SYNC_RESOURCE_0));
        row.setRemoveRunnable(new Runnable() {

            public void run() {

                setOkButtonEnabled(true);
            }
        });
        m_resources.addComponent(row);
    }
734590
public void setSiteUrl(String siteUrl) {
        this.siteUrl = StringUtils.isBlank(siteUrl) ? new ServerSiteUrlConfig() : new ServerSiteUrlConfig(siteUrl);
    }
430570
public void setWorkPath(String workPath) throws CmsIllegalArgumentException {

        if (CmsStringUtil.isEmptyOrWhitespaceOnly(workPath)) {
            throw new CmsIllegalArgumentException(Messages.get().container(Messages.GUI_ERR_WIDGETVALUE_EMPTY_0));
        }
        // test if it is a valid path:
        if (!m_cms.existsResource(workPath)) {
            throw new CmsIllegalArgumentException(
                Messages.get().container(Messages.GUI_ERR_TAGREPLACE_WORKPATH_1, workPath));
        }
        m_workPath = workPath;

    }
191003
public void substituteLinkForRootPath(final String rootPath, final I_CmsSimpleCallback<String> callback) {

        CmsRpcAction<String> action = new CmsRpcAction<String>() {

            @Override
            public void execute() {

                getVfsService().substituteLinkForRootPath(getSiteRoot(), rootPath, this);
            }

            @Override
            protected void onResponse(String result) {

                callback.execute(result);
            }
        };
        action.execute();
    }
996738
public void setContextPath(String contextPath) {

		if (contextPath != null && !contextPath.endsWith("/")) {
			contextPath += "/";
		}
		this.contextPath = contextPath;
	}
1039463
public String getDisplayedUrl(String sitePath) {

        if (getSitemapEntry().isLeafType() && sitePath.endsWith("/")) {
            sitePath = sitePath.substring(0, sitePath.length() - 1);
        }
        CmsSitemapController controller = CmsSitemapView.getInstance().getController();
        String exportProp = controller.getEffectiveProperty(getSitemapEntry(), "export");
        if ("true".equals(exportProp)) {
            String exportName = getSitemapEntry().getExportName();
            if (exportName == null) {
                exportName = CmsCoreProvider.get().getSiteRoot();
            }
            String rfsPrefix = CmsSitemapView.getInstance().getController().getData().getExportRfsPrefix();
            if (rfsPrefix != null) {
                return CmsStringUtil.joinPaths(rfsPrefix, exportName, sitePath);
            }
        }
        return CmsCoreProvider.get().link(sitePath);
    }
1188475
public void setSitePath(String sitepath) {

        if (!isLeafType() && !sitepath.endsWith("/")) {
            sitepath = sitepath + "/";
        }
        m_sitePath = sitepath;
    }
754518
private void selectSite(String siteRoot) {

        if (m_sortSelectBox == null) {
            return;
        }
        Map<String, String> options = m_sortSelectBox.getItems();
        String option = null;
        for (Map.Entry<String, String> entry : options.entrySet()) {
            if (CmsStringUtil.comparePaths(entry.getKey(), siteRoot)) {
                option = entry.getKey();
                break;
            }
        }
        if (option != null) {
            m_sortSelectBox.setFormValue(option, false);
        }
    }
15568
public void loadPath(final String sitePath, final AsyncCallback<CmsClientSitemapEntry> callback) {

        loadPath(sitePath, false, callback);
    }
1372323
public void setEntityPath(java.util.Collection<ResponseTimeRootCauseEntity> entityPath) {
        if (entityPath == null) {
            this.entityPath = null;
            return;
        }

        this.entityPath = new java.util.ArrayList<ResponseTimeRootCauseEntity>(entityPath);
    }