View Source Ontogen.Agent (Ontogen v0.1.1)

Summary

Types

@type t() :: %Ontogen.Agent{
  __additional_statements__: term(),
  __id__: term(),
  email: term(),
  name: term()
}

Functions

Link to this function

deref!(ref, graph, opts \\ [])

View Source
@spec email(t()) :: String.t() | nil

Returns the email of an Ontogen agent.

Example

iex> Ontogen.Agent.build!(EX.Agent, email: ~I<mailto:agent@example.com>)
...> |> Ontogen.Agent.email()
"agent@example.com"

iex> Ontogen.Agent.build!(EX.Agent)
...> |> Ontogen.Agent.email()
nil
@spec from(Grax.Schema.t()) :: {:ok, t()} | {:error, any()}
@spec from!(Grax.Schema.t()) :: t()
Link to this function

load(graph, id, opts \\ [])

View Source
@spec load(
  RDF.Graph.t() | RDF.Description.t(),
  RDF.IRI.coercible() | RDF.BlankNode.t(),
  opts :: keyword()
) :: {:ok, t()} | {:error, any()}
Link to this function

load!(graph, id, opts \\ [])

View Source
@spec load!(
  RDF.Graph.t() | RDF.Description.t(),
  RDF.IRI.coercible() | RDF.BlankNode.t(),
  opts :: keyword()
) :: t()
Link to this function

this!(graph, opts \\ [])

View Source