mirror of
https://codeberg.org/demostf/parser.git
synced 2026-06-03 10:14:06 +02:00
update schemars to 1.0
This commit is contained in:
parent
6143e0289b
commit
b500fe772a
5 changed files with 11641 additions and 8280 deletions
|
|
@ -125,11 +125,11 @@ impl<'de> Deserialize<'de> for MaybeUtf8String {
|
|||
|
||||
#[cfg(feature = "schema")]
|
||||
impl schemars::JsonSchema for MaybeUtf8String {
|
||||
fn schema_name() -> String {
|
||||
fn schema_name() -> std::borrow::Cow<'static, str> {
|
||||
String::schema_name()
|
||||
}
|
||||
|
||||
fn json_schema(gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
||||
fn json_schema(gen: &mut schemars::SchemaGenerator) -> schemars::Schema {
|
||||
String::json_schema(gen)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -332,11 +332,11 @@ pub struct SendPropFlags(BitFlags<SendPropFlag>);
|
|||
|
||||
#[cfg(feature = "schemars")]
|
||||
impl schemars::JsonSchema for SendPropFlags {
|
||||
fn schema_name() -> String {
|
||||
fn schema_name() -> std::borrow::Cow<'static, str> {
|
||||
"SendPropFlags".into()
|
||||
}
|
||||
|
||||
fn json_schema(gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
||||
fn json_schema(gen: &mut schemars::SchemaGenerator) -> schemars::Schema {
|
||||
u16::json_schema(gen)
|
||||
}
|
||||
}
|
||||
|
|
@ -1240,11 +1240,11 @@ impl Serialize for SendPropIdentifier {
|
|||
|
||||
#[cfg(feature = "schema")]
|
||||
impl schemars::JsonSchema for SendPropIdentifier {
|
||||
fn schema_name() -> String {
|
||||
fn schema_name() -> std::borrow::Cow<'static, str> {
|
||||
"SendPropIdentifier".into()
|
||||
}
|
||||
|
||||
fn json_schema(gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
||||
fn json_schema(gen: &mut schemars::SchemaGenerator) -> schemars::Schema {
|
||||
<String as schemars::JsonSchema>::json_schema(gen)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue