Class AutoTranslateLiveActionImpl
- java.lang.Object
-
- com.day.cq.wcm.msm.commons.BaseAction
-
- com.composum.ai.aem.core.impl.autotranslate.rollout.AutoTranslateLiveActionImpl
-
- All Implemented Interfaces:
AutoTranslateLiveAction
,com.day.cq.commons.JSONItem
,com.day.cq.wcm.msm.api.LiveAction
public class AutoTranslateLiveActionImpl extends com.day.cq.wcm.msm.commons.BaseAction implements AutoTranslateLiveAction
Implementation for the rollout configuration.
-
-
Field Summary
Fields Modifier and Type Field Description protected AutoPageTranslateService
autoPageTranslateService
protected AutoTranslateService
autoTranslateService
protected AIConfigurationService
configurationService
static String
NAME
-
Constructor Summary
Constructors Modifier Constructor Description protected
AutoTranslateLiveActionImpl(org.apache.sling.api.resource.ValueMap config, com.day.cq.wcm.msm.commons.BaseActionFactory<? extends com.day.cq.wcm.msm.api.LiveAction> liveActionFactory, AutoPageTranslateService autoPageTranslateService, AIConfigurationService configurationService, AutoTranslateService autoTranslateService)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doExecute(org.apache.sling.api.resource.Resource source, org.apache.sling.api.resource.Resource target, com.day.cq.wcm.msm.api.LiveRelationship liveRelationship, boolean autoSave)
String
getName()
protected boolean
handles(org.apache.sling.api.resource.Resource source, org.apache.sling.api.resource.Resource target, com.day.cq.wcm.msm.api.LiveRelationship relation, boolean isResetRollout)
protected static void
markAsError(org.apache.sling.api.resource.Resource target)
Make it easy to find pages with errors by marking page with AI_TRANSLATION_ERRORMARKER.-
Methods inherited from class com.day.cq.wcm.msm.commons.BaseAction
execute, execute, execute, getActionFactory, getConfig, getParameterName, getPropertiesNames, getRank, getTitle, isPage, resourceHasNode, write
-
-
-
-
Field Detail
-
NAME
public static final String NAME
- See Also:
- Constant Field Values
-
autoPageTranslateService
protected final AutoPageTranslateService autoPageTranslateService
-
configurationService
protected final AIConfigurationService configurationService
-
autoTranslateService
protected final AutoTranslateService autoTranslateService
-
-
Constructor Detail
-
AutoTranslateLiveActionImpl
protected AutoTranslateLiveActionImpl(org.apache.sling.api.resource.ValueMap config, com.day.cq.wcm.msm.commons.BaseActionFactory<? extends com.day.cq.wcm.msm.api.LiveAction> liveActionFactory, AutoPageTranslateService autoPageTranslateService, AIConfigurationService configurationService, AutoTranslateService autoTranslateService)
-
-
Method Detail
-
getName
public String getName()
- Specified by:
getName
in interfacecom.day.cq.wcm.msm.api.LiveAction
- Overrides:
getName
in classcom.day.cq.wcm.msm.commons.BaseAction
-
handles
protected boolean handles(org.apache.sling.api.resource.Resource source, org.apache.sling.api.resource.Resource target, com.day.cq.wcm.msm.api.LiveRelationship relation, boolean isResetRollout) throws javax.jcr.RepositoryException
- Specified by:
handles
in classcom.day.cq.wcm.msm.commons.BaseAction
- Throws:
javax.jcr.RepositoryException
-
doExecute
protected void doExecute(org.apache.sling.api.resource.Resource source, org.apache.sling.api.resource.Resource target, com.day.cq.wcm.msm.api.LiveRelationship liveRelationship, boolean autoSave) throws com.day.cq.wcm.api.WCMException
- Specified by:
doExecute
in classcom.day.cq.wcm.msm.commons.BaseAction
- Throws:
com.day.cq.wcm.api.WCMException
-
markAsError
protected static void markAsError(org.apache.sling.api.resource.Resource target)
Make it easy to find pages with errors by marking page with AI_TRANSLATION_ERRORMARKER.
-
-