X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=org.argeo.api.cms%2Fsrc%2Forg%2Fargeo%2Fapi%2Fcms%2Fux%2FCmsView.java;h=121e4bdcbf601a654fc608aeda89ec895f4b4e3b;hb=4086635cfaa04c8a184124048794398b0ba96a55;hp=a36baf8e08b642cd2c7b625162494ae9710b9d14;hpb=f1b9c5f7bd5ab6ea3337cb59317bb6e6d449d88e;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.api.cms/src/org/argeo/api/cms/ux/CmsView.java b/org.argeo.api.cms/src/org/argeo/api/cms/ux/CmsView.java index a36baf8e0..121e4bdcb 100644 --- a/org.argeo.api.cms/src/org/argeo/api/cms/ux/CmsView.java +++ b/org.argeo.api.cms/src/org/argeo/api/cms/ux/CmsView.java @@ -1,5 +1,6 @@ package org.argeo.api.cms.ux; +import java.net.URI; import java.util.HashMap; import java.util.Map; import java.util.concurrent.Callable; @@ -9,7 +10,7 @@ import javax.security.auth.login.LoginContext; import org.argeo.api.cms.CmsSession; -/** Provides interaction with the CMS system. */ +/** Provides UX interactions with the CMS system. */ public interface CmsView { final static String CMS_VIEW_UID_PROPERTY = "argeo.cms.view.uid"; // String KEY = "org.argeo.cms.ui.view"; @@ -31,10 +32,18 @@ public interface CmsView { // SERVICES void exception(Throwable e); - CmsImageManager getImageManager(); + CmsImageManager getImageManager(); boolean isAnonymous(); + /** + * Translates to an URL that can be reached by a client, depending on its type. + * Typically, if a web interface asks for /path/on/the/web/server it will be + * returned without modifications; but a thin client will probably need to add a + * server and a port. + */ + URI toBackendUri(String url); + /** * Send an event to this topic. Does nothing by default., but if implemented it * MUST set the {@link #CMS_VIEW_UID_PROPERTY} in the properties.