Package org.languagetool.rules.ml
Interface MLServerProto.MatchOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
MLServerProto.Match,MLServerProto.Match.Builder
- Enclosing class:
MLServerProto
public static interface MLServerProto.MatchOrBuilder
extends com.google.protobuf.MessageOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptionbooleanis this correction eligible for auto-correction?intsint32 contextForSureMatch = 13;getId()prefix for rule ids; should use a common value for one model/servercom.google.protobuf.ByteStringprefix for rule ids; should use a common value for one model/serverintlength of matched area; >0description of the match; displayed in e.g.com.google.protobuf.ByteStringdescription of the match; displayed in e.g.shortened description of the match; displayed in e.g.com.google.protobuf.ByteStringshortened description of the match; displayed in e.g.intstart position in the sentence (i.e.getRule().lt_ml_server.Rule rule = 14;added later, optional (can be substituted by Java)com.google.protobuf.ByteStringadded later, optional (can be substituted by Java).lt_ml_server.Rule rule = 14;getSubId()more specific suffix for rule ids; i.e.com.google.protobuf.ByteStringmore specific suffix for rule ids; i.e.getSuggestedReplacements(int index) new and extended suggestions; overwrite any values set in suggestionsintnew and extended suggestions; overwrite any values set in suggestionsnew and extended suggestions; overwrite any values set in suggestionsgetSuggestedReplacementsOrBuilder(int index) new and extended suggestions; overwrite any values set in suggestionsList<? extends MLServerProto.SuggestedReplacementOrBuilder> new and extended suggestions; overwrite any values set in suggestionsgetSuggestions(int index) legacy; use suggestedReplacementscom.google.protobuf.ByteStringgetSuggestionsBytes(int index) legacy; use suggestedReplacementsintlegacy; use suggestedReplacementslegacy; use suggestedReplacementsgetType().lt_ml_server.Match.MatchType type = 12;int.lt_ml_server.Match.MatchType type = 12;getUrl()to show a link, e.g.com.google.protobuf.ByteStringto show a link, e.g.booleanhasRule().lt_ml_server.Rule rule = 14;Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
isInitializedMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getOffset
int getOffset()start position in the sentence (i.e. not relative to whole text)
uint32 offset = 1;- Returns:
- The offset.
-
getLength
int getLength()length of matched area; >0
uint32 length = 2;- Returns:
- The length.
-
getId
String getId()prefix for rule ids; should use a common value for one model/server
string id = 3;- Returns:
- The id.
-
getIdBytes
com.google.protobuf.ByteString getIdBytes()prefix for rule ids; should use a common value for one model/server
string id = 3;- Returns:
- The bytes for id.
-
getSubId
String getSubId()more specific suffix for rule ids; i.e. one model/server can return multiple values to distinguish between mach types
string sub_id = 4;- Returns:
- The subId.
-
getSubIdBytes
com.google.protobuf.ByteString getSubIdBytes()more specific suffix for rule ids; i.e. one model/server can return multiple values to distinguish between mach types
string sub_id = 4;- Returns:
- The bytes for subId.
-
getSuggestionsList
legacy; use suggestedReplacements
repeated string suggestions = 5;- Returns:
- A list containing the suggestions.
-
getSuggestionsCount
int getSuggestionsCount()legacy; use suggestedReplacements
repeated string suggestions = 5;- Returns:
- The count of suggestions.
-
getSuggestions
legacy; use suggestedReplacements
repeated string suggestions = 5;- Parameters:
index- The index of the element to return.- Returns:
- The suggestions at the given index.
-
getSuggestionsBytes
com.google.protobuf.ByteString getSuggestionsBytes(int index) legacy; use suggestedReplacements
repeated string suggestions = 5;- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the suggestions at the given index.
-
getRuleDescription
String getRuleDescription()added later, optional (can be substituted by Java)
string ruleDescription = 6;- Returns:
- The ruleDescription.
-
getRuleDescriptionBytes
com.google.protobuf.ByteString getRuleDescriptionBytes()added later, optional (can be substituted by Java)
string ruleDescription = 6;- Returns:
- The bytes for ruleDescription.
-
getMatchDescription
String getMatchDescription()description of the match; displayed in e.g. the add-on pop-up
string matchDescription = 7;- Returns:
- The matchDescription.
-
getMatchDescriptionBytes
com.google.protobuf.ByteString getMatchDescriptionBytes()description of the match; displayed in e.g. the add-on pop-up
string matchDescription = 7;- Returns:
- The bytes for matchDescription.
-
getMatchShortDescription
String getMatchShortDescription()shortened description of the match; displayed in e.g. LibreOffice context menu
string matchShortDescription = 8;- Returns:
- The matchShortDescription.
-
getMatchShortDescriptionBytes
com.google.protobuf.ByteString getMatchShortDescriptionBytes()shortened description of the match; displayed in e.g. LibreOffice context menu
string matchShortDescription = 8;- Returns:
- The bytes for matchShortDescription.
-
getUrl
String getUrl()to show a link, e.g. with further explanations for this error
string url = 9;- Returns:
- The url.
-
getUrlBytes
com.google.protobuf.ByteString getUrlBytes()to show a link, e.g. with further explanations for this error
string url = 9;- Returns:
- The bytes for url.
-
getSuggestedReplacementsList
List<MLServerProto.SuggestedReplacement> getSuggestedReplacementsList()new and extended suggestions; overwrite any values set in suggestions
repeated .lt_ml_server.SuggestedReplacement suggestedReplacements = 10; -
getSuggestedReplacements
new and extended suggestions; overwrite any values set in suggestions
repeated .lt_ml_server.SuggestedReplacement suggestedReplacements = 10; -
getSuggestedReplacementsCount
int getSuggestedReplacementsCount()new and extended suggestions; overwrite any values set in suggestions
repeated .lt_ml_server.SuggestedReplacement suggestedReplacements = 10; -
getSuggestedReplacementsOrBuilderList
List<? extends MLServerProto.SuggestedReplacementOrBuilder> getSuggestedReplacementsOrBuilderList()new and extended suggestions; overwrite any values set in suggestions
repeated .lt_ml_server.SuggestedReplacement suggestedReplacements = 10; -
getSuggestedReplacementsOrBuilder
new and extended suggestions; overwrite any values set in suggestions
repeated .lt_ml_server.SuggestedReplacement suggestedReplacements = 10; -
getAutoCorrect
boolean getAutoCorrect()is this correction eligible for auto-correction?
bool autoCorrect = 11;- Returns:
- The autoCorrect.
-
getTypeValue
int getTypeValue().lt_ml_server.Match.MatchType type = 12;- Returns:
- The enum numeric value on the wire for type.
-
getType
MLServerProto.Match.MatchType getType().lt_ml_server.Match.MatchType type = 12;- Returns:
- The type.
-
getContextForSureMatch
int getContextForSureMatch()sint32 contextForSureMatch = 13;- Returns:
- The contextForSureMatch.
-
hasRule
boolean hasRule().lt_ml_server.Rule rule = 14;- Returns:
- Whether the rule field is set.
-
getRule
MLServerProto.Rule getRule().lt_ml_server.Rule rule = 14;- Returns:
- The rule.
-
getRuleOrBuilder
MLServerProto.RuleOrBuilder getRuleOrBuilder().lt_ml_server.Rule rule = 14;
-