mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-12-26 10:46:13 +00:00
07a48b9293
Co-authored-by: FloatingGhost <hannah@coffee-and-dreams.uk> Reviewed-on: https://akkoma.dev/AkkomaGang/akkoma/pulls/371
18 lines
631 B
Elixir
18 lines
631 B
Elixir
defmodule Pleroma.Search.SearchBackend do
|
|
@doc """
|
|
Add the object associated with the activity to the search index.
|
|
|
|
The whole activity is passed, to allow filtering on things such as scope.
|
|
"""
|
|
@callback add_to_index(activity :: Pleroma.Activity.t()) :: {:ok, any()} | {:error, any()}
|
|
|
|
@doc """
|
|
Remove the object from the index.
|
|
|
|
Just the object, as opposed to the whole activity, is passed, since the object
|
|
is what contains the actual content and there is no need for fitlering when removing
|
|
from index.
|
|
"""
|
|
@callback remove_from_index(object :: Pleroma.Object.t()) :: {:ok, any()} | {:error, any()}
|
|
end
|