Instance Method

setLanguage(_:range:)

Sets the language for a range of text within the tagger's string.

Declaration

@nonobjc func setLanguage(_ language: NLLanguage, range: Range<String.Index>)

Parameters

language

The language of the text range.

range

The range of the string that is being assigned a language.

See Also

Determining the Dominant Language and Orthography

var dominantLanguage: NLLanguage?

The dominant language of the string set for the linguistic tagger.

func setOrthography(NSOrthography, range: Range<String.Index>)

Sets the orthography for the specified range.