diff --git a/lib/Cargo.toml b/lib/Cargo.toml index 1ad28f2b..482a210d 100644 --- a/lib/Cargo.toml +++ b/lib/Cargo.toml @@ -18,7 +18,6 @@ rocksdb = { version = "0.13", optional = true } byteorder = { version = "1", features = ["i128"] } quick-xml = "0.17" num-traits = "0.2" -chrono = "0.4" rand = "0.7" md-5 = "0.8" sha-1 = "0.8" @@ -26,10 +25,11 @@ sha2 = "0.8" digest = "0.8" failure = "0.1" regex = "1" -rio_api = "0.4" -rio_turtle = "0.4" -rio_xml = "0.4" +rio_api = "0.3" +rio_turtle = "0.3" +rio_xml = "0.3" hex = "0.4" +nom = "5" [dev-dependencies] rayon = "1" diff --git a/lib/src/model/literal.rs b/lib/src/model/literal.rs index bd52cefc..b2c0c4d8 100644 --- a/lib/src/model/literal.rs +++ b/lib/src/model/literal.rs @@ -1,8 +1,7 @@ use crate::model::named_node::NamedNode; use crate::model::vocab::rdf; use crate::model::vocab::xsd; -use crate::model::xsd::Decimal; -use chrono::prelude::*; +use crate::model::xsd::*; use rio_api::model as rio; use std::borrow::Cow; use std::fmt; @@ -237,8 +236,8 @@ impl From for Literal { } } -impl From> for Literal { - fn from(value: Date) -> Self { +impl From for Literal { + fn from(value: Date) -> Self { Literal(LiteralContent::TypedLiteral { value: value.to_string(), datatype: xsd::DATE.clone(), @@ -246,17 +245,8 @@ impl From> for Literal { } } -impl From for Literal { - fn from(value: NaiveDate) -> Self { - Literal(LiteralContent::TypedLiteral { - value: value.to_string(), - datatype: xsd::DATE.clone(), - }) - } -} - -impl From for Literal { - fn from(value: NaiveTime) -> Self { +impl From