Essence.Document.context_of
You're seeing just the function
context_of
, go back to Essence.Document module for more information.
Link to this function
context_of(doc, token, n \\ 5)
Specs
context_of( doc :: %Essence.Document{ meta: term(), nested_tokens: term(), text: term(), type: term(), uri: term() }, token :: String.t(), n :: number() ) :: List.t()
For each occurrence of token
in the given Essence.Document
, doc
,
returns a list containing the token as well as n
(default=5) tokens to the left and
right of the occurrence.