Rename RDF.Serialization behaviour to RDF.Serialization.Format
This commit is contained in:
parent
7753d0d6f7
commit
7314f2d643
8 changed files with 17 additions and 12 deletions
|
@ -7,9 +7,14 @@ This project adheres to [Semantic Versioning](http://semver.org/) and
|
||||||
|
|
||||||
## Unreleased
|
## Unreleased
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- rename `RDF.Serialization` behaviour to `RDF.Serialization.Format`
|
||||||
|
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
- `RDF.Serialization`s define an atom name
|
- `RDF.Serialization.Format`s define an atom name
|
||||||
|
|
||||||
|
|
||||||
[Compare v0.3.1...HEAD](https://github.com/marcelotto/rdf-ex/compare/v0.3.1...HEAD)
|
[Compare v0.3.1...HEAD](https://github.com/marcelotto/rdf-ex/compare/v0.3.1...HEAD)
|
||||||
|
|
|
@ -683,7 +683,7 @@ iex> RDF.list(["foo", EX.Bar, ~B<bar>, [1, 2]]) |> RDF.List.values
|
||||||
|
|
||||||
### Serializations
|
### Serializations
|
||||||
|
|
||||||
RDF graphs and datasets can be read and written to files or strings in a RDF serialization format using the `read_file`, `read_string` and `write_file`, `write_string` functions of the resp. `RDF.Serialization` module.
|
RDF graphs and datasets can be read and written to files or strings in a RDF serialization format using the `read_file`, `read_string` and `write_file`, `write_string` functions of the resp. `RDF.Serialization.Format` module.
|
||||||
|
|
||||||
```elixir
|
```elixir
|
||||||
{:ok, graph} = RDF.NTriples.read_file("/path/to/some_file.nt")
|
{:ok, graph} = RDF.NTriples.read_file("/path/to/some_file.nt")
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
defmodule RDF.Serialization do
|
defmodule RDF.Serialization.Format do
|
||||||
@moduledoc """
|
@moduledoc """
|
||||||
A behaviour for RDF serialization formats.
|
A behaviour for RDF serialization formats.
|
||||||
|
|
|
@ -13,7 +13,7 @@ defmodule RDF.NQuads do
|
||||||
see <https://www.w3.org/TR/n-quads/>
|
see <https://www.w3.org/TR/n-quads/>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
use RDF.Serialization
|
use RDF.Serialization.Format
|
||||||
|
|
||||||
import RDF.Sigils
|
import RDF.Sigils
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@ defmodule RDF.NTriples do
|
||||||
see <https://www.w3.org/TR/n-triples/>
|
see <https://www.w3.org/TR/n-triples/>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
use RDF.Serialization
|
use RDF.Serialization.Format
|
||||||
|
|
||||||
import RDF.Sigils
|
import RDF.Sigils
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ defmodule RDF.Turtle do
|
||||||
see <https://www.w3.org/TR/turtle/>
|
see <https://www.w3.org/TR/turtle/>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
use RDF.Serialization
|
use RDF.Serialization.Format
|
||||||
|
|
||||||
import RDF.Sigils
|
import RDF.Sigils
|
||||||
|
|
||||||
|
|
6
test/unit/serialization/format_test.exs
Normal file
6
test/unit/serialization/format_test.exs
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
defmodule RDF.Serialization.FormatTest do
|
||||||
|
use ExUnit.Case
|
||||||
|
|
||||||
|
doctest RDF.Serialization.Format
|
||||||
|
|
||||||
|
end
|
|
@ -1,6 +0,0 @@
|
||||||
defmodule RDF.SerializationTest do
|
|
||||||
use ExUnit.Case
|
|
||||||
|
|
||||||
doctest RDF.Serialization
|
|
||||||
|
|
||||||
end
|
|
Loading…
Reference in a new issue