Package com.e1c.langtool.v8.dt.dcs.check
Class PresentationTranslationCheck
java.lang.Object
com.e1c.g5.v8.dt.check.components.BasicCheck<AbstractTranslationValidator.TranslationValidatorContext>
com.e1c.langtool.v8.dt.check.AbstractTranslationValidator
com.e1c.langtool.v8.dt.dcs.check.PresentationTranslationCheck
- All Implemented Interfaces:
ITopObjectFilter,ICheck<AbstractTranslationValidator.TranslationValidatorContext>
Checks that
Presentation has local value or single-language value filled.
Then checks that presentation has translation into all translatable languages.-
Nested Class Summary
Nested classes/interfaces inherited from class com.e1c.langtool.v8.dt.check.AbstractTranslationValidator
AbstractTranslationValidator.TranslationValidatorContextNested classes/interfaces inherited from class com.e1c.g5.v8.dt.check.components.BasicCheck
BasicCheck.CheckConfigurer, BasicCheck.CheckParameterBuilder, BasicCheck.ContainmentConfigurationBuilder, BasicCheck.DelegateCheckConfigurationBuilder, BasicCheck.ModuleConfigurationBuilder, BasicCheck.ResultAcceptor, BasicCheck.TopObjectConfigurationBuilder, BasicCheck.TopObjectFeatureConfigurationBuilder -
Field Summary
Fields inherited from class com.e1c.langtool.v8.dt.check.AbstractTranslationValidator
collectingService, computedNameService, featureKeyProvider, projectManager, resourceLookup, settingsService, storageSettingsManager, v8ProjectManager -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddNoTranslationMessage(org.eclipse.emf.ecore.EObject object, BasicCheck.ResultAcceptor resultAcceptor, String value, FeatureKey key, FeatureSettings featureSettings, Collection<String> languages) Adds the message about empty translation for specific languages.protected voidcheck(Object object, BasicCheck.ResultAcceptor resultAcceptor, ICheckParameters parameters, org.eclipse.core.runtime.IProgressMonitor monitor) The method that performs the check.protected voidconfigureCheck(BasicCheck.CheckConfigurer builder) The check is performed in case of changes of the tracjed object model/language module changes.Gets the unique identifier of the check.protected org.eclipse.emf.ecore.EStructuralFeaturegetMessageFeature(FeatureSettings featureSettings) Methods inherited from class com.e1c.langtool.v8.dt.check.AbstractTranslationValidator
checkTranslation, getParameters, getReader, getTranslation, prepareContextMethods inherited from class com.e1c.g5.v8.dt.check.components.BasicCheck
check, check, configureContextCollector, isCheckApplicable, postConfigureContextCollectorMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.e1c.g5.v8.dt.check.ICheck
check, prepareContext
-
Constructor Details
-
PresentationTranslationCheck
public PresentationTranslationCheck()
-
-
Method Details
-
getCheckId
Description copied from interface:ICheckGets the unique identifier of the check. The identifier should be unique. The system performs automated identifier conflict resolution in case of non-unique identifiers, with addition of conflict-resolving symbols to the identifier- Returns:
- The identifier of the check. May not be
null
-
configureCheck
Description copied from class:BasicCheckThe check is performed in case of changes of the tracjed object model/language module changes. In order to define the rules of the check performing, the developer should define the set ofEClass'es and their features those changes are being tracked/or be targets of the validation- Overrides:
configureCheckin classAbstractTranslationValidator
-
check
protected void check(Object object, BasicCheck.ResultAcceptor resultAcceptor, ICheckParameters parameters, org.eclipse.core.runtime.IProgressMonitor monitor) Description copied from class:BasicCheckThe method that performs the check. Check results (issues) need to be placed into the result acceptor. Validation may be cancelled by a user. Complex implemantations should take this into the account and checkIProgressMonitor.isCanceled()periodically during long-running operations.- Overrides:
checkin classBasicCheck<AbstractTranslationValidator.TranslationValidatorContext>- Parameters:
object- The object to check, notnullresultAcceptor- Result acceptor, notnullparameters- The set of check execution parameters taken from check settings, notnullmonitor- Current check progress monitor, notnull
-
addNoTranslationMessage
protected void addNoTranslationMessage(org.eclipse.emf.ecore.EObject object, BasicCheck.ResultAcceptor resultAcceptor, String value, FeatureKey key, FeatureSettings featureSettings, Collection<String> languages) Description copied from class:AbstractTranslationValidatorAdds the message about empty translation for specific languages.- Overrides:
addNoTranslationMessagein classAbstractTranslationValidator- Parameters:
object- the objectresultAcceptor- the message acceptorvalue- the valuekey- the keylanguages- the languages without translation
-
getMessageFeature
protected org.eclipse.emf.ecore.EStructuralFeature getMessageFeature(FeatureSettings featureSettings) - Overrides:
getMessageFeaturein classAbstractTranslationValidator
-