public interface WebCmsEndpointService
| Modifier and Type | Method and Description |
|---|---|
org.springframework.web.util.UriComponentsBuilder |
appendPreviewCode(WebCmsEndpoint endpoint,
org.springframework.web.util.UriComponentsBuilder uriComponentsBuilder) |
Optional<WebCmsUrl> |
getPrimaryUrlForAsset(WebCmsAsset asset)
Get the primary URL for a
WebCmsAsset on the current domain. |
Optional<WebCmsUrl> |
getPrimaryUrlForAssetOnDomain(WebCmsAsset asset,
WebCmsDomain domain)
Get the primary URL for a
WebCmsAsset on the specified domain. |
Optional<WebCmsUrl> |
getUrlForPath(String path)
Retrieve the
WebCmsUrl corresponding to a particular path. |
Optional<WebCmsUrl> |
getUrlForPathAndDomain(String path,
WebCmsDomain domain)
Retrieve the
WebCmsUrl corresponding to a particular path on a specific domain. |
boolean |
isValidPreviewCode(WebCmsEndpoint endpoint,
String securityCode)
Check if a particular security code allows access to an endpoint.
|
ModificationReport<EndpointModificationType,WebCmsUrl> |
updateOrCreatePrimaryUrlForAsset(String primaryUrl,
WebCmsAsset asset,
boolean publishEventOnFailure)
Update the primary URL for a
WebCmsAsset. |
Optional<WebCmsUrl> getUrlForPath(String path)
WebCmsUrl corresponding to a particular path.
Will use the current WebCmsDomainContext to perform the lookup.path - to find the url forOptional<WebCmsUrl> getUrlForPathAndDomain(String path, WebCmsDomain domain)
WebCmsUrl corresponding to a particular path on a specific domain.path - to find the url fordomain - to look onModificationReport<EndpointModificationType,WebCmsUrl> updateOrCreatePrimaryUrlForAsset(String primaryUrl, WebCmsAsset asset, boolean publishEventOnFailure)
WebCmsAsset. Depending on the published status of the asset
will either create or update the existing primary url, or will update the previous primary url
as a redirect to the new primary url.
Note that if there is no single WebCmsAssetEndpoint
for the asset, this method will do nothing. The ModificationReport returned should contain the
status information on which action was performed. A ModificationStatus.FAILED
means another endpoint already has that url.
The third parameter indicates if a PrimaryUrlForAssetFailedEvent should
be published in case of a conflict with another endpoint. This allows another bean to take action and change the modification report.primaryUrl - for the assetasset - to updatepublishEventOnFailure - true if an evenOptional<WebCmsUrl> getPrimaryUrlForAsset(WebCmsAsset asset)
WebCmsAsset on the current domain.asset - to get the primary url forOptional<WebCmsUrl> getPrimaryUrlForAssetOnDomain(WebCmsAsset asset, WebCmsDomain domain)
WebCmsAsset on the specified domain.asset - to get the primary url fordomain - to get the primary url onorg.springframework.web.util.UriComponentsBuilder appendPreviewCode(WebCmsEndpoint endpoint, org.springframework.web.util.UriComponentsBuilder uriComponentsBuilder)
boolean isValidPreviewCode(WebCmsEndpoint endpoint, String securityCode)
endpoint - to accesssecurityCode - that was usedCopyright © 2020. All rights reserved.