Package org.ametys.cms.content.version
Class CompareContentVersionToolClientSideElement
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.core.ui.StaticFileImportsClientSideElement
-
- org.ametys.core.ui.StaticClientSideElement
-
- org.ametys.cms.content.version.CompareContentVersionToolClientSideElement
-
- All Implemented Interfaces:
ClientSideElement
,LogEnabled
,PluginAware
,Configurable
,Serviceable
public class CompareContentVersionToolClientSideElement extends StaticClientSideElement
ClientSideElement
for the tool for comparing a content between a base version and a target version.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private class
CompareContentVersionToolClientSideElement.ContentVersionComparator
-
Nested classes/interfaces inherited from interface org.ametys.core.ui.ClientSideElement
ClientSideElement.Script, ClientSideElement.ScriptFile
-
-
Field Summary
Fields Modifier and Type Field Description private static String
__FALLBACK_VIEW_NAME
private static String
__VIEW_NAME
private CompareVersionHelper
_compareVersionHelper
private ContentTypesHelper
_cTypesHelper
private ExternalizableMetadataProviderExtensionPoint
_externalizableMetaProvider
private SourceResolver
_sourceResolver
-
Fields inherited from class org.ametys.core.ui.StaticFileImportsClientSideElement
_currentUserProvider, _dependencies, _featureName, _id, _pluginName, _rightManager, _rights, _rightsMode, _script
-
-
Constructor Summary
Constructors Constructor Description CompareContentVersionToolClientSideElement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Object>
getDiffValues(String contentId, String targetVersion, String baseVersion)
Gets the JSON information about the changes for the given content id between the base and target provided versions.void
service(ServiceManager smanager)
-
Methods inherited from class org.ametys.core.ui.StaticClientSideElement
_configureClass, _configureParameters, _configureScript, configureInitialParameters
-
Methods inherited from class org.ametys.core.ui.StaticFileImportsClientSideElement
_configureDependencies, _configureImports, _configureRights, _configureRightsMode, configure, getDependencies, getId, getPluginName, getRights, getScripts, getScripts, hasRight, setPluginInfo, toString
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
-
-
-
Field Detail
-
__VIEW_NAME
private static final String __VIEW_NAME
- See Also:
- Constant Field Values
-
__FALLBACK_VIEW_NAME
private static final String __FALLBACK_VIEW_NAME
- See Also:
- Constant Field Values
-
_compareVersionHelper
private CompareVersionHelper _compareVersionHelper
-
_sourceResolver
private SourceResolver _sourceResolver
-
_cTypesHelper
private ContentTypesHelper _cTypesHelper
-
_externalizableMetaProvider
private ExternalizableMetadataProviderExtensionPoint _externalizableMetaProvider
-
-
Constructor Detail
-
CompareContentVersionToolClientSideElement
public CompareContentVersionToolClientSideElement()
-
-
Method Detail
-
service
public void service(ServiceManager smanager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classStaticFileImportsClientSideElement
- Throws:
ServiceException
-
getDiffValues
public Map<String,Object> getDiffValues(String contentId, String targetVersion, String baseVersion) throws IOException, ProcessingException
Gets the JSON information about the changes for the given content id between the base and target provided versions.- Parameters:
contentId
- TheContent
idtargetVersion
- The content version to be comparedbaseVersion
- The base content version- Returns:
- The information
- Throws:
IOException
- If an I/O exception occured during the comparison between the two versions, or when getting content valuesProcessingException
- If an exception occured when converting the "change" view
-
-