XEts.match_object
You're seeing just the function
match_object
, go back to XEts module for more information.
Link to this function
match_object(tab, pattern)
Specs
Match an item in the table.
Examples
iex> tab = XEts.new(:table) |> XEts.insert(x: 1, y: 2)
iex> tab |> XEts.match_object({:x, :_})
[{:x, 1}]
iex> tab |> XEts.match_object({:_, 2})
[{:y, 2}]
Link to this function
match_object(tab, pattern, limit_or_meta)
Specs
Match an item in the table given limit or metadata.
Examples
iex> tab = XEts.new(:table) |> XEts.insert(x: 1, y: 2, z: 3)
iex> tab |> XEts.match_object({:x, :_}, XEts.get_meta(tab))
[{:x, 1}]
iex> tab |> XEts.match_object(:_, 2) |> elem(0)
[{:y, 2}, {:z, 3}]
Link to this function
match_object(tab, pattern, limit, meta)
Specs
Match an item in the table given limit and metadata.
Examples
iex> tab = XEts.new(:table) |> XEts.insert(x: 1, y: 1, z: 1)
iex> tab |> XEts.match_object({:_, 1}, 2, XEts.get_meta(tab)) |> elem(0)
[{:y, 1}, {:z, 1}]