Add RDF.BlankNode.value/1

This commit is contained in:
Marcel Otto 2020-11-01 02:26:18 +01:00
parent ddb3d365bc
commit 3041204ff7
2 changed files with 6 additions and 0 deletions

View file

@ -11,6 +11,7 @@ This project adheres to [Semantic Versioning](http://semver.org/) and
- `RDF.Dataset.prefixes/1` for getting an aggregated `RDF.PrefixMap` over all graphs
- `RDF.PrefixMap.put/3` for adding a prefix mapping and overwrite an existing one
- `RDF.BlankNode.value/1` for getting the internal string representation of a blank node
### Changed

View file

@ -40,6 +40,11 @@ defmodule RDF.BlankNode do
def new(value) when is_atom(value) or is_integer(value),
do: value |> to_string |> new
@doc """
Returns the internal string representation of a blank node.
"""
def value(%__MODULE__{} = bnode), do: bnode.value
@doc """
Tests for value equality of blank nodes.