A pluggable language-scoring strategy.
LanguageDetector.pureDart supplies the built-in script + n-gram
implementation (CompositeBackend); custom backends — test doubles, or a
future model-backed detector — can implement this directly and be passed
to LanguageDetector's primary constructor.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
supportedLanguages
→ Set<
String> -
The language codes this backend can ever return from score.
no setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
score(
String text) → List< LanguageGuess> -
Scores
textagainst every language in supportedLanguages. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited