atproto blogging
1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: tools.ozone.verification.defs
4//
5// This file was automatically generated from Lexicon schemas.
6// Any manual changes will be overwritten on the next regeneration.
7
8pub mod grant_verifications;
9pub mod list_verifications;
10pub mod revoke_verifications;
11
12/// Verification data for the associated subject.
13#[jacquard_derive::lexicon]
14#[derive(
15 serde::Serialize,
16 serde::Deserialize,
17 Debug,
18 Clone,
19 PartialEq,
20 Eq,
21 jacquard_derive::IntoStatic
22)]
23#[serde(rename_all = "camelCase")]
24pub struct VerificationView<'a> {
25 /// Timestamp when the verification was created.
26 pub created_at: jacquard_common::types::string::Datetime,
27 /// Display name of the subject the verification applies to at the moment of verifying, which might not be the same at the time of viewing. The verification is only valid if the current displayName matches the one at the time of verifying.
28 #[serde(borrow)]
29 pub display_name: jacquard_common::CowStr<'a>,
30 /// Handle of the subject the verification applies to at the moment of verifying, which might not be the same at the time of viewing. The verification is only valid if the current handle matches the one at the time of verifying.
31 #[serde(borrow)]
32 pub handle: jacquard_common::types::string::Handle<'a>,
33 /// The user who issued this verification.
34 #[serde(borrow)]
35 pub issuer: jacquard_common::types::string::Did<'a>,
36 #[serde(skip_serializing_if = "std::option::Option::is_none")]
37 #[serde(borrow)]
38 pub issuer_profile: std::option::Option<jacquard_common::types::value::Data<'a>>,
39 #[serde(skip_serializing_if = "std::option::Option::is_none")]
40 #[serde(borrow)]
41 pub issuer_repo: std::option::Option<VerificationViewIssuerRepo<'a>>,
42 /// Describes the reason for revocation, also indicating that the verification is no longer valid.
43 #[serde(skip_serializing_if = "std::option::Option::is_none")]
44 #[serde(borrow)]
45 pub revoke_reason: std::option::Option<jacquard_common::CowStr<'a>>,
46 /// Timestamp when the verification was revoked.
47 #[serde(skip_serializing_if = "std::option::Option::is_none")]
48 pub revoked_at: std::option::Option<jacquard_common::types::string::Datetime>,
49 /// The user who revoked this verification.
50 #[serde(skip_serializing_if = "std::option::Option::is_none")]
51 #[serde(borrow)]
52 pub revoked_by: std::option::Option<jacquard_common::types::string::Did<'a>>,
53 /// The subject of the verification.
54 #[serde(borrow)]
55 pub subject: jacquard_common::types::string::Did<'a>,
56 #[serde(skip_serializing_if = "std::option::Option::is_none")]
57 #[serde(borrow)]
58 pub subject_profile: std::option::Option<jacquard_common::types::value::Data<'a>>,
59 #[serde(skip_serializing_if = "std::option::Option::is_none")]
60 #[serde(borrow)]
61 pub subject_repo: std::option::Option<VerificationViewSubjectRepo<'a>>,
62 /// The AT-URI of the verification record.
63 #[serde(borrow)]
64 pub uri: jacquard_common::types::string::AtUri<'a>,
65}
66
67pub mod verification_view_state {
68
69 pub use crate::builder_types::{Set, Unset, IsSet, IsUnset};
70 #[allow(unused)]
71 use ::core::marker::PhantomData;
72 mod sealed {
73 pub trait Sealed {}
74 }
75 /// State trait tracking which required fields have been set
76 pub trait State: sealed::Sealed {
77 type Handle;
78 type CreatedAt;
79 type Uri;
80 type DisplayName;
81 type Issuer;
82 type Subject;
83 }
84 /// Empty state - all required fields are unset
85 pub struct Empty(());
86 impl sealed::Sealed for Empty {}
87 impl State for Empty {
88 type Handle = Unset;
89 type CreatedAt = Unset;
90 type Uri = Unset;
91 type DisplayName = Unset;
92 type Issuer = Unset;
93 type Subject = Unset;
94 }
95 ///State transition - sets the `handle` field to Set
96 pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
97 impl<S: State> sealed::Sealed for SetHandle<S> {}
98 impl<S: State> State for SetHandle<S> {
99 type Handle = Set<members::handle>;
100 type CreatedAt = S::CreatedAt;
101 type Uri = S::Uri;
102 type DisplayName = S::DisplayName;
103 type Issuer = S::Issuer;
104 type Subject = S::Subject;
105 }
106 ///State transition - sets the `created_at` field to Set
107 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
108 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
109 impl<S: State> State for SetCreatedAt<S> {
110 type Handle = S::Handle;
111 type CreatedAt = Set<members::created_at>;
112 type Uri = S::Uri;
113 type DisplayName = S::DisplayName;
114 type Issuer = S::Issuer;
115 type Subject = S::Subject;
116 }
117 ///State transition - sets the `uri` field to Set
118 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
119 impl<S: State> sealed::Sealed for SetUri<S> {}
120 impl<S: State> State for SetUri<S> {
121 type Handle = S::Handle;
122 type CreatedAt = S::CreatedAt;
123 type Uri = Set<members::uri>;
124 type DisplayName = S::DisplayName;
125 type Issuer = S::Issuer;
126 type Subject = S::Subject;
127 }
128 ///State transition - sets the `display_name` field to Set
129 pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
130 impl<S: State> sealed::Sealed for SetDisplayName<S> {}
131 impl<S: State> State for SetDisplayName<S> {
132 type Handle = S::Handle;
133 type CreatedAt = S::CreatedAt;
134 type Uri = S::Uri;
135 type DisplayName = Set<members::display_name>;
136 type Issuer = S::Issuer;
137 type Subject = S::Subject;
138 }
139 ///State transition - sets the `issuer` field to Set
140 pub struct SetIssuer<S: State = Empty>(PhantomData<fn() -> S>);
141 impl<S: State> sealed::Sealed for SetIssuer<S> {}
142 impl<S: State> State for SetIssuer<S> {
143 type Handle = S::Handle;
144 type CreatedAt = S::CreatedAt;
145 type Uri = S::Uri;
146 type DisplayName = S::DisplayName;
147 type Issuer = Set<members::issuer>;
148 type Subject = S::Subject;
149 }
150 ///State transition - sets the `subject` field to Set
151 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
152 impl<S: State> sealed::Sealed for SetSubject<S> {}
153 impl<S: State> State for SetSubject<S> {
154 type Handle = S::Handle;
155 type CreatedAt = S::CreatedAt;
156 type Uri = S::Uri;
157 type DisplayName = S::DisplayName;
158 type Issuer = S::Issuer;
159 type Subject = Set<members::subject>;
160 }
161 /// Marker types for field names
162 #[allow(non_camel_case_types)]
163 pub mod members {
164 ///Marker type for the `handle` field
165 pub struct handle(());
166 ///Marker type for the `created_at` field
167 pub struct created_at(());
168 ///Marker type for the `uri` field
169 pub struct uri(());
170 ///Marker type for the `display_name` field
171 pub struct display_name(());
172 ///Marker type for the `issuer` field
173 pub struct issuer(());
174 ///Marker type for the `subject` field
175 pub struct subject(());
176 }
177}
178
179/// Builder for constructing an instance of this type
180pub struct VerificationViewBuilder<'a, S: verification_view_state::State> {
181 _phantom_state: ::core::marker::PhantomData<fn() -> S>,
182 __unsafe_private_named: (
183 ::core::option::Option<jacquard_common::types::string::Datetime>,
184 ::core::option::Option<jacquard_common::CowStr<'a>>,
185 ::core::option::Option<jacquard_common::types::string::Handle<'a>>,
186 ::core::option::Option<jacquard_common::types::string::Did<'a>>,
187 ::core::option::Option<jacquard_common::types::value::Data<'a>>,
188 ::core::option::Option<VerificationViewIssuerRepo<'a>>,
189 ::core::option::Option<jacquard_common::CowStr<'a>>,
190 ::core::option::Option<jacquard_common::types::string::Datetime>,
191 ::core::option::Option<jacquard_common::types::string::Did<'a>>,
192 ::core::option::Option<jacquard_common::types::string::Did<'a>>,
193 ::core::option::Option<jacquard_common::types::value::Data<'a>>,
194 ::core::option::Option<VerificationViewSubjectRepo<'a>>,
195 ::core::option::Option<jacquard_common::types::string::AtUri<'a>>,
196 ),
197 _phantom: ::core::marker::PhantomData<&'a ()>,
198}
199
200impl<'a> VerificationView<'a> {
201 /// Create a new builder for this type
202 pub fn new() -> VerificationViewBuilder<'a, verification_view_state::Empty> {
203 VerificationViewBuilder::new()
204 }
205}
206
207impl<'a> VerificationViewBuilder<'a, verification_view_state::Empty> {
208 /// Create a new builder with all fields unset
209 pub fn new() -> Self {
210 VerificationViewBuilder {
211 _phantom_state: ::core::marker::PhantomData,
212 __unsafe_private_named: (
213 None,
214 None,
215 None,
216 None,
217 None,
218 None,
219 None,
220 None,
221 None,
222 None,
223 None,
224 None,
225 None,
226 ),
227 _phantom: ::core::marker::PhantomData,
228 }
229 }
230}
231
232impl<'a, S> VerificationViewBuilder<'a, S>
233where
234 S: verification_view_state::State,
235 S::CreatedAt: verification_view_state::IsUnset,
236{
237 /// Set the `createdAt` field (required)
238 pub fn created_at(
239 mut self,
240 value: impl Into<jacquard_common::types::string::Datetime>,
241 ) -> VerificationViewBuilder<'a, verification_view_state::SetCreatedAt<S>> {
242 self.__unsafe_private_named.0 = ::core::option::Option::Some(value.into());
243 VerificationViewBuilder {
244 _phantom_state: ::core::marker::PhantomData,
245 __unsafe_private_named: self.__unsafe_private_named,
246 _phantom: ::core::marker::PhantomData,
247 }
248 }
249}
250
251impl<'a, S> VerificationViewBuilder<'a, S>
252where
253 S: verification_view_state::State,
254 S::DisplayName: verification_view_state::IsUnset,
255{
256 /// Set the `displayName` field (required)
257 pub fn display_name(
258 mut self,
259 value: impl Into<jacquard_common::CowStr<'a>>,
260 ) -> VerificationViewBuilder<'a, verification_view_state::SetDisplayName<S>> {
261 self.__unsafe_private_named.1 = ::core::option::Option::Some(value.into());
262 VerificationViewBuilder {
263 _phantom_state: ::core::marker::PhantomData,
264 __unsafe_private_named: self.__unsafe_private_named,
265 _phantom: ::core::marker::PhantomData,
266 }
267 }
268}
269
270impl<'a, S> VerificationViewBuilder<'a, S>
271where
272 S: verification_view_state::State,
273 S::Handle: verification_view_state::IsUnset,
274{
275 /// Set the `handle` field (required)
276 pub fn handle(
277 mut self,
278 value: impl Into<jacquard_common::types::string::Handle<'a>>,
279 ) -> VerificationViewBuilder<'a, verification_view_state::SetHandle<S>> {
280 self.__unsafe_private_named.2 = ::core::option::Option::Some(value.into());
281 VerificationViewBuilder {
282 _phantom_state: ::core::marker::PhantomData,
283 __unsafe_private_named: self.__unsafe_private_named,
284 _phantom: ::core::marker::PhantomData,
285 }
286 }
287}
288
289impl<'a, S> VerificationViewBuilder<'a, S>
290where
291 S: verification_view_state::State,
292 S::Issuer: verification_view_state::IsUnset,
293{
294 /// Set the `issuer` field (required)
295 pub fn issuer(
296 mut self,
297 value: impl Into<jacquard_common::types::string::Did<'a>>,
298 ) -> VerificationViewBuilder<'a, verification_view_state::SetIssuer<S>> {
299 self.__unsafe_private_named.3 = ::core::option::Option::Some(value.into());
300 VerificationViewBuilder {
301 _phantom_state: ::core::marker::PhantomData,
302 __unsafe_private_named: self.__unsafe_private_named,
303 _phantom: ::core::marker::PhantomData,
304 }
305 }
306}
307
308impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
309 /// Set the `issuerProfile` field (optional)
310 pub fn issuer_profile(
311 mut self,
312 value: impl Into<Option<jacquard_common::types::value::Data<'a>>>,
313 ) -> Self {
314 self.__unsafe_private_named.4 = value.into();
315 self
316 }
317 /// Set the `issuerProfile` field to an Option value (optional)
318 pub fn maybe_issuer_profile(
319 mut self,
320 value: Option<jacquard_common::types::value::Data<'a>>,
321 ) -> Self {
322 self.__unsafe_private_named.4 = value;
323 self
324 }
325}
326
327impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
328 /// Set the `issuerRepo` field (optional)
329 pub fn issuer_repo(
330 mut self,
331 value: impl Into<Option<VerificationViewIssuerRepo<'a>>>,
332 ) -> Self {
333 self.__unsafe_private_named.5 = value.into();
334 self
335 }
336 /// Set the `issuerRepo` field to an Option value (optional)
337 pub fn maybe_issuer_repo(
338 mut self,
339 value: Option<VerificationViewIssuerRepo<'a>>,
340 ) -> Self {
341 self.__unsafe_private_named.5 = value;
342 self
343 }
344}
345
346impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
347 /// Set the `revokeReason` field (optional)
348 pub fn revoke_reason(
349 mut self,
350 value: impl Into<Option<jacquard_common::CowStr<'a>>>,
351 ) -> Self {
352 self.__unsafe_private_named.6 = value.into();
353 self
354 }
355 /// Set the `revokeReason` field to an Option value (optional)
356 pub fn maybe_revoke_reason(
357 mut self,
358 value: Option<jacquard_common::CowStr<'a>>,
359 ) -> Self {
360 self.__unsafe_private_named.6 = value;
361 self
362 }
363}
364
365impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
366 /// Set the `revokedAt` field (optional)
367 pub fn revoked_at(
368 mut self,
369 value: impl Into<Option<jacquard_common::types::string::Datetime>>,
370 ) -> Self {
371 self.__unsafe_private_named.7 = value.into();
372 self
373 }
374 /// Set the `revokedAt` field to an Option value (optional)
375 pub fn maybe_revoked_at(
376 mut self,
377 value: Option<jacquard_common::types::string::Datetime>,
378 ) -> Self {
379 self.__unsafe_private_named.7 = value;
380 self
381 }
382}
383
384impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
385 /// Set the `revokedBy` field (optional)
386 pub fn revoked_by(
387 mut self,
388 value: impl Into<Option<jacquard_common::types::string::Did<'a>>>,
389 ) -> Self {
390 self.__unsafe_private_named.8 = value.into();
391 self
392 }
393 /// Set the `revokedBy` field to an Option value (optional)
394 pub fn maybe_revoked_by(
395 mut self,
396 value: Option<jacquard_common::types::string::Did<'a>>,
397 ) -> Self {
398 self.__unsafe_private_named.8 = value;
399 self
400 }
401}
402
403impl<'a, S> VerificationViewBuilder<'a, S>
404where
405 S: verification_view_state::State,
406 S::Subject: verification_view_state::IsUnset,
407{
408 /// Set the `subject` field (required)
409 pub fn subject(
410 mut self,
411 value: impl Into<jacquard_common::types::string::Did<'a>>,
412 ) -> VerificationViewBuilder<'a, verification_view_state::SetSubject<S>> {
413 self.__unsafe_private_named.9 = ::core::option::Option::Some(value.into());
414 VerificationViewBuilder {
415 _phantom_state: ::core::marker::PhantomData,
416 __unsafe_private_named: self.__unsafe_private_named,
417 _phantom: ::core::marker::PhantomData,
418 }
419 }
420}
421
422impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
423 /// Set the `subjectProfile` field (optional)
424 pub fn subject_profile(
425 mut self,
426 value: impl Into<Option<jacquard_common::types::value::Data<'a>>>,
427 ) -> Self {
428 self.__unsafe_private_named.10 = value.into();
429 self
430 }
431 /// Set the `subjectProfile` field to an Option value (optional)
432 pub fn maybe_subject_profile(
433 mut self,
434 value: Option<jacquard_common::types::value::Data<'a>>,
435 ) -> Self {
436 self.__unsafe_private_named.10 = value;
437 self
438 }
439}
440
441impl<'a, S: verification_view_state::State> VerificationViewBuilder<'a, S> {
442 /// Set the `subjectRepo` field (optional)
443 pub fn subject_repo(
444 mut self,
445 value: impl Into<Option<VerificationViewSubjectRepo<'a>>>,
446 ) -> Self {
447 self.__unsafe_private_named.11 = value.into();
448 self
449 }
450 /// Set the `subjectRepo` field to an Option value (optional)
451 pub fn maybe_subject_repo(
452 mut self,
453 value: Option<VerificationViewSubjectRepo<'a>>,
454 ) -> Self {
455 self.__unsafe_private_named.11 = value;
456 self
457 }
458}
459
460impl<'a, S> VerificationViewBuilder<'a, S>
461where
462 S: verification_view_state::State,
463 S::Uri: verification_view_state::IsUnset,
464{
465 /// Set the `uri` field (required)
466 pub fn uri(
467 mut self,
468 value: impl Into<jacquard_common::types::string::AtUri<'a>>,
469 ) -> VerificationViewBuilder<'a, verification_view_state::SetUri<S>> {
470 self.__unsafe_private_named.12 = ::core::option::Option::Some(value.into());
471 VerificationViewBuilder {
472 _phantom_state: ::core::marker::PhantomData,
473 __unsafe_private_named: self.__unsafe_private_named,
474 _phantom: ::core::marker::PhantomData,
475 }
476 }
477}
478
479impl<'a, S> VerificationViewBuilder<'a, S>
480where
481 S: verification_view_state::State,
482 S::Handle: verification_view_state::IsSet,
483 S::CreatedAt: verification_view_state::IsSet,
484 S::Uri: verification_view_state::IsSet,
485 S::DisplayName: verification_view_state::IsSet,
486 S::Issuer: verification_view_state::IsSet,
487 S::Subject: verification_view_state::IsSet,
488{
489 /// Build the final struct
490 pub fn build(self) -> VerificationView<'a> {
491 VerificationView {
492 created_at: self.__unsafe_private_named.0.unwrap(),
493 display_name: self.__unsafe_private_named.1.unwrap(),
494 handle: self.__unsafe_private_named.2.unwrap(),
495 issuer: self.__unsafe_private_named.3.unwrap(),
496 issuer_profile: self.__unsafe_private_named.4,
497 issuer_repo: self.__unsafe_private_named.5,
498 revoke_reason: self.__unsafe_private_named.6,
499 revoked_at: self.__unsafe_private_named.7,
500 revoked_by: self.__unsafe_private_named.8,
501 subject: self.__unsafe_private_named.9.unwrap(),
502 subject_profile: self.__unsafe_private_named.10,
503 subject_repo: self.__unsafe_private_named.11,
504 uri: self.__unsafe_private_named.12.unwrap(),
505 extra_data: Default::default(),
506 }
507 }
508 /// Build the final struct with custom extra_data
509 pub fn build_with_data(
510 self,
511 extra_data: std::collections::BTreeMap<
512 jacquard_common::smol_str::SmolStr,
513 jacquard_common::types::value::Data<'a>,
514 >,
515 ) -> VerificationView<'a> {
516 VerificationView {
517 created_at: self.__unsafe_private_named.0.unwrap(),
518 display_name: self.__unsafe_private_named.1.unwrap(),
519 handle: self.__unsafe_private_named.2.unwrap(),
520 issuer: self.__unsafe_private_named.3.unwrap(),
521 issuer_profile: self.__unsafe_private_named.4,
522 issuer_repo: self.__unsafe_private_named.5,
523 revoke_reason: self.__unsafe_private_named.6,
524 revoked_at: self.__unsafe_private_named.7,
525 revoked_by: self.__unsafe_private_named.8,
526 subject: self.__unsafe_private_named.9.unwrap(),
527 subject_profile: self.__unsafe_private_named.10,
528 subject_repo: self.__unsafe_private_named.11,
529 uri: self.__unsafe_private_named.12.unwrap(),
530 extra_data: Some(extra_data),
531 }
532 }
533}
534
535#[jacquard_derive::open_union]
536#[derive(
537 serde::Serialize,
538 serde::Deserialize,
539 Debug,
540 Clone,
541 PartialEq,
542 Eq,
543 jacquard_derive::IntoStatic
544)]
545#[serde(tag = "$type")]
546#[serde(bound(deserialize = "'de: 'a"))]
547pub enum VerificationViewIssuerRepo<'a> {
548 #[serde(rename = "tools.ozone.moderation.defs#repoViewDetail")]
549 RepoViewDetail(Box<crate::tools_ozone::moderation::RepoViewDetail<'a>>),
550 #[serde(rename = "tools.ozone.moderation.defs#repoViewNotFound")]
551 RepoViewNotFound(Box<crate::tools_ozone::moderation::RepoViewNotFound<'a>>),
552}
553
554#[jacquard_derive::open_union]
555#[derive(
556 serde::Serialize,
557 serde::Deserialize,
558 Debug,
559 Clone,
560 PartialEq,
561 Eq,
562 jacquard_derive::IntoStatic
563)]
564#[serde(tag = "$type")]
565#[serde(bound(deserialize = "'de: 'a"))]
566pub enum VerificationViewSubjectRepo<'a> {
567 #[serde(rename = "tools.ozone.moderation.defs#repoViewDetail")]
568 RepoViewDetail(Box<crate::tools_ozone::moderation::RepoViewDetail<'a>>),
569 #[serde(rename = "tools.ozone.moderation.defs#repoViewNotFound")]
570 RepoViewNotFound(Box<crate::tools_ozone::moderation::RepoViewNotFound<'a>>),
571}
572
573fn lexicon_doc_tools_ozone_verification_defs() -> ::jacquard_lexicon::lexicon::LexiconDoc<
574 'static,
575> {
576 ::jacquard_lexicon::lexicon::LexiconDoc {
577 lexicon: ::jacquard_lexicon::lexicon::Lexicon::Lexicon1,
578 id: ::jacquard_common::CowStr::new_static("tools.ozone.verification.defs"),
579 revision: None,
580 description: None,
581 defs: {
582 let mut map = ::alloc::collections::BTreeMap::new();
583 map.insert(
584 ::jacquard_common::smol_str::SmolStr::new_static("verificationView"),
585 ::jacquard_lexicon::lexicon::LexUserType::Object(::jacquard_lexicon::lexicon::LexObject {
586 description: Some(
587 ::jacquard_common::CowStr::new_static(
588 "Verification data for the associated subject.",
589 ),
590 ),
591 required: Some(
592 vec![
593 ::jacquard_common::smol_str::SmolStr::new_static("issuer"),
594 ::jacquard_common::smol_str::SmolStr::new_static("uri"),
595 ::jacquard_common::smol_str::SmolStr::new_static("subject"),
596 ::jacquard_common::smol_str::SmolStr::new_static("handle"),
597 ::jacquard_common::smol_str::SmolStr::new_static("displayName"),
598 ::jacquard_common::smol_str::SmolStr::new_static("createdAt")
599 ],
600 ),
601 nullable: None,
602 properties: {
603 #[allow(unused_mut)]
604 let mut map = ::alloc::collections::BTreeMap::new();
605 map.insert(
606 ::jacquard_common::smol_str::SmolStr::new_static(
607 "createdAt",
608 ),
609 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
610 description: Some(
611 ::jacquard_common::CowStr::new_static(
612 "Timestamp when the verification was created.",
613 ),
614 ),
615 format: Some(
616 ::jacquard_lexicon::lexicon::LexStringFormat::Datetime,
617 ),
618 default: None,
619 min_length: None,
620 max_length: None,
621 min_graphemes: None,
622 max_graphemes: None,
623 r#enum: None,
624 r#const: None,
625 known_values: None,
626 }),
627 );
628 map.insert(
629 ::jacquard_common::smol_str::SmolStr::new_static(
630 "displayName",
631 ),
632 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
633 description: Some(
634 ::jacquard_common::CowStr::new_static(
635 "Display name of the subject the verification applies to at the moment of verifying, which might not be the same at the time of viewing. The verification is only valid if the current displayName matches the one at the time of verifying.",
636 ),
637 ),
638 format: None,
639 default: None,
640 min_length: None,
641 max_length: None,
642 min_graphemes: None,
643 max_graphemes: None,
644 r#enum: None,
645 r#const: None,
646 known_values: None,
647 }),
648 );
649 map.insert(
650 ::jacquard_common::smol_str::SmolStr::new_static("handle"),
651 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
652 description: Some(
653 ::jacquard_common::CowStr::new_static(
654 "Handle of the subject the verification applies to at the moment of verifying, which might not be the same at the time of viewing. The verification is only valid if the current handle matches the one at the time of verifying.",
655 ),
656 ),
657 format: Some(
658 ::jacquard_lexicon::lexicon::LexStringFormat::Handle,
659 ),
660 default: None,
661 min_length: None,
662 max_length: None,
663 min_graphemes: None,
664 max_graphemes: None,
665 r#enum: None,
666 r#const: None,
667 known_values: None,
668 }),
669 );
670 map.insert(
671 ::jacquard_common::smol_str::SmolStr::new_static("issuer"),
672 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
673 description: Some(
674 ::jacquard_common::CowStr::new_static(
675 "The user who issued this verification.",
676 ),
677 ),
678 format: Some(
679 ::jacquard_lexicon::lexicon::LexStringFormat::Did,
680 ),
681 default: None,
682 min_length: None,
683 max_length: None,
684 min_graphemes: None,
685 max_graphemes: None,
686 r#enum: None,
687 r#const: None,
688 known_values: None,
689 }),
690 );
691 map.insert(
692 ::jacquard_common::smol_str::SmolStr::new_static(
693 "issuerProfile",
694 ),
695 ::jacquard_lexicon::lexicon::LexObjectProperty::Union(::jacquard_lexicon::lexicon::LexRefUnion {
696 description: None,
697 refs: vec![],
698 closed: None,
699 }),
700 );
701 map.insert(
702 ::jacquard_common::smol_str::SmolStr::new_static(
703 "issuerRepo",
704 ),
705 ::jacquard_lexicon::lexicon::LexObjectProperty::Union(::jacquard_lexicon::lexicon::LexRefUnion {
706 description: None,
707 refs: vec![
708 ::jacquard_common::CowStr::new_static("tools.ozone.moderation.defs#repoViewDetail"),
709 ::jacquard_common::CowStr::new_static("tools.ozone.moderation.defs#repoViewNotFound")
710 ],
711 closed: None,
712 }),
713 );
714 map.insert(
715 ::jacquard_common::smol_str::SmolStr::new_static(
716 "revokeReason",
717 ),
718 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
719 description: Some(
720 ::jacquard_common::CowStr::new_static(
721 "Describes the reason for revocation, also indicating that the verification is no longer valid.",
722 ),
723 ),
724 format: None,
725 default: None,
726 min_length: None,
727 max_length: None,
728 min_graphemes: None,
729 max_graphemes: None,
730 r#enum: None,
731 r#const: None,
732 known_values: None,
733 }),
734 );
735 map.insert(
736 ::jacquard_common::smol_str::SmolStr::new_static(
737 "revokedAt",
738 ),
739 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
740 description: Some(
741 ::jacquard_common::CowStr::new_static(
742 "Timestamp when the verification was revoked.",
743 ),
744 ),
745 format: Some(
746 ::jacquard_lexicon::lexicon::LexStringFormat::Datetime,
747 ),
748 default: None,
749 min_length: None,
750 max_length: None,
751 min_graphemes: None,
752 max_graphemes: None,
753 r#enum: None,
754 r#const: None,
755 known_values: None,
756 }),
757 );
758 map.insert(
759 ::jacquard_common::smol_str::SmolStr::new_static(
760 "revokedBy",
761 ),
762 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
763 description: Some(
764 ::jacquard_common::CowStr::new_static(
765 "The user who revoked this verification.",
766 ),
767 ),
768 format: Some(
769 ::jacquard_lexicon::lexicon::LexStringFormat::Did,
770 ),
771 default: None,
772 min_length: None,
773 max_length: None,
774 min_graphemes: None,
775 max_graphemes: None,
776 r#enum: None,
777 r#const: None,
778 known_values: None,
779 }),
780 );
781 map.insert(
782 ::jacquard_common::smol_str::SmolStr::new_static("subject"),
783 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
784 description: Some(
785 ::jacquard_common::CowStr::new_static(
786 "The subject of the verification.",
787 ),
788 ),
789 format: Some(
790 ::jacquard_lexicon::lexicon::LexStringFormat::Did,
791 ),
792 default: None,
793 min_length: None,
794 max_length: None,
795 min_graphemes: None,
796 max_graphemes: None,
797 r#enum: None,
798 r#const: None,
799 known_values: None,
800 }),
801 );
802 map.insert(
803 ::jacquard_common::smol_str::SmolStr::new_static(
804 "subjectProfile",
805 ),
806 ::jacquard_lexicon::lexicon::LexObjectProperty::Union(::jacquard_lexicon::lexicon::LexRefUnion {
807 description: None,
808 refs: vec![],
809 closed: None,
810 }),
811 );
812 map.insert(
813 ::jacquard_common::smol_str::SmolStr::new_static(
814 "subjectRepo",
815 ),
816 ::jacquard_lexicon::lexicon::LexObjectProperty::Union(::jacquard_lexicon::lexicon::LexRefUnion {
817 description: None,
818 refs: vec![
819 ::jacquard_common::CowStr::new_static("tools.ozone.moderation.defs#repoViewDetail"),
820 ::jacquard_common::CowStr::new_static("tools.ozone.moderation.defs#repoViewNotFound")
821 ],
822 closed: None,
823 }),
824 );
825 map.insert(
826 ::jacquard_common::smol_str::SmolStr::new_static("uri"),
827 ::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
828 description: Some(
829 ::jacquard_common::CowStr::new_static(
830 "The AT-URI of the verification record.",
831 ),
832 ),
833 format: Some(
834 ::jacquard_lexicon::lexicon::LexStringFormat::AtUri,
835 ),
836 default: None,
837 min_length: None,
838 max_length: None,
839 min_graphemes: None,
840 max_graphemes: None,
841 r#enum: None,
842 r#const: None,
843 known_values: None,
844 }),
845 );
846 map
847 },
848 }),
849 );
850 map
851 },
852 }
853}
854
855impl<'a> ::jacquard_lexicon::schema::LexiconSchema for VerificationView<'a> {
856 fn nsid() -> &'static str {
857 "tools.ozone.verification.defs"
858 }
859 fn def_name() -> &'static str {
860 "verificationView"
861 }
862 fn lexicon_doc() -> ::jacquard_lexicon::lexicon::LexiconDoc<'static> {
863 lexicon_doc_tools_ozone_verification_defs()
864 }
865 fn validate(
866 &self,
867 ) -> ::core::result::Result<(), ::jacquard_lexicon::validation::ConstraintError> {
868 Ok(())
869 }
870}