Assorted tweaks to support external playground crate (#322)
* Assorted tweaks to support external playground crate * Fix schemas * Fixed schema again * Add ToHex for RawValue * Add FromHex to RawValue
This commit is contained in:
parent
335100d1d7
commit
24cafde231
10 changed files with 111 additions and 46 deletions
|
|
@ -50,7 +50,7 @@ impl ToFields for NativePredicate {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, JsonSchema)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)]
|
||||
#[serde(tag = "type", content = "value")]
|
||||
pub enum Predicate {
|
||||
Native(NativePredicate),
|
||||
|
|
@ -129,7 +129,7 @@ impl fmt::Display for Predicate {
|
|||
}
|
||||
|
||||
/// Type encapsulating statements with their associated arguments.
|
||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, JsonSchema)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)]
|
||||
#[serde(tag = "predicate", content = "args")]
|
||||
pub enum Statement {
|
||||
None,
|
||||
|
|
@ -368,7 +368,8 @@ impl ToFields for StatementArg {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, JsonSchema)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)]
|
||||
#[serde(tag = "type", content = "value")]
|
||||
pub enum ValueRef {
|
||||
Literal(Value),
|
||||
Key(AnchoredKey),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue