Class BslCommentTextProcessor
java.lang.Object
com.e1c.langtool.v8.dt.bsl.comment.DocCommentProcessor
com.e1c.langtool.v8.dt.bsl.comment.DocCommentCollector
com.e1c.langtool.v8.dt.bsl.translator.AbstractBslCommentTextProcessor
com.e1c.langtool.v8.dt.bsl.translator.BslCommentTextProcessor
- All Implemented Interfaces:
FeatureValueCollector,IBasicProcessor
- Direct Known Subclasses:
BslCommentClearableTextProcessor
Translator processor of Documentation comment model.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.e1c.langtool.v8.dt.bsl.comment.DocCommentProcessor
DocCommentProcessor.Parent -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final org.eclipse.emf.ecore.EObjectThe contextFields inherited from class com.e1c.langtool.v8.dt.bsl.translator.AbstractBslCommentTextProcessor
eObjectReplaceProvider, lines, method, module, translationProviderFields inherited from class com.e1c.langtool.v8.dt.bsl.comment.DocCommentCollector
featureKeyProvider, typeComputationContextFields inherited from class com.e1c.langtool.v8.dt.bsl.comment.DocCommentProcessor
monitor, rootObject -
Constructor Summary
ConstructorsConstructorDescriptionBslCommentTextProcessor(org.eclipse.core.resources.IFile file, FeatureKey featureKeyPreffix, BslDocumentationComment comment, List<org.eclipse.xtext.nodemodel.INode> lines, org.eclipse.text.edits.MultiTextEdit edit, IProjectTranslationProvider translationProvider, Function<org.eclipse.emf.ecore.EObject, String> eObjectReplaceProvider, TranslatorProperties translatorProperties, BslTranslationLogger problemLogger, Method method, BmOperationContext typeComputationContext) Instantiates a new bsl documentation comment text processor.BslCommentTextProcessor(org.eclipse.core.resources.IFile file, org.eclipse.emf.ecore.EObject context, FeatureKey featureKeyPreffix, BslDocumentationComment comment, List<org.eclipse.xtext.nodemodel.INode> lines, org.eclipse.text.edits.MultiTextEdit edit, IProjectTranslationProvider translationProvider, Function<org.eclipse.emf.ecore.EObject, String> eObjectReplaceProvider, TranslatorProperties translatorProperties, BslTranslationLogger problemLogger, BmOperationContext typeComputationContext, Method method) Instantiates a new bsl documentation comment text processor. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddReplace(org.eclipse.xtext.nodemodel.INode bslNode, int partOffset, String original, String replace, boolean firstPart) Adds the replace.protected <T> voiddoProcess(DocCommentProcessor.Parent parent, T object, Class<T> clazz) Processes concrete object of Bsl commentprotected voidDo process translatable.protected voiddoProcessTranslatable(TagPart object, FeatureValue fv) Do process translatable.protected static booleanisMethodDescription(Object rootObject) protected voidreplaceLinkPart(LinkPart link) Replaces link part.protected voidreplaceTypes(TypeSection.TypeDefinition typeDef) Replaces types.protected voidtranslateDocComment(BslDocumentationComment.Description object, String translation, boolean methodDescription) Translate doc comment.protected voidtranslateTagDescription(TagPart part, String translation) Translates tag description.Methods inherited from class com.e1c.langtool.v8.dt.bsl.translator.AbstractBslCommentTextProcessor
computeDerivedPropertyCacheMethods inherited from class com.e1c.langtool.v8.dt.bsl.comment.DocCommentCollector
create, doProcess, doProcess, getFieldProperty, getFieldPropertyByOrder, getFunctionReturnTypeFieldOrder, getTypeComputationContext, isComputedValue, isRealLink, isSkipTextPart, setAddActionMethods inherited from class com.e1c.langtool.v8.dt.bsl.comment.DocCommentProcessor
isCanceled, processMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.e1c.langtool.IBasicProcessor
isCanceled, process
-
Field Details
-
context
protected final org.eclipse.emf.ecore.EObject contextThe context
-
-
Constructor Details
-
BslCommentTextProcessor
public BslCommentTextProcessor(org.eclipse.core.resources.IFile file, org.eclipse.emf.ecore.EObject context, FeatureKey featureKeyPreffix, BslDocumentationComment comment, List<org.eclipse.xtext.nodemodel.INode> lines, org.eclipse.text.edits.MultiTextEdit edit, IProjectTranslationProvider translationProvider, Function<org.eclipse.emf.ecore.EObject, String> eObjectReplaceProvider, TranslatorProperties translatorProperties, BslTranslationLogger problemLogger, BmOperationContext typeComputationContext, Method method) Instantiates a new bsl documentation comment text processor.- Parameters:
file- the file of the module, cannot benull.context- the context of doc-comment, cannot benull.featureKeyPreffix- the feature key prefix, cannot benull.comment- the root documentation comment model object, cannot benull.lines- the lines of the doc-comment, cannot benull.edit- the edits that will be append by translator changes, cannot benull.translationProvider- the translation provider, cannot benull.eObjectReplaceProvider- the e object replace provider, cannot benull.translatorProperties- the translator properties, cannot benull.problemLogger- the translation problem loggertypeComputationContext- the BM operation context for the type computation process, cannot benull.
-
BslCommentTextProcessor
public BslCommentTextProcessor(org.eclipse.core.resources.IFile file, FeatureKey featureKeyPreffix, BslDocumentationComment comment, List<org.eclipse.xtext.nodemodel.INode> lines, org.eclipse.text.edits.MultiTextEdit edit, IProjectTranslationProvider translationProvider, Function<org.eclipse.emf.ecore.EObject, String> eObjectReplaceProvider, TranslatorProperties translatorProperties, BslTranslationLogger problemLogger, Method method, BmOperationContext typeComputationContext) Instantiates a new bsl documentation comment text processor.- Parameters:
file- the file of the module, cannot benull.featureKeyPreffix- the feature key prefix, cannot benull.comment- the root documentation comment model object, cannot benull.lines- the lines of the doc-comment, cannot benull.edit- the edits that will be append by translator changes, cannot benull.translationProvider- the translation provider, cannot benull.eObjectReplaceProvider- the e object replace provider, cannot benull.translatorProperties- the translator properties, cannot benull.problemLogger- the translation problem loggermethod- the method of doc-comment, cannot benull.typeComputationContext- the BM operation context for the type computation process, cannot benull.
-
-
Method Details
-
doProcess
Description copied from class:DocCommentProcessorProcesses concrete object of Bsl comment- Overrides:
doProcessin classDocCommentCollectorobject- processing object, can't benull
-
replaceLinkPart
Replaces link part.- Parameters:
link- the link, can benull.
-
replaceTypes
Replaces types.- Parameters:
typeDef- the type definition, cannot benull.
-
doProcessTranslatable
Do process translatable.- Parameters:
object- the object, cannot benull.fv- the feature value, cannot benull.
-
doProcessTranslatable
Do process translatable.- Parameters:
object- the object, cannot benull.fv- the feature value, cannot benull.
-
translateDocComment
protected void translateDocComment(BslDocumentationComment.Description object, String translation, boolean methodDescription) Translate doc comment.- Parameters:
object- the object, cannot benull.translation- the translation, cannot benull.methodDescription- the method description
-
translateTagDescription
Translates tag description.- Parameters:
part- the part, cannot benulltranslation- the translation, cannot benull
-
addReplace
protected void addReplace(org.eclipse.xtext.nodemodel.INode bslNode, int partOffset, String original, String replace, boolean firstPart) Adds the replace.- Parameters:
bslNode- the bsl node, cannot benull.partOffset- the part offset, cannot benull.original- the original, cannot benull.replace- the replace, cannot benull.firstPart- the first part, cannot benull.
-
isMethodDescription
-