···31373137 }
31383138 /// State trait tracking which required fields have been set
31393139 pub trait State: sealed::Sealed {
31403140- type Followers;
31413140 type Count;
31413141+ type Followers;
31423142 }
31433143 /// Empty state - all required fields are unset
31443144 pub struct Empty(());
31453145 impl sealed::Sealed for Empty {}
31463146 impl State for Empty {
31473147- type Followers = Unset;
31483147 type Count = Unset;
31493149- }
31503150- ///State transition - sets the `followers` field to Set
31513151- pub struct SetFollowers<S: State = Empty>(PhantomData<fn() -> S>);
31523152- impl<S: State> sealed::Sealed for SetFollowers<S> {}
31533153- impl<S: State> State for SetFollowers<S> {
31543154- type Followers = Set<members::followers>;
31553155- type Count = S::Count;
31483148+ type Followers = Unset;
31563149 }
31573150 ///State transition - sets the `count` field to Set
31583151 pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
31593152 impl<S: State> sealed::Sealed for SetCount<S> {}
31603153 impl<S: State> State for SetCount<S> {
31613161- type Followers = S::Followers;
31623154 type Count = Set<members::count>;
31553155+ type Followers = S::Followers;
31563156+ }
31573157+ ///State transition - sets the `followers` field to Set
31583158+ pub struct SetFollowers<S: State = Empty>(PhantomData<fn() -> S>);
31593159+ impl<S: State> sealed::Sealed for SetFollowers<S> {}
31603160+ impl<S: State> State for SetFollowers<S> {
31613161+ type Count = S::Count;
31623162+ type Followers = Set<members::followers>;
31633163 }
31643164 /// Marker types for field names
31653165 #[allow(non_camel_case_types)]
31663166 pub mod members {
31673167- ///Marker type for the `followers` field
31683168- pub struct followers(());
31693167 ///Marker type for the `count` field
31703168 pub struct count(());
31693169+ ///Marker type for the `followers` field
31703170+ pub struct followers(());
31713171 }
31723172}
31733173···32403240impl<'a, S> KnownFollowersBuilder<'a, S>
32413241where
32423242 S: known_followers_state::State,
32433243- S::Followers: known_followers_state::IsSet,
32443243 S::Count: known_followers_state::IsSet,
32443244+ S::Followers: known_followers_state::IsSet,
32453245{
32463246 /// Build the final struct
32473247 pub fn build(self) -> KnownFollowers<'a> {
···42154215 }
42164216 /// State trait tracking which required fields have been set
42174217 pub trait State: sealed::Sealed {
42184218- type Completed;
42194218 type Id;
42194219+ type Completed;
42204220 }
42214221 /// Empty state - all required fields are unset
42224222 pub struct Empty(());
42234223 impl sealed::Sealed for Empty {}
42244224 impl State for Empty {
42254225- type Completed = Unset;
42264225 type Id = Unset;
42274227- }
42284228- ///State transition - sets the `completed` field to Set
42294229- pub struct SetCompleted<S: State = Empty>(PhantomData<fn() -> S>);
42304230- impl<S: State> sealed::Sealed for SetCompleted<S> {}
42314231- impl<S: State> State for SetCompleted<S> {
42324232- type Completed = Set<members::completed>;
42334233- type Id = S::Id;
42264226+ type Completed = Unset;
42344227 }
42354228 ///State transition - sets the `id` field to Set
42364229 pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
42374230 impl<S: State> sealed::Sealed for SetId<S> {}
42384231 impl<S: State> State for SetId<S> {
42394239- type Completed = S::Completed;
42404232 type Id = Set<members::id>;
42334233+ type Completed = S::Completed;
42344234+ }
42354235+ ///State transition - sets the `completed` field to Set
42364236+ pub struct SetCompleted<S: State = Empty>(PhantomData<fn() -> S>);
42374237+ impl<S: State> sealed::Sealed for SetCompleted<S> {}
42384238+ impl<S: State> State for SetCompleted<S> {
42394239+ type Id = S::Id;
42404240+ type Completed = Set<members::completed>;
42414241 }
42424242 /// Marker types for field names
42434243 #[allow(non_camel_case_types)]
42444244 pub mod members {
42454245- ///Marker type for the `completed` field
42464246- pub struct completed(());
42474245 ///Marker type for the `id` field
42484246 pub struct id(());
42474247+ ///Marker type for the `completed` field
42484248+ pub struct completed(());
42494249 }
42504250}
42514251···43554355impl<'a, S> NuxBuilder<'a, S>
43564356where
43574357 S: nux_state::State,
43584358- S::Completed: nux_state::IsSet,
43594358 S::Id: nux_state::IsSet,
43594359+ S::Completed: nux_state::IsSet,
43604360{
43614361 /// Build the final struct
43624362 pub fn build(self) -> Nux<'a> {
···50075007 }
50085008 /// State trait tracking which required fields have been set
50095009 pub trait State: sealed::Sealed {
50105010- type Did;
50115010 type Handle;
50115011+ type Did;
50125012 }
50135013 /// Empty state - all required fields are unset
50145014 pub struct Empty(());
50155015 impl sealed::Sealed for Empty {}
50165016 impl State for Empty {
50175017- type Did = Unset;
50185017 type Handle = Unset;
50195019- }
50205020- ///State transition - sets the `did` field to Set
50215021- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
50225022- impl<S: State> sealed::Sealed for SetDid<S> {}
50235023- impl<S: State> State for SetDid<S> {
50245024- type Did = Set<members::did>;
50255025- type Handle = S::Handle;
50185018+ type Did = Unset;
50265019 }
50275020 ///State transition - sets the `handle` field to Set
50285021 pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
50295022 impl<S: State> sealed::Sealed for SetHandle<S> {}
50305023 impl<S: State> State for SetHandle<S> {
50315031- type Did = S::Did;
50325024 type Handle = Set<members::handle>;
50255025+ type Did = S::Did;
50265026+ }
50275027+ ///State transition - sets the `did` field to Set
50285028+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
50295029+ impl<S: State> sealed::Sealed for SetDid<S> {}
50305030+ impl<S: State> State for SetDid<S> {
50315031+ type Handle = S::Handle;
50325032+ type Did = Set<members::did>;
50335033 }
50345034 /// Marker types for field names
50355035 #[allow(non_camel_case_types)]
50365036 pub mod members {
50375037+ ///Marker type for the `handle` field
50385038+ pub struct handle(());
50375039 ///Marker type for the `did` field
50385040 pub struct did(());
50395039- ///Marker type for the `handle` field
50405040- pub struct handle(());
50415041 }
50425042}
50435043···53625362impl<'a, S> ProfileViewBuilder<'a, S>
53635363where
53645364 S: profile_view_state::State,
53655365- S::Did: profile_view_state::IsSet,
53665365 S::Handle: profile_view_state::IsSet,
53665366+ S::Did: profile_view_state::IsSet,
53675367{
53685368 /// Build the final struct
53695369 pub fn build(self) -> ProfileView<'a> {
···55485548 }
55495549 /// State trait tracking which required fields have been set
55505550 pub trait State: sealed::Sealed {
55515551- type Handle;
55525551 type Did;
55525552+ type Handle;
55535553 }
55545554 /// Empty state - all required fields are unset
55555555 pub struct Empty(());
55565556 impl sealed::Sealed for Empty {}
55575557 impl State for Empty {
55585558- type Handle = Unset;
55595558 type Did = Unset;
55605560- }
55615561- ///State transition - sets the `handle` field to Set
55625562- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
55635563- impl<S: State> sealed::Sealed for SetHandle<S> {}
55645564- impl<S: State> State for SetHandle<S> {
55655565- type Handle = Set<members::handle>;
55665566- type Did = S::Did;
55595559+ type Handle = Unset;
55675560 }
55685561 ///State transition - sets the `did` field to Set
55695562 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
55705563 impl<S: State> sealed::Sealed for SetDid<S> {}
55715564 impl<S: State> State for SetDid<S> {
55725572- type Handle = S::Handle;
55735565 type Did = Set<members::did>;
55665566+ type Handle = S::Handle;
55675567+ }
55685568+ ///State transition - sets the `handle` field to Set
55695569+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
55705570+ impl<S: State> sealed::Sealed for SetHandle<S> {}
55715571+ impl<S: State> State for SetHandle<S> {
55725572+ type Did = S::Did;
55735573+ type Handle = Set<members::handle>;
55745574 }
55755575 /// Marker types for field names
55765576 #[allow(non_camel_case_types)]
55775577 pub mod members {
55785578- ///Marker type for the `handle` field
55795579- pub struct handle(());
55805578 ///Marker type for the `did` field
55815579 pub struct did(());
55805580+ ///Marker type for the `handle` field
55815581+ pub struct handle(());
55825582 }
55835583}
55845584···58615861impl<'a, S> ProfileViewBasicBuilder<'a, S>
58625862where
58635863 S: profile_view_basic_state::State,
58645864- S::Handle: profile_view_basic_state::IsSet,
58655864 S::Did: profile_view_basic_state::IsSet,
58655865+ S::Handle: profile_view_basic_state::IsSet,
58665866{
58675867 /// Build the final struct
58685868 pub fn build(self) -> ProfileViewBasic<'a> {
···60406040 }
60416041 /// State trait tracking which required fields have been set
60426042 pub trait State: sealed::Sealed {
60436043- type Handle;
60446043 type Did;
60446044+ type Handle;
60456045 }
60466046 /// Empty state - all required fields are unset
60476047 pub struct Empty(());
60486048 impl sealed::Sealed for Empty {}
60496049 impl State for Empty {
60506050- type Handle = Unset;
60516050 type Did = Unset;
60526052- }
60536053- ///State transition - sets the `handle` field to Set
60546054- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
60556055- impl<S: State> sealed::Sealed for SetHandle<S> {}
60566056- impl<S: State> State for SetHandle<S> {
60576057- type Handle = Set<members::handle>;
60586058- type Did = S::Did;
60516051+ type Handle = Unset;
60596052 }
60606053 ///State transition - sets the `did` field to Set
60616054 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
60626055 impl<S: State> sealed::Sealed for SetDid<S> {}
60636056 impl<S: State> State for SetDid<S> {
60646064- type Handle = S::Handle;
60656057 type Did = Set<members::did>;
60586058+ type Handle = S::Handle;
60596059+ }
60606060+ ///State transition - sets the `handle` field to Set
60616061+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
60626062+ impl<S: State> sealed::Sealed for SetHandle<S> {}
60636063+ impl<S: State> State for SetHandle<S> {
60646064+ type Did = S::Did;
60656065+ type Handle = Set<members::handle>;
60666066 }
60676067 /// Marker types for field names
60686068 #[allow(non_camel_case_types)]
60696069 pub mod members {
60706070- ///Marker type for the `handle` field
60716071- pub struct handle(());
60726070 ///Marker type for the `did` field
60736071 pub struct did(());
60726072+ ///Marker type for the `handle` field
60736073+ pub struct handle(());
60746074 }
60756075}
60766076···65246524impl<'a, S> ProfileViewDetailedBuilder<'a, S>
65256525where
65266526 S: profile_view_detailed_state::State,
65276527- S::Handle: profile_view_detailed_state::IsSet,
65286527 S::Did: profile_view_detailed_state::IsSet,
65286528+ S::Handle: profile_view_detailed_state::IsSet,
65296529{
65306530 /// Build the final struct
65316531 pub fn build(self) -> ProfileViewDetailed<'a> {
···66976697 }
66986698 /// State trait tracking which required fields have been set
66996699 pub trait State: sealed::Sealed {
67006700- type Id;
67016700 type Type;
67026701 type Pinned;
67026702+ type Id;
67036703 type Value;
67046704 }
67056705 /// Empty state - all required fields are unset
67066706 pub struct Empty(());
67076707 impl sealed::Sealed for Empty {}
67086708 impl State for Empty {
67096709- type Id = Unset;
67106709 type Type = Unset;
67116710 type Pinned = Unset;
67116711+ type Id = Unset;
67126712 type Value = Unset;
67136713 }
67146714- ///State transition - sets the `id` field to Set
67156715- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
67166716- impl<S: State> sealed::Sealed for SetId<S> {}
67176717- impl<S: State> State for SetId<S> {
67186718- type Id = Set<members::id>;
67196719- type Type = S::Type;
67206720- type Pinned = S::Pinned;
67216721- type Value = S::Value;
67226722- }
67236714 ///State transition - sets the `type` field to Set
67246715 pub struct SetType<S: State = Empty>(PhantomData<fn() -> S>);
67256716 impl<S: State> sealed::Sealed for SetType<S> {}
67266717 impl<S: State> State for SetType<S> {
67276727- type Id = S::Id;
67286718 type Type = Set<members::r#type>;
67296719 type Pinned = S::Pinned;
67206720+ type Id = S::Id;
67306721 type Value = S::Value;
67316722 }
67326723 ///State transition - sets the `pinned` field to Set
67336724 pub struct SetPinned<S: State = Empty>(PhantomData<fn() -> S>);
67346725 impl<S: State> sealed::Sealed for SetPinned<S> {}
67356726 impl<S: State> State for SetPinned<S> {
67366736- type Id = S::Id;
67376727 type Type = S::Type;
67386728 type Pinned = Set<members::pinned>;
67296729+ type Id = S::Id;
67306730+ type Value = S::Value;
67316731+ }
67326732+ ///State transition - sets the `id` field to Set
67336733+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
67346734+ impl<S: State> sealed::Sealed for SetId<S> {}
67356735+ impl<S: State> State for SetId<S> {
67366736+ type Type = S::Type;
67376737+ type Pinned = S::Pinned;
67386738+ type Id = Set<members::id>;
67396739 type Value = S::Value;
67406740 }
67416741 ///State transition - sets the `value` field to Set
67426742 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
67436743 impl<S: State> sealed::Sealed for SetValue<S> {}
67446744 impl<S: State> State for SetValue<S> {
67456745- type Id = S::Id;
67466745 type Type = S::Type;
67476746 type Pinned = S::Pinned;
67476747+ type Id = S::Id;
67486748 type Value = Set<members::value>;
67496749 }
67506750 /// Marker types for field names
67516751 #[allow(non_camel_case_types)]
67526752 pub mod members {
67536753- ///Marker type for the `id` field
67546754- pub struct id(());
67556753 ///Marker type for the `type` field
67566754 pub struct r#type(());
67576755 ///Marker type for the `pinned` field
67586756 pub struct pinned(());
67576757+ ///Marker type for the `id` field
67586758+ pub struct id(());
67596759 ///Marker type for the `value` field
67606760 pub struct value(());
67616761 }
···68706870impl<'a, S> SavedFeedBuilder<'a, S>
68716871where
68726872 S: saved_feed_state::State,
68736873- S::Id: saved_feed_state::IsSet,
68746873 S::Type: saved_feed_state::IsSet,
68756874 S::Pinned: saved_feed_state::IsSet,
68756875+ S::Id: saved_feed_state::IsSet,
68766876 S::Value: saved_feed_state::IsSet,
68776877{
68786878 /// Build the final struct
···70437043 }
70447044 /// State trait tracking which required fields have been set
70457045 pub trait State: sealed::Sealed {
70467046- type Saved;
70477046 type Pinned;
70477047+ type Saved;
70487048 }
70497049 /// Empty state - all required fields are unset
70507050 pub struct Empty(());
70517051 impl sealed::Sealed for Empty {}
70527052 impl State for Empty {
70537053- type Saved = Unset;
70547053 type Pinned = Unset;
70557055- }
70567056- ///State transition - sets the `saved` field to Set
70577057- pub struct SetSaved<S: State = Empty>(PhantomData<fn() -> S>);
70587058- impl<S: State> sealed::Sealed for SetSaved<S> {}
70597059- impl<S: State> State for SetSaved<S> {
70607060- type Saved = Set<members::saved>;
70617061- type Pinned = S::Pinned;
70547054+ type Saved = Unset;
70627055 }
70637056 ///State transition - sets the `pinned` field to Set
70647057 pub struct SetPinned<S: State = Empty>(PhantomData<fn() -> S>);
70657058 impl<S: State> sealed::Sealed for SetPinned<S> {}
70667059 impl<S: State> State for SetPinned<S> {
70677067- type Saved = S::Saved;
70687060 type Pinned = Set<members::pinned>;
70617061+ type Saved = S::Saved;
70627062+ }
70637063+ ///State transition - sets the `saved` field to Set
70647064+ pub struct SetSaved<S: State = Empty>(PhantomData<fn() -> S>);
70657065+ impl<S: State> sealed::Sealed for SetSaved<S> {}
70667066+ impl<S: State> State for SetSaved<S> {
70677067+ type Pinned = S::Pinned;
70687068+ type Saved = Set<members::saved>;
70697069 }
70707070 /// Marker types for field names
70717071 #[allow(non_camel_case_types)]
70727072 pub mod members {
70737073+ ///Marker type for the `pinned` field
70747074+ pub struct pinned(());
70737075 ///Marker type for the `saved` field
70747076 pub struct saved(());
70757075- ///Marker type for the `pinned` field
70767076- pub struct pinned(());
70777077 }
70787078}
70797079···71607160impl<'a, S> SavedFeedsPrefBuilder<'a, S>
71617161where
71627162 S: saved_feeds_pref_state::State,
71637163- S::Saved: saved_feeds_pref_state::IsSet,
71647163 S::Pinned: saved_feeds_pref_state::IsSet,
71647164+ S::Saved: saved_feeds_pref_state::IsSet,
71657165{
71667166 /// Build the final struct
71677167 pub fn build(self) -> SavedFeedsPref<'a> {
···73837383 }
73847384 /// State trait tracking which required fields have been set
73857385 pub trait State: sealed::Sealed {
73867386- type Status;
73877386 type Record;
73877387+ type Status;
73887388 }
73897389 /// Empty state - all required fields are unset
73907390 pub struct Empty(());
73917391 impl sealed::Sealed for Empty {}
73927392 impl State for Empty {
73937393- type Status = Unset;
73947393 type Record = Unset;
73957395- }
73967396- ///State transition - sets the `status` field to Set
73977397- pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
73987398- impl<S: State> sealed::Sealed for SetStatus<S> {}
73997399- impl<S: State> State for SetStatus<S> {
74007400- type Status = Set<members::status>;
74017401- type Record = S::Record;
73947394+ type Status = Unset;
74027395 }
74037396 ///State transition - sets the `record` field to Set
74047397 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
74057398 impl<S: State> sealed::Sealed for SetRecord<S> {}
74067399 impl<S: State> State for SetRecord<S> {
74077407- type Status = S::Status;
74087400 type Record = Set<members::record>;
74017401+ type Status = S::Status;
74027402+ }
74037403+ ///State transition - sets the `status` field to Set
74047404+ pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
74057405+ impl<S: State> sealed::Sealed for SetStatus<S> {}
74067406+ impl<S: State> State for SetStatus<S> {
74077407+ type Record = S::Record;
74087408+ type Status = Set<members::status>;
74097409 }
74107410 /// Marker types for field names
74117411 #[allow(non_camel_case_types)]
74127412 pub mod members {
74137413+ ///Marker type for the `record` field
74147414+ pub struct record(());
74137415 ///Marker type for the `status` field
74147416 pub struct status(());
74157415- ///Marker type for the `record` field
74167416- pub struct record(());
74177417 }
74187418}
74197419···75407540impl<'a, S> StatusViewBuilder<'a, S>
75417541where
75427542 S: status_view_state::State,
75437543- S::Status: status_view_state::IsSet,
75447543 S::Record: status_view_state::IsSet,
75447544+ S::Status: status_view_state::IsSet,
75457545{
75467546 /// Build the final struct
75477547 pub fn build(self) -> StatusView<'a> {
···83108310 }
83118311 /// State trait tracking which required fields have been set
83128312 pub trait State: sealed::Sealed {
83138313- type Issuer;
83138313+ type IsValid;
83148314 type CreatedAt;
83158315+ type Issuer;
83158316 type Uri;
83168316- type IsValid;
83178317 }
83188318 /// Empty state - all required fields are unset
83198319 pub struct Empty(());
83208320 impl sealed::Sealed for Empty {}
83218321 impl State for Empty {
83228322+ type IsValid = Unset;
83238323+ type CreatedAt = Unset;
83228324 type Issuer = Unset;
83238323- type CreatedAt = Unset;
83248325 type Uri = Unset;
83258325- type IsValid = Unset;
83268326 }
83278327- ///State transition - sets the `issuer` field to Set
83288328- pub struct SetIssuer<S: State = Empty>(PhantomData<fn() -> S>);
83298329- impl<S: State> sealed::Sealed for SetIssuer<S> {}
83308330- impl<S: State> State for SetIssuer<S> {
83318331- type Issuer = Set<members::issuer>;
83278327+ ///State transition - sets the `is_valid` field to Set
83288328+ pub struct SetIsValid<S: State = Empty>(PhantomData<fn() -> S>);
83298329+ impl<S: State> sealed::Sealed for SetIsValid<S> {}
83308330+ impl<S: State> State for SetIsValid<S> {
83318331+ type IsValid = Set<members::is_valid>;
83328332 type CreatedAt = S::CreatedAt;
83338333+ type Issuer = S::Issuer;
83338334 type Uri = S::Uri;
83348334- type IsValid = S::IsValid;
83358335 }
83368336 ///State transition - sets the `created_at` field to Set
83378337 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
83388338 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
83398339 impl<S: State> State for SetCreatedAt<S> {
83408340+ type IsValid = S::IsValid;
83418341+ type CreatedAt = Set<members::created_at>;
83408342 type Issuer = S::Issuer;
83418341- type CreatedAt = Set<members::created_at>;
83428343 type Uri = S::Uri;
83448344+ }
83458345+ ///State transition - sets the `issuer` field to Set
83468346+ pub struct SetIssuer<S: State = Empty>(PhantomData<fn() -> S>);
83478347+ impl<S: State> sealed::Sealed for SetIssuer<S> {}
83488348+ impl<S: State> State for SetIssuer<S> {
83438349 type IsValid = S::IsValid;
83508350+ type CreatedAt = S::CreatedAt;
83518351+ type Issuer = Set<members::issuer>;
83528352+ type Uri = S::Uri;
83448353 }
83458354 ///State transition - sets the `uri` field to Set
83468355 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
83478356 impl<S: State> sealed::Sealed for SetUri<S> {}
83488357 impl<S: State> State for SetUri<S> {
83498349- type Issuer = S::Issuer;
83508350- type CreatedAt = S::CreatedAt;
83518351- type Uri = Set<members::uri>;
83528358 type IsValid = S::IsValid;
83538353- }
83548354- ///State transition - sets the `is_valid` field to Set
83558355- pub struct SetIsValid<S: State = Empty>(PhantomData<fn() -> S>);
83568356- impl<S: State> sealed::Sealed for SetIsValid<S> {}
83578357- impl<S: State> State for SetIsValid<S> {
83588358- type Issuer = S::Issuer;
83598359 type CreatedAt = S::CreatedAt;
83608360- type Uri = S::Uri;
83618361- type IsValid = Set<members::is_valid>;
83608360+ type Issuer = S::Issuer;
83618361+ type Uri = Set<members::uri>;
83628362 }
83638363 /// Marker types for field names
83648364 #[allow(non_camel_case_types)]
83658365 pub mod members {
83668366- ///Marker type for the `issuer` field
83678367- pub struct issuer(());
83668366+ ///Marker type for the `is_valid` field
83678367+ pub struct is_valid(());
83688368 ///Marker type for the `created_at` field
83698369 pub struct created_at(());
83708370+ ///Marker type for the `issuer` field
83718371+ pub struct issuer(());
83708372 ///Marker type for the `uri` field
83718373 pub struct uri(());
83728372- ///Marker type for the `is_valid` field
83738373- pub struct is_valid(());
83748374 }
83758375}
83768376···84838483impl<'a, S> VerificationViewBuilder<'a, S>
84848484where
84858485 S: verification_view_state::State,
84868486- S::Issuer: verification_view_state::IsSet,
84868486+ S::IsValid: verification_view_state::IsSet,
84878487 S::CreatedAt: verification_view_state::IsSet,
84888488+ S::Issuer: verification_view_state::IsSet,
84888489 S::Uri: verification_view_state::IsSet,
84898489- S::IsValid: verification_view_state::IsSet,
84908490{
84918491 /// Build the final struct
84928492 pub fn build(self) -> VerificationView<'a> {
+58-58
crates/weaver-api/src/app_bsky/ageassurance.rs
···17001700 }
17011701 /// State trait tracking which required fields have been set
17021702 pub trait State: sealed::Sealed {
17031703- type Access;
17041703 type Date;
17041704+ type Access;
17051705 }
17061706 /// Empty state - all required fields are unset
17071707 pub struct Empty(());
17081708 impl sealed::Sealed for Empty {}
17091709 impl State for Empty {
17101710- type Access = Unset;
17111710 type Date = Unset;
17121712- }
17131713- ///State transition - sets the `access` field to Set
17141714- pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
17151715- impl<S: State> sealed::Sealed for SetAccess<S> {}
17161716- impl<S: State> State for SetAccess<S> {
17171717- type Access = Set<members::access>;
17181718- type Date = S::Date;
17111711+ type Access = Unset;
17191712 }
17201713 ///State transition - sets the `date` field to Set
17211714 pub struct SetDate<S: State = Empty>(PhantomData<fn() -> S>);
17221715 impl<S: State> sealed::Sealed for SetDate<S> {}
17231716 impl<S: State> State for SetDate<S> {
17241724- type Access = S::Access;
17251717 type Date = Set<members::date>;
17181718+ type Access = S::Access;
17191719+ }
17201720+ ///State transition - sets the `access` field to Set
17211721+ pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
17221722+ impl<S: State> sealed::Sealed for SetAccess<S> {}
17231723+ impl<S: State> State for SetAccess<S> {
17241724+ type Date = S::Date;
17251725+ type Access = Set<members::access>;
17261726 }
17271727 /// Marker types for field names
17281728 #[allow(non_camel_case_types)]
17291729 pub mod members {
17301730- ///Marker type for the `access` field
17311731- pub struct access(());
17321730 ///Marker type for the `date` field
17331731 pub struct date(());
17321732+ ///Marker type for the `access` field
17331733+ pub struct access(());
17341734 }
17351735}
17361736···18201820impl<'a, S> ConfigRegionRuleIfAccountOlderThanBuilder<'a, S>
18211821where
18221822 S: config_region_rule_if_account_older_than_state::State,
18231823- S::Access: config_region_rule_if_account_older_than_state::IsSet,
18241823 S::Date: config_region_rule_if_account_older_than_state::IsSet,
18241824+ S::Access: config_region_rule_if_account_older_than_state::IsSet,
18251825{
18261826 /// Build the final struct
18271827 pub fn build(self) -> ConfigRegionRuleIfAccountOlderThan<'a> {
···24762476 }
24772477 /// State trait tracking which required fields have been set
24782478 pub trait State: sealed::Sealed {
24792479- type Access;
24802479 type Age;
24802480+ type Access;
24812481 }
24822482 /// Empty state - all required fields are unset
24832483 pub struct Empty(());
24842484 impl sealed::Sealed for Empty {}
24852485 impl State for Empty {
24862486- type Access = Unset;
24872486 type Age = Unset;
24882488- }
24892489- ///State transition - sets the `access` field to Set
24902490- pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
24912491- impl<S: State> sealed::Sealed for SetAccess<S> {}
24922492- impl<S: State> State for SetAccess<S> {
24932493- type Access = Set<members::access>;
24942494- type Age = S::Age;
24872487+ type Access = Unset;
24952488 }
24962489 ///State transition - sets the `age` field to Set
24972490 pub struct SetAge<S: State = Empty>(PhantomData<fn() -> S>);
24982491 impl<S: State> sealed::Sealed for SetAge<S> {}
24992492 impl<S: State> State for SetAge<S> {
25002500- type Access = S::Access;
25012493 type Age = Set<members::age>;
24942494+ type Access = S::Access;
24952495+ }
24962496+ ///State transition - sets the `access` field to Set
24972497+ pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
24982498+ impl<S: State> sealed::Sealed for SetAccess<S> {}
24992499+ impl<S: State> State for SetAccess<S> {
25002500+ type Age = S::Age;
25012501+ type Access = Set<members::access>;
25022502 }
25032503 /// Marker types for field names
25042504 #[allow(non_camel_case_types)]
25052505 pub mod members {
25062506+ ///Marker type for the `age` field
25072507+ pub struct age(());
25062508 ///Marker type for the `access` field
25072509 pub struct access(());
25082508- ///Marker type for the `age` field
25092509- pub struct age(());
25102510 }
25112511}
25122512···25962596impl<'a, S> ConfigRegionRuleIfDeclaredUnderAgeBuilder<'a, S>
25972597where
25982598 S: config_region_rule_if_declared_under_age_state::State,
25992599- S::Access: config_region_rule_if_declared_under_age_state::IsSet,
26002599 S::Age: config_region_rule_if_declared_under_age_state::IsSet,
26002600+ S::Access: config_region_rule_if_declared_under_age_state::IsSet,
26012601{
26022602 /// Build the final struct
26032603 pub fn build(self) -> ConfigRegionRuleIfDeclaredUnderAge<'a> {
···27042704 }
27052705 /// State trait tracking which required fields have been set
27062706 pub trait State: sealed::Sealed {
27072707+ type CreatedAt;
27072708 type Access;
27082709 type Status;
27092710 type AttemptId;
27102711 type CountryCode;
27112711- type CreatedAt;
27122712 }
27132713 /// Empty state - all required fields are unset
27142714 pub struct Empty(());
27152715 impl sealed::Sealed for Empty {}
27162716 impl State for Empty {
27172717+ type CreatedAt = Unset;
27172718 type Access = Unset;
27182719 type Status = Unset;
27192720 type AttemptId = Unset;
27202721 type CountryCode = Unset;
27212721- type CreatedAt = Unset;
27222722+ }
27232723+ ///State transition - sets the `created_at` field to Set
27242724+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
27252725+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
27262726+ impl<S: State> State for SetCreatedAt<S> {
27272727+ type CreatedAt = Set<members::created_at>;
27282728+ type Access = S::Access;
27292729+ type Status = S::Status;
27302730+ type AttemptId = S::AttemptId;
27312731+ type CountryCode = S::CountryCode;
27222732 }
27232733 ///State transition - sets the `access` field to Set
27242734 pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
27252735 impl<S: State> sealed::Sealed for SetAccess<S> {}
27262736 impl<S: State> State for SetAccess<S> {
27372737+ type CreatedAt = S::CreatedAt;
27272738 type Access = Set<members::access>;
27282739 type Status = S::Status;
27292740 type AttemptId = S::AttemptId;
27302741 type CountryCode = S::CountryCode;
27312731- type CreatedAt = S::CreatedAt;
27322742 }
27332743 ///State transition - sets the `status` field to Set
27342744 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
27352745 impl<S: State> sealed::Sealed for SetStatus<S> {}
27362746 impl<S: State> State for SetStatus<S> {
27472747+ type CreatedAt = S::CreatedAt;
27372748 type Access = S::Access;
27382749 type Status = Set<members::status>;
27392750 type AttemptId = S::AttemptId;
27402751 type CountryCode = S::CountryCode;
27412741- type CreatedAt = S::CreatedAt;
27422752 }
27432753 ///State transition - sets the `attempt_id` field to Set
27442754 pub struct SetAttemptId<S: State = Empty>(PhantomData<fn() -> S>);
27452755 impl<S: State> sealed::Sealed for SetAttemptId<S> {}
27462756 impl<S: State> State for SetAttemptId<S> {
27572757+ type CreatedAt = S::CreatedAt;
27472758 type Access = S::Access;
27482759 type Status = S::Status;
27492760 type AttemptId = Set<members::attempt_id>;
27502761 type CountryCode = S::CountryCode;
27512751- type CreatedAt = S::CreatedAt;
27522762 }
27532763 ///State transition - sets the `country_code` field to Set
27542764 pub struct SetCountryCode<S: State = Empty>(PhantomData<fn() -> S>);
27552765 impl<S: State> sealed::Sealed for SetCountryCode<S> {}
27562766 impl<S: State> State for SetCountryCode<S> {
27672767+ type CreatedAt = S::CreatedAt;
27572768 type Access = S::Access;
27582769 type Status = S::Status;
27592770 type AttemptId = S::AttemptId;
27602771 type CountryCode = Set<members::country_code>;
27612761- type CreatedAt = S::CreatedAt;
27622762- }
27632763- ///State transition - sets the `created_at` field to Set
27642764- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
27652765- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
27662766- impl<S: State> State for SetCreatedAt<S> {
27672767- type Access = S::Access;
27682768- type Status = S::Status;
27692769- type AttemptId = S::AttemptId;
27702770- type CountryCode = S::CountryCode;
27712771- type CreatedAt = Set<members::created_at>;
27722772 }
27732773 /// Marker types for field names
27742774 #[allow(non_camel_case_types)]
27752775 pub mod members {
27762776+ ///Marker type for the `created_at` field
27772777+ pub struct created_at(());
27762778 ///Marker type for the `access` field
27772779 pub struct access(());
27782780 ///Marker type for the `status` field
···27812783 pub struct attempt_id(());
27822784 ///Marker type for the `country_code` field
27832785 pub struct country_code(());
27842784- ///Marker type for the `created_at` field
27852785- pub struct created_at(());
27862786 }
27872787}
27882788···30383038impl<'a, S> EventBuilder<'a, S>
30393039where
30403040 S: event_state::State,
30413041+ S::CreatedAt: event_state::IsSet,
30413042 S::Access: event_state::IsSet,
30423043 S::Status: event_state::IsSet,
30433044 S::AttemptId: event_state::IsSet,
30443045 S::CountryCode: event_state::IsSet,
30453045- S::CreatedAt: event_state::IsSet,
30463046{
30473047 /// Build the final struct
30483048 pub fn build(self) -> Event<'a> {
···33333333 }
33343334 /// State trait tracking which required fields have been set
33353335 pub trait State: sealed::Sealed {
33363336- type Access;
33373336 type Status;
33373337+ type Access;
33383338 }
33393339 /// Empty state - all required fields are unset
33403340 pub struct Empty(());
33413341 impl sealed::Sealed for Empty {}
33423342 impl State for Empty {
33433343- type Access = Unset;
33443343 type Status = Unset;
33443344+ type Access = Unset;
33453345+ }
33463346+ ///State transition - sets the `status` field to Set
33473347+ pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
33483348+ impl<S: State> sealed::Sealed for SetStatus<S> {}
33493349+ impl<S: State> State for SetStatus<S> {
33503350+ type Status = Set<members::status>;
33513351+ type Access = S::Access;
33453352 }
33463353 ///State transition - sets the `access` field to Set
33473354 pub struct SetAccess<S: State = Empty>(PhantomData<fn() -> S>);
33483355 impl<S: State> sealed::Sealed for SetAccess<S> {}
33493356 impl<S: State> State for SetAccess<S> {
33573357+ type Status = S::Status;
33503358 type Access = Set<members::access>;
33513351- type Status = S::Status;
33523352- }
33533353- ///State transition - sets the `status` field to Set
33543354- pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
33553355- impl<S: State> sealed::Sealed for SetStatus<S> {}
33563356- impl<S: State> State for SetStatus<S> {
33573357- type Access = S::Access;
33583358- type Status = Set<members::status>;
33593359 }
33603360 /// Marker types for field names
33613361 #[allow(non_camel_case_types)]
33623362 pub mod members {
33633363- ///Marker type for the `access` field
33643364- pub struct access(());
33653363 ///Marker type for the `status` field
33663364 pub struct status(());
33653365+ ///Marker type for the `access` field
33663366+ pub struct access(());
33673367 }
33683368}
33693369···34563456impl<'a, S> StateBuilder<'a, S>
34573457where
34583458 S: state_state::State,
34593459- S::Access: state_state::IsSet,
34603459 S::Status: state_state::IsSet,
34603460+ S::Access: state_state::IsSet,
34613461{
34623462 /// Build the final struct
34633463 pub fn build(self) -> State<'a> {
+13-13
crates/weaver-api/src/app_bsky/bookmark.rs
···281281 }
282282 /// State trait tracking which required fields have been set
283283 pub trait State: sealed::Sealed {
284284- type Subject;
285284 type Item;
285285+ type Subject;
286286 }
287287 /// Empty state - all required fields are unset
288288 pub struct Empty(());
289289 impl sealed::Sealed for Empty {}
290290 impl State for Empty {
291291- type Subject = Unset;
292291 type Item = Unset;
293293- }
294294- ///State transition - sets the `subject` field to Set
295295- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
296296- impl<S: State> sealed::Sealed for SetSubject<S> {}
297297- impl<S: State> State for SetSubject<S> {
298298- type Subject = Set<members::subject>;
299299- type Item = S::Item;
292292+ type Subject = Unset;
300293 }
301294 ///State transition - sets the `item` field to Set
302295 pub struct SetItem<S: State = Empty>(PhantomData<fn() -> S>);
303296 impl<S: State> sealed::Sealed for SetItem<S> {}
304297 impl<S: State> State for SetItem<S> {
305305- type Subject = S::Subject;
306298 type Item = Set<members::item>;
299299+ type Subject = S::Subject;
300300+ }
301301+ ///State transition - sets the `subject` field to Set
302302+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
303303+ impl<S: State> sealed::Sealed for SetSubject<S> {}
304304+ impl<S: State> State for SetSubject<S> {
305305+ type Item = S::Item;
306306+ type Subject = Set<members::subject>;
307307 }
308308 /// Marker types for field names
309309 #[allow(non_camel_case_types)]
310310 pub mod members {
311311- ///Marker type for the `subject` field
312312- pub struct subject(());
313311 ///Marker type for the `item` field
314312 pub struct item(());
313313+ ///Marker type for the `subject` field
314314+ pub struct subject(());
315315 }
316316}
317317···404404impl<'a, S> BookmarkViewBuilder<'a, S>
405405where
406406 S: bookmark_view_state::State,
407407- S::Subject: bookmark_view_state::IsSet,
408407 S::Item: bookmark_view_state::IsSet,
408408+ S::Subject: bookmark_view_state::IsSet,
409409{
410410 /// Build the final struct
411411 pub fn build(self) -> BookmarkView<'a> {
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Cid;
3736 type Uri;
3737+ type Cid;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Cid = Unset;
4443 type Uri = Unset;
4545- }
4646- ///State transition - sets the `cid` field to Set
4747- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetCid<S> {}
4949- impl<S: State> State for SetCid<S> {
5050- type Cid = Set<members::cid>;
5151- type Uri = S::Uri;
4444+ type Cid = Unset;
5245 }
5346 ///State transition - sets the `uri` field to Set
5447 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetUri<S> {}
5649 impl<S: State> State for SetUri<S> {
5757- type Cid = S::Cid;
5850 type Uri = Set<members::uri>;
5151+ type Cid = S::Cid;
5252+ }
5353+ ///State transition - sets the `cid` field to Set
5454+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetCid<S> {}
5656+ impl<S: State> State for SetCid<S> {
5757+ type Uri = S::Uri;
5858+ type Cid = Set<members::cid>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `cid` field
6464- pub struct cid(());
6563 ///Marker type for the `uri` field
6664 pub struct uri(());
6565+ ///Marker type for the `cid` field
6666+ pub struct cid(());
6767 }
6868}
6969···136136impl<'a, S> CreateBookmarkBuilder<'a, S>
137137where
138138 S: create_bookmark_state::State,
139139- S::Cid: create_bookmark_state::IsSet,
140139 S::Uri: create_bookmark_state::IsSet,
140140+ S::Cid: create_bookmark_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> CreateBookmark<'a> {
+13-13
crates/weaver-api/src/app_bsky/embed.rs
···3838 }
3939 /// State trait tracking which required fields have been set
4040 pub trait State: sealed::Sealed {
4141- type Height;
4241 type Width;
4242+ type Height;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848- type Height = Unset;
4948 type Width = Unset;
5050- }
5151- ///State transition - sets the `height` field to Set
5252- pub struct SetHeight<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetHeight<S> {}
5454- impl<S: State> State for SetHeight<S> {
5555- type Height = Set<members::height>;
5656- type Width = S::Width;
4949+ type Height = Unset;
5750 }
5851 ///State transition - sets the `width` field to Set
5952 pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
6053 impl<S: State> sealed::Sealed for SetWidth<S> {}
6154 impl<S: State> State for SetWidth<S> {
6262- type Height = S::Height;
6355 type Width = Set<members::width>;
5656+ type Height = S::Height;
5757+ }
5858+ ///State transition - sets the `height` field to Set
5959+ pub struct SetHeight<S: State = Empty>(PhantomData<fn() -> S>);
6060+ impl<S: State> sealed::Sealed for SetHeight<S> {}
6161+ impl<S: State> State for SetHeight<S> {
6262+ type Width = S::Width;
6363+ type Height = Set<members::height>;
6464 }
6565 /// Marker types for field names
6666 #[allow(non_camel_case_types)]
6767 pub mod members {
6868- ///Marker type for the `height` field
6969- pub struct height(());
7068 ///Marker type for the `width` field
7169 pub struct width(());
7070+ ///Marker type for the `height` field
7171+ pub struct height(());
7272 }
7373}
7474···138138impl<'a, S> AspectRatioBuilder<'a, S>
139139where
140140 S: aspect_ratio_state::State,
141141- S::Height: aspect_ratio_state::IsSet,
142141 S::Width: aspect_ratio_state::IsSet,
142142+ S::Height: aspect_ratio_state::IsSet,
143143{
144144 /// Build the final struct
145145 pub fn build(self) -> AspectRatio<'a> {
+39-39
crates/weaver-api/src/app_bsky/embed/external.rs
···3939 /// State trait tracking which required fields have been set
4040 pub trait State: sealed::Sealed {
4141 type Title;
4242- type Uri;
4342 type Description;
4343+ type Uri;
4444 }
4545 /// Empty state - all required fields are unset
4646 pub struct Empty(());
4747 impl sealed::Sealed for Empty {}
4848 impl State for Empty {
4949 type Title = Unset;
5050- type Uri = Unset;
5150 type Description = Unset;
5151+ type Uri = Unset;
5252 }
5353 ///State transition - sets the `title` field to Set
5454 pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
5555 impl<S: State> sealed::Sealed for SetTitle<S> {}
5656 impl<S: State> State for SetTitle<S> {
5757 type Title = Set<members::title>;
5858- type Uri = S::Uri;
5958 type Description = S::Description;
6060- }
6161- ///State transition - sets the `uri` field to Set
6262- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
6363- impl<S: State> sealed::Sealed for SetUri<S> {}
6464- impl<S: State> State for SetUri<S> {
6565- type Title = S::Title;
6666- type Uri = Set<members::uri>;
6767- type Description = S::Description;
5959+ type Uri = S::Uri;
6860 }
6961 ///State transition - sets the `description` field to Set
7062 pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
7163 impl<S: State> sealed::Sealed for SetDescription<S> {}
7264 impl<S: State> State for SetDescription<S> {
7365 type Title = S::Title;
7474- type Uri = S::Uri;
7566 type Description = Set<members::description>;
6767+ type Uri = S::Uri;
6868+ }
6969+ ///State transition - sets the `uri` field to Set
7070+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
7171+ impl<S: State> sealed::Sealed for SetUri<S> {}
7272+ impl<S: State> State for SetUri<S> {
7373+ type Title = S::Title;
7474+ type Description = S::Description;
7575+ type Uri = Set<members::uri>;
7676 }
7777 /// Marker types for field names
7878 #[allow(non_camel_case_types)]
7979 pub mod members {
8080 ///Marker type for the `title` field
8181 pub struct title(());
8282+ ///Marker type for the `description` field
8383+ pub struct description(());
8284 ///Marker type for the `uri` field
8385 pub struct uri(());
8484- ///Marker type for the `description` field
8585- pub struct description(());
8686 }
8787}
8888···196196where
197197 S: external_state::State,
198198 S::Title: external_state::IsSet,
199199- S::Uri: external_state::IsSet,
200199 S::Description: external_state::IsSet,
200200+ S::Uri: external_state::IsSet,
201201{
202202 /// Build the final struct
203203 pub fn build(self) -> External<'a> {
···784784 }
785785 /// State trait tracking which required fields have been set
786786 pub trait State: sealed::Sealed {
787787- type Description;
788788- type Uri;
789787 type Title;
788788+ type Uri;
789789+ type Description;
790790 }
791791 /// Empty state - all required fields are unset
792792 pub struct Empty(());
793793 impl sealed::Sealed for Empty {}
794794 impl State for Empty {
795795+ type Title = Unset;
796796+ type Uri = Unset;
795797 type Description = Unset;
796796- type Uri = Unset;
797797- type Title = Unset;
798798 }
799799- ///State transition - sets the `description` field to Set
800800- pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
801801- impl<S: State> sealed::Sealed for SetDescription<S> {}
802802- impl<S: State> State for SetDescription<S> {
803803- type Description = Set<members::description>;
799799+ ///State transition - sets the `title` field to Set
800800+ pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
801801+ impl<S: State> sealed::Sealed for SetTitle<S> {}
802802+ impl<S: State> State for SetTitle<S> {
803803+ type Title = Set<members::title>;
804804 type Uri = S::Uri;
805805- type Title = S::Title;
805805+ type Description = S::Description;
806806 }
807807 ///State transition - sets the `uri` field to Set
808808 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
809809 impl<S: State> sealed::Sealed for SetUri<S> {}
810810 impl<S: State> State for SetUri<S> {
811811- type Description = S::Description;
812812- type Uri = Set<members::uri>;
813811 type Title = S::Title;
812812+ type Uri = Set<members::uri>;
813813+ type Description = S::Description;
814814 }
815815- ///State transition - sets the `title` field to Set
816816- pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
817817- impl<S: State> sealed::Sealed for SetTitle<S> {}
818818- impl<S: State> State for SetTitle<S> {
819819- type Description = S::Description;
815815+ ///State transition - sets the `description` field to Set
816816+ pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
817817+ impl<S: State> sealed::Sealed for SetDescription<S> {}
818818+ impl<S: State> State for SetDescription<S> {
819819+ type Title = S::Title;
820820 type Uri = S::Uri;
821821- type Title = Set<members::title>;
821821+ type Description = Set<members::description>;
822822 }
823823 /// Marker types for field names
824824 #[allow(non_camel_case_types)]
825825 pub mod members {
826826+ ///Marker type for the `title` field
827827+ pub struct title(());
828828+ ///Marker type for the `uri` field
829829+ pub struct uri(());
826830 ///Marker type for the `description` field
827831 pub struct description(());
828828- ///Marker type for the `uri` field
829829- pub struct uri(());
830830- ///Marker type for the `title` field
831831- pub struct title(());
832832 }
833833}
834834···941941impl<'a, S> ViewExternalBuilder<'a, S>
942942where
943943 S: view_external_state::State,
944944- S::Description: view_external_state::IsSet,
945945- S::Uri: view_external_state::IsSet,
946944 S::Title: view_external_state::IsSet,
945945+ S::Uri: view_external_state::IsSet,
946946+ S::Description: view_external_state::IsSet,
947947{
948948 /// Build the final struct
949949 pub fn build(self) -> ViewExternal<'a> {
+13-13
crates/weaver-api/src/app_bsky/embed/images.rs
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040- type Alt;
4140 type Image;
4141+ type Alt;
4242 }
4343 /// Empty state - all required fields are unset
4444 pub struct Empty(());
4545 impl sealed::Sealed for Empty {}
4646 impl State for Empty {
4747- type Alt = Unset;
4847 type Image = Unset;
4949- }
5050- ///State transition - sets the `alt` field to Set
5151- pub struct SetAlt<S: State = Empty>(PhantomData<fn() -> S>);
5252- impl<S: State> sealed::Sealed for SetAlt<S> {}
5353- impl<S: State> State for SetAlt<S> {
5454- type Alt = Set<members::alt>;
5555- type Image = S::Image;
4848+ type Alt = Unset;
5649 }
5750 ///State transition - sets the `image` field to Set
5851 pub struct SetImage<S: State = Empty>(PhantomData<fn() -> S>);
5952 impl<S: State> sealed::Sealed for SetImage<S> {}
6053 impl<S: State> State for SetImage<S> {
6161- type Alt = S::Alt;
6254 type Image = Set<members::image>;
5555+ type Alt = S::Alt;
5656+ }
5757+ ///State transition - sets the `alt` field to Set
5858+ pub struct SetAlt<S: State = Empty>(PhantomData<fn() -> S>);
5959+ impl<S: State> sealed::Sealed for SetAlt<S> {}
6060+ impl<S: State> State for SetAlt<S> {
6161+ type Image = S::Image;
6262+ type Alt = Set<members::alt>;
6363 }
6464 /// Marker types for field names
6565 #[allow(non_camel_case_types)]
6666 pub mod members {
6767- ///Marker type for the `alt` field
6868- pub struct alt(());
6967 ///Marker type for the `image` field
7068 pub struct image(());
6969+ ///Marker type for the `alt` field
7070+ pub struct alt(());
7171 }
7272}
7373···160160impl<'a, S> ImageBuilder<'a, S>
161161where
162162 S: image_state::State,
163163- S::Alt: image_state::IsSet,
164163 S::Image: image_state::IsSet,
164164+ S::Alt: image_state::IsSet,
165165{
166166 /// Build the final struct
167167 pub fn build(self) -> Image<'a> {
+73-73
crates/weaver-api/src/app_bsky/embed/record.rs
···723723 }
724724 /// State trait tracking which required fields have been set
725725 pub trait State: sealed::Sealed {
726726- type Author;
727726 type Uri;
728727 type Blocked;
728728+ type Author;
729729 }
730730 /// Empty state - all required fields are unset
731731 pub struct Empty(());
732732 impl sealed::Sealed for Empty {}
733733 impl State for Empty {
734734- type Author = Unset;
735734 type Uri = Unset;
736735 type Blocked = Unset;
737737- }
738738- ///State transition - sets the `author` field to Set
739739- pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
740740- impl<S: State> sealed::Sealed for SetAuthor<S> {}
741741- impl<S: State> State for SetAuthor<S> {
742742- type Author = Set<members::author>;
743743- type Uri = S::Uri;
744744- type Blocked = S::Blocked;
736736+ type Author = Unset;
745737 }
746738 ///State transition - sets the `uri` field to Set
747739 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
748740 impl<S: State> sealed::Sealed for SetUri<S> {}
749741 impl<S: State> State for SetUri<S> {
750750- type Author = S::Author;
751742 type Uri = Set<members::uri>;
752743 type Blocked = S::Blocked;
744744+ type Author = S::Author;
753745 }
754746 ///State transition - sets the `blocked` field to Set
755747 pub struct SetBlocked<S: State = Empty>(PhantomData<fn() -> S>);
756748 impl<S: State> sealed::Sealed for SetBlocked<S> {}
757749 impl<S: State> State for SetBlocked<S> {
750750+ type Uri = S::Uri;
751751+ type Blocked = Set<members::blocked>;
758752 type Author = S::Author;
753753+ }
754754+ ///State transition - sets the `author` field to Set
755755+ pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
756756+ impl<S: State> sealed::Sealed for SetAuthor<S> {}
757757+ impl<S: State> State for SetAuthor<S> {
759758 type Uri = S::Uri;
760760- type Blocked = Set<members::blocked>;
759759+ type Blocked = S::Blocked;
760760+ type Author = Set<members::author>;
761761 }
762762 /// Marker types for field names
763763 #[allow(non_camel_case_types)]
764764 pub mod members {
765765- ///Marker type for the `author` field
766766- pub struct author(());
767765 ///Marker type for the `uri` field
768766 pub struct uri(());
769767 ///Marker type for the `blocked` field
770768 pub struct blocked(());
769769+ ///Marker type for the `author` field
770770+ pub struct author(());
771771 }
772772}
773773···860860impl<'a, S> ViewBlockedBuilder<'a, S>
861861where
862862 S: view_blocked_state::State,
863863- S::Author: view_blocked_state::IsSet,
864863 S::Uri: view_blocked_state::IsSet,
865864 S::Blocked: view_blocked_state::IsSet,
865865+ S::Author: view_blocked_state::IsSet,
866866{
867867 /// Build the final struct
868868 pub fn build(self) -> ViewBlocked<'a> {
···934934 }
935935 /// State trait tracking which required fields have been set
936936 pub trait State: sealed::Sealed {
937937- type Uri;
938937 type Detached;
938938+ type Uri;
939939 }
940940 /// Empty state - all required fields are unset
941941 pub struct Empty(());
942942 impl sealed::Sealed for Empty {}
943943 impl State for Empty {
944944+ type Detached = Unset;
944945 type Uri = Unset;
945945- type Detached = Unset;
946946+ }
947947+ ///State transition - sets the `detached` field to Set
948948+ pub struct SetDetached<S: State = Empty>(PhantomData<fn() -> S>);
949949+ impl<S: State> sealed::Sealed for SetDetached<S> {}
950950+ impl<S: State> State for SetDetached<S> {
951951+ type Detached = Set<members::detached>;
952952+ type Uri = S::Uri;
946953 }
947954 ///State transition - sets the `uri` field to Set
948955 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
949956 impl<S: State> sealed::Sealed for SetUri<S> {}
950957 impl<S: State> State for SetUri<S> {
958958+ type Detached = S::Detached;
951959 type Uri = Set<members::uri>;
952952- type Detached = S::Detached;
953953- }
954954- ///State transition - sets the `detached` field to Set
955955- pub struct SetDetached<S: State = Empty>(PhantomData<fn() -> S>);
956956- impl<S: State> sealed::Sealed for SetDetached<S> {}
957957- impl<S: State> State for SetDetached<S> {
958958- type Uri = S::Uri;
959959- type Detached = Set<members::detached>;
960960 }
961961 /// Marker types for field names
962962 #[allow(non_camel_case_types)]
963963 pub mod members {
964964+ ///Marker type for the `detached` field
965965+ pub struct detached(());
964966 ///Marker type for the `uri` field
965967 pub struct uri(());
966966- ///Marker type for the `detached` field
967967- pub struct detached(());
968968 }
969969}
970970···10371037impl<'a, S> ViewDetachedBuilder<'a, S>
10381038where
10391039 S: view_detached_state::State,
10401040- S::Uri: view_detached_state::IsSet,
10411040 S::Detached: view_detached_state::IsSet,
10411041+ S::Uri: view_detached_state::IsSet,
10421042{
10431043 /// Build the final struct
10441044 pub fn build(self) -> ViewDetached<'a> {
···11081108 }
11091109 /// State trait tracking which required fields have been set
11101110 pub trait State: sealed::Sealed {
11111111- type Uri;
11121111 type NotFound;
11121112+ type Uri;
11131113 }
11141114 /// Empty state - all required fields are unset
11151115 pub struct Empty(());
11161116 impl sealed::Sealed for Empty {}
11171117 impl State for Empty {
11181118+ type NotFound = Unset;
11181119 type Uri = Unset;
11191119- type NotFound = Unset;
11201120- }
11211121- ///State transition - sets the `uri` field to Set
11221122- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
11231123- impl<S: State> sealed::Sealed for SetUri<S> {}
11241124- impl<S: State> State for SetUri<S> {
11251125- type Uri = Set<members::uri>;
11261126- type NotFound = S::NotFound;
11271120 }
11281121 ///State transition - sets the `not_found` field to Set
11291122 pub struct SetNotFound<S: State = Empty>(PhantomData<fn() -> S>);
11301123 impl<S: State> sealed::Sealed for SetNotFound<S> {}
11311124 impl<S: State> State for SetNotFound<S> {
11321132- type Uri = S::Uri;
11331125 type NotFound = Set<members::not_found>;
11261126+ type Uri = S::Uri;
11271127+ }
11281128+ ///State transition - sets the `uri` field to Set
11291129+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
11301130+ impl<S: State> sealed::Sealed for SetUri<S> {}
11311131+ impl<S: State> State for SetUri<S> {
11321132+ type NotFound = S::NotFound;
11331133+ type Uri = Set<members::uri>;
11341134 }
11351135 /// Marker types for field names
11361136 #[allow(non_camel_case_types)]
11371137 pub mod members {
11381138+ ///Marker type for the `not_found` field
11391139+ pub struct not_found(());
11381140 ///Marker type for the `uri` field
11391141 pub struct uri(());
11401140- ///Marker type for the `not_found` field
11411141- pub struct not_found(());
11421142 }
11431143}
11441144···12111211impl<'a, S> ViewNotFoundBuilder<'a, S>
12121212where
12131213 S: view_not_found_state::State,
12141214- S::Uri: view_not_found_state::IsSet,
12151214 S::NotFound: view_not_found_state::IsSet,
12151215+ S::Uri: view_not_found_state::IsSet,
12161216{
12171217 /// Build the final struct
12181218 pub fn build(self) -> ViewNotFound<'a> {
···13031303 }
13041304 /// State trait tracking which required fields have been set
13051305 pub trait State: sealed::Sealed {
13061306- type Uri;
13071306 type Cid;
13071307+ type Author;
13081308 type Value;
13091309 type IndexedAt;
13101310- type Author;
13101310+ type Uri;
13111311 }
13121312 /// Empty state - all required fields are unset
13131313 pub struct Empty(());
13141314 impl sealed::Sealed for Empty {}
13151315 impl State for Empty {
13161316- type Uri = Unset;
13171316 type Cid = Unset;
13171317+ type Author = Unset;
13181318 type Value = Unset;
13191319 type IndexedAt = Unset;
13201320- type Author = Unset;
13211321- }
13221322- ///State transition - sets the `uri` field to Set
13231323- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
13241324- impl<S: State> sealed::Sealed for SetUri<S> {}
13251325- impl<S: State> State for SetUri<S> {
13261326- type Uri = Set<members::uri>;
13271327- type Cid = S::Cid;
13281328- type Value = S::Value;
13291329- type IndexedAt = S::IndexedAt;
13301330- type Author = S::Author;
13201320+ type Uri = Unset;
13311321 }
13321322 ///State transition - sets the `cid` field to Set
13331323 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
13341324 impl<S: State> sealed::Sealed for SetCid<S> {}
13351325 impl<S: State> State for SetCid<S> {
13261326+ type Cid = Set<members::cid>;
13271327+ type Author = S::Author;
13281328+ type Value = S::Value;
13291329+ type IndexedAt = S::IndexedAt;
13361330 type Uri = S::Uri;
13371337- type Cid = Set<members::cid>;
13311331+ }
13321332+ ///State transition - sets the `author` field to Set
13331333+ pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
13341334+ impl<S: State> sealed::Sealed for SetAuthor<S> {}
13351335+ impl<S: State> State for SetAuthor<S> {
13361336+ type Cid = S::Cid;
13371337+ type Author = Set<members::author>;
13381338 type Value = S::Value;
13391339 type IndexedAt = S::IndexedAt;
13401340- type Author = S::Author;
13401340+ type Uri = S::Uri;
13411341 }
13421342 ///State transition - sets the `value` field to Set
13431343 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
13441344 impl<S: State> sealed::Sealed for SetValue<S> {}
13451345 impl<S: State> State for SetValue<S> {
13461346- type Uri = S::Uri;
13471346 type Cid = S::Cid;
13471347+ type Author = S::Author;
13481348 type Value = Set<members::value>;
13491349 type IndexedAt = S::IndexedAt;
13501350- type Author = S::Author;
13501350+ type Uri = S::Uri;
13511351 }
13521352 ///State transition - sets the `indexed_at` field to Set
13531353 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
13541354 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
13551355 impl<S: State> State for SetIndexedAt<S> {
13561356- type Uri = S::Uri;
13571356 type Cid = S::Cid;
13571357+ type Author = S::Author;
13581358 type Value = S::Value;
13591359 type IndexedAt = Set<members::indexed_at>;
13601360- type Author = S::Author;
13611361- }
13621362- ///State transition - sets the `author` field to Set
13631363- pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
13641364- impl<S: State> sealed::Sealed for SetAuthor<S> {}
13651365- impl<S: State> State for SetAuthor<S> {
13661360 type Uri = S::Uri;
13611361+ }
13621362+ ///State transition - sets the `uri` field to Set
13631363+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
13641364+ impl<S: State> sealed::Sealed for SetUri<S> {}
13651365+ impl<S: State> State for SetUri<S> {
13671366 type Cid = S::Cid;
13671367+ type Author = S::Author;
13681368 type Value = S::Value;
13691369 type IndexedAt = S::IndexedAt;
13701370- type Author = Set<members::author>;
13701370+ type Uri = Set<members::uri>;
13711371 }
13721372 /// Marker types for field names
13731373 #[allow(non_camel_case_types)]
13741374 pub mod members {
13751375- ///Marker type for the `uri` field
13761376- pub struct uri(());
13771375 ///Marker type for the `cid` field
13781376 pub struct cid(());
13771377+ ///Marker type for the `author` field
13781378+ pub struct author(());
13791379 ///Marker type for the `value` field
13801380 pub struct value(());
13811381 ///Marker type for the `indexed_at` field
13821382 pub struct indexed_at(());
13831383- ///Marker type for the `author` field
13841384- pub struct author(());
13831383+ ///Marker type for the `uri` field
13841384+ pub struct uri(());
13851385 }
13861386}
13871387···16191619impl<'a, S> ViewRecordBuilder<'a, S>
16201620where
16211621 S: view_record_state::State,
16221622- S::Uri: view_record_state::IsSet,
16231622 S::Cid: view_record_state::IsSet,
16231623+ S::Author: view_record_state::IsSet,
16241624 S::Value: view_record_state::IsSet,
16251625 S::IndexedAt: view_record_state::IsSet,
16261626- S::Author: view_record_state::IsSet,
16261626+ S::Uri: view_record_state::IsSet,
16271627{
16281628 /// Build the final struct
16291629 pub fn build(self) -> ViewRecord<'a> {
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Record;
3736 type Media;
3737+ type Record;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Record = Unset;
4443 type Media = Unset;
4545- }
4646- ///State transition - sets the `record` field to Set
4747- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetRecord<S> {}
4949- impl<S: State> State for SetRecord<S> {
5050- type Record = Set<members::record>;
5151- type Media = S::Media;
4444+ type Record = Unset;
5245 }
5346 ///State transition - sets the `media` field to Set
5447 pub struct SetMedia<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetMedia<S> {}
5649 impl<S: State> State for SetMedia<S> {
5757- type Record = S::Record;
5850 type Media = Set<members::media>;
5151+ type Record = S::Record;
5252+ }
5353+ ///State transition - sets the `record` field to Set
5454+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetRecord<S> {}
5656+ impl<S: State> State for SetRecord<S> {
5757+ type Media = S::Media;
5858+ type Record = Set<members::record>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `record` field
6464- pub struct record(());
6563 ///Marker type for the `media` field
6664 pub struct media(());
6565+ ///Marker type for the `record` field
6666+ pub struct record(());
6767 }
6868}
6969···136136impl<'a, S> RecordWithMediaBuilder<'a, S>
137137where
138138 S: record_with_media_state::State,
139139- S::Record: record_with_media_state::IsSet,
140139 S::Media: record_with_media_state::IsSet,
140140+ S::Record: record_with_media_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> RecordWithMedia<'a> {
+13-13
crates/weaver-api/src/app_bsky/embed/video.rs
···687687 }
688688 /// State trait tracking which required fields have been set
689689 pub trait State: sealed::Sealed {
690690- type Cid;
691690 type Playlist;
691691+ type Cid;
692692 }
693693 /// Empty state - all required fields are unset
694694 pub struct Empty(());
695695 impl sealed::Sealed for Empty {}
696696 impl State for Empty {
697697- type Cid = Unset;
698697 type Playlist = Unset;
699699- }
700700- ///State transition - sets the `cid` field to Set
701701- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
702702- impl<S: State> sealed::Sealed for SetCid<S> {}
703703- impl<S: State> State for SetCid<S> {
704704- type Cid = Set<members::cid>;
705705- type Playlist = S::Playlist;
698698+ type Cid = Unset;
706699 }
707700 ///State transition - sets the `playlist` field to Set
708701 pub struct SetPlaylist<S: State = Empty>(PhantomData<fn() -> S>);
709702 impl<S: State> sealed::Sealed for SetPlaylist<S> {}
710703 impl<S: State> State for SetPlaylist<S> {
711711- type Cid = S::Cid;
712704 type Playlist = Set<members::playlist>;
705705+ type Cid = S::Cid;
706706+ }
707707+ ///State transition - sets the `cid` field to Set
708708+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
709709+ impl<S: State> sealed::Sealed for SetCid<S> {}
710710+ impl<S: State> State for SetCid<S> {
711711+ type Playlist = S::Playlist;
712712+ type Cid = Set<members::cid>;
713713 }
714714 /// Marker types for field names
715715 #[allow(non_camel_case_types)]
716716 pub mod members {
717717- ///Marker type for the `cid` field
718718- pub struct cid(());
719717 ///Marker type for the `playlist` field
720718 pub struct playlist(());
719719+ ///Marker type for the `cid` field
720720+ pub struct cid(());
721721 }
722722}
723723···844844impl<'a, S> ViewBuilder<'a, S>
845845where
846846 S: view_state::State,
847847- S::Cid: view_state::IsSet,
848847 S::Playlist: view_state::IsSet,
848848+ S::Cid: view_state::IsSet,
849849{
850850 /// Build the final struct
851851 pub fn build(self) -> View<'a> {
+89-89
crates/weaver-api/src/app_bsky/feed.rs
···16091609 }
16101610 /// State trait tracking which required fields have been set
16111611 pub trait State: sealed::Sealed {
16121612- type Blocked;
16131612 type Author;
16131613+ type Blocked;
16141614 type Uri;
16151615 }
16161616 /// Empty state - all required fields are unset
16171617 pub struct Empty(());
16181618 impl sealed::Sealed for Empty {}
16191619 impl State for Empty {
16201620- type Blocked = Unset;
16211620 type Author = Unset;
16211621+ type Blocked = Unset;
16221622 type Uri = Unset;
16231623 }
16241624- ///State transition - sets the `blocked` field to Set
16251625- pub struct SetBlocked<S: State = Empty>(PhantomData<fn() -> S>);
16261626- impl<S: State> sealed::Sealed for SetBlocked<S> {}
16271627- impl<S: State> State for SetBlocked<S> {
16281628- type Blocked = Set<members::blocked>;
16291629- type Author = S::Author;
16301630- type Uri = S::Uri;
16311631- }
16321624 ///State transition - sets the `author` field to Set
16331625 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
16341626 impl<S: State> sealed::Sealed for SetAuthor<S> {}
16351627 impl<S: State> State for SetAuthor<S> {
16361636- type Blocked = S::Blocked;
16371628 type Author = Set<members::author>;
16291629+ type Blocked = S::Blocked;
16301630+ type Uri = S::Uri;
16311631+ }
16321632+ ///State transition - sets the `blocked` field to Set
16331633+ pub struct SetBlocked<S: State = Empty>(PhantomData<fn() -> S>);
16341634+ impl<S: State> sealed::Sealed for SetBlocked<S> {}
16351635+ impl<S: State> State for SetBlocked<S> {
16361636+ type Author = S::Author;
16371637+ type Blocked = Set<members::blocked>;
16381638 type Uri = S::Uri;
16391639 }
16401640 ///State transition - sets the `uri` field to Set
16411641 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
16421642 impl<S: State> sealed::Sealed for SetUri<S> {}
16431643 impl<S: State> State for SetUri<S> {
16441644- type Blocked = S::Blocked;
16451644 type Author = S::Author;
16451645+ type Blocked = S::Blocked;
16461646 type Uri = Set<members::uri>;
16471647 }
16481648 /// Marker types for field names
16491649 #[allow(non_camel_case_types)]
16501650 pub mod members {
16511651+ ///Marker type for the `author` field
16521652+ pub struct author(());
16511653 ///Marker type for the `blocked` field
16521654 pub struct blocked(());
16531653- ///Marker type for the `author` field
16541654- pub struct author(());
16551655 ///Marker type for the `uri` field
16561656 pub struct uri(());
16571657 }
···17461746impl<'a, S> BlockedPostBuilder<'a, S>
17471747where
17481748 S: blocked_post_state::State,
17491749- S::Blocked: blocked_post_state::IsSet,
17501749 S::Author: blocked_post_state::IsSet,
17501750+ S::Blocked: blocked_post_state::IsSet,
17511751 S::Uri: blocked_post_state::IsSet,
17521752{
17531753 /// Build the final struct
···22342234 }
22352235 /// State trait tracking which required fields have been set
22362236 pub trait State: sealed::Sealed {
22372237- type Creator;
22372237+ type Uri;
22382238 type Cid;
22392239 type Did;
22402240 type IndexedAt;
22412241- type Uri;
22412241+ type Creator;
22422242 type DisplayName;
22432243 }
22442244 /// Empty state - all required fields are unset
22452245 pub struct Empty(());
22462246 impl sealed::Sealed for Empty {}
22472247 impl State for Empty {
22482248- type Creator = Unset;
22482248+ type Uri = Unset;
22492249 type Cid = Unset;
22502250 type Did = Unset;
22512251 type IndexedAt = Unset;
22522252- type Uri = Unset;
22522252+ type Creator = Unset;
22532253 type DisplayName = Unset;
22542254 }
22552255- ///State transition - sets the `creator` field to Set
22562256- pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
22572257- impl<S: State> sealed::Sealed for SetCreator<S> {}
22582258- impl<S: State> State for SetCreator<S> {
22592259- type Creator = Set<members::creator>;
22552255+ ///State transition - sets the `uri` field to Set
22562256+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
22572257+ impl<S: State> sealed::Sealed for SetUri<S> {}
22582258+ impl<S: State> State for SetUri<S> {
22592259+ type Uri = Set<members::uri>;
22602260 type Cid = S::Cid;
22612261 type Did = S::Did;
22622262 type IndexedAt = S::IndexedAt;
22632263- type Uri = S::Uri;
22632263+ type Creator = S::Creator;
22642264 type DisplayName = S::DisplayName;
22652265 }
22662266 ///State transition - sets the `cid` field to Set
22672267 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
22682268 impl<S: State> sealed::Sealed for SetCid<S> {}
22692269 impl<S: State> State for SetCid<S> {
22702270- type Creator = S::Creator;
22702270+ type Uri = S::Uri;
22712271 type Cid = Set<members::cid>;
22722272 type Did = S::Did;
22732273 type IndexedAt = S::IndexedAt;
22742274- type Uri = S::Uri;
22742274+ type Creator = S::Creator;
22752275 type DisplayName = S::DisplayName;
22762276 }
22772277 ///State transition - sets the `did` field to Set
22782278 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
22792279 impl<S: State> sealed::Sealed for SetDid<S> {}
22802280 impl<S: State> State for SetDid<S> {
22812281- type Creator = S::Creator;
22812281+ type Uri = S::Uri;
22822282 type Cid = S::Cid;
22832283 type Did = Set<members::did>;
22842284 type IndexedAt = S::IndexedAt;
22852285- type Uri = S::Uri;
22852285+ type Creator = S::Creator;
22862286 type DisplayName = S::DisplayName;
22872287 }
22882288 ///State transition - sets the `indexed_at` field to Set
22892289 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
22902290 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
22912291 impl<S: State> State for SetIndexedAt<S> {
22922292- type Creator = S::Creator;
22922292+ type Uri = S::Uri;
22932293 type Cid = S::Cid;
22942294 type Did = S::Did;
22952295 type IndexedAt = Set<members::indexed_at>;
22962296- type Uri = S::Uri;
22962296+ type Creator = S::Creator;
22972297 type DisplayName = S::DisplayName;
22982298 }
22992299- ///State transition - sets the `uri` field to Set
23002300- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
23012301- impl<S: State> sealed::Sealed for SetUri<S> {}
23022302- impl<S: State> State for SetUri<S> {
23032303- type Creator = S::Creator;
22992299+ ///State transition - sets the `creator` field to Set
23002300+ pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
23012301+ impl<S: State> sealed::Sealed for SetCreator<S> {}
23022302+ impl<S: State> State for SetCreator<S> {
23032303+ type Uri = S::Uri;
23042304 type Cid = S::Cid;
23052305 type Did = S::Did;
23062306 type IndexedAt = S::IndexedAt;
23072307- type Uri = Set<members::uri>;
23072307+ type Creator = Set<members::creator>;
23082308 type DisplayName = S::DisplayName;
23092309 }
23102310 ///State transition - sets the `display_name` field to Set
23112311 pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
23122312 impl<S: State> sealed::Sealed for SetDisplayName<S> {}
23132313 impl<S: State> State for SetDisplayName<S> {
23142314- type Creator = S::Creator;
23142314+ type Uri = S::Uri;
23152315 type Cid = S::Cid;
23162316 type Did = S::Did;
23172317 type IndexedAt = S::IndexedAt;
23182318- type Uri = S::Uri;
23182318+ type Creator = S::Creator;
23192319 type DisplayName = Set<members::display_name>;
23202320 }
23212321 /// Marker types for field names
23222322 #[allow(non_camel_case_types)]
23232323 pub mod members {
23242324- ///Marker type for the `creator` field
23252325- pub struct creator(());
23242324+ ///Marker type for the `uri` field
23252325+ pub struct uri(());
23262326 ///Marker type for the `cid` field
23272327 pub struct cid(());
23282328 ///Marker type for the `did` field
23292329 pub struct did(());
23302330 ///Marker type for the `indexed_at` field
23312331 pub struct indexed_at(());
23322332- ///Marker type for the `uri` field
23332333- pub struct uri(());
23322332+ ///Marker type for the `creator` field
23332333+ pub struct creator(());
23342334 ///Marker type for the `display_name` field
23352335 pub struct display_name(());
23362336 }
···26482648impl<'a, S> GeneratorViewBuilder<'a, S>
26492649where
26502650 S: generator_view_state::State,
26512651- S::Creator: generator_view_state::IsSet,
26512651+ S::Uri: generator_view_state::IsSet,
26522652 S::Cid: generator_view_state::IsSet,
26532653 S::Did: generator_view_state::IsSet,
26542654 S::IndexedAt: generator_view_state::IsSet,
26552655- S::Uri: generator_view_state::IsSet,
26552655+ S::Creator: generator_view_state::IsSet,
26562656 S::DisplayName: generator_view_state::IsSet,
26572657{
26582658 /// Build the final struct
···34413441 }
34423442 /// State trait tracking which required fields have been set
34433443 pub trait State: sealed::Sealed {
34443444- type Cid;
34443444+ type Record;
34453445 type Author;
34463446 type IndexedAt;
34473447+ type Cid;
34473448 type Uri;
34483448- type Record;
34493449 }
34503450 /// Empty state - all required fields are unset
34513451 pub struct Empty(());
34523452 impl sealed::Sealed for Empty {}
34533453 impl State for Empty {
34543454- type Cid = Unset;
34543454+ type Record = Unset;
34553455 type Author = Unset;
34563456 type IndexedAt = Unset;
34573457+ type Cid = Unset;
34573458 type Uri = Unset;
34583458- type Record = Unset;
34593459 }
34603460- ///State transition - sets the `cid` field to Set
34613461- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
34623462- impl<S: State> sealed::Sealed for SetCid<S> {}
34633463- impl<S: State> State for SetCid<S> {
34643464- type Cid = Set<members::cid>;
34603460+ ///State transition - sets the `record` field to Set
34613461+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
34623462+ impl<S: State> sealed::Sealed for SetRecord<S> {}
34633463+ impl<S: State> State for SetRecord<S> {
34643464+ type Record = Set<members::record>;
34653465 type Author = S::Author;
34663466 type IndexedAt = S::IndexedAt;
34673467+ type Cid = S::Cid;
34673468 type Uri = S::Uri;
34683468- type Record = S::Record;
34693469 }
34703470 ///State transition - sets the `author` field to Set
34713471 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
34723472 impl<S: State> sealed::Sealed for SetAuthor<S> {}
34733473 impl<S: State> State for SetAuthor<S> {
34743474- type Cid = S::Cid;
34743474+ type Record = S::Record;
34753475 type Author = Set<members::author>;
34763476 type IndexedAt = S::IndexedAt;
34773477+ type Cid = S::Cid;
34773478 type Uri = S::Uri;
34783478- type Record = S::Record;
34793479 }
34803480 ///State transition - sets the `indexed_at` field to Set
34813481 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
34823482 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
34833483 impl<S: State> State for SetIndexedAt<S> {
34843484- type Cid = S::Cid;
34843484+ type Record = S::Record;
34853485 type Author = S::Author;
34863486 type IndexedAt = Set<members::indexed_at>;
34873487+ type Cid = S::Cid;
34873488 type Uri = S::Uri;
34893489+ }
34903490+ ///State transition - sets the `cid` field to Set
34913491+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
34923492+ impl<S: State> sealed::Sealed for SetCid<S> {}
34933493+ impl<S: State> State for SetCid<S> {
34883494 type Record = S::Record;
34953495+ type Author = S::Author;
34963496+ type IndexedAt = S::IndexedAt;
34973497+ type Cid = Set<members::cid>;
34983498+ type Uri = S::Uri;
34893499 }
34903500 ///State transition - sets the `uri` field to Set
34913501 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
34923502 impl<S: State> sealed::Sealed for SetUri<S> {}
34933503 impl<S: State> State for SetUri<S> {
34943494- type Cid = S::Cid;
35043504+ type Record = S::Record;
34953505 type Author = S::Author;
34963506 type IndexedAt = S::IndexedAt;
35073507+ type Cid = S::Cid;
34973508 type Uri = Set<members::uri>;
34983498- type Record = S::Record;
34993499- }
35003500- ///State transition - sets the `record` field to Set
35013501- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
35023502- impl<S: State> sealed::Sealed for SetRecord<S> {}
35033503- impl<S: State> State for SetRecord<S> {
35043504- type Cid = S::Cid;
35053505- type Author = S::Author;
35063506- type IndexedAt = S::IndexedAt;
35073507- type Uri = S::Uri;
35083508- type Record = Set<members::record>;
35093509 }
35103510 /// Marker types for field names
35113511 #[allow(non_camel_case_types)]
35123512 pub mod members {
35133513- ///Marker type for the `cid` field
35143514- pub struct cid(());
35133513+ ///Marker type for the `record` field
35143514+ pub struct record(());
35153515 ///Marker type for the `author` field
35163516 pub struct author(());
35173517 ///Marker type for the `indexed_at` field
35183518 pub struct indexed_at(());
35193519+ ///Marker type for the `cid` field
35203520+ pub struct cid(());
35193521 ///Marker type for the `uri` field
35203522 pub struct uri(());
35213521- ///Marker type for the `record` field
35223522- pub struct record(());
35233523 }
35243524}
35253525···38323832impl<'a, S> PostViewBuilder<'a, S>
38333833where
38343834 S: post_view_state::State,
38353835- S::Cid: post_view_state::IsSet,
38353835+ S::Record: post_view_state::IsSet,
38363836 S::Author: post_view_state::IsSet,
38373837 S::IndexedAt: post_view_state::IsSet,
38383838+ S::Cid: post_view_state::IsSet,
38383839 S::Uri: post_view_state::IsSet,
38393839- S::Record: post_view_state::IsSet,
38403840{
38413841 /// Build the final struct
38423842 pub fn build(self) -> PostView<'a> {
···42184218 }
42194219 /// State trait tracking which required fields have been set
42204220 pub trait State: sealed::Sealed {
42214221- type Root;
42224221 type Parent;
42224222+ type Root;
42234223 }
42244224 /// Empty state - all required fields are unset
42254225 pub struct Empty(());
42264226 impl sealed::Sealed for Empty {}
42274227 impl State for Empty {
42284228- type Root = Unset;
42294228 type Parent = Unset;
42304230- }
42314231- ///State transition - sets the `root` field to Set
42324232- pub struct SetRoot<S: State = Empty>(PhantomData<fn() -> S>);
42334233- impl<S: State> sealed::Sealed for SetRoot<S> {}
42344234- impl<S: State> State for SetRoot<S> {
42354235- type Root = Set<members::root>;
42364236- type Parent = S::Parent;
42294229+ type Root = Unset;
42374230 }
42384231 ///State transition - sets the `parent` field to Set
42394232 pub struct SetParent<S: State = Empty>(PhantomData<fn() -> S>);
42404233 impl<S: State> sealed::Sealed for SetParent<S> {}
42414234 impl<S: State> State for SetParent<S> {
42424242- type Root = S::Root;
42434235 type Parent = Set<members::parent>;
42364236+ type Root = S::Root;
42374237+ }
42384238+ ///State transition - sets the `root` field to Set
42394239+ pub struct SetRoot<S: State = Empty>(PhantomData<fn() -> S>);
42404240+ impl<S: State> sealed::Sealed for SetRoot<S> {}
42414241+ impl<S: State> State for SetRoot<S> {
42424242+ type Parent = S::Parent;
42434243+ type Root = Set<members::root>;
42444244 }
42454245 /// Marker types for field names
42464246 #[allow(non_camel_case_types)]
42474247 pub mod members {
42484248+ ///Marker type for the `parent` field
42494249+ pub struct parent(());
42484250 ///Marker type for the `root` field
42494251 pub struct root(());
42504250- ///Marker type for the `parent` field
42514251- pub struct parent(());
42524252 }
42534253}
42544254···43414341impl<'a, S> ReplyRefBuilder<'a, S>
43424342where
43434343 S: reply_ref_state::State,
43444344- S::Root: reply_ref_state::IsSet,
43454344 S::Parent: reply_ref_state::IsSet,
43454345+ S::Root: reply_ref_state::IsSet,
43464346{
43474347 /// Build the final struct
43484348 pub fn build(self) -> ReplyRef<'a> {
+15-15
crates/weaver-api/src/app_bsky/feed/generator.rs
···5656 }
5757 /// State trait tracking which required fields have been set
5858 pub trait State: sealed::Sealed {
5959- type CreatedAt;
6059 type Did;
6060+ type CreatedAt;
6161 type DisplayName;
6262 }
6363 /// Empty state - all required fields are unset
6464 pub struct Empty(());
6565 impl sealed::Sealed for Empty {}
6666 impl State for Empty {
6767- type CreatedAt = Unset;
6867 type Did = Unset;
6868+ type CreatedAt = Unset;
6969 type DisplayName = Unset;
7070 }
7171- ///State transition - sets the `created_at` field to Set
7272- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
7373- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
7474- impl<S: State> State for SetCreatedAt<S> {
7575- type CreatedAt = Set<members::created_at>;
7676- type Did = S::Did;
7777- type DisplayName = S::DisplayName;
7878- }
7971 ///State transition - sets the `did` field to Set
8072 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
8173 impl<S: State> sealed::Sealed for SetDid<S> {}
8274 impl<S: State> State for SetDid<S> {
8383- type CreatedAt = S::CreatedAt;
8475 type Did = Set<members::did>;
7676+ type CreatedAt = S::CreatedAt;
7777+ type DisplayName = S::DisplayName;
7878+ }
7979+ ///State transition - sets the `created_at` field to Set
8080+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
8181+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
8282+ impl<S: State> State for SetCreatedAt<S> {
8383+ type Did = S::Did;
8484+ type CreatedAt = Set<members::created_at>;
8585 type DisplayName = S::DisplayName;
8686 }
8787 ///State transition - sets the `display_name` field to Set
8888 pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
8989 impl<S: State> sealed::Sealed for SetDisplayName<S> {}
9090 impl<S: State> State for SetDisplayName<S> {
9191- type CreatedAt = S::CreatedAt;
9291 type Did = S::Did;
9292+ type CreatedAt = S::CreatedAt;
9393 type DisplayName = Set<members::display_name>;
9494 }
9595 /// Marker types for field names
9696 #[allow(non_camel_case_types)]
9797 pub mod members {
9898+ ///Marker type for the `did` field
9999+ pub struct did(());
98100 ///Marker type for the `created_at` field
99101 pub struct created_at(());
100100- ///Marker type for the `did` field
101101- pub struct did(());
102102 ///Marker type for the `display_name` field
103103 pub struct display_name(());
104104 }
···317317impl<'a, S> GeneratorBuilder<'a, S>
318318where
319319 S: generator_state::State,
320320- S::CreatedAt: generator_state::IsSet,
321320 S::Did: generator_state::IsSet,
321321+ S::CreatedAt: generator_state::IsSet,
322322 S::DisplayName: generator_state::IsSet,
323323{
324324 /// Build the final struct
+15-15
crates/weaver-api/src/app_bsky/feed/get_likes.rs
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type CreatedAt;
3736 type IndexedAt;
3837 type Actor;
3838+ type CreatedAt;
3939 }
4040 /// Empty state - all required fields are unset
4141 pub struct Empty(());
4242 impl sealed::Sealed for Empty {}
4343 impl State for Empty {
4444- type CreatedAt = Unset;
4544 type IndexedAt = Unset;
4645 type Actor = Unset;
4747- }
4848- ///State transition - sets the `created_at` field to Set
4949- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5050- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5151- impl<S: State> State for SetCreatedAt<S> {
5252- type CreatedAt = Set<members::created_at>;
5353- type IndexedAt = S::IndexedAt;
5454- type Actor = S::Actor;
4646+ type CreatedAt = Unset;
5547 }
5648 ///State transition - sets the `indexed_at` field to Set
5749 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
5850 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
5951 impl<S: State> State for SetIndexedAt<S> {
6060- type CreatedAt = S::CreatedAt;
6152 type IndexedAt = Set<members::indexed_at>;
6253 type Actor = S::Actor;
5454+ type CreatedAt = S::CreatedAt;
6355 }
6456 ///State transition - sets the `actor` field to Set
6557 pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
6658 impl<S: State> sealed::Sealed for SetActor<S> {}
6759 impl<S: State> State for SetActor<S> {
6868- type CreatedAt = S::CreatedAt;
6960 type IndexedAt = S::IndexedAt;
7061 type Actor = Set<members::actor>;
6262+ type CreatedAt = S::CreatedAt;
6363+ }
6464+ ///State transition - sets the `created_at` field to Set
6565+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6666+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
6767+ impl<S: State> State for SetCreatedAt<S> {
6868+ type IndexedAt = S::IndexedAt;
6969+ type Actor = S::Actor;
7070+ type CreatedAt = Set<members::created_at>;
7171 }
7272 /// Marker types for field names
7373 #[allow(non_camel_case_types)]
7474 pub mod members {
7575- ///Marker type for the `created_at` field
7676- pub struct created_at(());
7775 ///Marker type for the `indexed_at` field
7876 pub struct indexed_at(());
7977 ///Marker type for the `actor` field
8078 pub struct actor(());
7979+ ///Marker type for the `created_at` field
8080+ pub struct created_at(());
8181 }
8282}
8383···170170impl<'a, S> LikeBuilder<'a, S>
171171where
172172 S: like_state::State,
173173- S::CreatedAt: like_state::IsSet,
174173 S::IndexedAt: like_state::IsSet,
175174 S::Actor: like_state::IsSet,
175175+ S::CreatedAt: like_state::IsSet,
176176{
177177 /// Build the final struct
178178 pub fn build(self) -> Like<'a> {
+28-28
crates/weaver-api/src/app_bsky/feed/post.rs
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040+ type Index;
4041 type Type;
4142 type Value;
4242- type Index;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848+ type Index = Unset;
4849 type Type = Unset;
4950 type Value = Unset;
5050- type Index = Unset;
5151+ }
5252+ ///State transition - sets the `index` field to Set
5353+ pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetIndex<S> {}
5555+ impl<S: State> State for SetIndex<S> {
5656+ type Index = Set<members::index>;
5757+ type Type = S::Type;
5858+ type Value = S::Value;
5159 }
5260 ///State transition - sets the `type` field to Set
5361 pub struct SetType<S: State = Empty>(PhantomData<fn() -> S>);
5462 impl<S: State> sealed::Sealed for SetType<S> {}
5563 impl<S: State> State for SetType<S> {
6464+ type Index = S::Index;
5665 type Type = Set<members::r#type>;
5766 type Value = S::Value;
5858- type Index = S::Index;
5967 }
6068 ///State transition - sets the `value` field to Set
6169 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
6270 impl<S: State> sealed::Sealed for SetValue<S> {}
6371 impl<S: State> State for SetValue<S> {
6464- type Type = S::Type;
6565- type Value = Set<members::value>;
6672 type Index = S::Index;
6767- }
6868- ///State transition - sets the `index` field to Set
6969- pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
7070- impl<S: State> sealed::Sealed for SetIndex<S> {}
7171- impl<S: State> State for SetIndex<S> {
7273 type Type = S::Type;
7373- type Value = S::Value;
7474- type Index = Set<members::index>;
7474+ type Value = Set<members::value>;
7575 }
7676 /// Marker types for field names
7777 #[allow(non_camel_case_types)]
7878 pub mod members {
7979+ ///Marker type for the `index` field
8080+ pub struct index(());
7981 ///Marker type for the `type` field
8082 pub struct r#type(());
8183 ///Marker type for the `value` field
8284 pub struct value(());
8383- ///Marker type for the `index` field
8484- pub struct index(());
8585 }
8686}
8787···174174impl<'a, S> EntityBuilder<'a, S>
175175where
176176 S: entity_state::State,
177177+ S::Index: entity_state::IsSet,
177178 S::Type: entity_state::IsSet,
178179 S::Value: entity_state::IsSet,
179179- S::Index: entity_state::IsSet,
180180{
181181 /// Build the final struct
182182 pub fn build(self) -> Entity<'a> {
···622622 }
623623 /// State trait tracking which required fields have been set
624624 pub trait State: sealed::Sealed {
625625- type Text;
626625 type CreatedAt;
626626+ type Text;
627627 }
628628 /// Empty state - all required fields are unset
629629 pub struct Empty(());
630630 impl sealed::Sealed for Empty {}
631631 impl State for Empty {
632632- type Text = Unset;
633632 type CreatedAt = Unset;
634634- }
635635- ///State transition - sets the `text` field to Set
636636- pub struct SetText<S: State = Empty>(PhantomData<fn() -> S>);
637637- impl<S: State> sealed::Sealed for SetText<S> {}
638638- impl<S: State> State for SetText<S> {
639639- type Text = Set<members::text>;
640640- type CreatedAt = S::CreatedAt;
633633+ type Text = Unset;
641634 }
642635 ///State transition - sets the `created_at` field to Set
643636 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
644637 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
645638 impl<S: State> State for SetCreatedAt<S> {
646646- type Text = S::Text;
647639 type CreatedAt = Set<members::created_at>;
640640+ type Text = S::Text;
641641+ }
642642+ ///State transition - sets the `text` field to Set
643643+ pub struct SetText<S: State = Empty>(PhantomData<fn() -> S>);
644644+ impl<S: State> sealed::Sealed for SetText<S> {}
645645+ impl<S: State> State for SetText<S> {
646646+ type CreatedAt = S::CreatedAt;
647647+ type Text = Set<members::text>;
648648 }
649649 /// Marker types for field names
650650 #[allow(non_camel_case_types)]
651651 pub mod members {
652652- ///Marker type for the `text` field
653653- pub struct text(());
654652 ///Marker type for the `created_at` field
655653 pub struct created_at(());
654654+ ///Marker type for the `text` field
655655+ pub struct text(());
656656 }
657657}
658658···869869impl<'a, S> PostBuilder<'a, S>
870870where
871871 S: post_state::State,
872872- S::Text: post_state::IsSet,
873872 S::CreatedAt: post_state::IsSet,
873873+ S::Text: post_state::IsSet,
874874{
875875 /// Build the final struct
876876 pub fn build(self) -> Post<'a> {
+13-13
crates/weaver-api/src/app_bsky/feed/postgate.rs
···224224 }
225225 /// State trait tracking which required fields have been set
226226 pub trait State: sealed::Sealed {
227227- type CreatedAt;
228227 type Post;
228228+ type CreatedAt;
229229 }
230230 /// Empty state - all required fields are unset
231231 pub struct Empty(());
232232 impl sealed::Sealed for Empty {}
233233 impl State for Empty {
234234- type CreatedAt = Unset;
235234 type Post = Unset;
236236- }
237237- ///State transition - sets the `created_at` field to Set
238238- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
239239- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
240240- impl<S: State> State for SetCreatedAt<S> {
241241- type CreatedAt = Set<members::created_at>;
242242- type Post = S::Post;
235235+ type CreatedAt = Unset;
243236 }
244237 ///State transition - sets the `post` field to Set
245238 pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
246239 impl<S: State> sealed::Sealed for SetPost<S> {}
247240 impl<S: State> State for SetPost<S> {
248248- type CreatedAt = S::CreatedAt;
249241 type Post = Set<members::post>;
242242+ type CreatedAt = S::CreatedAt;
243243+ }
244244+ ///State transition - sets the `created_at` field to Set
245245+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
246246+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
247247+ impl<S: State> State for SetCreatedAt<S> {
248248+ type Post = S::Post;
249249+ type CreatedAt = Set<members::created_at>;
250250 }
251251 /// Marker types for field names
252252 #[allow(non_camel_case_types)]
253253 pub mod members {
254254- ///Marker type for the `created_at` field
255255- pub struct created_at(());
256254 ///Marker type for the `post` field
257255 pub struct post(());
256256+ ///Marker type for the `created_at` field
257257+ pub struct created_at(());
258258 }
259259}
260260···367367impl<'a, S> PostgateBuilder<'a, S>
368368where
369369 S: postgate_state::State,
370370- S::CreatedAt: postgate_state::IsSet,
371370 S::Post: postgate_state::IsSet,
371371+ S::CreatedAt: postgate_state::IsSet,
372372{
373373 /// Build the final struct
374374 pub fn build(self) -> Postgate<'a> {
+13-13
crates/weaver-api/src/app_bsky/feed/repost.rs
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type CreatedAt;
4039 type Subject;
4040+ type CreatedAt;
4141 }
4242 /// Empty state - all required fields are unset
4343 pub struct Empty(());
4444 impl sealed::Sealed for Empty {}
4545 impl State for Empty {
4646- type CreatedAt = Unset;
4746 type Subject = Unset;
4848- }
4949- ///State transition - sets the `created_at` field to Set
5050- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5151- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5252- impl<S: State> State for SetCreatedAt<S> {
5353- type CreatedAt = Set<members::created_at>;
5454- type Subject = S::Subject;
4747+ type CreatedAt = Unset;
5548 }
5649 ///State transition - sets the `subject` field to Set
5750 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5851 impl<S: State> sealed::Sealed for SetSubject<S> {}
5952 impl<S: State> State for SetSubject<S> {
6060- type CreatedAt = S::CreatedAt;
6153 type Subject = Set<members::subject>;
5454+ type CreatedAt = S::CreatedAt;
5555+ }
5656+ ///State transition - sets the `created_at` field to Set
5757+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5858+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5959+ impl<S: State> State for SetCreatedAt<S> {
6060+ type Subject = S::Subject;
6161+ type CreatedAt = Set<members::created_at>;
6262 }
6363 /// Marker types for field names
6464 #[allow(non_camel_case_types)]
6565 pub mod members {
6666- ///Marker type for the `created_at` field
6767- pub struct created_at(());
6866 ///Marker type for the `subject` field
6967 pub struct subject(());
6868+ ///Marker type for the `created_at` field
6969+ pub struct created_at(());
7070 }
7171}
7272···159159impl<'a, S> RepostBuilder<'a, S>
160160where
161161 S: repost_state::State,
162162- S::CreatedAt: repost_state::IsSet,
163162 S::Subject: repost_state::IsSet,
163163+ S::CreatedAt: repost_state::IsSet,
164164{
165165 /// Build the final struct
166166 pub fn build(self) -> Repost<'a> {
+13-13
crates/weaver-api/src/app_bsky/feed/threadgate.rs
···463463 }
464464 /// State trait tracking which required fields have been set
465465 pub trait State: sealed::Sealed {
466466- type Post;
467466 type CreatedAt;
467467+ type Post;
468468 }
469469 /// Empty state - all required fields are unset
470470 pub struct Empty(());
471471 impl sealed::Sealed for Empty {}
472472 impl State for Empty {
473473- type Post = Unset;
474473 type CreatedAt = Unset;
475475- }
476476- ///State transition - sets the `post` field to Set
477477- pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
478478- impl<S: State> sealed::Sealed for SetPost<S> {}
479479- impl<S: State> State for SetPost<S> {
480480- type Post = Set<members::post>;
481481- type CreatedAt = S::CreatedAt;
474474+ type Post = Unset;
482475 }
483476 ///State transition - sets the `created_at` field to Set
484477 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
485478 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
486479 impl<S: State> State for SetCreatedAt<S> {
487487- type Post = S::Post;
488480 type CreatedAt = Set<members::created_at>;
481481+ type Post = S::Post;
482482+ }
483483+ ///State transition - sets the `post` field to Set
484484+ pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
485485+ impl<S: State> sealed::Sealed for SetPost<S> {}
486486+ impl<S: State> State for SetPost<S> {
487487+ type CreatedAt = S::CreatedAt;
488488+ type Post = Set<members::post>;
489489 }
490490 /// Marker types for field names
491491 #[allow(non_camel_case_types)]
492492 pub mod members {
493493- ///Marker type for the `post` field
494494- pub struct post(());
495493 ///Marker type for the `created_at` field
496494 pub struct created_at(());
495495+ ///Marker type for the `post` field
496496+ pub struct post(());
497497 }
498498}
499499···603603impl<'a, S> ThreadgateBuilder<'a, S>
604604where
605605 S: threadgate_state::State,
606606- S::Post: threadgate_state::IsSet,
607606 S::CreatedAt: threadgate_state::IsSet,
607607+ S::Post: threadgate_state::IsSet,
608608{
609609 /// Build the final struct
610610 pub fn build(self) -> Threadgate<'a> {
+144-144
crates/weaver-api/src/app_bsky/graph.rs
···12841284 /// State trait tracking which required fields have been set
12851285 pub trait State: sealed::Sealed {
12861286 type Purpose;
12871287+ type Name;
12871288 type Cid;
12891289+ type Creator;
12901290+ type IndexedAt;
12881291 type Uri;
12891289- type IndexedAt;
12901290- type Name;
12911291- type Creator;
12921292 }
12931293 /// Empty state - all required fields are unset
12941294 pub struct Empty(());
12951295 impl sealed::Sealed for Empty {}
12961296 impl State for Empty {
12971297 type Purpose = Unset;
12981298- type Cid = Unset;
12991299- type Uri = Unset;
13001300- type IndexedAt = Unset;
13011298 type Name = Unset;
12991299+ type Cid = Unset;
13021300 type Creator = Unset;
13011301+ type IndexedAt = Unset;
13021302+ type Uri = Unset;
13031303 }
13041304 ///State transition - sets the `purpose` field to Set
13051305 pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
13061306 impl<S: State> sealed::Sealed for SetPurpose<S> {}
13071307 impl<S: State> State for SetPurpose<S> {
13081308 type Purpose = Set<members::purpose>;
13091309+ type Name = S::Name;
13091310 type Cid = S::Cid;
13101310- type Uri = S::Uri;
13111311+ type Creator = S::Creator;
13111312 type IndexedAt = S::IndexedAt;
13121312- type Name = S::Name;
13131313+ type Uri = S::Uri;
13141314+ }
13151315+ ///State transition - sets the `name` field to Set
13161316+ pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
13171317+ impl<S: State> sealed::Sealed for SetName<S> {}
13181318+ impl<S: State> State for SetName<S> {
13191319+ type Purpose = S::Purpose;
13201320+ type Name = Set<members::name>;
13211321+ type Cid = S::Cid;
13131322 type Creator = S::Creator;
13231323+ type IndexedAt = S::IndexedAt;
13241324+ type Uri = S::Uri;
13141325 }
13151326 ///State transition - sets the `cid` field to Set
13161327 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
13171328 impl<S: State> sealed::Sealed for SetCid<S> {}
13181329 impl<S: State> State for SetCid<S> {
13191330 type Purpose = S::Purpose;
13311331+ type Name = S::Name;
13201332 type Cid = Set<members::cid>;
13331333+ type Creator = S::Creator;
13341334+ type IndexedAt = S::IndexedAt;
13211335 type Uri = S::Uri;
13221322- type IndexedAt = S::IndexedAt;
13231323- type Name = S::Name;
13241324- type Creator = S::Creator;
13251336 }
13261326- ///State transition - sets the `uri` field to Set
13271327- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
13281328- impl<S: State> sealed::Sealed for SetUri<S> {}
13291329- impl<S: State> State for SetUri<S> {
13371337+ ///State transition - sets the `creator` field to Set
13381338+ pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
13391339+ impl<S: State> sealed::Sealed for SetCreator<S> {}
13401340+ impl<S: State> State for SetCreator<S> {
13301341 type Purpose = S::Purpose;
13421342+ type Name = S::Name;
13311343 type Cid = S::Cid;
13321332- type Uri = Set<members::uri>;
13441344+ type Creator = Set<members::creator>;
13331345 type IndexedAt = S::IndexedAt;
13341334- type Name = S::Name;
13351335- type Creator = S::Creator;
13461346+ type Uri = S::Uri;
13361347 }
13371348 ///State transition - sets the `indexed_at` field to Set
13381349 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
13391350 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
13401351 impl<S: State> State for SetIndexedAt<S> {
13411352 type Purpose = S::Purpose;
13421342- type Cid = S::Cid;
13431343- type Uri = S::Uri;
13441344- type IndexedAt = Set<members::indexed_at>;
13451353 type Name = S::Name;
13461346- type Creator = S::Creator;
13471347- }
13481348- ///State transition - sets the `name` field to Set
13491349- pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
13501350- impl<S: State> sealed::Sealed for SetName<S> {}
13511351- impl<S: State> State for SetName<S> {
13521352- type Purpose = S::Purpose;
13531354 type Cid = S::Cid;
13551355+ type Creator = S::Creator;
13561356+ type IndexedAt = Set<members::indexed_at>;
13541357 type Uri = S::Uri;
13551355- type IndexedAt = S::IndexedAt;
13561356- type Name = Set<members::name>;
13571357- type Creator = S::Creator;
13581358 }
13591359- ///State transition - sets the `creator` field to Set
13601360- pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
13611361- impl<S: State> sealed::Sealed for SetCreator<S> {}
13621362- impl<S: State> State for SetCreator<S> {
13591359+ ///State transition - sets the `uri` field to Set
13601360+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
13611361+ impl<S: State> sealed::Sealed for SetUri<S> {}
13621362+ impl<S: State> State for SetUri<S> {
13631363 type Purpose = S::Purpose;
13641364+ type Name = S::Name;
13641365 type Cid = S::Cid;
13651365- type Uri = S::Uri;
13661366+ type Creator = S::Creator;
13661367 type IndexedAt = S::IndexedAt;
13671367- type Name = S::Name;
13681368- type Creator = Set<members::creator>;
13681368+ type Uri = Set<members::uri>;
13691369 }
13701370 /// Marker types for field names
13711371 #[allow(non_camel_case_types)]
13721372 pub mod members {
13731373 ///Marker type for the `purpose` field
13741374 pub struct purpose(());
13751375- ///Marker type for the `cid` field
13761376- pub struct cid(());
13771377- ///Marker type for the `uri` field
13781378- pub struct uri(());
13791379- ///Marker type for the `indexed_at` field
13801380- pub struct indexed_at(());
13811375 ///Marker type for the `name` field
13821376 pub struct name(());
13771377+ ///Marker type for the `cid` field
13781378+ pub struct cid(());
13831379 ///Marker type for the `creator` field
13841380 pub struct creator(());
13811381+ ///Marker type for the `indexed_at` field
13821382+ pub struct indexed_at(());
13831383+ ///Marker type for the `uri` field
13841384+ pub struct uri(());
13851385 }
13861386}
13871387···16621662where
16631663 S: list_view_state::State,
16641664 S::Purpose: list_view_state::IsSet,
16651665- S::Cid: list_view_state::IsSet,
16661666- S::Uri: list_view_state::IsSet,
16671667- S::IndexedAt: list_view_state::IsSet,
16681665 S::Name: list_view_state::IsSet,
16661666+ S::Cid: list_view_state::IsSet,
16691667 S::Creator: list_view_state::IsSet,
16681668+ S::IndexedAt: list_view_state::IsSet,
16691669+ S::Uri: list_view_state::IsSet,
16701670{
16711671 /// Build the final struct
16721672 pub fn build(self) -> ListView<'a> {
···18411841 }
18421842 /// State trait tracking which required fields have been set
18431843 pub trait State: sealed::Sealed {
18441844- type Cid;
18441844+ type Name;
18451845 type Purpose;
18461846 type Uri;
18471847- type Name;
18471847+ type Cid;
18481848 }
18491849 /// Empty state - all required fields are unset
18501850 pub struct Empty(());
18511851 impl sealed::Sealed for Empty {}
18521852 impl State for Empty {
18531853- type Cid = Unset;
18531853+ type Name = Unset;
18541854 type Purpose = Unset;
18551855 type Uri = Unset;
18561856- type Name = Unset;
18561856+ type Cid = Unset;
18571857 }
18581858- ///State transition - sets the `cid` field to Set
18591859- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
18601860- impl<S: State> sealed::Sealed for SetCid<S> {}
18611861- impl<S: State> State for SetCid<S> {
18621862- type Cid = Set<members::cid>;
18581858+ ///State transition - sets the `name` field to Set
18591859+ pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
18601860+ impl<S: State> sealed::Sealed for SetName<S> {}
18611861+ impl<S: State> State for SetName<S> {
18621862+ type Name = Set<members::name>;
18631863 type Purpose = S::Purpose;
18641864 type Uri = S::Uri;
18651865- type Name = S::Name;
18651865+ type Cid = S::Cid;
18661866 }
18671867 ///State transition - sets the `purpose` field to Set
18681868 pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
18691869 impl<S: State> sealed::Sealed for SetPurpose<S> {}
18701870 impl<S: State> State for SetPurpose<S> {
18711871- type Cid = S::Cid;
18711871+ type Name = S::Name;
18721872 type Purpose = Set<members::purpose>;
18731873 type Uri = S::Uri;
18741874- type Name = S::Name;
18741874+ type Cid = S::Cid;
18751875 }
18761876 ///State transition - sets the `uri` field to Set
18771877 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
18781878 impl<S: State> sealed::Sealed for SetUri<S> {}
18791879 impl<S: State> State for SetUri<S> {
18801880- type Cid = S::Cid;
18801880+ type Name = S::Name;
18811881 type Purpose = S::Purpose;
18821882 type Uri = Set<members::uri>;
18831883- type Name = S::Name;
18841884- }
18851885- ///State transition - sets the `name` field to Set
18861886- pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
18871887- impl<S: State> sealed::Sealed for SetName<S> {}
18881888- impl<S: State> State for SetName<S> {
18891883 type Cid = S::Cid;
18841884+ }
18851885+ ///State transition - sets the `cid` field to Set
18861886+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
18871887+ impl<S: State> sealed::Sealed for SetCid<S> {}
18881888+ impl<S: State> State for SetCid<S> {
18891889+ type Name = S::Name;
18901890 type Purpose = S::Purpose;
18911891 type Uri = S::Uri;
18921892- type Name = Set<members::name>;
18921892+ type Cid = Set<members::cid>;
18931893 }
18941894 /// Marker types for field names
18951895 #[allow(non_camel_case_types)]
18961896 pub mod members {
18971897- ///Marker type for the `cid` field
18981898- pub struct cid(());
18971897+ ///Marker type for the `name` field
18981898+ pub struct name(());
18991899 ///Marker type for the `purpose` field
19001900 pub struct purpose(());
19011901 ///Marker type for the `uri` field
19021902 pub struct uri(());
19031903- ///Marker type for the `name` field
19041904- pub struct name(());
19031903+ ///Marker type for the `cid` field
19041904+ pub struct cid(());
19051905 }
19061906}
19071907···21182118impl<'a, S> ListViewBasicBuilder<'a, S>
21192119where
21202120 S: list_view_basic_state::State,
21212121- S::Cid: list_view_basic_state::IsSet,
21212121+ S::Name: list_view_basic_state::IsSet,
21222122 S::Purpose: list_view_basic_state::IsSet,
21232123 S::Uri: list_view_basic_state::IsSet,
21242124- S::Name: list_view_basic_state::IsSet,
21242124+ S::Cid: list_view_basic_state::IsSet,
21252125{
21262126 /// Build the final struct
21272127 pub fn build(self) -> ListViewBasic<'a> {
···27052705 }
27062706 /// State trait tracking which required fields have been set
27072707 pub trait State: sealed::Sealed {
27082708+ type Creator;
27092709+ type Uri;
27102710+ type Record;
27082711 type IndexedAt;
27092709- type Record;
27102712 type Cid;
27112711- type Creator;
27122712- type Uri;
27132713 }
27142714 /// Empty state - all required fields are unset
27152715 pub struct Empty(());
27162716 impl sealed::Sealed for Empty {}
27172717 impl State for Empty {
27182718- type IndexedAt = Unset;
27192719- type Record = Unset;
27202720- type Cid = Unset;
27212718 type Creator = Unset;
27222719 type Uri = Unset;
27202720+ type Record = Unset;
27212721+ type IndexedAt = Unset;
27222722+ type Cid = Unset;
27232723 }
27242724- ///State transition - sets the `indexed_at` field to Set
27252725- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
27262726- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
27272727- impl<S: State> State for SetIndexedAt<S> {
27282728- type IndexedAt = Set<members::indexed_at>;
27242724+ ///State transition - sets the `creator` field to Set
27252725+ pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
27262726+ impl<S: State> sealed::Sealed for SetCreator<S> {}
27272727+ impl<S: State> State for SetCreator<S> {
27282728+ type Creator = Set<members::creator>;
27292729+ type Uri = S::Uri;
27292730 type Record = S::Record;
27312731+ type IndexedAt = S::IndexedAt;
27302732 type Cid = S::Cid;
27332733+ }
27342734+ ///State transition - sets the `uri` field to Set
27352735+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
27362736+ impl<S: State> sealed::Sealed for SetUri<S> {}
27372737+ impl<S: State> State for SetUri<S> {
27312738 type Creator = S::Creator;
27322732- type Uri = S::Uri;
27392739+ type Uri = Set<members::uri>;
27402740+ type Record = S::Record;
27412741+ type IndexedAt = S::IndexedAt;
27422742+ type Cid = S::Cid;
27332743 }
27342744 ///State transition - sets the `record` field to Set
27352745 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
27362746 impl<S: State> sealed::Sealed for SetRecord<S> {}
27372747 impl<S: State> State for SetRecord<S> {
27382738- type IndexedAt = S::IndexedAt;
27482748+ type Creator = S::Creator;
27492749+ type Uri = S::Uri;
27392750 type Record = Set<members::record>;
27512751+ type IndexedAt = S::IndexedAt;
27402752 type Cid = S::Cid;
27532753+ }
27542754+ ///State transition - sets the `indexed_at` field to Set
27552755+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
27562756+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
27572757+ impl<S: State> State for SetIndexedAt<S> {
27412758 type Creator = S::Creator;
27422759 type Uri = S::Uri;
27602760+ type Record = S::Record;
27612761+ type IndexedAt = Set<members::indexed_at>;
27622762+ type Cid = S::Cid;
27432763 }
27442764 ///State transition - sets the `cid` field to Set
27452765 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
27462766 impl<S: State> sealed::Sealed for SetCid<S> {}
27472767 impl<S: State> State for SetCid<S> {
27482748- type IndexedAt = S::IndexedAt;
27492749- type Record = S::Record;
27502750- type Cid = Set<members::cid>;
27512768 type Creator = S::Creator;
27522769 type Uri = S::Uri;
27532753- }
27542754- ///State transition - sets the `creator` field to Set
27552755- pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
27562756- impl<S: State> sealed::Sealed for SetCreator<S> {}
27572757- impl<S: State> State for SetCreator<S> {
27582758- type IndexedAt = S::IndexedAt;
27592770 type Record = S::Record;
27602760- type Cid = S::Cid;
27612761- type Creator = Set<members::creator>;
27622762- type Uri = S::Uri;
27632763- }
27642764- ///State transition - sets the `uri` field to Set
27652765- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
27662766- impl<S: State> sealed::Sealed for SetUri<S> {}
27672767- impl<S: State> State for SetUri<S> {
27682771 type IndexedAt = S::IndexedAt;
27692769- type Record = S::Record;
27702770- type Cid = S::Cid;
27712771- type Creator = S::Creator;
27722772- type Uri = Set<members::uri>;
27722772+ type Cid = Set<members::cid>;
27732773 }
27742774 /// Marker types for field names
27752775 #[allow(non_camel_case_types)]
27762776 pub mod members {
27772777- ///Marker type for the `indexed_at` field
27782778- pub struct indexed_at(());
27792779- ///Marker type for the `record` field
27802780- pub struct record(());
27812781- ///Marker type for the `cid` field
27822782- pub struct cid(());
27832777 ///Marker type for the `creator` field
27842778 pub struct creator(());
27852779 ///Marker type for the `uri` field
27862780 pub struct uri(());
27812781+ ///Marker type for the `record` field
27822782+ pub struct record(());
27832783+ ///Marker type for the `indexed_at` field
27842784+ pub struct indexed_at(());
27852785+ ///Marker type for the `cid` field
27862786+ pub struct cid(());
27872787 }
27882788}
27892789···30363036impl<'a, S> StarterPackViewBuilder<'a, S>
30373037where
30383038 S: starter_pack_view_state::State,
30393039- S::IndexedAt: starter_pack_view_state::IsSet,
30403040- S::Record: starter_pack_view_state::IsSet,
30413041- S::Cid: starter_pack_view_state::IsSet,
30423039 S::Creator: starter_pack_view_state::IsSet,
30433040 S::Uri: starter_pack_view_state::IsSet,
30413041+ S::Record: starter_pack_view_state::IsSet,
30423042+ S::IndexedAt: starter_pack_view_state::IsSet,
30433043+ S::Cid: starter_pack_view_state::IsSet,
30443044{
30453045 /// Build the final struct
30463046 pub fn build(self) -> StarterPackView<'a> {
···31893189 }
31903190 /// State trait tracking which required fields have been set
31913191 pub trait State: sealed::Sealed {
31923192- type IndexedAt;
31933193- type Creator;
31943192 type Cid;
31933193+ type Creator;
31943194+ type IndexedAt;
31953195 type Uri;
31963196 type Record;
31973197 }
···31993199 pub struct Empty(());
32003200 impl sealed::Sealed for Empty {}
32013201 impl State for Empty {
32023202- type IndexedAt = Unset;
32023202+ type Cid = Unset;
32033203 type Creator = Unset;
32043204- type Cid = Unset;
32043204+ type IndexedAt = Unset;
32053205 type Uri = Unset;
32063206 type Record = Unset;
32073207 }
32083208- ///State transition - sets the `indexed_at` field to Set
32093209- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
32103210- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
32113211- impl<S: State> State for SetIndexedAt<S> {
32123212- type IndexedAt = Set<members::indexed_at>;
32083208+ ///State transition - sets the `cid` field to Set
32093209+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
32103210+ impl<S: State> sealed::Sealed for SetCid<S> {}
32113211+ impl<S: State> State for SetCid<S> {
32123212+ type Cid = Set<members::cid>;
32133213 type Creator = S::Creator;
32143214- type Cid = S::Cid;
32143214+ type IndexedAt = S::IndexedAt;
32153215 type Uri = S::Uri;
32163216 type Record = S::Record;
32173217 }
···32193219 pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
32203220 impl<S: State> sealed::Sealed for SetCreator<S> {}
32213221 impl<S: State> State for SetCreator<S> {
32223222- type IndexedAt = S::IndexedAt;
32233223- type Creator = Set<members::creator>;
32243222 type Cid = S::Cid;
32233223+ type Creator = Set<members::creator>;
32243224+ type IndexedAt = S::IndexedAt;
32253225 type Uri = S::Uri;
32263226 type Record = S::Record;
32273227 }
32283228- ///State transition - sets the `cid` field to Set
32293229- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
32303230- impl<S: State> sealed::Sealed for SetCid<S> {}
32313231- impl<S: State> State for SetCid<S> {
32323232- type IndexedAt = S::IndexedAt;
32283228+ ///State transition - sets the `indexed_at` field to Set
32293229+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
32303230+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
32313231+ impl<S: State> State for SetIndexedAt<S> {
32323232+ type Cid = S::Cid;
32333233 type Creator = S::Creator;
32343234- type Cid = Set<members::cid>;
32343234+ type IndexedAt = Set<members::indexed_at>;
32353235 type Uri = S::Uri;
32363236 type Record = S::Record;
32373237 }
···32393239 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
32403240 impl<S: State> sealed::Sealed for SetUri<S> {}
32413241 impl<S: State> State for SetUri<S> {
32423242- type IndexedAt = S::IndexedAt;
32433243- type Creator = S::Creator;
32443242 type Cid = S::Cid;
32433243+ type Creator = S::Creator;
32443244+ type IndexedAt = S::IndexedAt;
32453245 type Uri = Set<members::uri>;
32463246 type Record = S::Record;
32473247 }
···32493249 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
32503250 impl<S: State> sealed::Sealed for SetRecord<S> {}
32513251 impl<S: State> State for SetRecord<S> {
32523252- type IndexedAt = S::IndexedAt;
32533253- type Creator = S::Creator;
32543252 type Cid = S::Cid;
32533253+ type Creator = S::Creator;
32543254+ type IndexedAt = S::IndexedAt;
32553255 type Uri = S::Uri;
32563256 type Record = Set<members::record>;
32573257 }
32583258 /// Marker types for field names
32593259 #[allow(non_camel_case_types)]
32603260 pub mod members {
32613261- ///Marker type for the `indexed_at` field
32623262- pub struct indexed_at(());
32633263- ///Marker type for the `creator` field
32643264- pub struct creator(());
32653261 ///Marker type for the `cid` field
32663262 pub struct cid(());
32633263+ ///Marker type for the `creator` field
32643264+ pub struct creator(());
32653265+ ///Marker type for the `indexed_at` field
32663266+ pub struct indexed_at(());
32673267 ///Marker type for the `uri` field
32683268 pub struct uri(());
32693269 ///Marker type for the `record` field
···34783478impl<'a, S> StarterPackViewBasicBuilder<'a, S>
34793479where
34803480 S: starter_pack_view_basic_state::State,
34813481- S::IndexedAt: starter_pack_view_basic_state::IsSet,
34823482- S::Creator: starter_pack_view_basic_state::IsSet,
34833481 S::Cid: starter_pack_view_basic_state::IsSet,
34823482+ S::Creator: starter_pack_view_basic_state::IsSet,
34833483+ S::IndexedAt: starter_pack_view_basic_state::IsSet,
34843484 S::Uri: starter_pack_view_basic_state::IsSet,
34853485 S::Record: starter_pack_view_basic_state::IsSet,
34863486{
+15-15
crates/weaver-api/src/app_bsky/graph/list.rs
···5252 /// State trait tracking which required fields have been set
5353 pub trait State: sealed::Sealed {
5454 type Name;
5555- type Purpose;
5655 type CreatedAt;
5656+ type Purpose;
5757 }
5858 /// Empty state - all required fields are unset
5959 pub struct Empty(());
6060 impl sealed::Sealed for Empty {}
6161 impl State for Empty {
6262 type Name = Unset;
6363- type Purpose = Unset;
6463 type CreatedAt = Unset;
6464+ type Purpose = Unset;
6565 }
6666 ///State transition - sets the `name` field to Set
6767 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
6868 impl<S: State> sealed::Sealed for SetName<S> {}
6969 impl<S: State> State for SetName<S> {
7070 type Name = Set<members::name>;
7171- type Purpose = S::Purpose;
7271 type CreatedAt = S::CreatedAt;
7373- }
7474- ///State transition - sets the `purpose` field to Set
7575- pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
7676- impl<S: State> sealed::Sealed for SetPurpose<S> {}
7777- impl<S: State> State for SetPurpose<S> {
7878- type Name = S::Name;
7979- type Purpose = Set<members::purpose>;
8080- type CreatedAt = S::CreatedAt;
7272+ type Purpose = S::Purpose;
8173 }
8274 ///State transition - sets the `created_at` field to Set
8375 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
8476 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
8577 impl<S: State> State for SetCreatedAt<S> {
8678 type Name = S::Name;
8787- type Purpose = S::Purpose;
8879 type CreatedAt = Set<members::created_at>;
8080+ type Purpose = S::Purpose;
8181+ }
8282+ ///State transition - sets the `purpose` field to Set
8383+ pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
8484+ impl<S: State> sealed::Sealed for SetPurpose<S> {}
8585+ impl<S: State> State for SetPurpose<S> {
8686+ type Name = S::Name;
8787+ type CreatedAt = S::CreatedAt;
8888+ type Purpose = Set<members::purpose>;
8989 }
9090 /// Marker types for field names
9191 #[allow(non_camel_case_types)]
9292 pub mod members {
9393 ///Marker type for the `name` field
9494 pub struct name(());
9595+ ///Marker type for the `created_at` field
9696+ pub struct created_at(());
9597 ///Marker type for the `purpose` field
9698 pub struct purpose(());
9797- ///Marker type for the `created_at` field
9898- pub struct created_at(());
9999 }
100100}
101101···269269where
270270 S: list_state::State,
271271 S::Name: list_state::IsSet,
272272- S::Purpose: list_state::IsSet,
273272 S::CreatedAt: list_state::IsSet,
273273+ S::Purpose: list_state::IsSet,
274274{
275275 /// Build the final struct
276276 pub fn build(self) -> List<'a> {
+13-13
crates/weaver-api/src/app_bsky/graph/listblock.rs
···3434 }
3535 /// State trait tracking which required fields have been set
3636 pub trait State: sealed::Sealed {
3737- type CreatedAt;
3837 type Subject;
3838+ type CreatedAt;
3939 }
4040 /// Empty state - all required fields are unset
4141 pub struct Empty(());
4242 impl sealed::Sealed for Empty {}
4343 impl State for Empty {
4444- type CreatedAt = Unset;
4544 type Subject = Unset;
4646- }
4747- ///State transition - sets the `created_at` field to Set
4848- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
4949- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5050- impl<S: State> State for SetCreatedAt<S> {
5151- type CreatedAt = Set<members::created_at>;
5252- type Subject = S::Subject;
4545+ type CreatedAt = Unset;
5346 }
5447 ///State transition - sets the `subject` field to Set
5548 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5649 impl<S: State> sealed::Sealed for SetSubject<S> {}
5750 impl<S: State> State for SetSubject<S> {
5858- type CreatedAt = S::CreatedAt;
5951 type Subject = Set<members::subject>;
5252+ type CreatedAt = S::CreatedAt;
5353+ }
5454+ ///State transition - sets the `created_at` field to Set
5555+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5656+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5757+ impl<S: State> State for SetCreatedAt<S> {
5858+ type Subject = S::Subject;
5959+ type CreatedAt = Set<members::created_at>;
6060 }
6161 /// Marker types for field names
6262 #[allow(non_camel_case_types)]
6363 pub mod members {
6464- ///Marker type for the `created_at` field
6565- pub struct created_at(());
6664 ///Marker type for the `subject` field
6765 pub struct subject(());
6666+ ///Marker type for the `created_at` field
6767+ pub struct created_at(());
6868 }
6969}
7070···137137impl<'a, S> ListblockBuilder<'a, S>
138138where
139139 S: listblock_state::State,
140140- S::CreatedAt: listblock_state::IsSet,
141140 S::Subject: listblock_state::IsSet,
141141+ S::CreatedAt: listblock_state::IsSet,
142142{
143143 /// Build the final struct
144144 pub fn build(self) -> Listblock<'a> {
···366366 }
367367 /// State trait tracking which required fields have been set
368368 pub trait State: sealed::Sealed {
369369- type CreatedAt;
370369 type Name;
371370 type List;
371371+ type CreatedAt;
372372 }
373373 /// Empty state - all required fields are unset
374374 pub struct Empty(());
375375 impl sealed::Sealed for Empty {}
376376 impl State for Empty {
377377- type CreatedAt = Unset;
378377 type Name = Unset;
379378 type List = Unset;
380380- }
381381- ///State transition - sets the `created_at` field to Set
382382- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
383383- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
384384- impl<S: State> State for SetCreatedAt<S> {
385385- type CreatedAt = Set<members::created_at>;
386386- type Name = S::Name;
387387- type List = S::List;
379379+ type CreatedAt = Unset;
388380 }
389381 ///State transition - sets the `name` field to Set
390382 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
391383 impl<S: State> sealed::Sealed for SetName<S> {}
392384 impl<S: State> State for SetName<S> {
393393- type CreatedAt = S::CreatedAt;
394385 type Name = Set<members::name>;
395386 type List = S::List;
387387+ type CreatedAt = S::CreatedAt;
396388 }
397389 ///State transition - sets the `list` field to Set
398390 pub struct SetList<S: State = Empty>(PhantomData<fn() -> S>);
399391 impl<S: State> sealed::Sealed for SetList<S> {}
400392 impl<S: State> State for SetList<S> {
401401- type CreatedAt = S::CreatedAt;
402393 type Name = S::Name;
403394 type List = Set<members::list>;
395395+ type CreatedAt = S::CreatedAt;
396396+ }
397397+ ///State transition - sets the `created_at` field to Set
398398+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
399399+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
400400+ impl<S: State> State for SetCreatedAt<S> {
401401+ type Name = S::Name;
402402+ type List = S::List;
403403+ type CreatedAt = Set<members::created_at>;
404404 }
405405 /// Marker types for field names
406406 #[allow(non_camel_case_types)]
407407 pub mod members {
408408- ///Marker type for the `created_at` field
409409- pub struct created_at(());
410408 ///Marker type for the `name` field
411409 pub struct name(());
412410 ///Marker type for the `list` field
413411 pub struct list(());
412412+ ///Marker type for the `created_at` field
413413+ pub struct created_at(());
414414 }
415415}
416416···563563impl<'a, S> StarterpackBuilder<'a, S>
564564where
565565 S: starterpack_state::State,
566566- S::CreatedAt: starterpack_state::IsSet,
567566 S::Name: starterpack_state::IsSet,
568567 S::List: starterpack_state::IsSet,
568568+ S::CreatedAt: starterpack_state::IsSet,
569569{
570570 /// Build the final struct
571571 pub fn build(self) -> Starterpack<'a> {
···4141 }
4242 /// State trait tracking which required fields have been set
4343 pub trait State: sealed::Sealed {
4444- type Subject;
4545- type DisplayName;
4644 type Handle;
4545+ type DisplayName;
4646+ type Subject;
4747 type CreatedAt;
4848 }
4949 /// Empty state - all required fields are unset
5050 pub struct Empty(());
5151 impl sealed::Sealed for Empty {}
5252 impl State for Empty {
5353- type Subject = Unset;
5454- type DisplayName = Unset;
5553 type Handle = Unset;
5454+ type DisplayName = Unset;
5555+ type Subject = Unset;
5656 type CreatedAt = Unset;
5757 }
5858- ///State transition - sets the `subject` field to Set
5959- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
6060- impl<S: State> sealed::Sealed for SetSubject<S> {}
6161- impl<S: State> State for SetSubject<S> {
6262- type Subject = Set<members::subject>;
5858+ ///State transition - sets the `handle` field to Set
5959+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
6060+ impl<S: State> sealed::Sealed for SetHandle<S> {}
6161+ impl<S: State> State for SetHandle<S> {
6262+ type Handle = Set<members::handle>;
6363 type DisplayName = S::DisplayName;
6464- type Handle = S::Handle;
6464+ type Subject = S::Subject;
6565 type CreatedAt = S::CreatedAt;
6666 }
6767 ///State transition - sets the `display_name` field to Set
6868 pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
6969 impl<S: State> sealed::Sealed for SetDisplayName<S> {}
7070 impl<S: State> State for SetDisplayName<S> {
7171- type Subject = S::Subject;
7272- type DisplayName = Set<members::display_name>;
7371 type Handle = S::Handle;
7272+ type DisplayName = Set<members::display_name>;
7373+ type Subject = S::Subject;
7474 type CreatedAt = S::CreatedAt;
7575 }
7676- ///State transition - sets the `handle` field to Set
7777- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
7878- impl<S: State> sealed::Sealed for SetHandle<S> {}
7979- impl<S: State> State for SetHandle<S> {
8080- type Subject = S::Subject;
7676+ ///State transition - sets the `subject` field to Set
7777+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
7878+ impl<S: State> sealed::Sealed for SetSubject<S> {}
7979+ impl<S: State> State for SetSubject<S> {
8080+ type Handle = S::Handle;
8181 type DisplayName = S::DisplayName;
8282- type Handle = Set<members::handle>;
8282+ type Subject = Set<members::subject>;
8383 type CreatedAt = S::CreatedAt;
8484 }
8585 ///State transition - sets the `created_at` field to Set
8686 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
8787 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
8888 impl<S: State> State for SetCreatedAt<S> {
8989- type Subject = S::Subject;
9090- type DisplayName = S::DisplayName;
9189 type Handle = S::Handle;
9090+ type DisplayName = S::DisplayName;
9191+ type Subject = S::Subject;
9292 type CreatedAt = Set<members::created_at>;
9393 }
9494 /// Marker types for field names
9595 #[allow(non_camel_case_types)]
9696 pub mod members {
9797- ///Marker type for the `subject` field
9898- pub struct subject(());
9999- ///Marker type for the `display_name` field
100100- pub struct display_name(());
10197 ///Marker type for the `handle` field
10298 pub struct handle(());
9999+ ///Marker type for the `display_name` field
100100+ pub struct display_name(());
101101+ ///Marker type for the `subject` field
102102+ pub struct subject(());
103103 ///Marker type for the `created_at` field
104104 pub struct created_at(());
105105 }
···214214impl<'a, S> VerificationBuilder<'a, S>
215215where
216216 S: verification_state::State,
217217- S::Subject: verification_state::IsSet,
218218- S::DisplayName: verification_state::IsSet,
219217 S::Handle: verification_state::IsSet,
218218+ S::DisplayName: verification_state::IsSet,
219219+ S::Subject: verification_state::IsSet,
220220 S::CreatedAt: verification_state::IsSet,
221221{
222222 /// Build the final struct
+71-71
crates/weaver-api/src/app_bsky/labeler.rs
···632632 }
633633 /// State trait tracking which required fields have been set
634634 pub trait State: sealed::Sealed {
635635+ type Creator;
636636+ type Uri;
637637+ type Cid;
635638 type IndexedAt;
636636- type Cid;
637637- type Uri;
638638- type Creator;
639639 }
640640 /// Empty state - all required fields are unset
641641 pub struct Empty(());
642642 impl sealed::Sealed for Empty {}
643643 impl State for Empty {
644644- type IndexedAt = Unset;
645645- type Cid = Unset;
646646- type Uri = Unset;
647644 type Creator = Unset;
645645+ type Uri = Unset;
646646+ type Cid = Unset;
647647+ type IndexedAt = Unset;
648648 }
649649- ///State transition - sets the `indexed_at` field to Set
650650- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
651651- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
652652- impl<S: State> State for SetIndexedAt<S> {
653653- type IndexedAt = Set<members::indexed_at>;
654654- type Cid = S::Cid;
649649+ ///State transition - sets the `creator` field to Set
650650+ pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
651651+ impl<S: State> sealed::Sealed for SetCreator<S> {}
652652+ impl<S: State> State for SetCreator<S> {
653653+ type Creator = Set<members::creator>;
655654 type Uri = S::Uri;
655655+ type Cid = S::Cid;
656656+ type IndexedAt = S::IndexedAt;
657657+ }
658658+ ///State transition - sets the `uri` field to Set
659659+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
660660+ impl<S: State> sealed::Sealed for SetUri<S> {}
661661+ impl<S: State> State for SetUri<S> {
656662 type Creator = S::Creator;
663663+ type Uri = Set<members::uri>;
664664+ type Cid = S::Cid;
665665+ type IndexedAt = S::IndexedAt;
657666 }
658667 ///State transition - sets the `cid` field to Set
659668 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
660669 impl<S: State> sealed::Sealed for SetCid<S> {}
661670 impl<S: State> State for SetCid<S> {
671671+ type Creator = S::Creator;
672672+ type Uri = S::Uri;
673673+ type Cid = Set<members::cid>;
662674 type IndexedAt = S::IndexedAt;
663663- type Cid = Set<members::cid>;
664664- type Uri = S::Uri;
665665- type Creator = S::Creator;
666675 }
667667- ///State transition - sets the `uri` field to Set
668668- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
669669- impl<S: State> sealed::Sealed for SetUri<S> {}
670670- impl<S: State> State for SetUri<S> {
671671- type IndexedAt = S::IndexedAt;
672672- type Cid = S::Cid;
673673- type Uri = Set<members::uri>;
676676+ ///State transition - sets the `indexed_at` field to Set
677677+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
678678+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
679679+ impl<S: State> State for SetIndexedAt<S> {
674680 type Creator = S::Creator;
675675- }
676676- ///State transition - sets the `creator` field to Set
677677- pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
678678- impl<S: State> sealed::Sealed for SetCreator<S> {}
679679- impl<S: State> State for SetCreator<S> {
680680- type IndexedAt = S::IndexedAt;
681681+ type Uri = S::Uri;
681682 type Cid = S::Cid;
682682- type Uri = S::Uri;
683683- type Creator = Set<members::creator>;
683683+ type IndexedAt = Set<members::indexed_at>;
684684 }
685685 /// Marker types for field names
686686 #[allow(non_camel_case_types)]
687687 pub mod members {
688688- ///Marker type for the `indexed_at` field
689689- pub struct indexed_at(());
688688+ ///Marker type for the `creator` field
689689+ pub struct creator(());
690690+ ///Marker type for the `uri` field
691691+ pub struct uri(());
690692 ///Marker type for the `cid` field
691693 pub struct cid(());
692692- ///Marker type for the `uri` field
693693- pub struct uri(());
694694- ///Marker type for the `creator` field
695695- pub struct creator(());
694694+ ///Marker type for the `indexed_at` field
695695+ pub struct indexed_at(());
696696 }
697697}
698698···859859impl<'a, S> LabelerViewBuilder<'a, S>
860860where
861861 S: labeler_view_state::State,
862862- S::IndexedAt: labeler_view_state::IsSet,
863863- S::Cid: labeler_view_state::IsSet,
864864- S::Uri: labeler_view_state::IsSet,
865862 S::Creator: labeler_view_state::IsSet,
863863+ S::Uri: labeler_view_state::IsSet,
864864+ S::Cid: labeler_view_state::IsSet,
865865+ S::IndexedAt: labeler_view_state::IsSet,
866866{
867867 /// Build the final struct
868868 pub fn build(self) -> LabelerView<'a> {
···985985 }
986986 /// State trait tracking which required fields have been set
987987 pub trait State: sealed::Sealed {
988988+ type Uri;
988989 type Policies;
989989- type Cid;
990990 type IndexedAt;
991991 type Creator;
992992- type Uri;
992992+ type Cid;
993993 }
994994 /// Empty state - all required fields are unset
995995 pub struct Empty(());
996996 impl sealed::Sealed for Empty {}
997997 impl State for Empty {
998998+ type Uri = Unset;
998999 type Policies = Unset;
999999- type Cid = Unset;
10001000 type IndexedAt = Unset;
10011001 type Creator = Unset;
10021002- type Uri = Unset;
10021002+ type Cid = Unset;
10031003+ }
10041004+ ///State transition - sets the `uri` field to Set
10051005+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
10061006+ impl<S: State> sealed::Sealed for SetUri<S> {}
10071007+ impl<S: State> State for SetUri<S> {
10081008+ type Uri = Set<members::uri>;
10091009+ type Policies = S::Policies;
10101010+ type IndexedAt = S::IndexedAt;
10111011+ type Creator = S::Creator;
10121012+ type Cid = S::Cid;
10031013 }
10041014 ///State transition - sets the `policies` field to Set
10051015 pub struct SetPolicies<S: State = Empty>(PhantomData<fn() -> S>);
10061016 impl<S: State> sealed::Sealed for SetPolicies<S> {}
10071017 impl<S: State> State for SetPolicies<S> {
10181018+ type Uri = S::Uri;
10081019 type Policies = Set<members::policies>;
10091009- type Cid = S::Cid;
10101020 type IndexedAt = S::IndexedAt;
10111021 type Creator = S::Creator;
10121012- type Uri = S::Uri;
10131013- }
10141014- ///State transition - sets the `cid` field to Set
10151015- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
10161016- impl<S: State> sealed::Sealed for SetCid<S> {}
10171017- impl<S: State> State for SetCid<S> {
10181018- type Policies = S::Policies;
10191019- type Cid = Set<members::cid>;
10201020- type IndexedAt = S::IndexedAt;
10211021- type Creator = S::Creator;
10221022- type Uri = S::Uri;
10221022+ type Cid = S::Cid;
10231023 }
10241024 ///State transition - sets the `indexed_at` field to Set
10251025 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
10261026 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
10271027 impl<S: State> State for SetIndexedAt<S> {
10281028+ type Uri = S::Uri;
10281029 type Policies = S::Policies;
10291029- type Cid = S::Cid;
10301030 type IndexedAt = Set<members::indexed_at>;
10311031 type Creator = S::Creator;
10321032- type Uri = S::Uri;
10321032+ type Cid = S::Cid;
10331033 }
10341034 ///State transition - sets the `creator` field to Set
10351035 pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
10361036 impl<S: State> sealed::Sealed for SetCreator<S> {}
10371037 impl<S: State> State for SetCreator<S> {
10381038+ type Uri = S::Uri;
10381039 type Policies = S::Policies;
10391039- type Cid = S::Cid;
10401040 type IndexedAt = S::IndexedAt;
10411041 type Creator = Set<members::creator>;
10421042- type Uri = S::Uri;
10421042+ type Cid = S::Cid;
10431043 }
10441044- ///State transition - sets the `uri` field to Set
10451045- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
10461046- impl<S: State> sealed::Sealed for SetUri<S> {}
10471047- impl<S: State> State for SetUri<S> {
10441044+ ///State transition - sets the `cid` field to Set
10451045+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
10461046+ impl<S: State> sealed::Sealed for SetCid<S> {}
10471047+ impl<S: State> State for SetCid<S> {
10481048+ type Uri = S::Uri;
10481049 type Policies = S::Policies;
10491049- type Cid = S::Cid;
10501050 type IndexedAt = S::IndexedAt;
10511051 type Creator = S::Creator;
10521052- type Uri = Set<members::uri>;
10521052+ type Cid = Set<members::cid>;
10531053 }
10541054 /// Marker types for field names
10551055 #[allow(non_camel_case_types)]
10561056 pub mod members {
10571057+ ///Marker type for the `uri` field
10581058+ pub struct uri(());
10571059 ///Marker type for the `policies` field
10581060 pub struct policies(());
10591059- ///Marker type for the `cid` field
10601060- pub struct cid(());
10611061 ///Marker type for the `indexed_at` field
10621062 pub struct indexed_at(());
10631063 ///Marker type for the `creator` field
10641064 pub struct creator(());
10651065- ///Marker type for the `uri` field
10661066- pub struct uri(());
10651065+ ///Marker type for the `cid` field
10661066+ pub struct cid(());
10671067 }
10681068}
10691069···13221322impl<'a, S> LabelerViewDetailedBuilder<'a, S>
13231323where
13241324 S: labeler_view_detailed_state::State,
13251325+ S::Uri: labeler_view_detailed_state::IsSet,
13251326 S::Policies: labeler_view_detailed_state::IsSet,
13261326- S::Cid: labeler_view_detailed_state::IsSet,
13271327 S::IndexedAt: labeler_view_detailed_state::IsSet,
13281328 S::Creator: labeler_view_detailed_state::IsSet,
13291329- S::Uri: labeler_view_detailed_state::IsSet,
13291329+ S::Cid: labeler_view_detailed_state::IsSet,
13301330{
13311331 /// Build the final struct
13321332 pub fn build(self) -> LabelerViewDetailed<'a> {
+260-260
crates/weaver-api/src/app_bsky/notification.rs
···4343 }
4444 /// State trait tracking which required fields have been set
4545 pub trait State: sealed::Sealed {
4646- type Post;
4746 type Reply;
4747+ type Post;
4848 }
4949 /// Empty state - all required fields are unset
5050 pub struct Empty(());
5151 impl sealed::Sealed for Empty {}
5252 impl State for Empty {
5353- type Post = Unset;
5453 type Reply = Unset;
5555- }
5656- ///State transition - sets the `post` field to Set
5757- pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
5858- impl<S: State> sealed::Sealed for SetPost<S> {}
5959- impl<S: State> State for SetPost<S> {
6060- type Post = Set<members::post>;
6161- type Reply = S::Reply;
5454+ type Post = Unset;
6255 }
6356 ///State transition - sets the `reply` field to Set
6457 pub struct SetReply<S: State = Empty>(PhantomData<fn() -> S>);
6558 impl<S: State> sealed::Sealed for SetReply<S> {}
6659 impl<S: State> State for SetReply<S> {
6767- type Post = S::Post;
6860 type Reply = Set<members::reply>;
6161+ type Post = S::Post;
6262+ }
6363+ ///State transition - sets the `post` field to Set
6464+ pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
6565+ impl<S: State> sealed::Sealed for SetPost<S> {}
6666+ impl<S: State> State for SetPost<S> {
6767+ type Reply = S::Reply;
6868+ type Post = Set<members::post>;
6969 }
7070 /// Marker types for field names
7171 #[allow(non_camel_case_types)]
7272 pub mod members {
7373- ///Marker type for the `post` field
7474- pub struct post(());
7573 ///Marker type for the `reply` field
7674 pub struct reply(());
7575+ ///Marker type for the `post` field
7676+ pub struct post(());
7777 }
7878}
7979···143143impl<'a, S> ActivitySubscriptionBuilder<'a, S>
144144where
145145 S: activity_subscription_state::State,
146146- S::Post: activity_subscription_state::IsSet,
147146 S::Reply: activity_subscription_state::IsSet,
147147+ S::Post: activity_subscription_state::IsSet,
148148{
149149 /// Build the final struct
150150 pub fn build(self) -> ActivitySubscription<'a> {
···601601 }
602602 /// State trait tracking which required fields have been set
603603 pub trait State: sealed::Sealed {
604604- type Include;
605604 type Push;
605605+ type Include;
606606 }
607607 /// Empty state - all required fields are unset
608608 pub struct Empty(());
609609 impl sealed::Sealed for Empty {}
610610 impl State for Empty {
611611- type Include = Unset;
612611 type Push = Unset;
613613- }
614614- ///State transition - sets the `include` field to Set
615615- pub struct SetInclude<S: State = Empty>(PhantomData<fn() -> S>);
616616- impl<S: State> sealed::Sealed for SetInclude<S> {}
617617- impl<S: State> State for SetInclude<S> {
618618- type Include = Set<members::include>;
619619- type Push = S::Push;
612612+ type Include = Unset;
620613 }
621614 ///State transition - sets the `push` field to Set
622615 pub struct SetPush<S: State = Empty>(PhantomData<fn() -> S>);
623616 impl<S: State> sealed::Sealed for SetPush<S> {}
624617 impl<S: State> State for SetPush<S> {
625625- type Include = S::Include;
626618 type Push = Set<members::push>;
619619+ type Include = S::Include;
620620+ }
621621+ ///State transition - sets the `include` field to Set
622622+ pub struct SetInclude<S: State = Empty>(PhantomData<fn() -> S>);
623623+ impl<S: State> sealed::Sealed for SetInclude<S> {}
624624+ impl<S: State> State for SetInclude<S> {
625625+ type Push = S::Push;
626626+ type Include = Set<members::include>;
627627 }
628628 /// Marker types for field names
629629 #[allow(non_camel_case_types)]
630630 pub mod members {
631631- ///Marker type for the `include` field
632632- pub struct include(());
633631 ///Marker type for the `push` field
634632 pub struct push(());
633633+ ///Marker type for the `include` field
634634+ pub struct include(());
635635 }
636636}
637637···704704impl<'a, S> ChatPreferenceBuilder<'a, S>
705705where
706706 S: chat_preference_state::State,
707707- S::Include: chat_preference_state::IsSet,
708707 S::Push: chat_preference_state::IsSet,
708708+ S::Include: chat_preference_state::IsSet,
709709{
710710 /// Build the final struct
711711 pub fn build(self) -> ChatPreference<'a> {
···867867 /// State trait tracking which required fields have been set
868868 pub trait State: sealed::Sealed {
869869 type Push;
870870- type List;
871870 type Include;
871871+ type List;
872872 }
873873 /// Empty state - all required fields are unset
874874 pub struct Empty(());
875875 impl sealed::Sealed for Empty {}
876876 impl State for Empty {
877877 type Push = Unset;
878878- type List = Unset;
879878 type Include = Unset;
879879+ type List = Unset;
880880 }
881881 ///State transition - sets the `push` field to Set
882882 pub struct SetPush<S: State = Empty>(PhantomData<fn() -> S>);
883883 impl<S: State> sealed::Sealed for SetPush<S> {}
884884 impl<S: State> State for SetPush<S> {
885885 type Push = Set<members::push>;
886886- type List = S::List;
887887- type Include = S::Include;
888888- }
889889- ///State transition - sets the `list` field to Set
890890- pub struct SetList<S: State = Empty>(PhantomData<fn() -> S>);
891891- impl<S: State> sealed::Sealed for SetList<S> {}
892892- impl<S: State> State for SetList<S> {
893893- type Push = S::Push;
894894- type List = Set<members::list>;
895886 type Include = S::Include;
887887+ type List = S::List;
896888 }
897889 ///State transition - sets the `include` field to Set
898890 pub struct SetInclude<S: State = Empty>(PhantomData<fn() -> S>);
899891 impl<S: State> sealed::Sealed for SetInclude<S> {}
900892 impl<S: State> State for SetInclude<S> {
901893 type Push = S::Push;
894894+ type Include = Set<members::include>;
902895 type List = S::List;
903903- type Include = Set<members::include>;
896896+ }
897897+ ///State transition - sets the `list` field to Set
898898+ pub struct SetList<S: State = Empty>(PhantomData<fn() -> S>);
899899+ impl<S: State> sealed::Sealed for SetList<S> {}
900900+ impl<S: State> State for SetList<S> {
901901+ type Push = S::Push;
902902+ type Include = S::Include;
903903+ type List = Set<members::list>;
904904 }
905905 /// Marker types for field names
906906 #[allow(non_camel_case_types)]
907907 pub mod members {
908908 ///Marker type for the `push` field
909909 pub struct push(());
910910+ ///Marker type for the `include` field
911911+ pub struct include(());
910912 ///Marker type for the `list` field
911913 pub struct list(());
912912- ///Marker type for the `include` field
913913- pub struct include(());
914914 }
915915}
916916···10041004where
10051005 S: filterable_preference_state::State,
10061006 S::Push: filterable_preference_state::IsSet,
10071007- S::List: filterable_preference_state::IsSet,
10081007 S::Include: filterable_preference_state::IsSet,
10081008+ S::List: filterable_preference_state::IsSet,
10091009{
10101010 /// Build the final struct
10111011 pub fn build(self) -> FilterablePreference<'a> {
···13601360 }
13611361 /// State trait tracking which required fields have been set
13621362 pub trait State: sealed::Sealed {
13631363- type Mention;
13641364- type LikeViaRepost;
13651365- type Reply;
13661366- type Quote;
13671367- type Repost;
13681368- type Follow;
13631363+ type SubscribedPost;
13691364 type RepostViaRepost;
13701365 type Unverified;
13661366+ type Verified;
13671367+ type Like;
13681368+ type Repost;
13691369+ type Quote;
13701370+ type Mention;
13711371 type StarterpackJoined;
13721372+ type Follow;
13731373+ type Reply;
13721374 type Chat;
13731373- type Like;
13741374- type SubscribedPost;
13751375- type Verified;
13751375+ type LikeViaRepost;
13761376 }
13771377 /// Empty state - all required fields are unset
13781378 pub struct Empty(());
13791379 impl sealed::Sealed for Empty {}
13801380 impl State for Empty {
13811381- type Mention = Unset;
13821382- type LikeViaRepost = Unset;
13831383- type Reply = Unset;
13841384- type Quote = Unset;
13851385- type Repost = Unset;
13861386- type Follow = Unset;
13811381+ type SubscribedPost = Unset;
13871382 type RepostViaRepost = Unset;
13881383 type Unverified = Unset;
13841384+ type Verified = Unset;
13851385+ type Like = Unset;
13861386+ type Repost = Unset;
13871387+ type Quote = Unset;
13881388+ type Mention = Unset;
13891389 type StarterpackJoined = Unset;
13901390+ type Follow = Unset;
13911391+ type Reply = Unset;
13901392 type Chat = Unset;
13911391- type Like = Unset;
13921392- type SubscribedPost = Unset;
13931393- type Verified = Unset;
13931393+ type LikeViaRepost = Unset;
13941394 }
13951395- ///State transition - sets the `mention` field to Set
13961396- pub struct SetMention<S: State = Empty>(PhantomData<fn() -> S>);
13971397- impl<S: State> sealed::Sealed for SetMention<S> {}
13981398- impl<S: State> State for SetMention<S> {
13991399- type Mention = Set<members::mention>;
14001400- type LikeViaRepost = S::LikeViaRepost;
14011401- type Reply = S::Reply;
14021402- type Quote = S::Quote;
14031403- type Repost = S::Repost;
14041404- type Follow = S::Follow;
13951395+ ///State transition - sets the `subscribed_post` field to Set
13961396+ pub struct SetSubscribedPost<S: State = Empty>(PhantomData<fn() -> S>);
13971397+ impl<S: State> sealed::Sealed for SetSubscribedPost<S> {}
13981398+ impl<S: State> State for SetSubscribedPost<S> {
13991399+ type SubscribedPost = Set<members::subscribed_post>;
14051400 type RepostViaRepost = S::RepostViaRepost;
14061401 type Unverified = S::Unverified;
14021402+ type Verified = S::Verified;
14031403+ type Like = S::Like;
14041404+ type Repost = S::Repost;
14051405+ type Quote = S::Quote;
14061406+ type Mention = S::Mention;
14071407 type StarterpackJoined = S::StarterpackJoined;
14081408+ type Follow = S::Follow;
14091409+ type Reply = S::Reply;
14081410 type Chat = S::Chat;
14091409- type Like = S::Like;
14111411+ type LikeViaRepost = S::LikeViaRepost;
14121412+ }
14131413+ ///State transition - sets the `repost_via_repost` field to Set
14141414+ pub struct SetRepostViaRepost<S: State = Empty>(PhantomData<fn() -> S>);
14151415+ impl<S: State> sealed::Sealed for SetRepostViaRepost<S> {}
14161416+ impl<S: State> State for SetRepostViaRepost<S> {
14101417 type SubscribedPost = S::SubscribedPost;
14181418+ type RepostViaRepost = Set<members::repost_via_repost>;
14191419+ type Unverified = S::Unverified;
14111420 type Verified = S::Verified;
14121412- }
14131413- ///State transition - sets the `like_via_repost` field to Set
14141414- pub struct SetLikeViaRepost<S: State = Empty>(PhantomData<fn() -> S>);
14151415- impl<S: State> sealed::Sealed for SetLikeViaRepost<S> {}
14161416- impl<S: State> State for SetLikeViaRepost<S> {
14171417- type Mention = S::Mention;
14181418- type LikeViaRepost = Set<members::like_via_repost>;
14191419- type Reply = S::Reply;
14201420- type Quote = S::Quote;
14211421+ type Like = S::Like;
14211422 type Repost = S::Repost;
14231423+ type Quote = S::Quote;
14241424+ type Mention = S::Mention;
14251425+ type StarterpackJoined = S::StarterpackJoined;
14221426 type Follow = S::Follow;
14231423- type RepostViaRepost = S::RepostViaRepost;
14241424- type Unverified = S::Unverified;
14251425- type StarterpackJoined = S::StarterpackJoined;
14271427+ type Reply = S::Reply;
14261428 type Chat = S::Chat;
14271427- type Like = S::Like;
14291429+ type LikeViaRepost = S::LikeViaRepost;
14301430+ }
14311431+ ///State transition - sets the `unverified` field to Set
14321432+ pub struct SetUnverified<S: State = Empty>(PhantomData<fn() -> S>);
14331433+ impl<S: State> sealed::Sealed for SetUnverified<S> {}
14341434+ impl<S: State> State for SetUnverified<S> {
14281435 type SubscribedPost = S::SubscribedPost;
14361436+ type RepostViaRepost = S::RepostViaRepost;
14371437+ type Unverified = Set<members::unverified>;
14291438 type Verified = S::Verified;
14301430- }
14311431- ///State transition - sets the `reply` field to Set
14321432- pub struct SetReply<S: State = Empty>(PhantomData<fn() -> S>);
14331433- impl<S: State> sealed::Sealed for SetReply<S> {}
14341434- impl<S: State> State for SetReply<S> {
14351435- type Mention = S::Mention;
14361436- type LikeViaRepost = S::LikeViaRepost;
14371437- type Reply = Set<members::reply>;
14381438- type Quote = S::Quote;
14391439+ type Like = S::Like;
14391440 type Repost = S::Repost;
14411441+ type Quote = S::Quote;
14421442+ type Mention = S::Mention;
14431443+ type StarterpackJoined = S::StarterpackJoined;
14401444 type Follow = S::Follow;
14451445+ type Reply = S::Reply;
14461446+ type Chat = S::Chat;
14471447+ type LikeViaRepost = S::LikeViaRepost;
14481448+ }
14491449+ ///State transition - sets the `verified` field to Set
14501450+ pub struct SetVerified<S: State = Empty>(PhantomData<fn() -> S>);
14511451+ impl<S: State> sealed::Sealed for SetVerified<S> {}
14521452+ impl<S: State> State for SetVerified<S> {
14531453+ type SubscribedPost = S::SubscribedPost;
14411454 type RepostViaRepost = S::RepostViaRepost;
14421455 type Unverified = S::Unverified;
14561456+ type Verified = Set<members::verified>;
14571457+ type Like = S::Like;
14581458+ type Repost = S::Repost;
14591459+ type Quote = S::Quote;
14601460+ type Mention = S::Mention;
14431461 type StarterpackJoined = S::StarterpackJoined;
14621462+ type Follow = S::Follow;
14631463+ type Reply = S::Reply;
14441464 type Chat = S::Chat;
14451445- type Like = S::Like;
14651465+ type LikeViaRepost = S::LikeViaRepost;
14661466+ }
14671467+ ///State transition - sets the `like` field to Set
14681468+ pub struct SetLike<S: State = Empty>(PhantomData<fn() -> S>);
14691469+ impl<S: State> sealed::Sealed for SetLike<S> {}
14701470+ impl<S: State> State for SetLike<S> {
14461471 type SubscribedPost = S::SubscribedPost;
14721472+ type RepostViaRepost = S::RepostViaRepost;
14731473+ type Unverified = S::Unverified;
14471474 type Verified = S::Verified;
14481448- }
14491449- ///State transition - sets the `quote` field to Set
14501450- pub struct SetQuote<S: State = Empty>(PhantomData<fn() -> S>);
14511451- impl<S: State> sealed::Sealed for SetQuote<S> {}
14521452- impl<S: State> State for SetQuote<S> {
14531453- type Mention = S::Mention;
14541454- type LikeViaRepost = S::LikeViaRepost;
14551455- type Reply = S::Reply;
14561456- type Quote = Set<members::quote>;
14751475+ type Like = Set<members::like>;
14571476 type Repost = S::Repost;
14771477+ type Quote = S::Quote;
14781478+ type Mention = S::Mention;
14791479+ type StarterpackJoined = S::StarterpackJoined;
14581480 type Follow = S::Follow;
14591459- type RepostViaRepost = S::RepostViaRepost;
14601460- type Unverified = S::Unverified;
14611461- type StarterpackJoined = S::StarterpackJoined;
14811481+ type Reply = S::Reply;
14621482 type Chat = S::Chat;
14631463- type Like = S::Like;
14641464- type SubscribedPost = S::SubscribedPost;
14651465- type Verified = S::Verified;
14831483+ type LikeViaRepost = S::LikeViaRepost;
14661484 }
14671485 ///State transition - sets the `repost` field to Set
14681486 pub struct SetRepost<S: State = Empty>(PhantomData<fn() -> S>);
14691487 impl<S: State> sealed::Sealed for SetRepost<S> {}
14701488 impl<S: State> State for SetRepost<S> {
14711471- type Mention = S::Mention;
14721472- type LikeViaRepost = S::LikeViaRepost;
14731473- type Reply = S::Reply;
14741474- type Quote = S::Quote;
14751475- type Repost = Set<members::repost>;
14761476- type Follow = S::Follow;
14891489+ type SubscribedPost = S::SubscribedPost;
14771490 type RepostViaRepost = S::RepostViaRepost;
14781491 type Unverified = S::Unverified;
14791479- type StarterpackJoined = S::StarterpackJoined;
14801480- type Chat = S::Chat;
14811481- type Like = S::Like;
14821482- type SubscribedPost = S::SubscribedPost;
14831492 type Verified = S::Verified;
14841484- }
14851485- ///State transition - sets the `follow` field to Set
14861486- pub struct SetFollow<S: State = Empty>(PhantomData<fn() -> S>);
14871487- impl<S: State> sealed::Sealed for SetFollow<S> {}
14881488- impl<S: State> State for SetFollow<S> {
14891489- type Mention = S::Mention;
14901490- type LikeViaRepost = S::LikeViaRepost;
14911491- type Reply = S::Reply;
14931493+ type Like = S::Like;
14941494+ type Repost = Set<members::repost>;
14921495 type Quote = S::Quote;
14931493- type Repost = S::Repost;
14941494- type Follow = Set<members::follow>;
14951495- type RepostViaRepost = S::RepostViaRepost;
14961496- type Unverified = S::Unverified;
14961496+ type Mention = S::Mention;
14971497 type StarterpackJoined = S::StarterpackJoined;
14981498+ type Follow = S::Follow;
14991499+ type Reply = S::Reply;
14981500 type Chat = S::Chat;
14991499- type Like = S::Like;
15011501+ type LikeViaRepost = S::LikeViaRepost;
15021502+ }
15031503+ ///State transition - sets the `quote` field to Set
15041504+ pub struct SetQuote<S: State = Empty>(PhantomData<fn() -> S>);
15051505+ impl<S: State> sealed::Sealed for SetQuote<S> {}
15061506+ impl<S: State> State for SetQuote<S> {
15001507 type SubscribedPost = S::SubscribedPost;
15081508+ type RepostViaRepost = S::RepostViaRepost;
15091509+ type Unverified = S::Unverified;
15011510 type Verified = S::Verified;
15021502- }
15031503- ///State transition - sets the `repost_via_repost` field to Set
15041504- pub struct SetRepostViaRepost<S: State = Empty>(PhantomData<fn() -> S>);
15051505- impl<S: State> sealed::Sealed for SetRepostViaRepost<S> {}
15061506- impl<S: State> State for SetRepostViaRepost<S> {
15111511+ type Like = S::Like;
15121512+ type Repost = S::Repost;
15131513+ type Quote = Set<members::quote>;
15071514 type Mention = S::Mention;
15081508- type LikeViaRepost = S::LikeViaRepost;
15091509- type Reply = S::Reply;
15101510- type Quote = S::Quote;
15111511- type Repost = S::Repost;
15121512- type Follow = S::Follow;
15131513- type RepostViaRepost = Set<members::repost_via_repost>;
15141514- type Unverified = S::Unverified;
15151515 type StarterpackJoined = S::StarterpackJoined;
15161516+ type Follow = S::Follow;
15171517+ type Reply = S::Reply;
15161518 type Chat = S::Chat;
15171517- type Like = S::Like;
15191519+ type LikeViaRepost = S::LikeViaRepost;
15201520+ }
15211521+ ///State transition - sets the `mention` field to Set
15221522+ pub struct SetMention<S: State = Empty>(PhantomData<fn() -> S>);
15231523+ impl<S: State> sealed::Sealed for SetMention<S> {}
15241524+ impl<S: State> State for SetMention<S> {
15181525 type SubscribedPost = S::SubscribedPost;
15261526+ type RepostViaRepost = S::RepostViaRepost;
15271527+ type Unverified = S::Unverified;
15191528 type Verified = S::Verified;
15201520- }
15211521- ///State transition - sets the `unverified` field to Set
15221522- pub struct SetUnverified<S: State = Empty>(PhantomData<fn() -> S>);
15231523- impl<S: State> sealed::Sealed for SetUnverified<S> {}
15241524- impl<S: State> State for SetUnverified<S> {
15251525- type Mention = S::Mention;
15261526- type LikeViaRepost = S::LikeViaRepost;
15271527- type Reply = S::Reply;
15281528- type Quote = S::Quote;
15291529+ type Like = S::Like;
15291530 type Repost = S::Repost;
15301530- type Follow = S::Follow;
15311531- type RepostViaRepost = S::RepostViaRepost;
15321532- type Unverified = Set<members::unverified>;
15311531+ type Quote = S::Quote;
15321532+ type Mention = Set<members::mention>;
15331533 type StarterpackJoined = S::StarterpackJoined;
15341534+ type Follow = S::Follow;
15351535+ type Reply = S::Reply;
15341536 type Chat = S::Chat;
15351535- type Like = S::Like;
15361536- type SubscribedPost = S::SubscribedPost;
15371537- type Verified = S::Verified;
15371537+ type LikeViaRepost = S::LikeViaRepost;
15381538 }
15391539 ///State transition - sets the `starterpack_joined` field to Set
15401540 pub struct SetStarterpackJoined<S: State = Empty>(PhantomData<fn() -> S>);
15411541 impl<S: State> sealed::Sealed for SetStarterpackJoined<S> {}
15421542 impl<S: State> State for SetStarterpackJoined<S> {
15431543- type Mention = S::Mention;
15441544- type LikeViaRepost = S::LikeViaRepost;
15451545- type Reply = S::Reply;
15461546- type Quote = S::Quote;
15471547- type Repost = S::Repost;
15481548- type Follow = S::Follow;
15431543+ type SubscribedPost = S::SubscribedPost;
15491544 type RepostViaRepost = S::RepostViaRepost;
15501545 type Unverified = S::Unverified;
15461546+ type Verified = S::Verified;
15471547+ type Like = S::Like;
15481548+ type Repost = S::Repost;
15491549+ type Quote = S::Quote;
15501550+ type Mention = S::Mention;
15511551 type StarterpackJoined = Set<members::starterpack_joined>;
15521552+ type Follow = S::Follow;
15531553+ type Reply = S::Reply;
15521554 type Chat = S::Chat;
15531553- type Like = S::Like;
15551555+ type LikeViaRepost = S::LikeViaRepost;
15561556+ }
15571557+ ///State transition - sets the `follow` field to Set
15581558+ pub struct SetFollow<S: State = Empty>(PhantomData<fn() -> S>);
15591559+ impl<S: State> sealed::Sealed for SetFollow<S> {}
15601560+ impl<S: State> State for SetFollow<S> {
15541561 type SubscribedPost = S::SubscribedPost;
15551555- type Verified = S::Verified;
15561556- }
15571557- ///State transition - sets the `chat` field to Set
15581558- pub struct SetChat<S: State = Empty>(PhantomData<fn() -> S>);
15591559- impl<S: State> sealed::Sealed for SetChat<S> {}
15601560- impl<S: State> State for SetChat<S> {
15611561- type Mention = S::Mention;
15621562- type LikeViaRepost = S::LikeViaRepost;
15631563- type Reply = S::Reply;
15641564- type Quote = S::Quote;
15651565- type Repost = S::Repost;
15661566- type Follow = S::Follow;
15671562 type RepostViaRepost = S::RepostViaRepost;
15681563 type Unverified = S::Unverified;
15691569- type StarterpackJoined = S::StarterpackJoined;
15701570- type Chat = Set<members::chat>;
15711571- type Like = S::Like;
15721572- type SubscribedPost = S::SubscribedPost;
15731564 type Verified = S::Verified;
15741574- }
15751575- ///State transition - sets the `like` field to Set
15761576- pub struct SetLike<S: State = Empty>(PhantomData<fn() -> S>);
15771577- impl<S: State> sealed::Sealed for SetLike<S> {}
15781578- impl<S: State> State for SetLike<S> {
15651565+ type Like = S::Like;
15661566+ type Repost = S::Repost;
15671567+ type Quote = S::Quote;
15791568 type Mention = S::Mention;
15801580- type LikeViaRepost = S::LikeViaRepost;
15811581- type Reply = S::Reply;
15821582- type Quote = S::Quote;
15831583- type Repost = S::Repost;
15841584- type Follow = S::Follow;
15851585- type RepostViaRepost = S::RepostViaRepost;
15861586- type Unverified = S::Unverified;
15871569 type StarterpackJoined = S::StarterpackJoined;
15701570+ type Follow = Set<members::follow>;
15711571+ type Reply = S::Reply;
15881572 type Chat = S::Chat;
15891589- type Like = Set<members::like>;
15731573+ type LikeViaRepost = S::LikeViaRepost;
15741574+ }
15751575+ ///State transition - sets the `reply` field to Set
15761576+ pub struct SetReply<S: State = Empty>(PhantomData<fn() -> S>);
15771577+ impl<S: State> sealed::Sealed for SetReply<S> {}
15781578+ impl<S: State> State for SetReply<S> {
15901579 type SubscribedPost = S::SubscribedPost;
15801580+ type RepostViaRepost = S::RepostViaRepost;
15811581+ type Unverified = S::Unverified;
15911582 type Verified = S::Verified;
15921592- }
15931593- ///State transition - sets the `subscribed_post` field to Set
15941594- pub struct SetSubscribedPost<S: State = Empty>(PhantomData<fn() -> S>);
15951595- impl<S: State> sealed::Sealed for SetSubscribedPost<S> {}
15961596- impl<S: State> State for SetSubscribedPost<S> {
15971597- type Mention = S::Mention;
15981598- type LikeViaRepost = S::LikeViaRepost;
15991599- type Reply = S::Reply;
16001600- type Quote = S::Quote;
15831583+ type Like = S::Like;
16011584 type Repost = S::Repost;
15851585+ type Quote = S::Quote;
15861586+ type Mention = S::Mention;
15871587+ type StarterpackJoined = S::StarterpackJoined;
16021588 type Follow = S::Follow;
15891589+ type Reply = Set<members::reply>;
15901590+ type Chat = S::Chat;
15911591+ type LikeViaRepost = S::LikeViaRepost;
15921592+ }
15931593+ ///State transition - sets the `chat` field to Set
15941594+ pub struct SetChat<S: State = Empty>(PhantomData<fn() -> S>);
15951595+ impl<S: State> sealed::Sealed for SetChat<S> {}
15961596+ impl<S: State> State for SetChat<S> {
15971597+ type SubscribedPost = S::SubscribedPost;
16031598 type RepostViaRepost = S::RepostViaRepost;
16041599 type Unverified = S::Unverified;
16051605- type StarterpackJoined = S::StarterpackJoined;
16061606- type Chat = S::Chat;
16001600+ type Verified = S::Verified;
16071601 type Like = S::Like;
16081608- type SubscribedPost = Set<members::subscribed_post>;
16091609- type Verified = S::Verified;
16101610- }
16111611- ///State transition - sets the `verified` field to Set
16121612- pub struct SetVerified<S: State = Empty>(PhantomData<fn() -> S>);
16131613- impl<S: State> sealed::Sealed for SetVerified<S> {}
16141614- impl<S: State> State for SetVerified<S> {
16021602+ type Repost = S::Repost;
16031603+ type Quote = S::Quote;
16151604 type Mention = S::Mention;
16051605+ type StarterpackJoined = S::StarterpackJoined;
16061606+ type Follow = S::Follow;
16071607+ type Reply = S::Reply;
16081608+ type Chat = Set<members::chat>;
16161609 type LikeViaRepost = S::LikeViaRepost;
16171617- type Reply = S::Reply;
16181618- type Quote = S::Quote;
16191619- type Repost = S::Repost;
16201620- type Follow = S::Follow;
16101610+ }
16111611+ ///State transition - sets the `like_via_repost` field to Set
16121612+ pub struct SetLikeViaRepost<S: State = Empty>(PhantomData<fn() -> S>);
16131613+ impl<S: State> sealed::Sealed for SetLikeViaRepost<S> {}
16141614+ impl<S: State> State for SetLikeViaRepost<S> {
16151615+ type SubscribedPost = S::SubscribedPost;
16211616 type RepostViaRepost = S::RepostViaRepost;
16221617 type Unverified = S::Unverified;
16181618+ type Verified = S::Verified;
16191619+ type Like = S::Like;
16201620+ type Repost = S::Repost;
16211621+ type Quote = S::Quote;
16221622+ type Mention = S::Mention;
16231623 type StarterpackJoined = S::StarterpackJoined;
16241624+ type Follow = S::Follow;
16251625+ type Reply = S::Reply;
16241626 type Chat = S::Chat;
16251625- type Like = S::Like;
16261626- type SubscribedPost = S::SubscribedPost;
16271627- type Verified = Set<members::verified>;
16271627+ type LikeViaRepost = Set<members::like_via_repost>;
16281628 }
16291629 /// Marker types for field names
16301630 #[allow(non_camel_case_types)]
16311631 pub mod members {
16321632- ///Marker type for the `mention` field
16331633- pub struct mention(());
16341634- ///Marker type for the `like_via_repost` field
16351635- pub struct like_via_repost(());
16361636- ///Marker type for the `reply` field
16371637- pub struct reply(());
16381638- ///Marker type for the `quote` field
16391639- pub struct quote(());
16401640- ///Marker type for the `repost` field
16411641- pub struct repost(());
16421642- ///Marker type for the `follow` field
16431643- pub struct follow(());
16321632+ ///Marker type for the `subscribed_post` field
16331633+ pub struct subscribed_post(());
16441634 ///Marker type for the `repost_via_repost` field
16451635 pub struct repost_via_repost(());
16461636 ///Marker type for the `unverified` field
16471637 pub struct unverified(());
16381638+ ///Marker type for the `verified` field
16391639+ pub struct verified(());
16401640+ ///Marker type for the `like` field
16411641+ pub struct like(());
16421642+ ///Marker type for the `repost` field
16431643+ pub struct repost(());
16441644+ ///Marker type for the `quote` field
16451645+ pub struct quote(());
16461646+ ///Marker type for the `mention` field
16471647+ pub struct mention(());
16481648 ///Marker type for the `starterpack_joined` field
16491649 pub struct starterpack_joined(());
16501650+ ///Marker type for the `follow` field
16511651+ pub struct follow(());
16521652+ ///Marker type for the `reply` field
16531653+ pub struct reply(());
16501654 ///Marker type for the `chat` field
16511655 pub struct chat(());
16521652- ///Marker type for the `like` field
16531653- pub struct like(());
16541654- ///Marker type for the `subscribed_post` field
16551655- pub struct subscribed_post(());
16561656- ///Marker type for the `verified` field
16571657- pub struct verified(());
16561656+ ///Marker type for the `like_via_repost` field
16571657+ pub struct like_via_repost(());
16581658 }
16591659}
16601660···19611961impl<'a, S> PreferencesBuilder<'a, S>
19621962where
19631963 S: preferences_state::State,
19641964- S::Mention: preferences_state::IsSet,
19651965- S::LikeViaRepost: preferences_state::IsSet,
19661966- S::Reply: preferences_state::IsSet,
19671967- S::Quote: preferences_state::IsSet,
19681968- S::Repost: preferences_state::IsSet,
19691969- S::Follow: preferences_state::IsSet,
19641964+ S::SubscribedPost: preferences_state::IsSet,
19701965 S::RepostViaRepost: preferences_state::IsSet,
19711966 S::Unverified: preferences_state::IsSet,
19671967+ S::Verified: preferences_state::IsSet,
19681968+ S::Like: preferences_state::IsSet,
19691969+ S::Repost: preferences_state::IsSet,
19701970+ S::Quote: preferences_state::IsSet,
19711971+ S::Mention: preferences_state::IsSet,
19721972 S::StarterpackJoined: preferences_state::IsSet,
19731973+ S::Follow: preferences_state::IsSet,
19741974+ S::Reply: preferences_state::IsSet,
19731975 S::Chat: preferences_state::IsSet,
19741974- S::Like: preferences_state::IsSet,
19751975- S::SubscribedPost: preferences_state::IsSet,
19761976- S::Verified: preferences_state::IsSet,
19761976+ S::LikeViaRepost: preferences_state::IsSet,
19771977{
19781978 /// Build the final struct
19791979 pub fn build(self) -> Preferences<'a> {
···20972097 }
20982098 /// State trait tracking which required fields have been set
20992099 pub trait State: sealed::Sealed {
21002100- type ActivitySubscription;
21012100 type Subject;
21012101+ type ActivitySubscription;
21022102 }
21032103 /// Empty state - all required fields are unset
21042104 pub struct Empty(());
21052105 impl sealed::Sealed for Empty {}
21062106 impl State for Empty {
21072107- type ActivitySubscription = Unset;
21082107 type Subject = Unset;
21092109- }
21102110- ///State transition - sets the `activity_subscription` field to Set
21112111- pub struct SetActivitySubscription<S: State = Empty>(PhantomData<fn() -> S>);
21122112- impl<S: State> sealed::Sealed for SetActivitySubscription<S> {}
21132113- impl<S: State> State for SetActivitySubscription<S> {
21142114- type ActivitySubscription = Set<members::activity_subscription>;
21152115- type Subject = S::Subject;
21082108+ type ActivitySubscription = Unset;
21162109 }
21172110 ///State transition - sets the `subject` field to Set
21182111 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
21192112 impl<S: State> sealed::Sealed for SetSubject<S> {}
21202113 impl<S: State> State for SetSubject<S> {
21212121- type ActivitySubscription = S::ActivitySubscription;
21222114 type Subject = Set<members::subject>;
21152115+ type ActivitySubscription = S::ActivitySubscription;
21162116+ }
21172117+ ///State transition - sets the `activity_subscription` field to Set
21182118+ pub struct SetActivitySubscription<S: State = Empty>(PhantomData<fn() -> S>);
21192119+ impl<S: State> sealed::Sealed for SetActivitySubscription<S> {}
21202120+ impl<S: State> State for SetActivitySubscription<S> {
21212121+ type Subject = S::Subject;
21222122+ type ActivitySubscription = Set<members::activity_subscription>;
21232123 }
21242124 /// Marker types for field names
21252125 #[allow(non_camel_case_types)]
21262126 pub mod members {
21272127+ ///Marker type for the `subject` field
21282128+ pub struct subject(());
21272129 ///Marker type for the `activity_subscription` field
21282130 pub struct activity_subscription(());
21292129- ///Marker type for the `subject` field
21302130- pub struct subject(());
21312131 }
21322132}
21332133···22142214impl<'a, S> SubjectActivitySubscriptionBuilder<'a, S>
22152215where
22162216 S: subject_activity_subscription_state::State,
22172217- S::ActivitySubscription: subject_activity_subscription_state::IsSet,
22182217 S::Subject: subject_activity_subscription_state::IsSet,
22182218+ S::ActivitySubscription: subject_activity_subscription_state::IsSet,
22192219{
22202220 /// Build the final struct
22212221 pub fn build(self) -> SubjectActivitySubscription<'a> {
···271271 }
272272 /// State trait tracking which required fields have been set
273273 pub trait State: sealed::Sealed {
274274- type Uri;
275274 type Cid;
276276- type Record;
277275 type Author;
276276+ type Record;
277277+ type IsRead;
278278 type Reason;
279279- type IsRead;
279279+ type Uri;
280280 type IndexedAt;
281281 }
282282 /// Empty state - all required fields are unset
283283 pub struct Empty(());
284284 impl sealed::Sealed for Empty {}
285285 impl State for Empty {
286286- type Uri = Unset;
287286 type Cid = Unset;
288288- type Record = Unset;
289287 type Author = Unset;
290290- type Reason = Unset;
288288+ type Record = Unset;
291289 type IsRead = Unset;
290290+ type Reason = Unset;
291291+ type Uri = Unset;
292292 type IndexedAt = Unset;
293293 }
294294- ///State transition - sets the `uri` field to Set
295295- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
296296- impl<S: State> sealed::Sealed for SetUri<S> {}
297297- impl<S: State> State for SetUri<S> {
298298- type Uri = Set<members::uri>;
299299- type Cid = S::Cid;
300300- type Record = S::Record;
301301- type Author = S::Author;
302302- type Reason = S::Reason;
303303- type IsRead = S::IsRead;
304304- type IndexedAt = S::IndexedAt;
305305- }
306294 ///State transition - sets the `cid` field to Set
307295 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
308296 impl<S: State> sealed::Sealed for SetCid<S> {}
309297 impl<S: State> State for SetCid<S> {
310310- type Uri = S::Uri;
311298 type Cid = Set<members::cid>;
299299+ type Author = S::Author;
312300 type Record = S::Record;
313313- type Author = S::Author;
301301+ type IsRead = S::IsRead;
314302 type Reason = S::Reason;
303303+ type Uri = S::Uri;
304304+ type IndexedAt = S::IndexedAt;
305305+ }
306306+ ///State transition - sets the `author` field to Set
307307+ pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
308308+ impl<S: State> sealed::Sealed for SetAuthor<S> {}
309309+ impl<S: State> State for SetAuthor<S> {
310310+ type Cid = S::Cid;
311311+ type Author = Set<members::author>;
312312+ type Record = S::Record;
315313 type IsRead = S::IsRead;
314314+ type Reason = S::Reason;
315315+ type Uri = S::Uri;
316316 type IndexedAt = S::IndexedAt;
317317 }
318318 ///State transition - sets the `record` field to Set
319319 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
320320 impl<S: State> sealed::Sealed for SetRecord<S> {}
321321 impl<S: State> State for SetRecord<S> {
322322- type Uri = S::Uri;
323322 type Cid = S::Cid;
324324- type Record = Set<members::record>;
325323 type Author = S::Author;
326326- type Reason = S::Reason;
324324+ type Record = Set<members::record>;
327325 type IsRead = S::IsRead;
326326+ type Reason = S::Reason;
327327+ type Uri = S::Uri;
328328 type IndexedAt = S::IndexedAt;
329329 }
330330- ///State transition - sets the `author` field to Set
331331- pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
332332- impl<S: State> sealed::Sealed for SetAuthor<S> {}
333333- impl<S: State> State for SetAuthor<S> {
334334- type Uri = S::Uri;
330330+ ///State transition - sets the `is_read` field to Set
331331+ pub struct SetIsRead<S: State = Empty>(PhantomData<fn() -> S>);
332332+ impl<S: State> sealed::Sealed for SetIsRead<S> {}
333333+ impl<S: State> State for SetIsRead<S> {
335334 type Cid = S::Cid;
335335+ type Author = S::Author;
336336 type Record = S::Record;
337337- type Author = Set<members::author>;
337337+ type IsRead = Set<members::is_read>;
338338 type Reason = S::Reason;
339339- type IsRead = S::IsRead;
339339+ type Uri = S::Uri;
340340 type IndexedAt = S::IndexedAt;
341341 }
342342 ///State transition - sets the `reason` field to Set
343343 pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
344344 impl<S: State> sealed::Sealed for SetReason<S> {}
345345 impl<S: State> State for SetReason<S> {
346346- type Uri = S::Uri;
347346 type Cid = S::Cid;
347347+ type Author = S::Author;
348348 type Record = S::Record;
349349- type Author = S::Author;
349349+ type IsRead = S::IsRead;
350350 type Reason = Set<members::reason>;
351351- type IsRead = S::IsRead;
351351+ type Uri = S::Uri;
352352 type IndexedAt = S::IndexedAt;
353353 }
354354- ///State transition - sets the `is_read` field to Set
355355- pub struct SetIsRead<S: State = Empty>(PhantomData<fn() -> S>);
356356- impl<S: State> sealed::Sealed for SetIsRead<S> {}
357357- impl<S: State> State for SetIsRead<S> {
358358- type Uri = S::Uri;
354354+ ///State transition - sets the `uri` field to Set
355355+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
356356+ impl<S: State> sealed::Sealed for SetUri<S> {}
357357+ impl<S: State> State for SetUri<S> {
359358 type Cid = S::Cid;
359359+ type Author = S::Author;
360360 type Record = S::Record;
361361- type Author = S::Author;
361361+ type IsRead = S::IsRead;
362362 type Reason = S::Reason;
363363- type IsRead = Set<members::is_read>;
363363+ type Uri = Set<members::uri>;
364364 type IndexedAt = S::IndexedAt;
365365 }
366366 ///State transition - sets the `indexed_at` field to Set
367367 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
368368 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
369369 impl<S: State> State for SetIndexedAt<S> {
370370- type Uri = S::Uri;
371370 type Cid = S::Cid;
372372- type Record = S::Record;
373371 type Author = S::Author;
374374- type Reason = S::Reason;
372372+ type Record = S::Record;
375373 type IsRead = S::IsRead;
374374+ type Reason = S::Reason;
375375+ type Uri = S::Uri;
376376 type IndexedAt = Set<members::indexed_at>;
377377 }
378378 /// Marker types for field names
379379 #[allow(non_camel_case_types)]
380380 pub mod members {
381381- ///Marker type for the `uri` field
382382- pub struct uri(());
383381 ///Marker type for the `cid` field
384382 pub struct cid(());
385385- ///Marker type for the `record` field
386386- pub struct record(());
387383 ///Marker type for the `author` field
388384 pub struct author(());
389389- ///Marker type for the `reason` field
390390- pub struct reason(());
385385+ ///Marker type for the `record` field
386386+ pub struct record(());
391387 ///Marker type for the `is_read` field
392388 pub struct is_read(());
389389+ ///Marker type for the `reason` field
390390+ pub struct reason(());
391391+ ///Marker type for the `uri` field
392392+ pub struct uri(());
393393 ///Marker type for the `indexed_at` field
394394 pub struct indexed_at(());
395395 }
···614614impl<'a, S> NotificationBuilder<'a, S>
615615where
616616 S: notification_state::State,
617617- S::Uri: notification_state::IsSet,
618617 S::Cid: notification_state::IsSet,
619619- S::Record: notification_state::IsSet,
620618 S::Author: notification_state::IsSet,
621621- S::Reason: notification_state::IsSet,
619619+ S::Record: notification_state::IsSet,
622620 S::IsRead: notification_state::IsSet,
621621+ S::Reason: notification_state::IsSet,
622622+ S::Uri: notification_state::IsSet,
623623 S::IndexedAt: notification_state::IsSet,
624624{
625625 /// Build the final struct
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Subject;
3736 type ActivitySubscription;
3737+ type Subject;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Subject = Unset;
4443 type ActivitySubscription = Unset;
4545- }
4646- ///State transition - sets the `subject` field to Set
4747- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetSubject<S> {}
4949- impl<S: State> State for SetSubject<S> {
5050- type Subject = Set<members::subject>;
5151- type ActivitySubscription = S::ActivitySubscription;
4444+ type Subject = Unset;
5245 }
5346 ///State transition - sets the `activity_subscription` field to Set
5447 pub struct SetActivitySubscription<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetActivitySubscription<S> {}
5649 impl<S: State> State for SetActivitySubscription<S> {
5757- type Subject = S::Subject;
5850 type ActivitySubscription = Set<members::activity_subscription>;
5151+ type Subject = S::Subject;
5252+ }
5353+ ///State transition - sets the `subject` field to Set
5454+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetSubject<S> {}
5656+ impl<S: State> State for SetSubject<S> {
5757+ type ActivitySubscription = S::ActivitySubscription;
5858+ type Subject = Set<members::subject>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `subject` field
6464- pub struct subject(());
6563 ///Marker type for the `activity_subscription` field
6664 pub struct activity_subscription(());
6565+ ///Marker type for the `subject` field
6666+ pub struct subject(());
6767 }
6868}
6969···148148impl<'a, S> PutActivitySubscriptionBuilder<'a, S>
149149where
150150 S: put_activity_subscription_state::State,
151151- S::Subject: put_activity_subscription_state::IsSet,
152151 S::ActivitySubscription: put_activity_subscription_state::IsSet,
152152+ S::Subject: put_activity_subscription_state::IsSet,
153153{
154154 /// Build the final struct
155155 pub fn build(self) -> PutActivitySubscription<'a> {
···4040 }
4141 /// State trait tracking which required fields have been set
4242 pub trait State: sealed::Sealed {
4343- type Token;
4444- type ServiceDid;
4543 type Platform;
4644 type AppId;
4545+ type ServiceDid;
4646+ type Token;
4747 }
4848 /// Empty state - all required fields are unset
4949 pub struct Empty(());
5050 impl sealed::Sealed for Empty {}
5151 impl State for Empty {
5252- type Token = Unset;
5353- type ServiceDid = Unset;
5452 type Platform = Unset;
5553 type AppId = Unset;
5656- }
5757- ///State transition - sets the `token` field to Set
5858- pub struct SetToken<S: State = Empty>(PhantomData<fn() -> S>);
5959- impl<S: State> sealed::Sealed for SetToken<S> {}
6060- impl<S: State> State for SetToken<S> {
6161- type Token = Set<members::token>;
6262- type ServiceDid = S::ServiceDid;
6363- type Platform = S::Platform;
6464- type AppId = S::AppId;
6565- }
6666- ///State transition - sets the `service_did` field to Set
6767- pub struct SetServiceDid<S: State = Empty>(PhantomData<fn() -> S>);
6868- impl<S: State> sealed::Sealed for SetServiceDid<S> {}
6969- impl<S: State> State for SetServiceDid<S> {
7070- type Token = S::Token;
7171- type ServiceDid = Set<members::service_did>;
7272- type Platform = S::Platform;
7373- type AppId = S::AppId;
5454+ type ServiceDid = Unset;
5555+ type Token = Unset;
7456 }
7557 ///State transition - sets the `platform` field to Set
7658 pub struct SetPlatform<S: State = Empty>(PhantomData<fn() -> S>);
7759 impl<S: State> sealed::Sealed for SetPlatform<S> {}
7860 impl<S: State> State for SetPlatform<S> {
7979- type Token = S::Token;
8080- type ServiceDid = S::ServiceDid;
8161 type Platform = Set<members::platform>;
8262 type AppId = S::AppId;
6363+ type ServiceDid = S::ServiceDid;
6464+ type Token = S::Token;
8365 }
8466 ///State transition - sets the `app_id` field to Set
8567 pub struct SetAppId<S: State = Empty>(PhantomData<fn() -> S>);
8668 impl<S: State> sealed::Sealed for SetAppId<S> {}
8769 impl<S: State> State for SetAppId<S> {
7070+ type Platform = S::Platform;
7171+ type AppId = Set<members::app_id>;
7272+ type ServiceDid = S::ServiceDid;
8873 type Token = S::Token;
8989- type ServiceDid = S::ServiceDid;
7474+ }
7575+ ///State transition - sets the `service_did` field to Set
7676+ pub struct SetServiceDid<S: State = Empty>(PhantomData<fn() -> S>);
7777+ impl<S: State> sealed::Sealed for SetServiceDid<S> {}
7878+ impl<S: State> State for SetServiceDid<S> {
9079 type Platform = S::Platform;
9191- type AppId = Set<members::app_id>;
8080+ type AppId = S::AppId;
8181+ type ServiceDid = Set<members::service_did>;
8282+ type Token = S::Token;
8383+ }
8484+ ///State transition - sets the `token` field to Set
8585+ pub struct SetToken<S: State = Empty>(PhantomData<fn() -> S>);
8686+ impl<S: State> sealed::Sealed for SetToken<S> {}
8787+ impl<S: State> State for SetToken<S> {
8888+ type Platform = S::Platform;
8989+ type AppId = S::AppId;
9090+ type ServiceDid = S::ServiceDid;
9191+ type Token = Set<members::token>;
9292 }
9393 /// Marker types for field names
9494 #[allow(non_camel_case_types)]
9595 pub mod members {
9696- ///Marker type for the `token` field
9797- pub struct token(());
9898- ///Marker type for the `service_did` field
9999- pub struct service_did(());
10096 ///Marker type for the `platform` field
10197 pub struct platform(());
10298 ///Marker type for the `app_id` field
10399 pub struct app_id(());
100100+ ///Marker type for the `service_did` field
101101+ pub struct service_did(());
102102+ ///Marker type for the `token` field
103103+ pub struct token(());
104104 }
105105}
106106···227227impl<'a, S> RegisterPushBuilder<'a, S>
228228where
229229 S: register_push_state::State,
230230- S::Token: register_push_state::IsSet,
231231- S::ServiceDid: register_push_state::IsSet,
232230 S::Platform: register_push_state::IsSet,
233231 S::AppId: register_push_state::IsSet,
232232+ S::ServiceDid: register_push_state::IsSet,
233233+ S::Token: register_push_state::IsSet,
234234{
235235 /// Build the final struct
236236 pub fn build(self) -> RegisterPush<'a> {
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040- type ServiceDid;
4141- type Platform;
4240 type AppId;
4141+ type ServiceDid;
4342 type Token;
4343+ type Platform;
4444 }
4545 /// Empty state - all required fields are unset
4646 pub struct Empty(());
4747 impl sealed::Sealed for Empty {}
4848 impl State for Empty {
4949+ type AppId = Unset;
4950 type ServiceDid = Unset;
5050- type Platform = Unset;
5151- type AppId = Unset;
5251 type Token = Unset;
5353- }
5454- ///State transition - sets the `service_did` field to Set
5555- pub struct SetServiceDid<S: State = Empty>(PhantomData<fn() -> S>);
5656- impl<S: State> sealed::Sealed for SetServiceDid<S> {}
5757- impl<S: State> State for SetServiceDid<S> {
5858- type ServiceDid = Set<members::service_did>;
5959- type Platform = S::Platform;
6060- type AppId = S::AppId;
6161- type Token = S::Token;
6262- }
6363- ///State transition - sets the `platform` field to Set
6464- pub struct SetPlatform<S: State = Empty>(PhantomData<fn() -> S>);
6565- impl<S: State> sealed::Sealed for SetPlatform<S> {}
6666- impl<S: State> State for SetPlatform<S> {
6767- type ServiceDid = S::ServiceDid;
6868- type Platform = Set<members::platform>;
6969- type AppId = S::AppId;
7070- type Token = S::Token;
5252+ type Platform = Unset;
7153 }
7254 ///State transition - sets the `app_id` field to Set
7355 pub struct SetAppId<S: State = Empty>(PhantomData<fn() -> S>);
7456 impl<S: State> sealed::Sealed for SetAppId<S> {}
7557 impl<S: State> State for SetAppId<S> {
5858+ type AppId = Set<members::app_id>;
7659 type ServiceDid = S::ServiceDid;
6060+ type Token = S::Token;
7761 type Platform = S::Platform;
7878- type AppId = Set<members::app_id>;
6262+ }
6363+ ///State transition - sets the `service_did` field to Set
6464+ pub struct SetServiceDid<S: State = Empty>(PhantomData<fn() -> S>);
6565+ impl<S: State> sealed::Sealed for SetServiceDid<S> {}
6666+ impl<S: State> State for SetServiceDid<S> {
6767+ type AppId = S::AppId;
6868+ type ServiceDid = Set<members::service_did>;
7969 type Token = S::Token;
7070+ type Platform = S::Platform;
8071 }
8172 ///State transition - sets the `token` field to Set
8273 pub struct SetToken<S: State = Empty>(PhantomData<fn() -> S>);
8374 impl<S: State> sealed::Sealed for SetToken<S> {}
8475 impl<S: State> State for SetToken<S> {
7676+ type AppId = S::AppId;
8577 type ServiceDid = S::ServiceDid;
7878+ type Token = Set<members::token>;
8679 type Platform = S::Platform;
8080+ }
8181+ ///State transition - sets the `platform` field to Set
8282+ pub struct SetPlatform<S: State = Empty>(PhantomData<fn() -> S>);
8383+ impl<S: State> sealed::Sealed for SetPlatform<S> {}
8484+ impl<S: State> State for SetPlatform<S> {
8785 type AppId = S::AppId;
8888- type Token = Set<members::token>;
8686+ type ServiceDid = S::ServiceDid;
8787+ type Token = S::Token;
8888+ type Platform = Set<members::platform>;
8989 }
9090 /// Marker types for field names
9191 #[allow(non_camel_case_types)]
9292 pub mod members {
9393- ///Marker type for the `service_did` field
9494- pub struct service_did(());
9595- ///Marker type for the `platform` field
9696- pub struct platform(());
9793 ///Marker type for the `app_id` field
9894 pub struct app_id(());
9595+ ///Marker type for the `service_did` field
9696+ pub struct service_did(());
9997 ///Marker type for the `token` field
10098 pub struct token(());
9999+ ///Marker type for the `platform` field
100100+ pub struct platform(());
101101 }
102102}
103103···210210impl<'a, S> UnregisterPushBuilder<'a, S>
211211where
212212 S: unregister_push_state::State,
213213- S::ServiceDid: unregister_push_state::IsSet,
214214- S::Platform: unregister_push_state::IsSet,
215213 S::AppId: unregister_push_state::IsSet,
214214+ S::ServiceDid: unregister_push_state::IsSet,
216215 S::Token: unregister_push_state::IsSet,
216216+ S::Platform: unregister_push_state::IsSet,
217217{
218218 /// Build the final struct
219219 pub fn build(self) -> UnregisterPush<'a> {
+13-13
crates/weaver-api/src/app_bsky/richtext/facet.rs
···581581 }
582582 /// State trait tracking which required fields have been set
583583 pub trait State: sealed::Sealed {
584584- type Features;
585584 type Index;
585585+ type Features;
586586 }
587587 /// Empty state - all required fields are unset
588588 pub struct Empty(());
589589 impl sealed::Sealed for Empty {}
590590 impl State for Empty {
591591- type Features = Unset;
592591 type Index = Unset;
593593- }
594594- ///State transition - sets the `features` field to Set
595595- pub struct SetFeatures<S: State = Empty>(PhantomData<fn() -> S>);
596596- impl<S: State> sealed::Sealed for SetFeatures<S> {}
597597- impl<S: State> State for SetFeatures<S> {
598598- type Features = Set<members::features>;
599599- type Index = S::Index;
592592+ type Features = Unset;
600593 }
601594 ///State transition - sets the `index` field to Set
602595 pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
603596 impl<S: State> sealed::Sealed for SetIndex<S> {}
604597 impl<S: State> State for SetIndex<S> {
605605- type Features = S::Features;
606598 type Index = Set<members::index>;
599599+ type Features = S::Features;
600600+ }
601601+ ///State transition - sets the `features` field to Set
602602+ pub struct SetFeatures<S: State = Empty>(PhantomData<fn() -> S>);
603603+ impl<S: State> sealed::Sealed for SetFeatures<S> {}
604604+ impl<S: State> State for SetFeatures<S> {
605605+ type Index = S::Index;
606606+ type Features = Set<members::features>;
607607 }
608608 /// Marker types for field names
609609 #[allow(non_camel_case_types)]
610610 pub mod members {
611611- ///Marker type for the `features` field
612612- pub struct features(());
613611 ///Marker type for the `index` field
614612 pub struct index(());
613613+ ///Marker type for the `features` field
614614+ pub struct features(());
615615 }
616616}
617617···684684impl<'a, S> FacetBuilder<'a, S>
685685where
686686 S: facet_state::State,
687687- S::Features: facet_state::IsSet,
688687 S::Index: facet_state::IsSet,
688688+ S::Features: facet_state::IsSet,
689689{
690690 /// Build the final struct
691691 pub fn build(self) -> Facet<'a> {
+147-147
crates/weaver-api/src/app_bsky/unspecced.rs
···8181 }
8282 /// State trait tracking which required fields have been set
8383 pub trait State: sealed::Sealed {
8484- type AttemptId;
8584 type Status;
8685 type CreatedAt;
8686+ type AttemptId;
8787 }
8888 /// Empty state - all required fields are unset
8989 pub struct Empty(());
9090 impl sealed::Sealed for Empty {}
9191 impl State for Empty {
9292- type AttemptId = Unset;
9392 type Status = Unset;
9493 type CreatedAt = Unset;
9595- }
9696- ///State transition - sets the `attempt_id` field to Set
9797- pub struct SetAttemptId<S: State = Empty>(PhantomData<fn() -> S>);
9898- impl<S: State> sealed::Sealed for SetAttemptId<S> {}
9999- impl<S: State> State for SetAttemptId<S> {
100100- type AttemptId = Set<members::attempt_id>;
101101- type Status = S::Status;
102102- type CreatedAt = S::CreatedAt;
9494+ type AttemptId = Unset;
10395 }
10496 ///State transition - sets the `status` field to Set
10597 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
10698 impl<S: State> sealed::Sealed for SetStatus<S> {}
10799 impl<S: State> State for SetStatus<S> {
108108- type AttemptId = S::AttemptId;
109100 type Status = Set<members::status>;
110101 type CreatedAt = S::CreatedAt;
102102+ type AttemptId = S::AttemptId;
111103 }
112104 ///State transition - sets the `created_at` field to Set
113105 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
114106 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
115107 impl<S: State> State for SetCreatedAt<S> {
116116- type AttemptId = S::AttemptId;
117108 type Status = S::Status;
118109 type CreatedAt = Set<members::created_at>;
110110+ type AttemptId = S::AttemptId;
111111+ }
112112+ ///State transition - sets the `attempt_id` field to Set
113113+ pub struct SetAttemptId<S: State = Empty>(PhantomData<fn() -> S>);
114114+ impl<S: State> sealed::Sealed for SetAttemptId<S> {}
115115+ impl<S: State> State for SetAttemptId<S> {
116116+ type Status = S::Status;
117117+ type CreatedAt = S::CreatedAt;
118118+ type AttemptId = Set<members::attempt_id>;
119119 }
120120 /// Marker types for field names
121121 #[allow(non_camel_case_types)]
122122 pub mod members {
123123- ///Marker type for the `attempt_id` field
124124- pub struct attempt_id(());
125123 ///Marker type for the `status` field
126124 pub struct status(());
127125 ///Marker type for the `created_at` field
128126 pub struct created_at(());
127127+ ///Marker type for the `attempt_id` field
128128+ pub struct attempt_id(());
129129 }
130130}
131131···309309impl<'a, S> AgeAssuranceEventBuilder<'a, S>
310310where
311311 S: age_assurance_event_state::State,
312312- S::AttemptId: age_assurance_event_state::IsSet,
313312 S::Status: age_assurance_event_state::IsSet,
314313 S::CreatedAt: age_assurance_event_state::IsSet,
314314+ S::AttemptId: age_assurance_event_state::IsSet,
315315{
316316 /// Build the final struct
317317 pub fn build(self) -> AgeAssuranceEvent<'a> {
···19401940 }
19411941 /// State trait tracking which required fields have been set
19421942 pub trait State: sealed::Sealed {
19431943- type DisplayName;
19431943+ type Dids;
19441944 type Link;
19451945 type Topic;
19461946- type Dids;
19461946+ type StartedAt;
19471947 type PostCount;
19481948- type StartedAt;
19481948+ type DisplayName;
19491949 }
19501950 /// Empty state - all required fields are unset
19511951 pub struct Empty(());
19521952 impl sealed::Sealed for Empty {}
19531953 impl State for Empty {
19541954- type DisplayName = Unset;
19541954+ type Dids = Unset;
19551955 type Link = Unset;
19561956 type Topic = Unset;
19571957- type Dids = Unset;
19571957+ type StartedAt = Unset;
19581958 type PostCount = Unset;
19591959- type StartedAt = Unset;
19591959+ type DisplayName = Unset;
19601960 }
19611961- ///State transition - sets the `display_name` field to Set
19621962- pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
19631963- impl<S: State> sealed::Sealed for SetDisplayName<S> {}
19641964- impl<S: State> State for SetDisplayName<S> {
19651965- type DisplayName = Set<members::display_name>;
19611961+ ///State transition - sets the `dids` field to Set
19621962+ pub struct SetDids<S: State = Empty>(PhantomData<fn() -> S>);
19631963+ impl<S: State> sealed::Sealed for SetDids<S> {}
19641964+ impl<S: State> State for SetDids<S> {
19651965+ type Dids = Set<members::dids>;
19661966 type Link = S::Link;
19671967 type Topic = S::Topic;
19681968- type Dids = S::Dids;
19691969- type PostCount = S::PostCount;
19701968 type StartedAt = S::StartedAt;
19691969+ type PostCount = S::PostCount;
19701970+ type DisplayName = S::DisplayName;
19711971 }
19721972 ///State transition - sets the `link` field to Set
19731973 pub struct SetLink<S: State = Empty>(PhantomData<fn() -> S>);
19741974 impl<S: State> sealed::Sealed for SetLink<S> {}
19751975 impl<S: State> State for SetLink<S> {
19761976- type DisplayName = S::DisplayName;
19761976+ type Dids = S::Dids;
19771977 type Link = Set<members::link>;
19781978 type Topic = S::Topic;
19791979- type Dids = S::Dids;
19791979+ type StartedAt = S::StartedAt;
19801980 type PostCount = S::PostCount;
19811981- type StartedAt = S::StartedAt;
19811981+ type DisplayName = S::DisplayName;
19821982 }
19831983 ///State transition - sets the `topic` field to Set
19841984 pub struct SetTopic<S: State = Empty>(PhantomData<fn() -> S>);
19851985 impl<S: State> sealed::Sealed for SetTopic<S> {}
19861986 impl<S: State> State for SetTopic<S> {
19871987- type DisplayName = S::DisplayName;
19871987+ type Dids = S::Dids;
19881988 type Link = S::Link;
19891989 type Topic = Set<members::topic>;
19901990- type Dids = S::Dids;
19911991- type PostCount = S::PostCount;
19921990 type StartedAt = S::StartedAt;
19931993- }
19941994- ///State transition - sets the `dids` field to Set
19951995- pub struct SetDids<S: State = Empty>(PhantomData<fn() -> S>);
19961996- impl<S: State> sealed::Sealed for SetDids<S> {}
19971997- impl<S: State> State for SetDids<S> {
19911991+ type PostCount = S::PostCount;
19981992 type DisplayName = S::DisplayName;
19931993+ }
19941994+ ///State transition - sets the `started_at` field to Set
19951995+ pub struct SetStartedAt<S: State = Empty>(PhantomData<fn() -> S>);
19961996+ impl<S: State> sealed::Sealed for SetStartedAt<S> {}
19971997+ impl<S: State> State for SetStartedAt<S> {
19981998+ type Dids = S::Dids;
19991999 type Link = S::Link;
20002000 type Topic = S::Topic;
20012001- type Dids = Set<members::dids>;
20012001+ type StartedAt = Set<members::started_at>;
20022002 type PostCount = S::PostCount;
20032003- type StartedAt = S::StartedAt;
20032003+ type DisplayName = S::DisplayName;
20042004 }
20052005 ///State transition - sets the `post_count` field to Set
20062006 pub struct SetPostCount<S: State = Empty>(PhantomData<fn() -> S>);
20072007 impl<S: State> sealed::Sealed for SetPostCount<S> {}
20082008 impl<S: State> State for SetPostCount<S> {
20092009- type DisplayName = S::DisplayName;
20092009+ type Dids = S::Dids;
20102010 type Link = S::Link;
20112011 type Topic = S::Topic;
20122012- type Dids = S::Dids;
20132013- type PostCount = Set<members::post_count>;
20142012 type StartedAt = S::StartedAt;
20152015- }
20162016- ///State transition - sets the `started_at` field to Set
20172017- pub struct SetStartedAt<S: State = Empty>(PhantomData<fn() -> S>);
20182018- impl<S: State> sealed::Sealed for SetStartedAt<S> {}
20192019- impl<S: State> State for SetStartedAt<S> {
20132013+ type PostCount = Set<members::post_count>;
20202014 type DisplayName = S::DisplayName;
20152015+ }
20162016+ ///State transition - sets the `display_name` field to Set
20172017+ pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
20182018+ impl<S: State> sealed::Sealed for SetDisplayName<S> {}
20192019+ impl<S: State> State for SetDisplayName<S> {
20202020+ type Dids = S::Dids;
20212021 type Link = S::Link;
20222022 type Topic = S::Topic;
20232023- type Dids = S::Dids;
20232023+ type StartedAt = S::StartedAt;
20242024 type PostCount = S::PostCount;
20252025- type StartedAt = Set<members::started_at>;
20252025+ type DisplayName = Set<members::display_name>;
20262026 }
20272027 /// Marker types for field names
20282028 #[allow(non_camel_case_types)]
20292029 pub mod members {
20302030- ///Marker type for the `display_name` field
20312031- pub struct display_name(());
20302030+ ///Marker type for the `dids` field
20312031+ pub struct dids(());
20322032 ///Marker type for the `link` field
20332033 pub struct link(());
20342034 ///Marker type for the `topic` field
20352035 pub struct topic(());
20362036- ///Marker type for the `dids` field
20372037- pub struct dids(());
20382038- ///Marker type for the `post_count` field
20392039- pub struct post_count(());
20402036 ///Marker type for the `started_at` field
20412037 pub struct started_at(());
20382038+ ///Marker type for the `post_count` field
20392039+ pub struct post_count(());
20402040+ ///Marker type for the `display_name` field
20412041+ pub struct display_name(());
20422042 }
20432043}
20442044···22222222impl<'a, S> SkeletonTrendBuilder<'a, S>
22232223where
22242224 S: skeleton_trend_state::State,
22252225- S::DisplayName: skeleton_trend_state::IsSet,
22252225+ S::Dids: skeleton_trend_state::IsSet,
22262226 S::Link: skeleton_trend_state::IsSet,
22272227 S::Topic: skeleton_trend_state::IsSet,
22282228- S::Dids: skeleton_trend_state::IsSet,
22282228+ S::StartedAt: skeleton_trend_state::IsSet,
22292229 S::PostCount: skeleton_trend_state::IsSet,
22302230- S::StartedAt: skeleton_trend_state::IsSet,
22302230+ S::DisplayName: skeleton_trend_state::IsSet,
22312231{
22322232 /// Build the final struct
22332233 pub fn build(self) -> SkeletonTrend<'a> {
···25992599 }
26002600 /// State trait tracking which required fields have been set
26012601 pub trait State: sealed::Sealed {
26022602- type Post;
26022602+ type MutedByViewer;
26032603 type MoreParents;
26042604 type MoreReplies;
26052605 type OpThread;
26062606+ type Post;
26062607 type HiddenByThreadgate;
26072607- type MutedByViewer;
26082608 }
26092609 /// Empty state - all required fields are unset
26102610 pub struct Empty(());
26112611 impl sealed::Sealed for Empty {}
26122612 impl State for Empty {
26132613- type Post = Unset;
26132613+ type MutedByViewer = Unset;
26142614 type MoreParents = Unset;
26152615 type MoreReplies = Unset;
26162616 type OpThread = Unset;
26172617+ type Post = Unset;
26172618 type HiddenByThreadgate = Unset;
26182618- type MutedByViewer = Unset;
26192619 }
26202620- ///State transition - sets the `post` field to Set
26212621- pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
26222622- impl<S: State> sealed::Sealed for SetPost<S> {}
26232623- impl<S: State> State for SetPost<S> {
26242624- type Post = Set<members::post>;
26202620+ ///State transition - sets the `muted_by_viewer` field to Set
26212621+ pub struct SetMutedByViewer<S: State = Empty>(PhantomData<fn() -> S>);
26222622+ impl<S: State> sealed::Sealed for SetMutedByViewer<S> {}
26232623+ impl<S: State> State for SetMutedByViewer<S> {
26242624+ type MutedByViewer = Set<members::muted_by_viewer>;
26252625 type MoreParents = S::MoreParents;
26262626 type MoreReplies = S::MoreReplies;
26272627 type OpThread = S::OpThread;
26282628+ type Post = S::Post;
26282629 type HiddenByThreadgate = S::HiddenByThreadgate;
26292629- type MutedByViewer = S::MutedByViewer;
26302630 }
26312631 ///State transition - sets the `more_parents` field to Set
26322632 pub struct SetMoreParents<S: State = Empty>(PhantomData<fn() -> S>);
26332633 impl<S: State> sealed::Sealed for SetMoreParents<S> {}
26342634 impl<S: State> State for SetMoreParents<S> {
26352635- type Post = S::Post;
26352635+ type MutedByViewer = S::MutedByViewer;
26362636 type MoreParents = Set<members::more_parents>;
26372637 type MoreReplies = S::MoreReplies;
26382638 type OpThread = S::OpThread;
26392639+ type Post = S::Post;
26392640 type HiddenByThreadgate = S::HiddenByThreadgate;
26402640- type MutedByViewer = S::MutedByViewer;
26412641 }
26422642 ///State transition - sets the `more_replies` field to Set
26432643 pub struct SetMoreReplies<S: State = Empty>(PhantomData<fn() -> S>);
26442644 impl<S: State> sealed::Sealed for SetMoreReplies<S> {}
26452645 impl<S: State> State for SetMoreReplies<S> {
26462646- type Post = S::Post;
26462646+ type MutedByViewer = S::MutedByViewer;
26472647 type MoreParents = S::MoreParents;
26482648 type MoreReplies = Set<members::more_replies>;
26492649 type OpThread = S::OpThread;
26502650+ type Post = S::Post;
26502651 type HiddenByThreadgate = S::HiddenByThreadgate;
26512651- type MutedByViewer = S::MutedByViewer;
26522652 }
26532653 ///State transition - sets the `op_thread` field to Set
26542654 pub struct SetOpThread<S: State = Empty>(PhantomData<fn() -> S>);
26552655 impl<S: State> sealed::Sealed for SetOpThread<S> {}
26562656 impl<S: State> State for SetOpThread<S> {
26572657- type Post = S::Post;
26572657+ type MutedByViewer = S::MutedByViewer;
26582658 type MoreParents = S::MoreParents;
26592659 type MoreReplies = S::MoreReplies;
26602660 type OpThread = Set<members::op_thread>;
26612661+ type Post = S::Post;
26612662 type HiddenByThreadgate = S::HiddenByThreadgate;
26632663+ }
26642664+ ///State transition - sets the `post` field to Set
26652665+ pub struct SetPost<S: State = Empty>(PhantomData<fn() -> S>);
26662666+ impl<S: State> sealed::Sealed for SetPost<S> {}
26672667+ impl<S: State> State for SetPost<S> {
26622668 type MutedByViewer = S::MutedByViewer;
26692669+ type MoreParents = S::MoreParents;
26702670+ type MoreReplies = S::MoreReplies;
26712671+ type OpThread = S::OpThread;
26722672+ type Post = Set<members::post>;
26732673+ type HiddenByThreadgate = S::HiddenByThreadgate;
26632674 }
26642675 ///State transition - sets the `hidden_by_threadgate` field to Set
26652676 pub struct SetHiddenByThreadgate<S: State = Empty>(PhantomData<fn() -> S>);
26662677 impl<S: State> sealed::Sealed for SetHiddenByThreadgate<S> {}
26672678 impl<S: State> State for SetHiddenByThreadgate<S> {
26682668- type Post = S::Post;
26692669- type MoreParents = S::MoreParents;
26702670- type MoreReplies = S::MoreReplies;
26712671- type OpThread = S::OpThread;
26722672- type HiddenByThreadgate = Set<members::hidden_by_threadgate>;
26732679 type MutedByViewer = S::MutedByViewer;
26742674- }
26752675- ///State transition - sets the `muted_by_viewer` field to Set
26762676- pub struct SetMutedByViewer<S: State = Empty>(PhantomData<fn() -> S>);
26772677- impl<S: State> sealed::Sealed for SetMutedByViewer<S> {}
26782678- impl<S: State> State for SetMutedByViewer<S> {
26792679- type Post = S::Post;
26802680 type MoreParents = S::MoreParents;
26812681 type MoreReplies = S::MoreReplies;
26822682 type OpThread = S::OpThread;
26832683- type HiddenByThreadgate = S::HiddenByThreadgate;
26842684- type MutedByViewer = Set<members::muted_by_viewer>;
26832683+ type Post = S::Post;
26842684+ type HiddenByThreadgate = Set<members::hidden_by_threadgate>;
26852685 }
26862686 /// Marker types for field names
26872687 #[allow(non_camel_case_types)]
26882688 pub mod members {
26892689- ///Marker type for the `post` field
26902690- pub struct post(());
26892689+ ///Marker type for the `muted_by_viewer` field
26902690+ pub struct muted_by_viewer(());
26912691 ///Marker type for the `more_parents` field
26922692 pub struct more_parents(());
26932693 ///Marker type for the `more_replies` field
26942694 pub struct more_replies(());
26952695 ///Marker type for the `op_thread` field
26962696 pub struct op_thread(());
26972697+ ///Marker type for the `post` field
26982698+ pub struct post(());
26972699 ///Marker type for the `hidden_by_threadgate` field
26982700 pub struct hidden_by_threadgate(());
26992699- ///Marker type for the `muted_by_viewer` field
27002700- pub struct muted_by_viewer(());
27012701 }
27022702}
27032703···28502850impl<'a, S> ThreadItemPostBuilder<'a, S>
28512851where
28522852 S: thread_item_post_state::State,
28532853- S::Post: thread_item_post_state::IsSet,
28532853+ S::MutedByViewer: thread_item_post_state::IsSet,
28542854 S::MoreParents: thread_item_post_state::IsSet,
28552855 S::MoreReplies: thread_item_post_state::IsSet,
28562856 S::OpThread: thread_item_post_state::IsSet,
28572857+ S::Post: thread_item_post_state::IsSet,
28572858 S::HiddenByThreadgate: thread_item_post_state::IsSet,
28582858- S::MutedByViewer: thread_item_post_state::IsSet,
28592859{
28602860 /// Build the final struct
28612861 pub fn build(self) -> ThreadItemPost<'a> {
···29472947 /// State trait tracking which required fields have been set
29482948 pub trait State: sealed::Sealed {
29492949 type Topic;
29502950- type DisplayName;
29512951- type Link;
29522952- type PostCount;
29532950 type Actors;
29542951 type StartedAt;
29522952+ type PostCount;
29532953+ type Link;
29542954+ type DisplayName;
29552955 }
29562956 /// Empty state - all required fields are unset
29572957 pub struct Empty(());
29582958 impl sealed::Sealed for Empty {}
29592959 impl State for Empty {
29602960 type Topic = Unset;
29612961- type DisplayName = Unset;
29622962- type Link = Unset;
29632963- type PostCount = Unset;
29642961 type Actors = Unset;
29652962 type StartedAt = Unset;
29632963+ type PostCount = Unset;
29642964+ type Link = Unset;
29652965+ type DisplayName = Unset;
29662966 }
29672967 ///State transition - sets the `topic` field to Set
29682968 pub struct SetTopic<S: State = Empty>(PhantomData<fn() -> S>);
29692969 impl<S: State> sealed::Sealed for SetTopic<S> {}
29702970 impl<S: State> State for SetTopic<S> {
29712971 type Topic = Set<members::topic>;
29722972- type DisplayName = S::DisplayName;
29732973- type Link = S::Link;
29742974- type PostCount = S::PostCount;
29752972 type Actors = S::Actors;
29762973 type StartedAt = S::StartedAt;
29772977- }
29782978- ///State transition - sets the `display_name` field to Set
29792979- pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
29802980- impl<S: State> sealed::Sealed for SetDisplayName<S> {}
29812981- impl<S: State> State for SetDisplayName<S> {
29822982- type Topic = S::Topic;
29832983- type DisplayName = Set<members::display_name>;
29842984- type Link = S::Link;
29852974 type PostCount = S::PostCount;
29862986- type Actors = S::Actors;
29872987- type StartedAt = S::StartedAt;
29882988- }
29892989- ///State transition - sets the `link` field to Set
29902990- pub struct SetLink<S: State = Empty>(PhantomData<fn() -> S>);
29912991- impl<S: State> sealed::Sealed for SetLink<S> {}
29922992- impl<S: State> State for SetLink<S> {
29932993- type Topic = S::Topic;
29942994- type DisplayName = S::DisplayName;
29952995- type Link = Set<members::link>;
29962996- type PostCount = S::PostCount;
29972997- type Actors = S::Actors;
29982998- type StartedAt = S::StartedAt;
29992999- }
30003000- ///State transition - sets the `post_count` field to Set
30013001- pub struct SetPostCount<S: State = Empty>(PhantomData<fn() -> S>);
30023002- impl<S: State> sealed::Sealed for SetPostCount<S> {}
30033003- impl<S: State> State for SetPostCount<S> {
30043004- type Topic = S::Topic;
30053005- type DisplayName = S::DisplayName;
30062975 type Link = S::Link;
30073007- type PostCount = Set<members::post_count>;
30083008- type Actors = S::Actors;
30093009- type StartedAt = S::StartedAt;
29762976+ type DisplayName = S::DisplayName;
30102977 }
30112978 ///State transition - sets the `actors` field to Set
30122979 pub struct SetActors<S: State = Empty>(PhantomData<fn() -> S>);
30132980 impl<S: State> sealed::Sealed for SetActors<S> {}
30142981 impl<S: State> State for SetActors<S> {
30152982 type Topic = S::Topic;
30163016- type DisplayName = S::DisplayName;
30173017- type Link = S::Link;
30183018- type PostCount = S::PostCount;
30192983 type Actors = Set<members::actors>;
30202984 type StartedAt = S::StartedAt;
29852985+ type PostCount = S::PostCount;
29862986+ type Link = S::Link;
29872987+ type DisplayName = S::DisplayName;
30212988 }
30222989 ///State transition - sets the `started_at` field to Set
30232990 pub struct SetStartedAt<S: State = Empty>(PhantomData<fn() -> S>);
30242991 impl<S: State> sealed::Sealed for SetStartedAt<S> {}
30252992 impl<S: State> State for SetStartedAt<S> {
30262993 type Topic = S::Topic;
29942994+ type Actors = S::Actors;
29952995+ type StartedAt = Set<members::started_at>;
29962996+ type PostCount = S::PostCount;
29972997+ type Link = S::Link;
30272998 type DisplayName = S::DisplayName;
29992999+ }
30003000+ ///State transition - sets the `post_count` field to Set
30013001+ pub struct SetPostCount<S: State = Empty>(PhantomData<fn() -> S>);
30023002+ impl<S: State> sealed::Sealed for SetPostCount<S> {}
30033003+ impl<S: State> State for SetPostCount<S> {
30043004+ type Topic = S::Topic;
30053005+ type Actors = S::Actors;
30063006+ type StartedAt = S::StartedAt;
30073007+ type PostCount = Set<members::post_count>;
30283008 type Link = S::Link;
30093009+ type DisplayName = S::DisplayName;
30103010+ }
30113011+ ///State transition - sets the `link` field to Set
30123012+ pub struct SetLink<S: State = Empty>(PhantomData<fn() -> S>);
30133013+ impl<S: State> sealed::Sealed for SetLink<S> {}
30143014+ impl<S: State> State for SetLink<S> {
30153015+ type Topic = S::Topic;
30163016+ type Actors = S::Actors;
30173017+ type StartedAt = S::StartedAt;
30293018 type PostCount = S::PostCount;
30193019+ type Link = Set<members::link>;
30203020+ type DisplayName = S::DisplayName;
30213021+ }
30223022+ ///State transition - sets the `display_name` field to Set
30233023+ pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
30243024+ impl<S: State> sealed::Sealed for SetDisplayName<S> {}
30253025+ impl<S: State> State for SetDisplayName<S> {
30263026+ type Topic = S::Topic;
30303027 type Actors = S::Actors;
30313031- type StartedAt = Set<members::started_at>;
30283028+ type StartedAt = S::StartedAt;
30293029+ type PostCount = S::PostCount;
30303030+ type Link = S::Link;
30313031+ type DisplayName = Set<members::display_name>;
30323032 }
30333033 /// Marker types for field names
30343034 #[allow(non_camel_case_types)]
30353035 pub mod members {
30363036 ///Marker type for the `topic` field
30373037 pub struct topic(());
30383038- ///Marker type for the `display_name` field
30393039- pub struct display_name(());
30403040- ///Marker type for the `link` field
30413041- pub struct link(());
30423042- ///Marker type for the `post_count` field
30433043- pub struct post_count(());
30443038 ///Marker type for the `actors` field
30453039 pub struct actors(());
30463040 ///Marker type for the `started_at` field
30473041 pub struct started_at(());
30423042+ ///Marker type for the `post_count` field
30433043+ pub struct post_count(());
30443044+ ///Marker type for the `link` field
30453045+ pub struct link(());
30463046+ ///Marker type for the `display_name` field
30473047+ pub struct display_name(());
30483048 }
30493049}
30503050···32293229where
32303230 S: trend_view_state::State,
32313231 S::Topic: trend_view_state::IsSet,
32323232- S::DisplayName: trend_view_state::IsSet,
32333233- S::Link: trend_view_state::IsSet,
32343234- S::PostCount: trend_view_state::IsSet,
32353232 S::Actors: trend_view_state::IsSet,
32363233 S::StartedAt: trend_view_state::IsSet,
32343234+ S::PostCount: trend_view_state::IsSet,
32353235+ S::Link: trend_view_state::IsSet,
32363236+ S::DisplayName: trend_view_state::IsSet,
32373237{
32383238 /// Build the final struct
32393239 pub fn build(self) -> TrendView<'a> {
···189189 }
190190 /// State trait tracking which required fields have been set
191191 pub trait State: sealed::Sealed {
192192- type Uri;
193193- type Value;
194192 type Depth;
193193+ type Value;
194194+ type Uri;
195195 }
196196 /// Empty state - all required fields are unset
197197 pub struct Empty(());
198198 impl sealed::Sealed for Empty {}
199199 impl State for Empty {
200200+ type Depth = Unset;
201201+ type Value = Unset;
200202 type Uri = Unset;
201201- type Value = Unset;
202202- type Depth = Unset;
203203 }
204204- ///State transition - sets the `uri` field to Set
205205- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
206206- impl<S: State> sealed::Sealed for SetUri<S> {}
207207- impl<S: State> State for SetUri<S> {
208208- type Uri = Set<members::uri>;
204204+ ///State transition - sets the `depth` field to Set
205205+ pub struct SetDepth<S: State = Empty>(PhantomData<fn() -> S>);
206206+ impl<S: State> sealed::Sealed for SetDepth<S> {}
207207+ impl<S: State> State for SetDepth<S> {
208208+ type Depth = Set<members::depth>;
209209 type Value = S::Value;
210210- type Depth = S::Depth;
210210+ type Uri = S::Uri;
211211 }
212212 ///State transition - sets the `value` field to Set
213213 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
214214 impl<S: State> sealed::Sealed for SetValue<S> {}
215215 impl<S: State> State for SetValue<S> {
216216- type Uri = S::Uri;
217217- type Value = Set<members::value>;
218216 type Depth = S::Depth;
217217+ type Value = Set<members::value>;
218218+ type Uri = S::Uri;
219219 }
220220- ///State transition - sets the `depth` field to Set
221221- pub struct SetDepth<S: State = Empty>(PhantomData<fn() -> S>);
222222- impl<S: State> sealed::Sealed for SetDepth<S> {}
223223- impl<S: State> State for SetDepth<S> {
224224- type Uri = S::Uri;
220220+ ///State transition - sets the `uri` field to Set
221221+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
222222+ impl<S: State> sealed::Sealed for SetUri<S> {}
223223+ impl<S: State> State for SetUri<S> {
224224+ type Depth = S::Depth;
225225 type Value = S::Value;
226226- type Depth = Set<members::depth>;
226226+ type Uri = Set<members::uri>;
227227 }
228228 /// Marker types for field names
229229 #[allow(non_camel_case_types)]
230230 pub mod members {
231231+ ///Marker type for the `depth` field
232232+ pub struct depth(());
233233+ ///Marker type for the `value` field
234234+ pub struct value(());
231235 ///Marker type for the `uri` field
232236 pub struct uri(());
233233- ///Marker type for the `value` field
234234- pub struct value(());
235235- ///Marker type for the `depth` field
236236- pub struct depth(());
237237 }
238238}
239239···326326impl<'a, S> ThreadItemBuilder<'a, S>
327327where
328328 S: thread_item_state::State,
329329- S::Uri: thread_item_state::IsSet,
330330- S::Value: thread_item_state::IsSet,
331329 S::Depth: thread_item_state::IsSet,
330330+ S::Value: thread_item_state::IsSet,
331331+ S::Uri: thread_item_state::IsSet,
332332{
333333 /// Build the final struct
334334 pub fn build(self) -> ThreadItem<'a> {
···265265 }
266266 /// State trait tracking which required fields have been set
267267 pub trait State: sealed::Sealed {
268268- type Uri;
269268 type Depth;
269269+ type Uri;
270270 type Value;
271271 }
272272 /// Empty state - all required fields are unset
273273 pub struct Empty(());
274274 impl sealed::Sealed for Empty {}
275275 impl State for Empty {
276276- type Uri = Unset;
277276 type Depth = Unset;
277277+ type Uri = Unset;
278278 type Value = Unset;
279279 }
280280- ///State transition - sets the `uri` field to Set
281281- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
282282- impl<S: State> sealed::Sealed for SetUri<S> {}
283283- impl<S: State> State for SetUri<S> {
284284- type Uri = Set<members::uri>;
285285- type Depth = S::Depth;
286286- type Value = S::Value;
287287- }
288280 ///State transition - sets the `depth` field to Set
289281 pub struct SetDepth<S: State = Empty>(PhantomData<fn() -> S>);
290282 impl<S: State> sealed::Sealed for SetDepth<S> {}
291283 impl<S: State> State for SetDepth<S> {
292292- type Uri = S::Uri;
293284 type Depth = Set<members::depth>;
285285+ type Uri = S::Uri;
286286+ type Value = S::Value;
287287+ }
288288+ ///State transition - sets the `uri` field to Set
289289+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
290290+ impl<S: State> sealed::Sealed for SetUri<S> {}
291291+ impl<S: State> State for SetUri<S> {
292292+ type Depth = S::Depth;
293293+ type Uri = Set<members::uri>;
294294 type Value = S::Value;
295295 }
296296 ///State transition - sets the `value` field to Set
297297 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
298298 impl<S: State> sealed::Sealed for SetValue<S> {}
299299 impl<S: State> State for SetValue<S> {
300300- type Uri = S::Uri;
301300 type Depth = S::Depth;
301301+ type Uri = S::Uri;
302302 type Value = Set<members::value>;
303303 }
304304 /// Marker types for field names
305305 #[allow(non_camel_case_types)]
306306 pub mod members {
307307+ ///Marker type for the `depth` field
308308+ pub struct depth(());
307309 ///Marker type for the `uri` field
308310 pub struct uri(());
309309- ///Marker type for the `depth` field
310310- pub struct depth(());
311311 ///Marker type for the `value` field
312312 pub struct value(());
313313 }
···402402impl<'a, S> ThreadItemBuilder<'a, S>
403403where
404404 S: thread_item_state::State,
405405- S::Uri: thread_item_state::IsSet,
406405 S::Depth: thread_item_state::IsSet,
406406+ S::Uri: thread_item_state::IsSet,
407407 S::Value: thread_item_state::IsSet,
408408{
409409 /// Build the final struct
···9090 }
9191 /// State trait tracking which required fields have been set
9292 pub trait State: sealed::Sealed {
9393- type Tag;
9493 type SubjectType;
9494+ type Tag;
9595 type Subject;
9696 }
9797 /// Empty state - all required fields are unset
9898 pub struct Empty(());
9999 impl sealed::Sealed for Empty {}
100100 impl State for Empty {
101101- type Tag = Unset;
102101 type SubjectType = Unset;
102102+ type Tag = Unset;
103103 type Subject = Unset;
104104 }
105105- ///State transition - sets the `tag` field to Set
106106- pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
107107- impl<S: State> sealed::Sealed for SetTag<S> {}
108108- impl<S: State> State for SetTag<S> {
109109- type Tag = Set<members::tag>;
110110- type SubjectType = S::SubjectType;
111111- type Subject = S::Subject;
112112- }
113105 ///State transition - sets the `subject_type` field to Set
114106 pub struct SetSubjectType<S: State = Empty>(PhantomData<fn() -> S>);
115107 impl<S: State> sealed::Sealed for SetSubjectType<S> {}
116108 impl<S: State> State for SetSubjectType<S> {
117117- type Tag = S::Tag;
118109 type SubjectType = Set<members::subject_type>;
110110+ type Tag = S::Tag;
111111+ type Subject = S::Subject;
112112+ }
113113+ ///State transition - sets the `tag` field to Set
114114+ pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
115115+ impl<S: State> sealed::Sealed for SetTag<S> {}
116116+ impl<S: State> State for SetTag<S> {
117117+ type SubjectType = S::SubjectType;
118118+ type Tag = Set<members::tag>;
119119 type Subject = S::Subject;
120120 }
121121 ///State transition - sets the `subject` field to Set
122122 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
123123 impl<S: State> sealed::Sealed for SetSubject<S> {}
124124 impl<S: State> State for SetSubject<S> {
125125- type Tag = S::Tag;
126125 type SubjectType = S::SubjectType;
126126+ type Tag = S::Tag;
127127 type Subject = Set<members::subject>;
128128 }
129129 /// Marker types for field names
130130 #[allow(non_camel_case_types)]
131131 pub mod members {
132132+ ///Marker type for the `subject_type` field
133133+ pub struct subject_type(());
132134 ///Marker type for the `tag` field
133135 pub struct tag(());
134134- ///Marker type for the `subject_type` field
135135- pub struct subject_type(());
136136 ///Marker type for the `subject` field
137137 pub struct subject(());
138138 }
···227227impl<'a, S> SuggestionBuilder<'a, S>
228228where
229229 S: suggestion_state::State,
230230- S::Tag: suggestion_state::IsSet,
231230 S::SubjectType: suggestion_state::IsSet,
231231+ S::Tag: suggestion_state::IsSet,
232232 S::Subject: suggestion_state::IsSet,
233233{
234234 /// Build the final struct
+15-15
crates/weaver-api/src/app_bsky/video.rs
···5252 }
5353 /// State trait tracking which required fields have been set
5454 pub trait State: sealed::Sealed {
5555- type State;
5655 type Did;
5656+ type State;
5757 type JobId;
5858 }
5959 /// Empty state - all required fields are unset
6060 pub struct Empty(());
6161 impl sealed::Sealed for Empty {}
6262 impl State for Empty {
6363- type State = Unset;
6463 type Did = Unset;
6464+ type State = Unset;
6565 type JobId = Unset;
6666 }
6767- ///State transition - sets the `state` field to Set
6868- pub struct SetState<S: State = Empty>(PhantomData<fn() -> S>);
6969- impl<S: State> sealed::Sealed for SetState<S> {}
7070- impl<S: State> State for SetState<S> {
7171- type State = Set<members::state>;
7272- type Did = S::Did;
7373- type JobId = S::JobId;
7474- }
7567 ///State transition - sets the `did` field to Set
7668 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
7769 impl<S: State> sealed::Sealed for SetDid<S> {}
7870 impl<S: State> State for SetDid<S> {
7979- type State = S::State;
8071 type Did = Set<members::did>;
7272+ type State = S::State;
7373+ type JobId = S::JobId;
7474+ }
7575+ ///State transition - sets the `state` field to Set
7676+ pub struct SetState<S: State = Empty>(PhantomData<fn() -> S>);
7777+ impl<S: State> sealed::Sealed for SetState<S> {}
7878+ impl<S: State> State for SetState<S> {
7979+ type Did = S::Did;
8080+ type State = Set<members::state>;
8181 type JobId = S::JobId;
8282 }
8383 ///State transition - sets the `job_id` field to Set
8484 pub struct SetJobId<S: State = Empty>(PhantomData<fn() -> S>);
8585 impl<S: State> sealed::Sealed for SetJobId<S> {}
8686 impl<S: State> State for SetJobId<S> {
8787- type State = S::State;
8887 type Did = S::Did;
8888+ type State = S::State;
8989 type JobId = Set<members::job_id>;
9090 }
9191 /// Marker types for field names
9292 #[allow(non_camel_case_types)]
9393 pub mod members {
9494+ ///Marker type for the `did` field
9595+ pub struct did(());
9496 ///Marker type for the `state` field
9597 pub struct state(());
9696- ///Marker type for the `did` field
9797- pub struct did(());
9898 ///Marker type for the `job_id` field
9999 pub struct job_id(());
100100 }
···257257impl<'a, S> JobStatusBuilder<'a, S>
258258where
259259 S: job_status_state::State,
260260- S::State: job_status_state::IsSet,
261260 S::Did: job_status_state::IsSet,
261261+ S::State: job_status_state::IsSet,
262262 S::JobId: job_status_state::IsSet,
263263{
264264 /// Build the final struct
+13-13
crates/weaver-api/src/blog_pckt/block/mention.rs
···3535 }
3636 /// State trait tracking which required fields have been set
3737 pub trait State: sealed::Sealed {
3838- type Handle;
3938 type Did;
3939+ type Handle;
4040 }
4141 /// Empty state - all required fields are unset
4242 pub struct Empty(());
4343 impl sealed::Sealed for Empty {}
4444 impl State for Empty {
4545- type Handle = Unset;
4645 type Did = Unset;
4747- }
4848- ///State transition - sets the `handle` field to Set
4949- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
5050- impl<S: State> sealed::Sealed for SetHandle<S> {}
5151- impl<S: State> State for SetHandle<S> {
5252- type Handle = Set<members::handle>;
5353- type Did = S::Did;
4646+ type Handle = Unset;
5447 }
5548 ///State transition - sets the `did` field to Set
5649 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
5750 impl<S: State> sealed::Sealed for SetDid<S> {}
5851 impl<S: State> State for SetDid<S> {
5959- type Handle = S::Handle;
6052 type Did = Set<members::did>;
5353+ type Handle = S::Handle;
5454+ }
5555+ ///State transition - sets the `handle` field to Set
5656+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
5757+ impl<S: State> sealed::Sealed for SetHandle<S> {}
5858+ impl<S: State> State for SetHandle<S> {
5959+ type Did = S::Did;
6060+ type Handle = Set<members::handle>;
6161 }
6262 /// Marker types for field names
6363 #[allow(non_camel_case_types)]
6464 pub mod members {
6565- ///Marker type for the `handle` field
6666- pub struct handle(());
6765 ///Marker type for the `did` field
6866 pub struct did(());
6767+ ///Marker type for the `handle` field
6868+ pub struct handle(());
6969 }
7070}
7171···138138impl<'a, S> MentionBuilder<'a, S>
139139where
140140 S: mention_state::State,
141141- S::Handle: mention_state::IsSet,
142141 S::Did: mention_state::IsSet,
142142+ S::Handle: mention_state::IsSet,
143143{
144144 /// Build the final struct
145145 pub fn build(self) -> Mention<'a> {
···3434 }
3535 /// State trait tracking which required fields have been set
3636 pub trait State: sealed::Sealed {
3737- type Checked;
3837 type Content;
3838+ type Checked;
3939 }
4040 /// Empty state - all required fields are unset
4141 pub struct Empty(());
4242 impl sealed::Sealed for Empty {}
4343 impl State for Empty {
4444- type Checked = Unset;
4544 type Content = Unset;
4646- }
4747- ///State transition - sets the `checked` field to Set
4848- pub struct SetChecked<S: State = Empty>(PhantomData<fn() -> S>);
4949- impl<S: State> sealed::Sealed for SetChecked<S> {}
5050- impl<S: State> State for SetChecked<S> {
5151- type Checked = Set<members::checked>;
5252- type Content = S::Content;
4545+ type Checked = Unset;
5346 }
5447 ///State transition - sets the `content` field to Set
5548 pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
5649 impl<S: State> sealed::Sealed for SetContent<S> {}
5750 impl<S: State> State for SetContent<S> {
5858- type Checked = S::Checked;
5951 type Content = Set<members::content>;
5252+ type Checked = S::Checked;
5353+ }
5454+ ///State transition - sets the `checked` field to Set
5555+ pub struct SetChecked<S: State = Empty>(PhantomData<fn() -> S>);
5656+ impl<S: State> sealed::Sealed for SetChecked<S> {}
5757+ impl<S: State> State for SetChecked<S> {
5858+ type Content = S::Content;
5959+ type Checked = Set<members::checked>;
6060 }
6161 /// Marker types for field names
6262 #[allow(non_camel_case_types)]
6363 pub mod members {
6464- ///Marker type for the `checked` field
6565- pub struct checked(());
6664 ///Marker type for the `content` field
6765 pub struct content(());
6666+ ///Marker type for the `checked` field
6767+ pub struct checked(());
6868 }
6969}
7070···137137impl<'a, S> TaskItemBuilder<'a, S>
138138where
139139 S: task_item_state::State,
140140- S::Checked: task_item_state::IsSet,
141140 S::Content: task_item_state::IsSet,
141141+ S::Checked: task_item_state::IsSet,
142142{
143143 /// Build the final struct
144144 pub fn build(self) -> TaskItem<'a> {
+26-26
crates/weaver-api/src/blog_pckt/post.rs
···5353 }
5454 /// State trait tracking which required fields have been set
5555 pub trait State: sealed::Sealed {
5656- type Title;
5656+ type Blog;
5757 type Blocks;
5858 type Url;
5959- type Blog;
5959+ type Title;
6060 }
6161 /// Empty state - all required fields are unset
6262 pub struct Empty(());
6363 impl sealed::Sealed for Empty {}
6464 impl State for Empty {
6565- type Title = Unset;
6565+ type Blog = Unset;
6666 type Blocks = Unset;
6767 type Url = Unset;
6868- type Blog = Unset;
6868+ type Title = Unset;
6969 }
7070- ///State transition - sets the `title` field to Set
7171- pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
7272- impl<S: State> sealed::Sealed for SetTitle<S> {}
7373- impl<S: State> State for SetTitle<S> {
7474- type Title = Set<members::title>;
7070+ ///State transition - sets the `blog` field to Set
7171+ pub struct SetBlog<S: State = Empty>(PhantomData<fn() -> S>);
7272+ impl<S: State> sealed::Sealed for SetBlog<S> {}
7373+ impl<S: State> State for SetBlog<S> {
7474+ type Blog = Set<members::blog>;
7575 type Blocks = S::Blocks;
7676 type Url = S::Url;
7777- type Blog = S::Blog;
7777+ type Title = S::Title;
7878 }
7979 ///State transition - sets the `blocks` field to Set
8080 pub struct SetBlocks<S: State = Empty>(PhantomData<fn() -> S>);
8181 impl<S: State> sealed::Sealed for SetBlocks<S> {}
8282 impl<S: State> State for SetBlocks<S> {
8383- type Title = S::Title;
8383+ type Blog = S::Blog;
8484 type Blocks = Set<members::blocks>;
8585 type Url = S::Url;
8686- type Blog = S::Blog;
8686+ type Title = S::Title;
8787 }
8888 ///State transition - sets the `url` field to Set
8989 pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
9090 impl<S: State> sealed::Sealed for SetUrl<S> {}
9191 impl<S: State> State for SetUrl<S> {
9292- type Title = S::Title;
9292+ type Blog = S::Blog;
9393 type Blocks = S::Blocks;
9494 type Url = Set<members::url>;
9595- type Blog = S::Blog;
9696- }
9797- ///State transition - sets the `blog` field to Set
9898- pub struct SetBlog<S: State = Empty>(PhantomData<fn() -> S>);
9999- impl<S: State> sealed::Sealed for SetBlog<S> {}
100100- impl<S: State> State for SetBlog<S> {
10195 type Title = S::Title;
9696+ }
9797+ ///State transition - sets the `title` field to Set
9898+ pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
9999+ impl<S: State> sealed::Sealed for SetTitle<S> {}
100100+ impl<S: State> State for SetTitle<S> {
101101+ type Blog = S::Blog;
102102 type Blocks = S::Blocks;
103103 type Url = S::Url;
104104- type Blog = Set<members::blog>;
104104+ type Title = Set<members::title>;
105105 }
106106 /// Marker types for field names
107107 #[allow(non_camel_case_types)]
108108 pub mod members {
109109- ///Marker type for the `title` field
110110- pub struct title(());
109109+ ///Marker type for the `blog` field
110110+ pub struct blog(());
111111 ///Marker type for the `blocks` field
112112 pub struct blocks(());
113113 ///Marker type for the `url` field
114114 pub struct url(());
115115- ///Marker type for the `blog` field
116116- pub struct blog(());
115115+ ///Marker type for the `title` field
116116+ pub struct title(());
117117 }
118118}
119119···357357impl<'a, S> PostBuilder<'a, S>
358358where
359359 S: post_state::State,
360360- S::Title: post_state::IsSet,
360360+ S::Blog: post_state::IsSet,
361361 S::Blocks: post_state::IsSet,
362362 S::Url: post_state::IsSet,
363363- S::Blog: post_state::IsSet,
363363+ S::Title: post_state::IsSet,
364364{
365365 /// Build the final struct
366366 pub fn build(self) -> Post<'a> {
+26-26
crates/weaver-api/src/blog_pckt/richtext/facet.rs
···552552 }
553553 /// State trait tracking which required fields have been set
554554 pub trait State: sealed::Sealed {
555555- type ByteStart;
556555 type ByteEnd;
556556+ type ByteStart;
557557 }
558558 /// Empty state - all required fields are unset
559559 pub struct Empty(());
560560 impl sealed::Sealed for Empty {}
561561 impl State for Empty {
562562- type ByteStart = Unset;
563562 type ByteEnd = Unset;
564564- }
565565- ///State transition - sets the `byte_start` field to Set
566566- pub struct SetByteStart<S: State = Empty>(PhantomData<fn() -> S>);
567567- impl<S: State> sealed::Sealed for SetByteStart<S> {}
568568- impl<S: State> State for SetByteStart<S> {
569569- type ByteStart = Set<members::byte_start>;
570570- type ByteEnd = S::ByteEnd;
563563+ type ByteStart = Unset;
571564 }
572565 ///State transition - sets the `byte_end` field to Set
573566 pub struct SetByteEnd<S: State = Empty>(PhantomData<fn() -> S>);
574567 impl<S: State> sealed::Sealed for SetByteEnd<S> {}
575568 impl<S: State> State for SetByteEnd<S> {
576576- type ByteStart = S::ByteStart;
577569 type ByteEnd = Set<members::byte_end>;
570570+ type ByteStart = S::ByteStart;
571571+ }
572572+ ///State transition - sets the `byte_start` field to Set
573573+ pub struct SetByteStart<S: State = Empty>(PhantomData<fn() -> S>);
574574+ impl<S: State> sealed::Sealed for SetByteStart<S> {}
575575+ impl<S: State> State for SetByteStart<S> {
576576+ type ByteEnd = S::ByteEnd;
577577+ type ByteStart = Set<members::byte_start>;
578578 }
579579 /// Marker types for field names
580580 #[allow(non_camel_case_types)]
581581 pub mod members {
582582- ///Marker type for the `byte_start` field
583583- pub struct byte_start(());
584582 ///Marker type for the `byte_end` field
585583 pub struct byte_end(());
584584+ ///Marker type for the `byte_start` field
585585+ pub struct byte_start(());
586586 }
587587}
588588···652652impl<'a, S> ByteSliceBuilder<'a, S>
653653where
654654 S: byte_slice_state::State,
655655- S::ByteStart: byte_slice_state::IsSet,
656655 S::ByteEnd: byte_slice_state::IsSet,
656656+ S::ByteStart: byte_slice_state::IsSet,
657657{
658658 /// Build the final struct
659659 pub fn build(self) -> ByteSlice<'a> {
···10511051 }
10521052 /// State trait tracking which required fields have been set
10531053 pub trait State: sealed::Sealed {
10541054- type Index;
10551054 type Features;
10551055+ type Index;
10561056 }
10571057 /// Empty state - all required fields are unset
10581058 pub struct Empty(());
10591059 impl sealed::Sealed for Empty {}
10601060 impl State for Empty {
10611061- type Index = Unset;
10621061 type Features = Unset;
10631063- }
10641064- ///State transition - sets the `index` field to Set
10651065- pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
10661066- impl<S: State> sealed::Sealed for SetIndex<S> {}
10671067- impl<S: State> State for SetIndex<S> {
10681068- type Index = Set<members::index>;
10691069- type Features = S::Features;
10621062+ type Index = Unset;
10701063 }
10711064 ///State transition - sets the `features` field to Set
10721065 pub struct SetFeatures<S: State = Empty>(PhantomData<fn() -> S>);
10731066 impl<S: State> sealed::Sealed for SetFeatures<S> {}
10741067 impl<S: State> State for SetFeatures<S> {
10751075- type Index = S::Index;
10761068 type Features = Set<members::features>;
10691069+ type Index = S::Index;
10701070+ }
10711071+ ///State transition - sets the `index` field to Set
10721072+ pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
10731073+ impl<S: State> sealed::Sealed for SetIndex<S> {}
10741074+ impl<S: State> State for SetIndex<S> {
10751075+ type Features = S::Features;
10761076+ type Index = Set<members::index>;
10771077 }
10781078 /// Marker types for field names
10791079 #[allow(non_camel_case_types)]
10801080 pub mod members {
10811081- ///Marker type for the `index` field
10821082- pub struct index(());
10831081 ///Marker type for the `features` field
10841082 pub struct features(());
10831083+ ///Marker type for the `index` field
10841084+ pub struct index(());
10851085 }
10861086}
10871087···11541154impl<'a, S> FacetBuilder<'a, S>
11551155where
11561156 S: facet_state::State,
11571157- S::Index: facet_state::IsSet,
11581157 S::Features: facet_state::IsSet,
11581158+ S::Index: facet_state::IsSet,
11591159{
11601160 /// Build the final struct
11611161 pub fn build(self) -> Facet<'a> {
+226-226
crates/weaver-api/src/chat_bsky/convo.rs
···6666 }
6767 /// State trait tracking which required fields have been set
6868 pub trait State: sealed::Sealed {
6969+ type Id;
6970 type Muted;
7071 type UnreadCount;
7171- type Id;
7272- type Members;
7372 type Rev;
7373+ type Members;
7474 }
7575 /// Empty state - all required fields are unset
7676 pub struct Empty(());
7777 impl sealed::Sealed for Empty {}
7878 impl State for Empty {
7979+ type Id = Unset;
7980 type Muted = Unset;
8081 type UnreadCount = Unset;
8181- type Id = Unset;
8282- type Members = Unset;
8382 type Rev = Unset;
8383+ type Members = Unset;
8484+ }
8585+ ///State transition - sets the `id` field to Set
8686+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
8787+ impl<S: State> sealed::Sealed for SetId<S> {}
8888+ impl<S: State> State for SetId<S> {
8989+ type Id = Set<members::id>;
9090+ type Muted = S::Muted;
9191+ type UnreadCount = S::UnreadCount;
9292+ type Rev = S::Rev;
9393+ type Members = S::Members;
8494 }
8595 ///State transition - sets the `muted` field to Set
8696 pub struct SetMuted<S: State = Empty>(PhantomData<fn() -> S>);
8797 impl<S: State> sealed::Sealed for SetMuted<S> {}
8898 impl<S: State> State for SetMuted<S> {
9999+ type Id = S::Id;
89100 type Muted = Set<members::muted>;
90101 type UnreadCount = S::UnreadCount;
9191- type Id = S::Id;
102102+ type Rev = S::Rev;
92103 type Members = S::Members;
9393- type Rev = S::Rev;
94104 }
95105 ///State transition - sets the `unread_count` field to Set
96106 pub struct SetUnreadCount<S: State = Empty>(PhantomData<fn() -> S>);
97107 impl<S: State> sealed::Sealed for SetUnreadCount<S> {}
98108 impl<S: State> State for SetUnreadCount<S> {
109109+ type Id = S::Id;
99110 type Muted = S::Muted;
100111 type UnreadCount = Set<members::unread_count>;
101101- type Id = S::Id;
102102- type Members = S::Members;
103112 type Rev = S::Rev;
113113+ type Members = S::Members;
104114 }
105105- ///State transition - sets the `id` field to Set
106106- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
107107- impl<S: State> sealed::Sealed for SetId<S> {}
108108- impl<S: State> State for SetId<S> {
115115+ ///State transition - sets the `rev` field to Set
116116+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
117117+ impl<S: State> sealed::Sealed for SetRev<S> {}
118118+ impl<S: State> State for SetRev<S> {
119119+ type Id = S::Id;
109120 type Muted = S::Muted;
110121 type UnreadCount = S::UnreadCount;
111111- type Id = Set<members::id>;
122122+ type Rev = Set<members::rev>;
112123 type Members = S::Members;
113113- type Rev = S::Rev;
114124 }
115125 ///State transition - sets the `members` field to Set
116126 pub struct SetMembers<S: State = Empty>(PhantomData<fn() -> S>);
117127 impl<S: State> sealed::Sealed for SetMembers<S> {}
118128 impl<S: State> State for SetMembers<S> {
119119- type Muted = S::Muted;
120120- type UnreadCount = S::UnreadCount;
121129 type Id = S::Id;
122122- type Members = Set<members::members>;
123123- type Rev = S::Rev;
124124- }
125125- ///State transition - sets the `rev` field to Set
126126- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
127127- impl<S: State> sealed::Sealed for SetRev<S> {}
128128- impl<S: State> State for SetRev<S> {
129130 type Muted = S::Muted;
130131 type UnreadCount = S::UnreadCount;
131131- type Id = S::Id;
132132- type Members = S::Members;
133133- type Rev = Set<members::rev>;
132132+ type Rev = S::Rev;
133133+ type Members = Set<members::members>;
134134 }
135135 /// Marker types for field names
136136 #[allow(non_camel_case_types)]
137137 pub mod members {
138138+ ///Marker type for the `id` field
139139+ pub struct id(());
138140 ///Marker type for the `muted` field
139141 pub struct muted(());
140142 ///Marker type for the `unread_count` field
141143 pub struct unread_count(());
142142- ///Marker type for the `id` field
143143- pub struct id(());
144144+ ///Marker type for the `rev` field
145145+ pub struct rev(());
144146 ///Marker type for the `members` field
145147 pub struct members(());
146146- ///Marker type for the `rev` field
147147- pub struct rev(());
148148 }
149149}
150150···331331impl<'a, S> ConvoViewBuilder<'a, S>
332332where
333333 S: convo_view_state::State,
334334+ S::Id: convo_view_state::IsSet,
334335 S::Muted: convo_view_state::IsSet,
335336 S::UnreadCount: convo_view_state::IsSet,
336336- S::Id: convo_view_state::IsSet,
337337- S::Members: convo_view_state::IsSet,
338337 S::Rev: convo_view_state::IsSet,
338338+ S::Members: convo_view_state::IsSet,
339339{
340340 /// Build the final struct
341341 pub fn build(self) -> ConvoView<'a> {
···17331733 }
17341734 /// State trait tracking which required fields have been set
17351735 pub trait State: sealed::Sealed {
17361736+ type Rev;
17361737 type Sender;
17371737- type SentAt;
17381738 type Id;
17391739- type Rev;
17391739+ type SentAt;
17401740 }
17411741 /// Empty state - all required fields are unset
17421742 pub struct Empty(());
17431743 impl sealed::Sealed for Empty {}
17441744 impl State for Empty {
17451745+ type Rev = Unset;
17451746 type Sender = Unset;
17471747+ type Id = Unset;
17461748 type SentAt = Unset;
17471747- type Id = Unset;
17481748- type Rev = Unset;
17491749+ }
17501750+ ///State transition - sets the `rev` field to Set
17511751+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
17521752+ impl<S: State> sealed::Sealed for SetRev<S> {}
17531753+ impl<S: State> State for SetRev<S> {
17541754+ type Rev = Set<members::rev>;
17551755+ type Sender = S::Sender;
17561756+ type Id = S::Id;
17571757+ type SentAt = S::SentAt;
17491758 }
17501759 ///State transition - sets the `sender` field to Set
17511760 pub struct SetSender<S: State = Empty>(PhantomData<fn() -> S>);
17521761 impl<S: State> sealed::Sealed for SetSender<S> {}
17531762 impl<S: State> State for SetSender<S> {
17631763+ type Rev = S::Rev;
17541764 type Sender = Set<members::sender>;
17551755- type SentAt = S::SentAt;
17561765 type Id = S::Id;
17571757- type Rev = S::Rev;
17581758- }
17591759- ///State transition - sets the `sent_at` field to Set
17601760- pub struct SetSentAt<S: State = Empty>(PhantomData<fn() -> S>);
17611761- impl<S: State> sealed::Sealed for SetSentAt<S> {}
17621762- impl<S: State> State for SetSentAt<S> {
17631763- type Sender = S::Sender;
17641764- type SentAt = Set<members::sent_at>;
17651765- type Id = S::Id;
17661766- type Rev = S::Rev;
17661766+ type SentAt = S::SentAt;
17671767 }
17681768 ///State transition - sets the `id` field to Set
17691769 pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
17701770 impl<S: State> sealed::Sealed for SetId<S> {}
17711771 impl<S: State> State for SetId<S> {
17721772+ type Rev = S::Rev;
17721773 type Sender = S::Sender;
17731773- type SentAt = S::SentAt;
17741774 type Id = Set<members::id>;
17751775- type Rev = S::Rev;
17751775+ type SentAt = S::SentAt;
17761776 }
17771777- ///State transition - sets the `rev` field to Set
17781778- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
17791779- impl<S: State> sealed::Sealed for SetRev<S> {}
17801780- impl<S: State> State for SetRev<S> {
17771777+ ///State transition - sets the `sent_at` field to Set
17781778+ pub struct SetSentAt<S: State = Empty>(PhantomData<fn() -> S>);
17791779+ impl<S: State> sealed::Sealed for SetSentAt<S> {}
17801780+ impl<S: State> State for SetSentAt<S> {
17811781+ type Rev = S::Rev;
17811782 type Sender = S::Sender;
17821782- type SentAt = S::SentAt;
17831783 type Id = S::Id;
17841784- type Rev = Set<members::rev>;
17841784+ type SentAt = Set<members::sent_at>;
17851785 }
17861786 /// Marker types for field names
17871787 #[allow(non_camel_case_types)]
17881788 pub mod members {
17891789+ ///Marker type for the `rev` field
17901790+ pub struct rev(());
17891791 ///Marker type for the `sender` field
17901792 pub struct sender(());
17911791- ///Marker type for the `sent_at` field
17921792- pub struct sent_at(());
17931793 ///Marker type for the `id` field
17941794 pub struct id(());
17951795- ///Marker type for the `rev` field
17961796- pub struct rev(());
17951795+ ///Marker type for the `sent_at` field
17961796+ pub struct sent_at(());
17971797 }
17981798}
17991799···19061906impl<'a, S> DeletedMessageViewBuilder<'a, S>
19071907where
19081908 S: deleted_message_view_state::State,
19091909+ S::Rev: deleted_message_view_state::IsSet,
19091910 S::Sender: deleted_message_view_state::IsSet,
19101910- S::SentAt: deleted_message_view_state::IsSet,
19111911 S::Id: deleted_message_view_state::IsSet,
19121912- S::Rev: deleted_message_view_state::IsSet,
19121912+ S::SentAt: deleted_message_view_state::IsSet,
19131913{
19141914 /// Build the final struct
19151915 pub fn build(self) -> DeletedMessageView<'a> {
···20252025 /// State trait tracking which required fields have been set
20262026 pub trait State: sealed::Sealed {
20272027 type Rev;
20282028- type Message;
20282028+ type ConvoId;
20292029 type Reaction;
20302030- type ConvoId;
20302030+ type Message;
20312031 }
20322032 /// Empty state - all required fields are unset
20332033 pub struct Empty(());
20342034 impl sealed::Sealed for Empty {}
20352035 impl State for Empty {
20362036 type Rev = Unset;
20372037- type Message = Unset;
20382038- type Reaction = Unset;
20392037 type ConvoId = Unset;
20382038+ type Reaction = Unset;
20392039+ type Message = Unset;
20402040 }
20412041 ///State transition - sets the `rev` field to Set
20422042 pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
20432043 impl<S: State> sealed::Sealed for SetRev<S> {}
20442044 impl<S: State> State for SetRev<S> {
20452045 type Rev = Set<members::rev>;
20462046+ type ConvoId = S::ConvoId;
20472047+ type Reaction = S::Reaction;
20462048 type Message = S::Message;
20472047- type Reaction = S::Reaction;
20482048- type ConvoId = S::ConvoId;
20492049 }
20502050- ///State transition - sets the `message` field to Set
20512051- pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
20522052- impl<S: State> sealed::Sealed for SetMessage<S> {}
20532053- impl<S: State> State for SetMessage<S> {
20502050+ ///State transition - sets the `convo_id` field to Set
20512051+ pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
20522052+ impl<S: State> sealed::Sealed for SetConvoId<S> {}
20532053+ impl<S: State> State for SetConvoId<S> {
20542054 type Rev = S::Rev;
20552055- type Message = Set<members::message>;
20552055+ type ConvoId = Set<members::convo_id>;
20562056 type Reaction = S::Reaction;
20572057- type ConvoId = S::ConvoId;
20572057+ type Message = S::Message;
20582058 }
20592059 ///State transition - sets the `reaction` field to Set
20602060 pub struct SetReaction<S: State = Empty>(PhantomData<fn() -> S>);
20612061 impl<S: State> sealed::Sealed for SetReaction<S> {}
20622062 impl<S: State> State for SetReaction<S> {
20632063 type Rev = S::Rev;
20642064+ type ConvoId = S::ConvoId;
20652065+ type Reaction = Set<members::reaction>;
20642066 type Message = S::Message;
20652065- type Reaction = Set<members::reaction>;
20662066- type ConvoId = S::ConvoId;
20672067 }
20682068- ///State transition - sets the `convo_id` field to Set
20692069- pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
20702070- impl<S: State> sealed::Sealed for SetConvoId<S> {}
20712071- impl<S: State> State for SetConvoId<S> {
20682068+ ///State transition - sets the `message` field to Set
20692069+ pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
20702070+ impl<S: State> sealed::Sealed for SetMessage<S> {}
20712071+ impl<S: State> State for SetMessage<S> {
20722072 type Rev = S::Rev;
20732073- type Message = S::Message;
20732073+ type ConvoId = S::ConvoId;
20742074 type Reaction = S::Reaction;
20752075- type ConvoId = Set<members::convo_id>;
20752075+ type Message = Set<members::message>;
20762076 }
20772077 /// Marker types for field names
20782078 #[allow(non_camel_case_types)]
20792079 pub mod members {
20802080 ///Marker type for the `rev` field
20812081 pub struct rev(());
20822082+ ///Marker type for the `convo_id` field
20832083+ pub struct convo_id(());
20842084+ ///Marker type for the `reaction` field
20852085+ pub struct reaction(());
20822086 ///Marker type for the `message` field
20832087 pub struct message(());
20842084- ///Marker type for the `reaction` field
20852085- pub struct reaction(());
20862086- ///Marker type for the `convo_id` field
20872087- pub struct convo_id(());
20882088 }
20892089}
20902090···21982198where
21992199 S: log_add_reaction_state::State,
22002200 S::Rev: log_add_reaction_state::IsSet,
22012201- S::Message: log_add_reaction_state::IsSet,
22022202- S::Reaction: log_add_reaction_state::IsSet,
22032201 S::ConvoId: log_add_reaction_state::IsSet,
22022202+ S::Reaction: log_add_reaction_state::IsSet,
22032203+ S::Message: log_add_reaction_state::IsSet,
22042204{
22052205 /// Build the final struct
22062206 pub fn build(self) -> LogAddReaction<'a> {
···23322332 }
23332333 /// State trait tracking which required fields have been set
23342334 pub trait State: sealed::Sealed {
23352335+ type Rev;
23352336 type ConvoId;
23362337 type Message;
23372337- type Rev;
23382338 }
23392339 /// Empty state - all required fields are unset
23402340 pub struct Empty(());
23412341 impl sealed::Sealed for Empty {}
23422342 impl State for Empty {
23432343+ type Rev = Unset;
23432344 type ConvoId = Unset;
23442345 type Message = Unset;
23452345- type Rev = Unset;
23462346+ }
23472347+ ///State transition - sets the `rev` field to Set
23482348+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
23492349+ impl<S: State> sealed::Sealed for SetRev<S> {}
23502350+ impl<S: State> State for SetRev<S> {
23512351+ type Rev = Set<members::rev>;
23522352+ type ConvoId = S::ConvoId;
23532353+ type Message = S::Message;
23462354 }
23472355 ///State transition - sets the `convo_id` field to Set
23482356 pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
23492357 impl<S: State> sealed::Sealed for SetConvoId<S> {}
23502358 impl<S: State> State for SetConvoId<S> {
23592359+ type Rev = S::Rev;
23512360 type ConvoId = Set<members::convo_id>;
23522361 type Message = S::Message;
23532353- type Rev = S::Rev;
23542362 }
23552363 ///State transition - sets the `message` field to Set
23562364 pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
23572365 impl<S: State> sealed::Sealed for SetMessage<S> {}
23582366 impl<S: State> State for SetMessage<S> {
23592359- type ConvoId = S::ConvoId;
23602360- type Message = Set<members::message>;
23612367 type Rev = S::Rev;
23622362- }
23632363- ///State transition - sets the `rev` field to Set
23642364- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
23652365- impl<S: State> sealed::Sealed for SetRev<S> {}
23662366- impl<S: State> State for SetRev<S> {
23672368 type ConvoId = S::ConvoId;
23682368- type Message = S::Message;
23692369- type Rev = Set<members::rev>;
23692369+ type Message = Set<members::message>;
23702370 }
23712371 /// Marker types for field names
23722372 #[allow(non_camel_case_types)]
23732373 pub mod members {
23742374+ ///Marker type for the `rev` field
23752375+ pub struct rev(());
23742376 ///Marker type for the `convo_id` field
23752377 pub struct convo_id(());
23762378 ///Marker type for the `message` field
23772379 pub struct message(());
23782378- ///Marker type for the `rev` field
23792379- pub struct rev(());
23802380 }
23812381}
23822382···24692469impl<'a, S> LogCreateMessageBuilder<'a, S>
24702470where
24712471 S: log_create_message_state::State,
24722472+ S::Rev: log_create_message_state::IsSet,
24722473 S::ConvoId: log_create_message_state::IsSet,
24732474 S::Message: log_create_message_state::IsSet,
24742474- S::Rev: log_create_message_state::IsSet,
24752475{
24762476 /// Build the final struct
24772477 pub fn build(self) -> LogCreateMessage<'a> {
···25652565 }
25662566 /// State trait tracking which required fields have been set
25672567 pub trait State: sealed::Sealed {
25682568- type Message;
25692568 type Rev;
25702569 type ConvoId;
25702570+ type Message;
25712571 }
25722572 /// Empty state - all required fields are unset
25732573 pub struct Empty(());
25742574 impl sealed::Sealed for Empty {}
25752575 impl State for Empty {
25762576- type Message = Unset;
25772576 type Rev = Unset;
25782577 type ConvoId = Unset;
25792579- }
25802580- ///State transition - sets the `message` field to Set
25812581- pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
25822582- impl<S: State> sealed::Sealed for SetMessage<S> {}
25832583- impl<S: State> State for SetMessage<S> {
25842584- type Message = Set<members::message>;
25852585- type Rev = S::Rev;
25862586- type ConvoId = S::ConvoId;
25782578+ type Message = Unset;
25872579 }
25882580 ///State transition - sets the `rev` field to Set
25892581 pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
25902582 impl<S: State> sealed::Sealed for SetRev<S> {}
25912583 impl<S: State> State for SetRev<S> {
25922592- type Message = S::Message;
25932584 type Rev = Set<members::rev>;
25942585 type ConvoId = S::ConvoId;
25862586+ type Message = S::Message;
25952587 }
25962588 ///State transition - sets the `convo_id` field to Set
25972589 pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
25982590 impl<S: State> sealed::Sealed for SetConvoId<S> {}
25992591 impl<S: State> State for SetConvoId<S> {
26002600- type Message = S::Message;
26012592 type Rev = S::Rev;
26022593 type ConvoId = Set<members::convo_id>;
25942594+ type Message = S::Message;
25952595+ }
25962596+ ///State transition - sets the `message` field to Set
25972597+ pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
25982598+ impl<S: State> sealed::Sealed for SetMessage<S> {}
25992599+ impl<S: State> State for SetMessage<S> {
26002600+ type Rev = S::Rev;
26012601+ type ConvoId = S::ConvoId;
26022602+ type Message = Set<members::message>;
26032603 }
26042604 /// Marker types for field names
26052605 #[allow(non_camel_case_types)]
26062606 pub mod members {
26072607- ///Marker type for the `message` field
26082608- pub struct message(());
26092607 ///Marker type for the `rev` field
26102608 pub struct rev(());
26112609 ///Marker type for the `convo_id` field
26122610 pub struct convo_id(());
26112611+ ///Marker type for the `message` field
26122612+ pub struct message(());
26132613 }
26142614}
26152615···27022702impl<'a, S> LogDeleteMessageBuilder<'a, S>
27032703where
27042704 S: log_delete_message_state::State,
27052705- S::Message: log_delete_message_state::IsSet,
27062705 S::Rev: log_delete_message_state::IsSet,
27072706 S::ConvoId: log_delete_message_state::IsSet,
27072707+ S::Message: log_delete_message_state::IsSet,
27082708{
27092709 /// Build the final struct
27102710 pub fn build(self) -> LogDeleteMessage<'a> {
···28702870 }
28712871 /// State trait tracking which required fields have been set
28722872 pub trait State: sealed::Sealed {
28732873+ type ConvoId;
28732874 type Rev;
28742875 type Message;
28752875- type ConvoId;
28762876 }
28772877 /// Empty state - all required fields are unset
28782878 pub struct Empty(());
28792879 impl sealed::Sealed for Empty {}
28802880 impl State for Empty {
28812881+ type ConvoId = Unset;
28812882 type Rev = Unset;
28822883 type Message = Unset;
28832883- type ConvoId = Unset;
28842884+ }
28852885+ ///State transition - sets the `convo_id` field to Set
28862886+ pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
28872887+ impl<S: State> sealed::Sealed for SetConvoId<S> {}
28882888+ impl<S: State> State for SetConvoId<S> {
28892889+ type ConvoId = Set<members::convo_id>;
28902890+ type Rev = S::Rev;
28912891+ type Message = S::Message;
28842892 }
28852893 ///State transition - sets the `rev` field to Set
28862894 pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
28872895 impl<S: State> sealed::Sealed for SetRev<S> {}
28882896 impl<S: State> State for SetRev<S> {
28972897+ type ConvoId = S::ConvoId;
28892898 type Rev = Set<members::rev>;
28902899 type Message = S::Message;
28912891- type ConvoId = S::ConvoId;
28922900 }
28932901 ///State transition - sets the `message` field to Set
28942902 pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
28952903 impl<S: State> sealed::Sealed for SetMessage<S> {}
28962904 impl<S: State> State for SetMessage<S> {
29052905+ type ConvoId = S::ConvoId;
28972906 type Rev = S::Rev;
28982907 type Message = Set<members::message>;
28992899- type ConvoId = S::ConvoId;
29002900- }
29012901- ///State transition - sets the `convo_id` field to Set
29022902- pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
29032903- impl<S: State> sealed::Sealed for SetConvoId<S> {}
29042904- impl<S: State> State for SetConvoId<S> {
29052905- type Rev = S::Rev;
29062906- type Message = S::Message;
29072907- type ConvoId = Set<members::convo_id>;
29082908 }
29092909 /// Marker types for field names
29102910 #[allow(non_camel_case_types)]
29112911 pub mod members {
29122912+ ///Marker type for the `convo_id` field
29132913+ pub struct convo_id(());
29122914 ///Marker type for the `rev` field
29132915 pub struct rev(());
29142916 ///Marker type for the `message` field
29152917 pub struct message(());
29162916- ///Marker type for the `convo_id` field
29172917- pub struct convo_id(());
29182918 }
29192919}
29202920···30073007impl<'a, S> LogReadMessageBuilder<'a, S>
30083008where
30093009 S: log_read_message_state::State,
30103010+ S::ConvoId: log_read_message_state::IsSet,
30103011 S::Rev: log_read_message_state::IsSet,
30113012 S::Message: log_read_message_state::IsSet,
30123012- S::ConvoId: log_read_message_state::IsSet,
30133013{
30143014 /// Build the final struct
30153015 pub fn build(self) -> LogReadMessage<'a> {
···31073107 pub trait State: sealed::Sealed {
31083108 type Reaction;
31093109 type ConvoId;
31103110- type Message;
31113110 type Rev;
31113111+ type Message;
31123112 }
31133113 /// Empty state - all required fields are unset
31143114 pub struct Empty(());
···31163116 impl State for Empty {
31173117 type Reaction = Unset;
31183118 type ConvoId = Unset;
31193119+ type Rev = Unset;
31193120 type Message = Unset;
31203120- type Rev = Unset;
31213121 }
31223122 ///State transition - sets the `reaction` field to Set
31233123 pub struct SetReaction<S: State = Empty>(PhantomData<fn() -> S>);
···31253125 impl<S: State> State for SetReaction<S> {
31263126 type Reaction = Set<members::reaction>;
31273127 type ConvoId = S::ConvoId;
31283128- type Message = S::Message;
31293128 type Rev = S::Rev;
31293129+ type Message = S::Message;
31303130 }
31313131 ///State transition - sets the `convo_id` field to Set
31323132 pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
···31343134 impl<S: State> State for SetConvoId<S> {
31353135 type Reaction = S::Reaction;
31363136 type ConvoId = Set<members::convo_id>;
31373137- type Message = S::Message;
31383137 type Rev = S::Rev;
31383138+ type Message = S::Message;
31393139+ }
31403140+ ///State transition - sets the `rev` field to Set
31413141+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
31423142+ impl<S: State> sealed::Sealed for SetRev<S> {}
31433143+ impl<S: State> State for SetRev<S> {
31443144+ type Reaction = S::Reaction;
31453145+ type ConvoId = S::ConvoId;
31463146+ type Rev = Set<members::rev>;
31473147+ type Message = S::Message;
31393148 }
31403149 ///State transition - sets the `message` field to Set
31413150 pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
···31433152 impl<S: State> State for SetMessage<S> {
31443153 type Reaction = S::Reaction;
31453154 type ConvoId = S::ConvoId;
31463146- type Message = Set<members::message>;
31473155 type Rev = S::Rev;
31483148- }
31493149- ///State transition - sets the `rev` field to Set
31503150- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
31513151- impl<S: State> sealed::Sealed for SetRev<S> {}
31523152- impl<S: State> State for SetRev<S> {
31533153- type Reaction = S::Reaction;
31543154- type ConvoId = S::ConvoId;
31553155- type Message = S::Message;
31563156- type Rev = Set<members::rev>;
31563156+ type Message = Set<members::message>;
31573157 }
31583158 /// Marker types for field names
31593159 #[allow(non_camel_case_types)]
···31623162 pub struct reaction(());
31633163 ///Marker type for the `convo_id` field
31643164 pub struct convo_id(());
31653165+ ///Marker type for the `rev` field
31663166+ pub struct rev(());
31653167 ///Marker type for the `message` field
31663168 pub struct message(());
31673167- ///Marker type for the `rev` field
31683168- pub struct rev(());
31693169 }
31703170}
31713171···32803280 S: log_remove_reaction_state::State,
32813281 S::Reaction: log_remove_reaction_state::IsSet,
32823282 S::ConvoId: log_remove_reaction_state::IsSet,
32833283- S::Message: log_remove_reaction_state::IsSet,
32843283 S::Rev: log_remove_reaction_state::IsSet,
32843284+ S::Message: log_remove_reaction_state::IsSet,
32853285{
32863286 /// Build the final struct
32873287 pub fn build(self) -> LogRemoveReaction<'a> {
···34113411 }
34123412 /// State trait tracking which required fields have been set
34133413 pub trait State: sealed::Sealed {
34143414- type Reaction;
34153414 type Message;
34153415+ type Reaction;
34163416 }
34173417 /// Empty state - all required fields are unset
34183418 pub struct Empty(());
34193419 impl sealed::Sealed for Empty {}
34203420 impl State for Empty {
34213421- type Reaction = Unset;
34223421 type Message = Unset;
34233423- }
34243424- ///State transition - sets the `reaction` field to Set
34253425- pub struct SetReaction<S: State = Empty>(PhantomData<fn() -> S>);
34263426- impl<S: State> sealed::Sealed for SetReaction<S> {}
34273427- impl<S: State> State for SetReaction<S> {
34283428- type Reaction = Set<members::reaction>;
34293429- type Message = S::Message;
34223422+ type Reaction = Unset;
34303423 }
34313424 ///State transition - sets the `message` field to Set
34323425 pub struct SetMessage<S: State = Empty>(PhantomData<fn() -> S>);
34333426 impl<S: State> sealed::Sealed for SetMessage<S> {}
34343427 impl<S: State> State for SetMessage<S> {
34353435- type Reaction = S::Reaction;
34363428 type Message = Set<members::message>;
34293429+ type Reaction = S::Reaction;
34303430+ }
34313431+ ///State transition - sets the `reaction` field to Set
34323432+ pub struct SetReaction<S: State = Empty>(PhantomData<fn() -> S>);
34333433+ impl<S: State> sealed::Sealed for SetReaction<S> {}
34343434+ impl<S: State> State for SetReaction<S> {
34353435+ type Message = S::Message;
34363436+ type Reaction = Set<members::reaction>;
34373437 }
34383438 /// Marker types for field names
34393439 #[allow(non_camel_case_types)]
34403440 pub mod members {
34413441+ ///Marker type for the `message` field
34423442+ pub struct message(());
34413443 ///Marker type for the `reaction` field
34423444 pub struct reaction(());
34433443- ///Marker type for the `message` field
34443444- pub struct message(());
34453445 }
34463446}
34473447···35233523impl<'a, S> MessageAndReactionViewBuilder<'a, S>
35243524where
35253525 S: message_and_reaction_view_state::State,
35263526- S::Reaction: message_and_reaction_view_state::IsSet,
35273526 S::Message: message_and_reaction_view_state::IsSet,
35273527+ S::Reaction: message_and_reaction_view_state::IsSet,
35283528{
35293529 /// Build the final struct
35303530 pub fn build(self) -> MessageAndReactionView<'a> {
···36703670 }
36713671 /// State trait tracking which required fields have been set
36723672 pub trait State: sealed::Sealed {
36733673- type MessageId;
36743673 type ConvoId;
36753674 type Did;
36753675+ type MessageId;
36763676 }
36773677 /// Empty state - all required fields are unset
36783678 pub struct Empty(());
36793679 impl sealed::Sealed for Empty {}
36803680 impl State for Empty {
36813681- type MessageId = Unset;
36823681 type ConvoId = Unset;
36833682 type Did = Unset;
36843684- }
36853685- ///State transition - sets the `message_id` field to Set
36863686- pub struct SetMessageId<S: State = Empty>(PhantomData<fn() -> S>);
36873687- impl<S: State> sealed::Sealed for SetMessageId<S> {}
36883688- impl<S: State> State for SetMessageId<S> {
36893689- type MessageId = Set<members::message_id>;
36903690- type ConvoId = S::ConvoId;
36913691- type Did = S::Did;
36833683+ type MessageId = Unset;
36923684 }
36933685 ///State transition - sets the `convo_id` field to Set
36943686 pub struct SetConvoId<S: State = Empty>(PhantomData<fn() -> S>);
36953687 impl<S: State> sealed::Sealed for SetConvoId<S> {}
36963688 impl<S: State> State for SetConvoId<S> {
36973697- type MessageId = S::MessageId;
36983689 type ConvoId = Set<members::convo_id>;
36993690 type Did = S::Did;
36913691+ type MessageId = S::MessageId;
37003692 }
37013693 ///State transition - sets the `did` field to Set
37023694 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
37033695 impl<S: State> sealed::Sealed for SetDid<S> {}
37043696 impl<S: State> State for SetDid<S> {
37053705- type MessageId = S::MessageId;
37063697 type ConvoId = S::ConvoId;
37073698 type Did = Set<members::did>;
36993699+ type MessageId = S::MessageId;
37003700+ }
37013701+ ///State transition - sets the `message_id` field to Set
37023702+ pub struct SetMessageId<S: State = Empty>(PhantomData<fn() -> S>);
37033703+ impl<S: State> sealed::Sealed for SetMessageId<S> {}
37043704+ impl<S: State> State for SetMessageId<S> {
37053705+ type ConvoId = S::ConvoId;
37063706+ type Did = S::Did;
37073707+ type MessageId = Set<members::message_id>;
37083708 }
37093709 /// Marker types for field names
37103710 #[allow(non_camel_case_types)]
37113711 pub mod members {
37123712- ///Marker type for the `message_id` field
37133713- pub struct message_id(());
37143712 ///Marker type for the `convo_id` field
37153713 pub struct convo_id(());
37163714 ///Marker type for the `did` field
37173715 pub struct did(());
37163716+ ///Marker type for the `message_id` field
37173717+ pub struct message_id(());
37183718 }
37193719}
37203720···38073807impl<'a, S> MessageRefBuilder<'a, S>
38083808where
38093809 S: message_ref_state::State,
38103810- S::MessageId: message_ref_state::IsSet,
38113810 S::ConvoId: message_ref_state::IsSet,
38123811 S::Did: message_ref_state::IsSet,
38123812+ S::MessageId: message_ref_state::IsSet,
38133813{
38143814 /// Build the final struct
38153815 pub fn build(self) -> MessageRef<'a> {
···38983898 }
38993899 /// State trait tracking which required fields have been set
39003900 pub trait State: sealed::Sealed {
39013901- type Id;
39023902- type Sender;
39033901 type Rev;
39023902+ type Id;
39043903 type Text;
39043904+ type Sender;
39053905 type SentAt;
39063906 }
39073907 /// Empty state - all required fields are unset
39083908 pub struct Empty(());
39093909 impl sealed::Sealed for Empty {}
39103910 impl State for Empty {
39113911+ type Rev = Unset;
39113912 type Id = Unset;
39123912- type Sender = Unset;
39133913- type Rev = Unset;
39143913 type Text = Unset;
39143914+ type Sender = Unset;
39153915 type SentAt = Unset;
39163916 }
39173917+ ///State transition - sets the `rev` field to Set
39183918+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
39193919+ impl<S: State> sealed::Sealed for SetRev<S> {}
39203920+ impl<S: State> State for SetRev<S> {
39213921+ type Rev = Set<members::rev>;
39223922+ type Id = S::Id;
39233923+ type Text = S::Text;
39243924+ type Sender = S::Sender;
39253925+ type SentAt = S::SentAt;
39263926+ }
39173927 ///State transition - sets the `id` field to Set
39183928 pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
39193929 impl<S: State> sealed::Sealed for SetId<S> {}
39203930 impl<S: State> State for SetId<S> {
39313931+ type Rev = S::Rev;
39213932 type Id = Set<members::id>;
39333933+ type Text = S::Text;
39223934 type Sender = S::Sender;
39353935+ type SentAt = S::SentAt;
39363936+ }
39373937+ ///State transition - sets the `text` field to Set
39383938+ pub struct SetText<S: State = Empty>(PhantomData<fn() -> S>);
39393939+ impl<S: State> sealed::Sealed for SetText<S> {}
39403940+ impl<S: State> State for SetText<S> {
39233941 type Rev = S::Rev;
39243924- type Text = S::Text;
39423942+ type Id = S::Id;
39433943+ type Text = Set<members::text>;
39443944+ type Sender = S::Sender;
39253945 type SentAt = S::SentAt;
39263946 }
39273947 ///State transition - sets the `sender` field to Set
39283948 pub struct SetSender<S: State = Empty>(PhantomData<fn() -> S>);
39293949 impl<S: State> sealed::Sealed for SetSender<S> {}
39303950 impl<S: State> State for SetSender<S> {
39313931- type Id = S::Id;
39323932- type Sender = Set<members::sender>;
39333951 type Rev = S::Rev;
39343934- type Text = S::Text;
39353935- type SentAt = S::SentAt;
39363936- }
39373937- ///State transition - sets the `rev` field to Set
39383938- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
39393939- impl<S: State> sealed::Sealed for SetRev<S> {}
39403940- impl<S: State> State for SetRev<S> {
39413952 type Id = S::Id;
39423942- type Sender = S::Sender;
39433943- type Rev = Set<members::rev>;
39443953 type Text = S::Text;
39453945- type SentAt = S::SentAt;
39463946- }
39473947- ///State transition - sets the `text` field to Set
39483948- pub struct SetText<S: State = Empty>(PhantomData<fn() -> S>);
39493949- impl<S: State> sealed::Sealed for SetText<S> {}
39503950- impl<S: State> State for SetText<S> {
39513951- type Id = S::Id;
39523952- type Sender = S::Sender;
39533953- type Rev = S::Rev;
39543954- type Text = Set<members::text>;
39543954+ type Sender = Set<members::sender>;
39553955 type SentAt = S::SentAt;
39563956 }
39573957 ///State transition - sets the `sent_at` field to Set
39583958 pub struct SetSentAt<S: State = Empty>(PhantomData<fn() -> S>);
39593959 impl<S: State> sealed::Sealed for SetSentAt<S> {}
39603960 impl<S: State> State for SetSentAt<S> {
39613961- type Id = S::Id;
39623962- type Sender = S::Sender;
39633961 type Rev = S::Rev;
39623962+ type Id = S::Id;
39643963 type Text = S::Text;
39643964+ type Sender = S::Sender;
39653965 type SentAt = Set<members::sent_at>;
39663966 }
39673967 /// Marker types for field names
39683968 #[allow(non_camel_case_types)]
39693969 pub mod members {
39703970+ ///Marker type for the `rev` field
39713971+ pub struct rev(());
39703972 ///Marker type for the `id` field
39713973 pub struct id(());
39743974+ ///Marker type for the `text` field
39753975+ pub struct text(());
39723976 ///Marker type for the `sender` field
39733977 pub struct sender(());
39743974- ///Marker type for the `rev` field
39753975- pub struct rev(());
39763976- ///Marker type for the `text` field
39773977- pub struct text(());
39783978 ///Marker type for the `sent_at` field
39793979 pub struct sent_at(());
39803980 }
···41694169impl<'a, S> MessageViewBuilder<'a, S>
41704170where
41714171 S: message_view_state::State,
41724172- S::Id: message_view_state::IsSet,
41734173- S::Sender: message_view_state::IsSet,
41744172 S::Rev: message_view_state::IsSet,
41734173+ S::Id: message_view_state::IsSet,
41754174 S::Text: message_view_state::IsSet,
41754175+ S::Sender: message_view_state::IsSet,
41764176 S::SentAt: message_view_state::IsSet,
41774177{
41784178 /// Build the final struct
···44284428 /// State trait tracking which required fields have been set
44294429 pub trait State: sealed::Sealed {
44304430 type Value;
44314431- type Sender;
44324431 type CreatedAt;
44324432+ type Sender;
44334433 }
44344434 /// Empty state - all required fields are unset
44354435 pub struct Empty(());
44364436 impl sealed::Sealed for Empty {}
44374437 impl State for Empty {
44384438 type Value = Unset;
44394439- type Sender = Unset;
44404439 type CreatedAt = Unset;
44404440+ type Sender = Unset;
44414441 }
44424442 ///State transition - sets the `value` field to Set
44434443 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
44444444 impl<S: State> sealed::Sealed for SetValue<S> {}
44454445 impl<S: State> State for SetValue<S> {
44464446 type Value = Set<members::value>;
44474447- type Sender = S::Sender;
44484447 type CreatedAt = S::CreatedAt;
44494449- }
44504450- ///State transition - sets the `sender` field to Set
44514451- pub struct SetSender<S: State = Empty>(PhantomData<fn() -> S>);
44524452- impl<S: State> sealed::Sealed for SetSender<S> {}
44534453- impl<S: State> State for SetSender<S> {
44544454- type Value = S::Value;
44554455- type Sender = Set<members::sender>;
44564456- type CreatedAt = S::CreatedAt;
44484448+ type Sender = S::Sender;
44574449 }
44584450 ///State transition - sets the `created_at` field to Set
44594451 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
44604452 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
44614453 impl<S: State> State for SetCreatedAt<S> {
44624454 type Value = S::Value;
44634463- type Sender = S::Sender;
44644455 type CreatedAt = Set<members::created_at>;
44564456+ type Sender = S::Sender;
44574457+ }
44584458+ ///State transition - sets the `sender` field to Set
44594459+ pub struct SetSender<S: State = Empty>(PhantomData<fn() -> S>);
44604460+ impl<S: State> sealed::Sealed for SetSender<S> {}
44614461+ impl<S: State> State for SetSender<S> {
44624462+ type Value = S::Value;
44634463+ type CreatedAt = S::CreatedAt;
44644464+ type Sender = Set<members::sender>;
44654465 }
44664466 /// Marker types for field names
44674467 #[allow(non_camel_case_types)]
44684468 pub mod members {
44694469 ///Marker type for the `value` field
44704470 pub struct value(());
44714471- ///Marker type for the `sender` field
44724472- pub struct sender(());
44734471 ///Marker type for the `created_at` field
44744472 pub struct created_at(());
44734473+ ///Marker type for the `sender` field
44744474+ pub struct sender(());
44754475 }
44764476}
44774477···45654565where
45664566 S: reaction_view_state::State,
45674567 S::Value: reaction_view_state::IsSet,
45684568- S::Sender: reaction_view_state::IsSet,
45694568 S::CreatedAt: reaction_view_state::IsSet,
45694569+ S::Sender: reaction_view_state::IsSet,
45704570{
45714571 /// Build the final struct
45724572 pub fn build(self) -> ReactionView<'a> {
···185185 }
186186 /// State trait tracking which required fields have been set
187187 pub trait State: sealed::Sealed {
188188- type ConvosStarted;
189189- type MessagesSent;
190188 type MessagesReceived;
189189+ type ConvosStarted;
191190 type Convos;
191191+ type MessagesSent;
192192 }
193193 /// Empty state - all required fields are unset
194194 pub struct Empty(());
195195 impl sealed::Sealed for Empty {}
196196 impl State for Empty {
197197+ type MessagesReceived = Unset;
197198 type ConvosStarted = Unset;
198198- type MessagesSent = Unset;
199199- type MessagesReceived = Unset;
200199 type Convos = Unset;
201201- }
202202- ///State transition - sets the `convos_started` field to Set
203203- pub struct SetConvosStarted<S: State = Empty>(PhantomData<fn() -> S>);
204204- impl<S: State> sealed::Sealed for SetConvosStarted<S> {}
205205- impl<S: State> State for SetConvosStarted<S> {
206206- type ConvosStarted = Set<members::convos_started>;
207207- type MessagesSent = S::MessagesSent;
208208- type MessagesReceived = S::MessagesReceived;
209209- type Convos = S::Convos;
210210- }
211211- ///State transition - sets the `messages_sent` field to Set
212212- pub struct SetMessagesSent<S: State = Empty>(PhantomData<fn() -> S>);
213213- impl<S: State> sealed::Sealed for SetMessagesSent<S> {}
214214- impl<S: State> State for SetMessagesSent<S> {
215215- type ConvosStarted = S::ConvosStarted;
216216- type MessagesSent = Set<members::messages_sent>;
217217- type MessagesReceived = S::MessagesReceived;
218218- type Convos = S::Convos;
200200+ type MessagesSent = Unset;
219201 }
220202 ///State transition - sets the `messages_received` field to Set
221203 pub struct SetMessagesReceived<S: State = Empty>(PhantomData<fn() -> S>);
222204 impl<S: State> sealed::Sealed for SetMessagesReceived<S> {}
223205 impl<S: State> State for SetMessagesReceived<S> {
206206+ type MessagesReceived = Set<members::messages_received>;
224207 type ConvosStarted = S::ConvosStarted;
208208+ type Convos = S::Convos;
225209 type MessagesSent = S::MessagesSent;
226226- type MessagesReceived = Set<members::messages_received>;
210210+ }
211211+ ///State transition - sets the `convos_started` field to Set
212212+ pub struct SetConvosStarted<S: State = Empty>(PhantomData<fn() -> S>);
213213+ impl<S: State> sealed::Sealed for SetConvosStarted<S> {}
214214+ impl<S: State> State for SetConvosStarted<S> {
215215+ type MessagesReceived = S::MessagesReceived;
216216+ type ConvosStarted = Set<members::convos_started>;
227217 type Convos = S::Convos;
218218+ type MessagesSent = S::MessagesSent;
228219 }
229220 ///State transition - sets the `convos` field to Set
230221 pub struct SetConvos<S: State = Empty>(PhantomData<fn() -> S>);
231222 impl<S: State> sealed::Sealed for SetConvos<S> {}
232223 impl<S: State> State for SetConvos<S> {
224224+ type MessagesReceived = S::MessagesReceived;
233225 type ConvosStarted = S::ConvosStarted;
226226+ type Convos = Set<members::convos>;
234227 type MessagesSent = S::MessagesSent;
228228+ }
229229+ ///State transition - sets the `messages_sent` field to Set
230230+ pub struct SetMessagesSent<S: State = Empty>(PhantomData<fn() -> S>);
231231+ impl<S: State> sealed::Sealed for SetMessagesSent<S> {}
232232+ impl<S: State> State for SetMessagesSent<S> {
235233 type MessagesReceived = S::MessagesReceived;
236236- type Convos = Set<members::convos>;
234234+ type ConvosStarted = S::ConvosStarted;
235235+ type Convos = S::Convos;
236236+ type MessagesSent = Set<members::messages_sent>;
237237 }
238238 /// Marker types for field names
239239 #[allow(non_camel_case_types)]
240240 pub mod members {
241241- ///Marker type for the `convos_started` field
242242- pub struct convos_started(());
243243- ///Marker type for the `messages_sent` field
244244- pub struct messages_sent(());
245241 ///Marker type for the `messages_received` field
246242 pub struct messages_received(());
243243+ ///Marker type for the `convos_started` field
244244+ pub struct convos_started(());
247245 ///Marker type for the `convos` field
248246 pub struct convos(());
247247+ ///Marker type for the `messages_sent` field
248248+ pub struct messages_sent(());
249249 }
250250}
251251···358358impl<'a, S> MetadataBuilder<'a, S>
359359where
360360 S: metadata_state::State,
361361- S::ConvosStarted: metadata_state::IsSet,
362362- S::MessagesSent: metadata_state::IsSet,
363361 S::MessagesReceived: metadata_state::IsSet,
362362+ S::ConvosStarted: metadata_state::IsSet,
364363 S::Convos: metadata_state::IsSet,
364364+ S::MessagesSent: metadata_state::IsSet,
365365{
366366 /// Build the final struct
367367 pub fn build(self) -> Metadata<'a> {
···3535 }
3636 /// State trait tracking which required fields have been set
3737 pub trait State: sealed::Sealed {
3838- type Actor;
3938 type AllowAccess;
3939+ type Actor;
4040 }
4141 /// Empty state - all required fields are unset
4242 pub struct Empty(());
4343 impl sealed::Sealed for Empty {}
4444 impl State for Empty {
4545- type Actor = Unset;
4645 type AllowAccess = Unset;
4747- }
4848- ///State transition - sets the `actor` field to Set
4949- pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
5050- impl<S: State> sealed::Sealed for SetActor<S> {}
5151- impl<S: State> State for SetActor<S> {
5252- type Actor = Set<members::actor>;
5353- type AllowAccess = S::AllowAccess;
4646+ type Actor = Unset;
5447 }
5548 ///State transition - sets the `allow_access` field to Set
5649 pub struct SetAllowAccess<S: State = Empty>(PhantomData<fn() -> S>);
5750 impl<S: State> sealed::Sealed for SetAllowAccess<S> {}
5851 impl<S: State> State for SetAllowAccess<S> {
5959- type Actor = S::Actor;
6052 type AllowAccess = Set<members::allow_access>;
5353+ type Actor = S::Actor;
5454+ }
5555+ ///State transition - sets the `actor` field to Set
5656+ pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
5757+ impl<S: State> sealed::Sealed for SetActor<S> {}
5858+ impl<S: State> State for SetActor<S> {
5959+ type AllowAccess = S::AllowAccess;
6060+ type Actor = Set<members::actor>;
6161 }
6262 /// Marker types for field names
6363 #[allow(non_camel_case_types)]
6464 pub mod members {
6565- ///Marker type for the `actor` field
6666- pub struct actor(());
6765 ///Marker type for the `allow_access` field
6866 pub struct allow_access(());
6767+ ///Marker type for the `actor` field
6868+ pub struct actor(());
6969 }
7070}
7171···155155impl<'a, S> UpdateActorAccessBuilder<'a, S>
156156where
157157 S: update_actor_access_state::State,
158158- S::Actor: update_actor_access_state::IsSet,
159158 S::AllowAccess: update_actor_access_state::IsSet,
159159+ S::Actor: update_actor_access_state::IsSet,
160160{
161161 /// Build the final struct
162162 pub fn build(self) -> UpdateActorAccess<'a> {
+37-37
crates/weaver-api/src/com_atproto/admin.rs
···8080 }
8181 /// State trait tracking which required fields have been set
8282 pub trait State: sealed::Sealed {
8383- type Handle;
8484- type Did;
8583 type IndexedAt;
8484+ type Did;
8585+ type Handle;
8686 }
8787 /// Empty state - all required fields are unset
8888 pub struct Empty(());
8989 impl sealed::Sealed for Empty {}
9090 impl State for Empty {
9191+ type IndexedAt = Unset;
9292+ type Did = Unset;
9193 type Handle = Unset;
9292- type Did = Unset;
9393- type IndexedAt = Unset;
9494 }
9595- ///State transition - sets the `handle` field to Set
9696- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
9797- impl<S: State> sealed::Sealed for SetHandle<S> {}
9898- impl<S: State> State for SetHandle<S> {
9999- type Handle = Set<members::handle>;
9595+ ///State transition - sets the `indexed_at` field to Set
9696+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
9797+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
9898+ impl<S: State> State for SetIndexedAt<S> {
9999+ type IndexedAt = Set<members::indexed_at>;
100100 type Did = S::Did;
101101- type IndexedAt = S::IndexedAt;
101101+ type Handle = S::Handle;
102102 }
103103 ///State transition - sets the `did` field to Set
104104 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
105105 impl<S: State> sealed::Sealed for SetDid<S> {}
106106 impl<S: State> State for SetDid<S> {
107107- type Handle = S::Handle;
108108- type Did = Set<members::did>;
109107 type IndexedAt = S::IndexedAt;
108108+ type Did = Set<members::did>;
109109+ type Handle = S::Handle;
110110 }
111111- ///State transition - sets the `indexed_at` field to Set
112112- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
113113- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
114114- impl<S: State> State for SetIndexedAt<S> {
115115- type Handle = S::Handle;
111111+ ///State transition - sets the `handle` field to Set
112112+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
113113+ impl<S: State> sealed::Sealed for SetHandle<S> {}
114114+ impl<S: State> State for SetHandle<S> {
115115+ type IndexedAt = S::IndexedAt;
116116 type Did = S::Did;
117117- type IndexedAt = Set<members::indexed_at>;
117117+ type Handle = Set<members::handle>;
118118 }
119119 /// Marker types for field names
120120 #[allow(non_camel_case_types)]
121121 pub mod members {
122122+ ///Marker type for the `indexed_at` field
123123+ pub struct indexed_at(());
124124+ ///Marker type for the `did` field
125125+ pub struct did(());
122126 ///Marker type for the `handle` field
123127 pub struct handle(());
124124- ///Marker type for the `did` field
125125- pub struct did(());
126126- ///Marker type for the `indexed_at` field
127127- pub struct indexed_at(());
128128 }
129129}
130130···401401impl<'a, S> AccountViewBuilder<'a, S>
402402where
403403 S: account_view_state::State,
404404- S::Handle: account_view_state::IsSet,
405405- S::Did: account_view_state::IsSet,
406404 S::IndexedAt: account_view_state::IsSet,
405405+ S::Did: account_view_state::IsSet,
406406+ S::Handle: account_view_state::IsSet,
407407{
408408 /// Build the final struct
409409 pub fn build(self) -> AccountView<'a> {
···907907 }
908908 /// State trait tracking which required fields have been set
909909 pub trait State: sealed::Sealed {
910910- type Did;
911910 type Cid;
911911+ type Did;
912912 }
913913 /// Empty state - all required fields are unset
914914 pub struct Empty(());
915915 impl sealed::Sealed for Empty {}
916916 impl State for Empty {
917917- type Did = Unset;
918917 type Cid = Unset;
919919- }
920920- ///State transition - sets the `did` field to Set
921921- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
922922- impl<S: State> sealed::Sealed for SetDid<S> {}
923923- impl<S: State> State for SetDid<S> {
924924- type Did = Set<members::did>;
925925- type Cid = S::Cid;
918918+ type Did = Unset;
926919 }
927920 ///State transition - sets the `cid` field to Set
928921 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
929922 impl<S: State> sealed::Sealed for SetCid<S> {}
930923 impl<S: State> State for SetCid<S> {
931931- type Did = S::Did;
932924 type Cid = Set<members::cid>;
925925+ type Did = S::Did;
926926+ }
927927+ ///State transition - sets the `did` field to Set
928928+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
929929+ impl<S: State> sealed::Sealed for SetDid<S> {}
930930+ impl<S: State> State for SetDid<S> {
931931+ type Cid = S::Cid;
932932+ type Did = Set<members::did>;
933933 }
934934 /// Marker types for field names
935935 #[allow(non_camel_case_types)]
936936 pub mod members {
937937- ///Marker type for the `did` field
938938- pub struct did(());
939937 ///Marker type for the `cid` field
940938 pub struct cid(());
939939+ ///Marker type for the `did` field
940940+ pub struct did(());
941941 }
942942}
943943···10301030impl<'a, S> RepoBlobRefBuilder<'a, S>
10311031where
10321032 S: repo_blob_ref_state::State,
10331033- S::Did: repo_blob_ref_state::IsSet,
10341033 S::Cid: repo_blob_ref_state::IsSet,
10341034+ S::Did: repo_blob_ref_state::IsSet,
10351035{
10361036 /// Build the final struct
10371037 pub fn build(self) -> RepoBlobRef<'a> {
···4242 }
4343 /// State trait tracking which required fields have been set
4444 pub trait State: sealed::Sealed {
4545- type Content;
4646- type SenderDid;
4745 type RecipientDid;
4646+ type SenderDid;
4747+ type Content;
4848 }
4949 /// Empty state - all required fields are unset
5050 pub struct Empty(());
5151 impl sealed::Sealed for Empty {}
5252 impl State for Empty {
5353+ type RecipientDid = Unset;
5454+ type SenderDid = Unset;
5355 type Content = Unset;
5454- type SenderDid = Unset;
5555- type RecipientDid = Unset;
5656 }
5757- ///State transition - sets the `content` field to Set
5858- pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
5959- impl<S: State> sealed::Sealed for SetContent<S> {}
6060- impl<S: State> State for SetContent<S> {
6161- type Content = Set<members::content>;
5757+ ///State transition - sets the `recipient_did` field to Set
5858+ pub struct SetRecipientDid<S: State = Empty>(PhantomData<fn() -> S>);
5959+ impl<S: State> sealed::Sealed for SetRecipientDid<S> {}
6060+ impl<S: State> State for SetRecipientDid<S> {
6161+ type RecipientDid = Set<members::recipient_did>;
6262 type SenderDid = S::SenderDid;
6363- type RecipientDid = S::RecipientDid;
6363+ type Content = S::Content;
6464 }
6565 ///State transition - sets the `sender_did` field to Set
6666 pub struct SetSenderDid<S: State = Empty>(PhantomData<fn() -> S>);
6767 impl<S: State> sealed::Sealed for SetSenderDid<S> {}
6868 impl<S: State> State for SetSenderDid<S> {
6969- type Content = S::Content;
7070- type SenderDid = Set<members::sender_did>;
7169 type RecipientDid = S::RecipientDid;
7070+ type SenderDid = Set<members::sender_did>;
7171+ type Content = S::Content;
7272 }
7373- ///State transition - sets the `recipient_did` field to Set
7474- pub struct SetRecipientDid<S: State = Empty>(PhantomData<fn() -> S>);
7575- impl<S: State> sealed::Sealed for SetRecipientDid<S> {}
7676- impl<S: State> State for SetRecipientDid<S> {
7777- type Content = S::Content;
7373+ ///State transition - sets the `content` field to Set
7474+ pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
7575+ impl<S: State> sealed::Sealed for SetContent<S> {}
7676+ impl<S: State> State for SetContent<S> {
7777+ type RecipientDid = S::RecipientDid;
7878 type SenderDid = S::SenderDid;
7979- type RecipientDid = Set<members::recipient_did>;
7979+ type Content = Set<members::content>;
8080 }
8181 /// Marker types for field names
8282 #[allow(non_camel_case_types)]
8383 pub mod members {
8484+ ///Marker type for the `recipient_did` field
8585+ pub struct recipient_did(());
8686+ ///Marker type for the `sender_did` field
8787+ pub struct sender_did(());
8488 ///Marker type for the `content` field
8589 pub struct content(());
8686- ///Marker type for the `sender_did` field
8787- pub struct sender_did(());
8888- ///Marker type for the `recipient_did` field
8989- pub struct recipient_did(());
9090 }
9191}
9292···213213impl<'a, S> SendEmailBuilder<'a, S>
214214where
215215 S: send_email_state::State,
216216- S::Content: send_email_state::IsSet,
217217- S::SenderDid: send_email_state::IsSet,
218216 S::RecipientDid: send_email_state::IsSet,
217217+ S::SenderDid: send_email_state::IsSet,
218218+ S::Content: send_email_state::IsSet,
219219{
220220 /// Build the final struct
221221 pub fn build(self) -> SendEmail<'a> {
+24-24
crates/weaver-api/src/com_atproto/identity.rs
···4747 }
4848 /// State trait tracking which required fields have been set
4949 pub trait State: sealed::Sealed {
5050- type Did;
5151- type Handle;
5250 type DidDoc;
5151+ type Handle;
5252+ type Did;
5353 }
5454 /// Empty state - all required fields are unset
5555 pub struct Empty(());
5656 impl sealed::Sealed for Empty {}
5757 impl State for Empty {
5858+ type DidDoc = Unset;
5959+ type Handle = Unset;
5860 type Did = Unset;
5959- type Handle = Unset;
6060- type DidDoc = Unset;
6161 }
6262- ///State transition - sets the `did` field to Set
6363- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
6464- impl<S: State> sealed::Sealed for SetDid<S> {}
6565- impl<S: State> State for SetDid<S> {
6666- type Did = Set<members::did>;
6262+ ///State transition - sets the `did_doc` field to Set
6363+ pub struct SetDidDoc<S: State = Empty>(PhantomData<fn() -> S>);
6464+ impl<S: State> sealed::Sealed for SetDidDoc<S> {}
6565+ impl<S: State> State for SetDidDoc<S> {
6666+ type DidDoc = Set<members::did_doc>;
6767 type Handle = S::Handle;
6868- type DidDoc = S::DidDoc;
6868+ type Did = S::Did;
6969 }
7070 ///State transition - sets the `handle` field to Set
7171 pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
7272 impl<S: State> sealed::Sealed for SetHandle<S> {}
7373 impl<S: State> State for SetHandle<S> {
7474- type Did = S::Did;
7575- type Handle = Set<members::handle>;
7674 type DidDoc = S::DidDoc;
7575+ type Handle = Set<members::handle>;
7676+ type Did = S::Did;
7777 }
7878- ///State transition - sets the `did_doc` field to Set
7979- pub struct SetDidDoc<S: State = Empty>(PhantomData<fn() -> S>);
8080- impl<S: State> sealed::Sealed for SetDidDoc<S> {}
8181- impl<S: State> State for SetDidDoc<S> {
8282- type Did = S::Did;
7878+ ///State transition - sets the `did` field to Set
7979+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
8080+ impl<S: State> sealed::Sealed for SetDid<S> {}
8181+ impl<S: State> State for SetDid<S> {
8282+ type DidDoc = S::DidDoc;
8383 type Handle = S::Handle;
8484- type DidDoc = Set<members::did_doc>;
8484+ type Did = Set<members::did>;
8585 }
8686 /// Marker types for field names
8787 #[allow(non_camel_case_types)]
8888 pub mod members {
8989+ ///Marker type for the `did_doc` field
9090+ pub struct did_doc(());
9191+ ///Marker type for the `handle` field
9292+ pub struct handle(());
8993 ///Marker type for the `did` field
9094 pub struct did(());
9191- ///Marker type for the `handle` field
9292- pub struct handle(());
9393- ///Marker type for the `did_doc` field
9494- pub struct did_doc(());
9595 }
9696}
9797···184184impl<'a, S> IdentityInfoBuilder<'a, S>
185185where
186186 S: identity_info_state::State,
187187- S::Did: identity_info_state::IsSet,
188188- S::Handle: identity_info_state::IsSet,
189187 S::DidDoc: identity_info_state::IsSet,
188188+ S::Handle: identity_info_state::IsSet,
189189+ S::Did: identity_info_state::IsSet,
190190{
191191 /// Build the final struct
192192 pub fn build(self) -> IdentityInfo<'a> {
+62-62
crates/weaver-api/src/com_atproto/label.rs
···6363 }
6464 /// State trait tracking which required fields have been set
6565 pub trait State: sealed::Sealed {
6666- type Src;
6766 type Uri;
6868- type Val;
6967 type Cts;
6868+ type Src;
6969+ type Val;
7070 }
7171 /// Empty state - all required fields are unset
7272 pub struct Empty(());
7373 impl sealed::Sealed for Empty {}
7474 impl State for Empty {
7575- type Src = Unset;
7675 type Uri = Unset;
7777- type Val = Unset;
7876 type Cts = Unset;
7979- }
8080- ///State transition - sets the `src` field to Set
8181- pub struct SetSrc<S: State = Empty>(PhantomData<fn() -> S>);
8282- impl<S: State> sealed::Sealed for SetSrc<S> {}
8383- impl<S: State> State for SetSrc<S> {
8484- type Src = Set<members::src>;
8585- type Uri = S::Uri;
8686- type Val = S::Val;
8787- type Cts = S::Cts;
7777+ type Src = Unset;
7878+ type Val = Unset;
8879 }
8980 ///State transition - sets the `uri` field to Set
9081 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
9182 impl<S: State> sealed::Sealed for SetUri<S> {}
9283 impl<S: State> State for SetUri<S> {
9393- type Src = S::Src;
9484 type Uri = Set<members::uri>;
9595- type Val = S::Val;
9685 type Cts = S::Cts;
9797- }
9898- ///State transition - sets the `val` field to Set
9999- pub struct SetVal<S: State = Empty>(PhantomData<fn() -> S>);
100100- impl<S: State> sealed::Sealed for SetVal<S> {}
101101- impl<S: State> State for SetVal<S> {
10286 type Src = S::Src;
103103- type Uri = S::Uri;
104104- type Val = Set<members::val>;
105105- type Cts = S::Cts;
8787+ type Val = S::Val;
10688 }
10789 ///State transition - sets the `cts` field to Set
10890 pub struct SetCts<S: State = Empty>(PhantomData<fn() -> S>);
10991 impl<S: State> sealed::Sealed for SetCts<S> {}
11092 impl<S: State> State for SetCts<S> {
9393+ type Uri = S::Uri;
9494+ type Cts = Set<members::cts>;
11195 type Src = S::Src;
9696+ type Val = S::Val;
9797+ }
9898+ ///State transition - sets the `src` field to Set
9999+ pub struct SetSrc<S: State = Empty>(PhantomData<fn() -> S>);
100100+ impl<S: State> sealed::Sealed for SetSrc<S> {}
101101+ impl<S: State> State for SetSrc<S> {
112102 type Uri = S::Uri;
103103+ type Cts = S::Cts;
104104+ type Src = Set<members::src>;
113105 type Val = S::Val;
114114- type Cts = Set<members::cts>;
106106+ }
107107+ ///State transition - sets the `val` field to Set
108108+ pub struct SetVal<S: State = Empty>(PhantomData<fn() -> S>);
109109+ impl<S: State> sealed::Sealed for SetVal<S> {}
110110+ impl<S: State> State for SetVal<S> {
111111+ type Uri = S::Uri;
112112+ type Cts = S::Cts;
113113+ type Src = S::Src;
114114+ type Val = Set<members::val>;
115115 }
116116 /// Marker types for field names
117117 #[allow(non_camel_case_types)]
118118 pub mod members {
119119- ///Marker type for the `src` field
120120- pub struct src(());
121119 ///Marker type for the `uri` field
122120 pub struct uri(());
121121+ ///Marker type for the `cts` field
122122+ pub struct cts(());
123123+ ///Marker type for the `src` field
124124+ pub struct src(());
123125 ///Marker type for the `val` field
124126 pub struct val(());
125125- ///Marker type for the `cts` field
126126- pub struct cts(());
127127 }
128128}
129129···328328impl<'a, S> LabelBuilder<'a, S>
329329where
330330 S: label_state::State,
331331- S::Src: label_state::IsSet,
332331 S::Uri: label_state::IsSet,
333333- S::Val: label_state::IsSet,
334332 S::Cts: label_state::IsSet,
333333+ S::Src: label_state::IsSet,
334334+ S::Val: label_state::IsSet,
335335{
336336 /// Build the final struct
337337 pub fn build(self) -> Label<'a> {
···10611061 pub trait State: sealed::Sealed {
10621062 type Severity;
10631063 type Identifier;
10641064- type Locales;
10651064 type Blurs;
10651065+ type Locales;
10661066 }
10671067 /// Empty state - all required fields are unset
10681068 pub struct Empty(());
···10701070 impl State for Empty {
10711071 type Severity = Unset;
10721072 type Identifier = Unset;
10731073- type Locales = Unset;
10741073 type Blurs = Unset;
10741074+ type Locales = Unset;
10751075 }
10761076 ///State transition - sets the `severity` field to Set
10771077 pub struct SetSeverity<S: State = Empty>(PhantomData<fn() -> S>);
···10791079 impl<S: State> State for SetSeverity<S> {
10801080 type Severity = Set<members::severity>;
10811081 type Identifier = S::Identifier;
10821082- type Locales = S::Locales;
10831082 type Blurs = S::Blurs;
10831083+ type Locales = S::Locales;
10841084 }
10851085 ///State transition - sets the `identifier` field to Set
10861086 pub struct SetIdentifier<S: State = Empty>(PhantomData<fn() -> S>);
···10881088 impl<S: State> State for SetIdentifier<S> {
10891089 type Severity = S::Severity;
10901090 type Identifier = Set<members::identifier>;
10911091- type Locales = S::Locales;
10921091 type Blurs = S::Blurs;
10931093- }
10941094- ///State transition - sets the `locales` field to Set
10951095- pub struct SetLocales<S: State = Empty>(PhantomData<fn() -> S>);
10961096- impl<S: State> sealed::Sealed for SetLocales<S> {}
10971097- impl<S: State> State for SetLocales<S> {
10981098- type Severity = S::Severity;
10991099- type Identifier = S::Identifier;
11001100- type Locales = Set<members::locales>;
11011101- type Blurs = S::Blurs;
10921092+ type Locales = S::Locales;
11021093 }
11031094 ///State transition - sets the `blurs` field to Set
11041095 pub struct SetBlurs<S: State = Empty>(PhantomData<fn() -> S>);
···11061097 impl<S: State> State for SetBlurs<S> {
11071098 type Severity = S::Severity;
11081099 type Identifier = S::Identifier;
11001100+ type Blurs = Set<members::blurs>;
11091101 type Locales = S::Locales;
11101110- type Blurs = Set<members::blurs>;
11021102+ }
11031103+ ///State transition - sets the `locales` field to Set
11041104+ pub struct SetLocales<S: State = Empty>(PhantomData<fn() -> S>);
11051105+ impl<S: State> sealed::Sealed for SetLocales<S> {}
11061106+ impl<S: State> State for SetLocales<S> {
11071107+ type Severity = S::Severity;
11081108+ type Identifier = S::Identifier;
11091109+ type Blurs = S::Blurs;
11101110+ type Locales = Set<members::locales>;
11111111 }
11121112 /// Marker types for field names
11131113 #[allow(non_camel_case_types)]
···11161116 pub struct severity(());
11171117 ///Marker type for the `identifier` field
11181118 pub struct identifier(());
11191119+ ///Marker type for the `blurs` field
11201120+ pub struct blurs(());
11191121 ///Marker type for the `locales` field
11201122 pub struct locales(());
11211121- ///Marker type for the `blurs` field
11221122- pub struct blurs(());
11231123 }
11241124}
11251125···12761276 S: label_value_definition_state::State,
12771277 S::Severity: label_value_definition_state::IsSet,
12781278 S::Identifier: label_value_definition_state::IsSet,
12791279- S::Locales: label_value_definition_state::IsSet,
12801279 S::Blurs: label_value_definition_state::IsSet,
12801280+ S::Locales: label_value_definition_state::IsSet,
12811281{
12821282 /// Build the final struct
12831283 pub fn build(self) -> LabelValueDefinition<'a> {
···16881688 /// State trait tracking which required fields have been set
16891689 pub trait State: sealed::Sealed {
16901690 type Name;
16911691- type Description;
16921691 type Lang;
16921692+ type Description;
16931693 }
16941694 /// Empty state - all required fields are unset
16951695 pub struct Empty(());
16961696 impl sealed::Sealed for Empty {}
16971697 impl State for Empty {
16981698 type Name = Unset;
16991699- type Description = Unset;
17001699 type Lang = Unset;
17001700+ type Description = Unset;
17011701 }
17021702 ///State transition - sets the `name` field to Set
17031703 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
17041704 impl<S: State> sealed::Sealed for SetName<S> {}
17051705 impl<S: State> State for SetName<S> {
17061706 type Name = Set<members::name>;
17071707- type Description = S::Description;
17081707 type Lang = S::Lang;
17091709- }
17101710- ///State transition - sets the `description` field to Set
17111711- pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
17121712- impl<S: State> sealed::Sealed for SetDescription<S> {}
17131713- impl<S: State> State for SetDescription<S> {
17141714- type Name = S::Name;
17151715- type Description = Set<members::description>;
17161716- type Lang = S::Lang;
17081708+ type Description = S::Description;
17171709 }
17181710 ///State transition - sets the `lang` field to Set
17191711 pub struct SetLang<S: State = Empty>(PhantomData<fn() -> S>);
17201712 impl<S: State> sealed::Sealed for SetLang<S> {}
17211713 impl<S: State> State for SetLang<S> {
17221714 type Name = S::Name;
17231723- type Description = S::Description;
17241715 type Lang = Set<members::lang>;
17161716+ type Description = S::Description;
17171717+ }
17181718+ ///State transition - sets the `description` field to Set
17191719+ pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
17201720+ impl<S: State> sealed::Sealed for SetDescription<S> {}
17211721+ impl<S: State> State for SetDescription<S> {
17221722+ type Name = S::Name;
17231723+ type Lang = S::Lang;
17241724+ type Description = Set<members::description>;
17251725 }
17261726 /// Marker types for field names
17271727 #[allow(non_camel_case_types)]
17281728 pub mod members {
17291729 ///Marker type for the `name` field
17301730 pub struct name(());
17311731+ ///Marker type for the `lang` field
17321732+ pub struct lang(());
17311733 ///Marker type for the `description` field
17321734 pub struct description(());
17331733- ///Marker type for the `lang` field
17341734- pub struct lang(());
17351735 }
17361736}
17371737···18421842where
18431843 S: label_value_definition_strings_state::State,
18441844 S::Name: label_value_definition_strings_state::IsSet,
18451845- S::Description: label_value_definition_strings_state::IsSet,
18461845 S::Lang: label_value_definition_strings_state::IsSet,
18461846+ S::Description: label_value_definition_strings_state::IsSet,
18471847{
18481848 /// Build the final struct
18491849 pub fn build(self) -> LabelValueDefinitionStrings<'a> {
···286286 }
287287 /// State trait tracking which required fields have been set
288288 pub trait State: sealed::Sealed {
289289- type Seq;
290289 type Labels;
290290+ type Seq;
291291 }
292292 /// Empty state - all required fields are unset
293293 pub struct Empty(());
294294 impl sealed::Sealed for Empty {}
295295 impl State for Empty {
296296- type Seq = Unset;
297296 type Labels = Unset;
298298- }
299299- ///State transition - sets the `seq` field to Set
300300- pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
301301- impl<S: State> sealed::Sealed for SetSeq<S> {}
302302- impl<S: State> State for SetSeq<S> {
303303- type Seq = Set<members::seq>;
304304- type Labels = S::Labels;
297297+ type Seq = Unset;
305298 }
306299 ///State transition - sets the `labels` field to Set
307300 pub struct SetLabels<S: State = Empty>(PhantomData<fn() -> S>);
308301 impl<S: State> sealed::Sealed for SetLabels<S> {}
309302 impl<S: State> State for SetLabels<S> {
310310- type Seq = S::Seq;
311303 type Labels = Set<members::labels>;
304304+ type Seq = S::Seq;
305305+ }
306306+ ///State transition - sets the `seq` field to Set
307307+ pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
308308+ impl<S: State> sealed::Sealed for SetSeq<S> {}
309309+ impl<S: State> State for SetSeq<S> {
310310+ type Labels = S::Labels;
311311+ type Seq = Set<members::seq>;
312312 }
313313 /// Marker types for field names
314314 #[allow(non_camel_case_types)]
315315 pub mod members {
316316- ///Marker type for the `seq` field
317317- pub struct seq(());
318316 ///Marker type for the `labels` field
319317 pub struct labels(());
318318+ ///Marker type for the `seq` field
319319+ pub struct seq(());
320320 }
321321}
322322···389389impl<'a, S> LabelsBuilder<'a, S>
390390where
391391 S: labels_state::State,
392392- S::Seq: labels_state::IsSet,
393392 S::Labels: labels_state::IsSet,
393393+ S::Seq: labels_state::IsSet,
394394{
395395 /// Build the final struct
396396 pub fn build(self) -> Labels<'a> {
+13-13
crates/weaver-api/src/com_atproto/repo.rs
···4444 }
4545 /// State trait tracking which required fields have been set
4646 pub trait State: sealed::Sealed {
4747- type Rev;
4847 type Cid;
4848+ type Rev;
4949 }
5050 /// Empty state - all required fields are unset
5151 pub struct Empty(());
5252 impl sealed::Sealed for Empty {}
5353 impl State for Empty {
5454- type Rev = Unset;
5554 type Cid = Unset;
5656- }
5757- ///State transition - sets the `rev` field to Set
5858- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
5959- impl<S: State> sealed::Sealed for SetRev<S> {}
6060- impl<S: State> State for SetRev<S> {
6161- type Rev = Set<members::rev>;
6262- type Cid = S::Cid;
5555+ type Rev = Unset;
6356 }
6457 ///State transition - sets the `cid` field to Set
6558 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
6659 impl<S: State> sealed::Sealed for SetCid<S> {}
6760 impl<S: State> State for SetCid<S> {
6868- type Rev = S::Rev;
6961 type Cid = Set<members::cid>;
6262+ type Rev = S::Rev;
6363+ }
6464+ ///State transition - sets the `rev` field to Set
6565+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
6666+ impl<S: State> sealed::Sealed for SetRev<S> {}
6767+ impl<S: State> State for SetRev<S> {
6868+ type Cid = S::Cid;
6969+ type Rev = Set<members::rev>;
7070 }
7171 /// Marker types for field names
7272 #[allow(non_camel_case_types)]
7373 pub mod members {
7474- ///Marker type for the `rev` field
7575- pub struct rev(());
7674 ///Marker type for the `cid` field
7775 pub struct cid(());
7676+ ///Marker type for the `rev` field
7777+ pub struct rev(());
7878 }
7979}
8080···147147impl<'a, S> CommitMetaBuilder<'a, S>
148148where
149149 S: commit_meta_state::State,
150150- S::Rev: commit_meta_state::IsSet,
151150 S::Cid: commit_meta_state::IsSet,
151151+ S::Rev: commit_meta_state::IsSet,
152152{
153153 /// Build the final struct
154154 pub fn build(self) -> CommitMeta<'a> {
···4242 }
4343 /// State trait tracking which required fields have been set
4444 pub trait State: sealed::Sealed {
4545- type Value;
4645 type Collection;
4646+ type Value;
4747 }
4848 /// Empty state - all required fields are unset
4949 pub struct Empty(());
5050 impl sealed::Sealed for Empty {}
5151 impl State for Empty {
5252- type Value = Unset;
5352 type Collection = Unset;
5454- }
5555- ///State transition - sets the `value` field to Set
5656- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
5757- impl<S: State> sealed::Sealed for SetValue<S> {}
5858- impl<S: State> State for SetValue<S> {
5959- type Value = Set<members::value>;
6060- type Collection = S::Collection;
5353+ type Value = Unset;
6154 }
6255 ///State transition - sets the `collection` field to Set
6356 pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
6457 impl<S: State> sealed::Sealed for SetCollection<S> {}
6558 impl<S: State> State for SetCollection<S> {
6666- type Value = S::Value;
6759 type Collection = Set<members::collection>;
6060+ type Value = S::Value;
6161+ }
6262+ ///State transition - sets the `value` field to Set
6363+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
6464+ impl<S: State> sealed::Sealed for SetValue<S> {}
6565+ impl<S: State> State for SetValue<S> {
6666+ type Collection = S::Collection;
6767+ type Value = Set<members::value>;
6868 }
6969 /// Marker types for field names
7070 #[allow(non_camel_case_types)]
7171 pub mod members {
7272- ///Marker type for the `value` field
7373- pub struct value(());
7472 ///Marker type for the `collection` field
7573 pub struct collection(());
7474+ ///Marker type for the `value` field
7575+ pub struct value(());
7676 }
7777}
7878···179179impl<'a, S> CreateBuilder<'a, S>
180180where
181181 S: create_state::State,
182182- S::Value: create_state::IsSet,
183182 S::Collection: create_state::IsSet,
183183+ S::Value: create_state::IsSet,
184184{
185185 /// Build the final struct
186186 pub fn build(self) -> Create<'a> {
···728728 }
729729 /// State trait tracking which required fields have been set
730730 pub trait State: sealed::Sealed {
731731- type Cid;
732731 type Uri;
732732+ type Cid;
733733 }
734734 /// Empty state - all required fields are unset
735735 pub struct Empty(());
736736 impl sealed::Sealed for Empty {}
737737 impl State for Empty {
738738+ type Uri = Unset;
738739 type Cid = Unset;
739739- type Uri = Unset;
740740+ }
741741+ ///State transition - sets the `uri` field to Set
742742+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
743743+ impl<S: State> sealed::Sealed for SetUri<S> {}
744744+ impl<S: State> State for SetUri<S> {
745745+ type Uri = Set<members::uri>;
746746+ type Cid = S::Cid;
740747 }
741748 ///State transition - sets the `cid` field to Set
742749 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
743750 impl<S: State> sealed::Sealed for SetCid<S> {}
744751 impl<S: State> State for SetCid<S> {
745745- type Cid = Set<members::cid>;
746752 type Uri = S::Uri;
747747- }
748748- ///State transition - sets the `uri` field to Set
749749- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
750750- impl<S: State> sealed::Sealed for SetUri<S> {}
751751- impl<S: State> State for SetUri<S> {
752752- type Cid = S::Cid;
753753- type Uri = Set<members::uri>;
753753+ type Cid = Set<members::cid>;
754754 }
755755 /// Marker types for field names
756756 #[allow(non_camel_case_types)]
757757 pub mod members {
758758+ ///Marker type for the `uri` field
759759+ pub struct uri(());
758760 ///Marker type for the `cid` field
759761 pub struct cid(());
760760- ///Marker type for the `uri` field
761761- pub struct uri(());
762762 }
763763}
764764···851851impl<'a, S> CreateResultBuilder<'a, S>
852852where
853853 S: create_result_state::State,
854854- S::Cid: create_result_state::IsSet,
855854 S::Uri: create_result_state::IsSet,
855855+ S::Cid: create_result_state::IsSet,
856856{
857857 /// Build the final struct
858858 pub fn build(self) -> CreateResult<'a> {
···12411241 }
12421242 /// State trait tracking which required fields have been set
12431243 pub trait State: sealed::Sealed {
12441244- type Repo;
12451244 type Writes;
12451245+ type Repo;
12461246 }
12471247 /// Empty state - all required fields are unset
12481248 pub struct Empty(());
12491249 impl sealed::Sealed for Empty {}
12501250 impl State for Empty {
12511251- type Repo = Unset;
12521251 type Writes = Unset;
12531253- }
12541254- ///State transition - sets the `repo` field to Set
12551255- pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
12561256- impl<S: State> sealed::Sealed for SetRepo<S> {}
12571257- impl<S: State> State for SetRepo<S> {
12581258- type Repo = Set<members::repo>;
12591259- type Writes = S::Writes;
12521252+ type Repo = Unset;
12601253 }
12611254 ///State transition - sets the `writes` field to Set
12621255 pub struct SetWrites<S: State = Empty>(PhantomData<fn() -> S>);
12631256 impl<S: State> sealed::Sealed for SetWrites<S> {}
12641257 impl<S: State> State for SetWrites<S> {
12581258+ type Writes = Set<members::writes>;
12651259 type Repo = S::Repo;
12661266- type Writes = Set<members::writes>;
12601260+ }
12611261+ ///State transition - sets the `repo` field to Set
12621262+ pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
12631263+ impl<S: State> sealed::Sealed for SetRepo<S> {}
12641264+ impl<S: State> State for SetRepo<S> {
12651265+ type Writes = S::Writes;
12661266+ type Repo = Set<members::repo>;
12671267 }
12681268 /// Marker types for field names
12691269 #[allow(non_camel_case_types)]
12701270 pub mod members {
12711271- ///Marker type for the `repo` field
12721272- pub struct repo(());
12731271 ///Marker type for the `writes` field
12741272 pub struct writes(());
12731273+ ///Marker type for the `repo` field
12741274+ pub struct repo(());
12751275 }
12761276}
12771277···13781378impl<'a, S> ApplyWritesBuilder<'a, S>
13791379where
13801380 S: apply_writes_state::State,
13811381- S::Repo: apply_writes_state::IsSet,
13821381 S::Writes: apply_writes_state::IsSet,
13821382+ S::Repo: apply_writes_state::IsSet,
13831383{
13841384 /// Build the final struct
13851385 pub fn build(self) -> ApplyWrites<'a> {
···15681568 }
15691569 /// State trait tracking which required fields have been set
15701570 pub trait State: sealed::Sealed {
15711571- type Value;
15721572- type Rkey;
15731571 type Collection;
15721572+ type Rkey;
15731573+ type Value;
15741574 }
15751575 /// Empty state - all required fields are unset
15761576 pub struct Empty(());
15771577 impl sealed::Sealed for Empty {}
15781578 impl State for Empty {
15791579- type Value = Unset;
15791579+ type Collection = Unset;
15801580 type Rkey = Unset;
15811581- type Collection = Unset;
15811581+ type Value = Unset;
15821582 }
15831583- ///State transition - sets the `value` field to Set
15841584- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
15851585- impl<S: State> sealed::Sealed for SetValue<S> {}
15861586- impl<S: State> State for SetValue<S> {
15871587- type Value = Set<members::value>;
15831583+ ///State transition - sets the `collection` field to Set
15841584+ pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
15851585+ impl<S: State> sealed::Sealed for SetCollection<S> {}
15861586+ impl<S: State> State for SetCollection<S> {
15871587+ type Collection = Set<members::collection>;
15881588 type Rkey = S::Rkey;
15891589- type Collection = S::Collection;
15891589+ type Value = S::Value;
15901590 }
15911591 ///State transition - sets the `rkey` field to Set
15921592 pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
15931593 impl<S: State> sealed::Sealed for SetRkey<S> {}
15941594 impl<S: State> State for SetRkey<S> {
15951595- type Value = S::Value;
15951595+ type Collection = S::Collection;
15961596 type Rkey = Set<members::rkey>;
15971597- type Collection = S::Collection;
15971597+ type Value = S::Value;
15981598 }
15991599- ///State transition - sets the `collection` field to Set
16001600- pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
16011601- impl<S: State> sealed::Sealed for SetCollection<S> {}
16021602- impl<S: State> State for SetCollection<S> {
16031603- type Value = S::Value;
15991599+ ///State transition - sets the `value` field to Set
16001600+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
16011601+ impl<S: State> sealed::Sealed for SetValue<S> {}
16021602+ impl<S: State> State for SetValue<S> {
16031603+ type Collection = S::Collection;
16041604 type Rkey = S::Rkey;
16051605- type Collection = Set<members::collection>;
16051605+ type Value = Set<members::value>;
16061606 }
16071607 /// Marker types for field names
16081608 #[allow(non_camel_case_types)]
16091609 pub mod members {
16101610- ///Marker type for the `value` field
16111611- pub struct value(());
16101610+ ///Marker type for the `collection` field
16111611+ pub struct collection(());
16121612 ///Marker type for the `rkey` field
16131613 pub struct rkey(());
16141614- ///Marker type for the `collection` field
16151615- pub struct collection(());
16141614+ ///Marker type for the `value` field
16151615+ pub struct value(());
16161616 }
16171617}
16181618···17131713impl<'a, S> UpdateBuilder<'a, S>
17141714where
17151715 S: update_state::State,
17161716- S::Value: update_state::IsSet,
17171717- S::Rkey: update_state::IsSet,
17181716 S::Collection: update_state::IsSet,
17171717+ S::Rkey: update_state::IsSet,
17181718+ S::Value: update_state::IsSet,
17191719{
17201720 /// Build the final struct
17211721 pub fn build(self) -> Update<'a> {
···5454 /// State trait tracking which required fields have been set
5555 pub trait State: sealed::Sealed {
5656 type Record;
5757- type Collection;
5857 type Repo;
5858+ type Collection;
5959 }
6060 /// Empty state - all required fields are unset
6161 pub struct Empty(());
6262 impl sealed::Sealed for Empty {}
6363 impl State for Empty {
6464 type Record = Unset;
6565- type Collection = Unset;
6665 type Repo = Unset;
6666+ type Collection = Unset;
6767 }
6868 ///State transition - sets the `record` field to Set
6969 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
7070 impl<S: State> sealed::Sealed for SetRecord<S> {}
7171 impl<S: State> State for SetRecord<S> {
7272 type Record = Set<members::record>;
7373- type Collection = S::Collection;
7473 type Repo = S::Repo;
7575- }
7676- ///State transition - sets the `collection` field to Set
7777- pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
7878- impl<S: State> sealed::Sealed for SetCollection<S> {}
7979- impl<S: State> State for SetCollection<S> {
8080- type Record = S::Record;
8181- type Collection = Set<members::collection>;
8282- type Repo = S::Repo;
7474+ type Collection = S::Collection;
8375 }
8476 ///State transition - sets the `repo` field to Set
8577 pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
8678 impl<S: State> sealed::Sealed for SetRepo<S> {}
8779 impl<S: State> State for SetRepo<S> {
8880 type Record = S::Record;
8989- type Collection = S::Collection;
9081 type Repo = Set<members::repo>;
8282+ type Collection = S::Collection;
8383+ }
8484+ ///State transition - sets the `collection` field to Set
8585+ pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
8686+ impl<S: State> sealed::Sealed for SetCollection<S> {}
8787+ impl<S: State> State for SetCollection<S> {
8888+ type Record = S::Record;
8989+ type Repo = S::Repo;
9090+ type Collection = Set<members::collection>;
9191 }
9292 /// Marker types for field names
9393 #[allow(non_camel_case_types)]
9494 pub mod members {
9595 ///Marker type for the `record` field
9696 pub struct record(());
9797+ ///Marker type for the `repo` field
9898+ pub struct repo(());
9799 ///Marker type for the `collection` field
98100 pub struct collection(());
9999- ///Marker type for the `repo` field
100100- pub struct repo(());
101101 }
102102}
103103···259259where
260260 S: create_record_state::State,
261261 S::Record: create_record_state::IsSet,
262262- S::Collection: create_record_state::IsSet,
263262 S::Repo: create_record_state::IsSet,
263263+ S::Collection: create_record_state::IsSet,
264264{
265265 /// Build the final struct
266266 pub fn build(self) -> CreateRecord<'a> {
···4848 }
4949 /// State trait tracking which required fields have been set
5050 pub trait State: sealed::Sealed {
5151- type Collection;
5251 type Repo;
5252+ type Collection;
5353 type Rkey;
5454 }
5555 /// Empty state - all required fields are unset
5656 pub struct Empty(());
5757 impl sealed::Sealed for Empty {}
5858 impl State for Empty {
5959- type Collection = Unset;
6059 type Repo = Unset;
6060+ type Collection = Unset;
6161 type Rkey = Unset;
6262 }
6363- ///State transition - sets the `collection` field to Set
6464- pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
6565- impl<S: State> sealed::Sealed for SetCollection<S> {}
6666- impl<S: State> State for SetCollection<S> {
6767- type Collection = Set<members::collection>;
6868- type Repo = S::Repo;
6969- type Rkey = S::Rkey;
7070- }
7163 ///State transition - sets the `repo` field to Set
7264 pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
7365 impl<S: State> sealed::Sealed for SetRepo<S> {}
7466 impl<S: State> State for SetRepo<S> {
7575- type Collection = S::Collection;
7667 type Repo = Set<members::repo>;
6868+ type Collection = S::Collection;
6969+ type Rkey = S::Rkey;
7070+ }
7171+ ///State transition - sets the `collection` field to Set
7272+ pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
7373+ impl<S: State> sealed::Sealed for SetCollection<S> {}
7474+ impl<S: State> State for SetCollection<S> {
7575+ type Repo = S::Repo;
7676+ type Collection = Set<members::collection>;
7777 type Rkey = S::Rkey;
7878 }
7979 ///State transition - sets the `rkey` field to Set
8080 pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
8181 impl<S: State> sealed::Sealed for SetRkey<S> {}
8282 impl<S: State> State for SetRkey<S> {
8383- type Collection = S::Collection;
8483 type Repo = S::Repo;
8484+ type Collection = S::Collection;
8585 type Rkey = Set<members::rkey>;
8686 }
8787 /// Marker types for field names
8888 #[allow(non_camel_case_types)]
8989 pub mod members {
9090+ ///Marker type for the `repo` field
9191+ pub struct repo(());
9092 ///Marker type for the `collection` field
9193 pub struct collection(());
9292- ///Marker type for the `repo` field
9393- pub struct repo(());
9494 ///Marker type for the `rkey` field
9595 pub struct rkey(());
9696 }
···233233impl<'a, S> DeleteRecordBuilder<'a, S>
234234where
235235 S: delete_record_state::State,
236236- S::Collection: delete_record_state::IsSet,
237236 S::Repo: delete_record_state::IsSet,
237237+ S::Collection: delete_record_state::IsSet,
238238 S::Rkey: delete_record_state::IsSet,
239239{
240240 /// Build the final struct
···4040 /// State trait tracking which required fields have been set
4141 pub trait State: sealed::Sealed {
4242 type Rkey;
4343- type Repo;
4443 type Collection;
4444+ type Repo;
4545 }
4646 /// Empty state - all required fields are unset
4747 pub struct Empty(());
4848 impl sealed::Sealed for Empty {}
4949 impl State for Empty {
5050 type Rkey = Unset;
5151- type Repo = Unset;
5251 type Collection = Unset;
5252+ type Repo = Unset;
5353 }
5454 ///State transition - sets the `rkey` field to Set
5555 pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
5656 impl<S: State> sealed::Sealed for SetRkey<S> {}
5757 impl<S: State> State for SetRkey<S> {
5858 type Rkey = Set<members::rkey>;
5959- type Repo = S::Repo;
6059 type Collection = S::Collection;
6161- }
6262- ///State transition - sets the `repo` field to Set
6363- pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
6464- impl<S: State> sealed::Sealed for SetRepo<S> {}
6565- impl<S: State> State for SetRepo<S> {
6666- type Rkey = S::Rkey;
6767- type Repo = Set<members::repo>;
6868- type Collection = S::Collection;
6060+ type Repo = S::Repo;
6961 }
7062 ///State transition - sets the `collection` field to Set
7163 pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
7264 impl<S: State> sealed::Sealed for SetCollection<S> {}
7365 impl<S: State> State for SetCollection<S> {
7466 type Rkey = S::Rkey;
7575- type Repo = S::Repo;
7667 type Collection = Set<members::collection>;
6868+ type Repo = S::Repo;
6969+ }
7070+ ///State transition - sets the `repo` field to Set
7171+ pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
7272+ impl<S: State> sealed::Sealed for SetRepo<S> {}
7373+ impl<S: State> State for SetRepo<S> {
7474+ type Rkey = S::Rkey;
7575+ type Collection = S::Collection;
7676+ type Repo = Set<members::repo>;
7777 }
7878 /// Marker types for field names
7979 #[allow(non_camel_case_types)]
8080 pub mod members {
8181 ///Marker type for the `rkey` field
8282 pub struct rkey(());
8383+ ///Marker type for the `collection` field
8484+ pub struct collection(());
8385 ///Marker type for the `repo` field
8486 pub struct repo(());
8585- ///Marker type for the `collection` field
8686- pub struct collection(());
8787 }
8888}
8989···205205where
206206 S: get_record_state::State,
207207 S::Rkey: get_record_state::IsSet,
208208- S::Repo: get_record_state::IsSet,
209208 S::Collection: get_record_state::IsSet,
209209+ S::Repo: get_record_state::IsSet,
210210{
211211 /// Build the final struct
212212 pub fn build(self) -> GetRecord<'a> {
···186186 }
187187 /// State trait tracking which required fields have been set
188188 pub trait State: sealed::Sealed {
189189- type RecordUri;
190189 type Cid;
190190+ type RecordUri;
191191 }
192192 /// Empty state - all required fields are unset
193193 pub struct Empty(());
194194 impl sealed::Sealed for Empty {}
195195 impl State for Empty {
196196- type RecordUri = Unset;
197196 type Cid = Unset;
198198- }
199199- ///State transition - sets the `record_uri` field to Set
200200- pub struct SetRecordUri<S: State = Empty>(PhantomData<fn() -> S>);
201201- impl<S: State> sealed::Sealed for SetRecordUri<S> {}
202202- impl<S: State> State for SetRecordUri<S> {
203203- type RecordUri = Set<members::record_uri>;
204204- type Cid = S::Cid;
197197+ type RecordUri = Unset;
205198 }
206199 ///State transition - sets the `cid` field to Set
207200 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
208201 impl<S: State> sealed::Sealed for SetCid<S> {}
209202 impl<S: State> State for SetCid<S> {
210210- type RecordUri = S::RecordUri;
211203 type Cid = Set<members::cid>;
204204+ type RecordUri = S::RecordUri;
205205+ }
206206+ ///State transition - sets the `record_uri` field to Set
207207+ pub struct SetRecordUri<S: State = Empty>(PhantomData<fn() -> S>);
208208+ impl<S: State> sealed::Sealed for SetRecordUri<S> {}
209209+ impl<S: State> State for SetRecordUri<S> {
210210+ type Cid = S::Cid;
211211+ type RecordUri = Set<members::record_uri>;
212212 }
213213 /// Marker types for field names
214214 #[allow(non_camel_case_types)]
215215 pub mod members {
216216- ///Marker type for the `record_uri` field
217217- pub struct record_uri(());
218216 ///Marker type for the `cid` field
219217 pub struct cid(());
218218+ ///Marker type for the `record_uri` field
219219+ pub struct record_uri(());
220220 }
221221}
222222···289289impl<'a, S> RecordBlobBuilder<'a, S>
290290where
291291 S: record_blob_state::State,
292292- S::RecordUri: record_blob_state::IsSet,
293292 S::Cid: record_blob_state::IsSet,
293293+ S::RecordUri: record_blob_state::IsSet,
294294{
295295 /// Build the final struct
296296 pub fn build(self) -> RecordBlob<'a> {
···4040 }
4141 /// State trait tracking which required fields have been set
4242 pub trait State: sealed::Sealed {
4343- type Repo;
4443 type Collection;
4444+ type Repo;
4545 }
4646 /// Empty state - all required fields are unset
4747 pub struct Empty(());
4848 impl sealed::Sealed for Empty {}
4949 impl State for Empty {
5050- type Repo = Unset;
5150 type Collection = Unset;
5252- }
5353- ///State transition - sets the `repo` field to Set
5454- pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
5555- impl<S: State> sealed::Sealed for SetRepo<S> {}
5656- impl<S: State> State for SetRepo<S> {
5757- type Repo = Set<members::repo>;
5858- type Collection = S::Collection;
5151+ type Repo = Unset;
5952 }
6053 ///State transition - sets the `collection` field to Set
6154 pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
6255 impl<S: State> sealed::Sealed for SetCollection<S> {}
6356 impl<S: State> State for SetCollection<S> {
6464- type Repo = S::Repo;
6557 type Collection = Set<members::collection>;
5858+ type Repo = S::Repo;
5959+ }
6060+ ///State transition - sets the `repo` field to Set
6161+ pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
6262+ impl<S: State> sealed::Sealed for SetRepo<S> {}
6363+ impl<S: State> State for SetRepo<S> {
6464+ type Collection = S::Collection;
6565+ type Repo = Set<members::repo>;
6666 }
6767 /// Marker types for field names
6868 #[allow(non_camel_case_types)]
6969 pub mod members {
7070+ ///Marker type for the `collection` field
7171+ pub struct collection(());
7072 ///Marker type for the `repo` field
7173 pub struct repo(());
7272- ///Marker type for the `collection` field
7373- pub struct collection(());
7474 }
7575}
7676···188188impl<'a, S> ListRecordsBuilder<'a, S>
189189where
190190 S: list_records_state::State,
191191- S::Repo: list_records_state::IsSet,
192191 S::Collection: list_records_state::IsSet,
192192+ S::Repo: list_records_state::IsSet,
193193{
194194 /// Build the final struct
195195 pub fn build(self) -> ListRecords<'a> {
···278278 }
279279 /// State trait tracking which required fields have been set
280280 pub trait State: sealed::Sealed {
281281- type Value;
282281 type Uri;
283282 type Cid;
283283+ type Value;
284284 }
285285 /// Empty state - all required fields are unset
286286 pub struct Empty(());
287287 impl sealed::Sealed for Empty {}
288288 impl State for Empty {
289289- type Value = Unset;
290289 type Uri = Unset;
291290 type Cid = Unset;
292292- }
293293- ///State transition - sets the `value` field to Set
294294- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
295295- impl<S: State> sealed::Sealed for SetValue<S> {}
296296- impl<S: State> State for SetValue<S> {
297297- type Value = Set<members::value>;
298298- type Uri = S::Uri;
299299- type Cid = S::Cid;
291291+ type Value = Unset;
300292 }
301293 ///State transition - sets the `uri` field to Set
302294 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
303295 impl<S: State> sealed::Sealed for SetUri<S> {}
304296 impl<S: State> State for SetUri<S> {
305305- type Value = S::Value;
306297 type Uri = Set<members::uri>;
307298 type Cid = S::Cid;
299299+ type Value = S::Value;
308300 }
309301 ///State transition - sets the `cid` field to Set
310302 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
311303 impl<S: State> sealed::Sealed for SetCid<S> {}
312304 impl<S: State> State for SetCid<S> {
313313- type Value = S::Value;
314305 type Uri = S::Uri;
315306 type Cid = Set<members::cid>;
307307+ type Value = S::Value;
308308+ }
309309+ ///State transition - sets the `value` field to Set
310310+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
311311+ impl<S: State> sealed::Sealed for SetValue<S> {}
312312+ impl<S: State> State for SetValue<S> {
313313+ type Uri = S::Uri;
314314+ type Cid = S::Cid;
315315+ type Value = Set<members::value>;
316316 }
317317 /// Marker types for field names
318318 #[allow(non_camel_case_types)]
319319 pub mod members {
320320- ///Marker type for the `value` field
321321- pub struct value(());
322320 ///Marker type for the `uri` field
323321 pub struct uri(());
324322 ///Marker type for the `cid` field
325323 pub struct cid(());
324324+ ///Marker type for the `value` field
325325+ pub struct value(());
326326 }
327327}
328328···415415impl<'a, S> RecordBuilder<'a, S>
416416where
417417 S: record_state::State,
418418- S::Value: record_state::IsSet,
419418 S::Uri: record_state::IsSet,
420419 S::Cid: record_state::IsSet,
420420+ S::Value: record_state::IsSet,
421421{
422422 /// Build the final struct
423423 pub fn build(self) -> Record<'a> {
···5454 }
5555 /// State trait tracking which required fields have been set
5656 pub trait State: sealed::Sealed {
5757- type Repo;
5857 type Record;
5858+ type Repo;
5959 type Collection;
6060 type Rkey;
6161 }
···6363 pub struct Empty(());
6464 impl sealed::Sealed for Empty {}
6565 impl State for Empty {
6666- type Repo = Unset;
6766 type Record = Unset;
6767+ type Repo = Unset;
6868 type Collection = Unset;
6969 type Rkey = Unset;
7070 }
7171- ///State transition - sets the `repo` field to Set
7272- pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
7373- impl<S: State> sealed::Sealed for SetRepo<S> {}
7474- impl<S: State> State for SetRepo<S> {
7575- type Repo = Set<members::repo>;
7676- type Record = S::Record;
7777- type Collection = S::Collection;
7878- type Rkey = S::Rkey;
7979- }
8071 ///State transition - sets the `record` field to Set
8172 pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
8273 impl<S: State> sealed::Sealed for SetRecord<S> {}
8374 impl<S: State> State for SetRecord<S> {
8484- type Repo = S::Repo;
8575 type Record = Set<members::record>;
7676+ type Repo = S::Repo;
7777+ type Collection = S::Collection;
7878+ type Rkey = S::Rkey;
7979+ }
8080+ ///State transition - sets the `repo` field to Set
8181+ pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
8282+ impl<S: State> sealed::Sealed for SetRepo<S> {}
8383+ impl<S: State> State for SetRepo<S> {
8484+ type Record = S::Record;
8585+ type Repo = Set<members::repo>;
8686 type Collection = S::Collection;
8787 type Rkey = S::Rkey;
8888 }
···9090 pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
9191 impl<S: State> sealed::Sealed for SetCollection<S> {}
9292 impl<S: State> State for SetCollection<S> {
9393- type Repo = S::Repo;
9493 type Record = S::Record;
9494+ type Repo = S::Repo;
9595 type Collection = Set<members::collection>;
9696 type Rkey = S::Rkey;
9797 }
···9999 pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
100100 impl<S: State> sealed::Sealed for SetRkey<S> {}
101101 impl<S: State> State for SetRkey<S> {
102102- type Repo = S::Repo;
103102 type Record = S::Record;
103103+ type Repo = S::Repo;
104104 type Collection = S::Collection;
105105 type Rkey = Set<members::rkey>;
106106 }
107107 /// Marker types for field names
108108 #[allow(non_camel_case_types)]
109109 pub mod members {
110110+ ///Marker type for the `record` field
111111+ pub struct record(());
110112 ///Marker type for the `repo` field
111113 pub struct repo(());
112112- ///Marker type for the `record` field
113113- pub struct record(());
114114 ///Marker type for the `collection` field
115115 pub struct collection(());
116116 ///Marker type for the `rkey` field
···289289impl<'a, S> PutRecordBuilder<'a, S>
290290where
291291 S: put_record_state::State,
292292- S::Repo: put_record_state::IsSet,
293292 S::Record: put_record_state::IsSet,
293293+ S::Repo: put_record_state::IsSet,
294294 S::Collection: put_record_state::IsSet,
295295 S::Rkey: put_record_state::IsSet,
296296{
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Cid;
3736 type Uri;
3737+ type Cid;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Cid = Unset;
4443 type Uri = Unset;
4545- }
4646- ///State transition - sets the `cid` field to Set
4747- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetCid<S> {}
4949- impl<S: State> State for SetCid<S> {
5050- type Cid = Set<members::cid>;
5151- type Uri = S::Uri;
4444+ type Cid = Unset;
5245 }
5346 ///State transition - sets the `uri` field to Set
5447 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetUri<S> {}
5649 impl<S: State> State for SetUri<S> {
5757- type Cid = S::Cid;
5850 type Uri = Set<members::uri>;
5151+ type Cid = S::Cid;
5252+ }
5353+ ///State transition - sets the `cid` field to Set
5454+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetCid<S> {}
5656+ impl<S: State> State for SetCid<S> {
5757+ type Uri = S::Uri;
5858+ type Cid = Set<members::cid>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `cid` field
6464- pub struct cid(());
6563 ///Marker type for the `uri` field
6664 pub struct uri(());
6565+ ///Marker type for the `cid` field
6666+ pub struct cid(());
6767 }
6868}
6969···136136impl<'a, S> StrongRefBuilder<'a, S>
137137where
138138 S: strong_ref_state::State,
139139- S::Cid: strong_ref_state::IsSet,
140139 S::Uri: strong_ref_state::IsSet,
140140+ S::Cid: strong_ref_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> StrongRef<'a> {
+84-84
crates/weaver-api/src/com_atproto/server.rs
···6666 }
6767 /// State trait tracking which required fields have been set
6868 pub trait State: sealed::Sealed {
6969+ type Available;
7070+ type CreatedAt;
6971 type Code;
7070- type Disabled;
7172 type Uses;
7272- type CreatedAt;
7373- type Available;
7373+ type Disabled;
7474+ type CreatedBy;
7475 type ForAccount;
7575- type CreatedBy;
7676 }
7777 /// Empty state - all required fields are unset
7878 pub struct Empty(());
7979 impl sealed::Sealed for Empty {}
8080 impl State for Empty {
8181+ type Available = Unset;
8282+ type CreatedAt = Unset;
8183 type Code = Unset;
8484+ type Uses = Unset;
8285 type Disabled = Unset;
8383- type Uses = Unset;
8484- type CreatedAt = Unset;
8585- type Available = Unset;
8686+ type CreatedBy = Unset;
8687 type ForAccount = Unset;
8787- type CreatedBy = Unset;
8888+ }
8989+ ///State transition - sets the `available` field to Set
9090+ pub struct SetAvailable<S: State = Empty>(PhantomData<fn() -> S>);
9191+ impl<S: State> sealed::Sealed for SetAvailable<S> {}
9292+ impl<S: State> State for SetAvailable<S> {
9393+ type Available = Set<members::available>;
9494+ type CreatedAt = S::CreatedAt;
9595+ type Code = S::Code;
9696+ type Uses = S::Uses;
9797+ type Disabled = S::Disabled;
9898+ type CreatedBy = S::CreatedBy;
9999+ type ForAccount = S::ForAccount;
100100+ }
101101+ ///State transition - sets the `created_at` field to Set
102102+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
103103+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
104104+ impl<S: State> State for SetCreatedAt<S> {
105105+ type Available = S::Available;
106106+ type CreatedAt = Set<members::created_at>;
107107+ type Code = S::Code;
108108+ type Uses = S::Uses;
109109+ type Disabled = S::Disabled;
110110+ type CreatedBy = S::CreatedBy;
111111+ type ForAccount = S::ForAccount;
88112 }
89113 ///State transition - sets the `code` field to Set
90114 pub struct SetCode<S: State = Empty>(PhantomData<fn() -> S>);
91115 impl<S: State> sealed::Sealed for SetCode<S> {}
92116 impl<S: State> State for SetCode<S> {
117117+ type Available = S::Available;
118118+ type CreatedAt = S::CreatedAt;
93119 type Code = Set<members::code>;
9494- type Disabled = S::Disabled;
95120 type Uses = S::Uses;
9696- type CreatedAt = S::CreatedAt;
9797- type Available = S::Available;
9898- type ForAccount = S::ForAccount;
121121+ type Disabled = S::Disabled;
99122 type CreatedBy = S::CreatedBy;
100100- }
101101- ///State transition - sets the `disabled` field to Set
102102- pub struct SetDisabled<S: State = Empty>(PhantomData<fn() -> S>);
103103- impl<S: State> sealed::Sealed for SetDisabled<S> {}
104104- impl<S: State> State for SetDisabled<S> {
105105- type Code = S::Code;
106106- type Disabled = Set<members::disabled>;
107107- type Uses = S::Uses;
108108- type CreatedAt = S::CreatedAt;
109109- type Available = S::Available;
110123 type ForAccount = S::ForAccount;
111111- type CreatedBy = S::CreatedBy;
112124 }
113125 ///State transition - sets the `uses` field to Set
114126 pub struct SetUses<S: State = Empty>(PhantomData<fn() -> S>);
115127 impl<S: State> sealed::Sealed for SetUses<S> {}
116128 impl<S: State> State for SetUses<S> {
129129+ type Available = S::Available;
130130+ type CreatedAt = S::CreatedAt;
117131 type Code = S::Code;
118118- type Disabled = S::Disabled;
119132 type Uses = Set<members::uses>;
120120- type CreatedAt = S::CreatedAt;
121121- type Available = S::Available;
133133+ type Disabled = S::Disabled;
134134+ type CreatedBy = S::CreatedBy;
122135 type ForAccount = S::ForAccount;
123123- type CreatedBy = S::CreatedBy;
124136 }
125125- ///State transition - sets the `created_at` field to Set
126126- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
127127- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
128128- impl<S: State> State for SetCreatedAt<S> {
137137+ ///State transition - sets the `disabled` field to Set
138138+ pub struct SetDisabled<S: State = Empty>(PhantomData<fn() -> S>);
139139+ impl<S: State> sealed::Sealed for SetDisabled<S> {}
140140+ impl<S: State> State for SetDisabled<S> {
141141+ type Available = S::Available;
142142+ type CreatedAt = S::CreatedAt;
129143 type Code = S::Code;
130130- type Disabled = S::Disabled;
131144 type Uses = S::Uses;
132132- type CreatedAt = Set<members::created_at>;
133133- type Available = S::Available;
145145+ type Disabled = Set<members::disabled>;
146146+ type CreatedBy = S::CreatedBy;
134147 type ForAccount = S::ForAccount;
135135- type CreatedBy = S::CreatedBy;
136148 }
137137- ///State transition - sets the `available` field to Set
138138- pub struct SetAvailable<S: State = Empty>(PhantomData<fn() -> S>);
139139- impl<S: State> sealed::Sealed for SetAvailable<S> {}
140140- impl<S: State> State for SetAvailable<S> {
149149+ ///State transition - sets the `created_by` field to Set
150150+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
151151+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
152152+ impl<S: State> State for SetCreatedBy<S> {
153153+ type Available = S::Available;
154154+ type CreatedAt = S::CreatedAt;
141155 type Code = S::Code;
156156+ type Uses = S::Uses;
142157 type Disabled = S::Disabled;
143143- type Uses = S::Uses;
144144- type CreatedAt = S::CreatedAt;
145145- type Available = Set<members::available>;
158158+ type CreatedBy = Set<members::created_by>;
146159 type ForAccount = S::ForAccount;
147147- type CreatedBy = S::CreatedBy;
148160 }
149161 ///State transition - sets the `for_account` field to Set
150162 pub struct SetForAccount<S: State = Empty>(PhantomData<fn() -> S>);
151163 impl<S: State> sealed::Sealed for SetForAccount<S> {}
152164 impl<S: State> State for SetForAccount<S> {
153153- type Code = S::Code;
154154- type Disabled = S::Disabled;
155155- type Uses = S::Uses;
156156- type CreatedAt = S::CreatedAt;
157165 type Available = S::Available;
158158- type ForAccount = Set<members::for_account>;
159159- type CreatedBy = S::CreatedBy;
160160- }
161161- ///State transition - sets the `created_by` field to Set
162162- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
163163- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
164164- impl<S: State> State for SetCreatedBy<S> {
166166+ type CreatedAt = S::CreatedAt;
165167 type Code = S::Code;
168168+ type Uses = S::Uses;
166169 type Disabled = S::Disabled;
167167- type Uses = S::Uses;
168168- type CreatedAt = S::CreatedAt;
169169- type Available = S::Available;
170170- type ForAccount = S::ForAccount;
171171- type CreatedBy = Set<members::created_by>;
170170+ type CreatedBy = S::CreatedBy;
171171+ type ForAccount = Set<members::for_account>;
172172 }
173173 /// Marker types for field names
174174 #[allow(non_camel_case_types)]
175175 pub mod members {
176176+ ///Marker type for the `available` field
177177+ pub struct available(());
178178+ ///Marker type for the `created_at` field
179179+ pub struct created_at(());
176180 ///Marker type for the `code` field
177181 pub struct code(());
178178- ///Marker type for the `disabled` field
179179- pub struct disabled(());
180182 ///Marker type for the `uses` field
181183 pub struct uses(());
182182- ///Marker type for the `created_at` field
183183- pub struct created_at(());
184184- ///Marker type for the `available` field
185185- pub struct available(());
186186- ///Marker type for the `for_account` field
187187- pub struct for_account(());
184184+ ///Marker type for the `disabled` field
185185+ pub struct disabled(());
188186 ///Marker type for the `created_by` field
189187 pub struct created_by(());
188188+ ///Marker type for the `for_account` field
189189+ pub struct for_account(());
190190 }
191191}
192192···359359impl<'a, S> InviteCodeBuilder<'a, S>
360360where
361361 S: invite_code_state::State,
362362+ S::Available: invite_code_state::IsSet,
363363+ S::CreatedAt: invite_code_state::IsSet,
362364 S::Code: invite_code_state::IsSet,
363363- S::Disabled: invite_code_state::IsSet,
364365 S::Uses: invite_code_state::IsSet,
365365- S::CreatedAt: invite_code_state::IsSet,
366366- S::Available: invite_code_state::IsSet,
367367- S::ForAccount: invite_code_state::IsSet,
366366+ S::Disabled: invite_code_state::IsSet,
368367 S::CreatedBy: invite_code_state::IsSet,
368368+ S::ForAccount: invite_code_state::IsSet,
369369{
370370 /// Build the final struct
371371 pub fn build(self) -> InviteCode<'a> {
···638638 }
639639 /// State trait tracking which required fields have been set
640640 pub trait State: sealed::Sealed {
641641- type UsedAt;
642641 type UsedBy;
642642+ type UsedAt;
643643 }
644644 /// Empty state - all required fields are unset
645645 pub struct Empty(());
646646 impl sealed::Sealed for Empty {}
647647 impl State for Empty {
648648- type UsedAt = Unset;
649648 type UsedBy = Unset;
650650- }
651651- ///State transition - sets the `used_at` field to Set
652652- pub struct SetUsedAt<S: State = Empty>(PhantomData<fn() -> S>);
653653- impl<S: State> sealed::Sealed for SetUsedAt<S> {}
654654- impl<S: State> State for SetUsedAt<S> {
655655- type UsedAt = Set<members::used_at>;
656656- type UsedBy = S::UsedBy;
649649+ type UsedAt = Unset;
657650 }
658651 ///State transition - sets the `used_by` field to Set
659652 pub struct SetUsedBy<S: State = Empty>(PhantomData<fn() -> S>);
660653 impl<S: State> sealed::Sealed for SetUsedBy<S> {}
661654 impl<S: State> State for SetUsedBy<S> {
655655+ type UsedBy = Set<members::used_by>;
662656 type UsedAt = S::UsedAt;
663663- type UsedBy = Set<members::used_by>;
657657+ }
658658+ ///State transition - sets the `used_at` field to Set
659659+ pub struct SetUsedAt<S: State = Empty>(PhantomData<fn() -> S>);
660660+ impl<S: State> sealed::Sealed for SetUsedAt<S> {}
661661+ impl<S: State> State for SetUsedAt<S> {
662662+ type UsedBy = S::UsedBy;
663663+ type UsedAt = Set<members::used_at>;
664664 }
665665 /// Marker types for field names
666666 #[allow(non_camel_case_types)]
667667 pub mod members {
668668+ ///Marker type for the `used_by` field
669669+ pub struct used_by(());
668670 ///Marker type for the `used_at` field
669671 pub struct used_at(());
670670- ///Marker type for the `used_by` field
671671- pub struct used_by(());
672672 }
673673}
674674···741741impl<'a, S> InviteCodeUseBuilder<'a, S>
742742where
743743 S: invite_code_use_state::State,
744744- S::UsedAt: invite_code_use_state::IsSet,
745744 S::UsedBy: invite_code_use_state::IsSet,
745745+ S::UsedAt: invite_code_use_state::IsSet,
746746{
747747 /// Build the final struct
748748 pub fn build(self) -> InviteCodeUse<'a> {
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type Password;
4039 type Name;
4040+ type Password;
4141 type CreatedAt;
4242 }
4343 /// Empty state - all required fields are unset
4444 pub struct Empty(());
4545 impl sealed::Sealed for Empty {}
4646 impl State for Empty {
4747- type Password = Unset;
4847 type Name = Unset;
4848+ type Password = Unset;
4949 type CreatedAt = Unset;
5050 }
5151- ///State transition - sets the `password` field to Set
5252- pub struct SetPassword<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetPassword<S> {}
5454- impl<S: State> State for SetPassword<S> {
5555- type Password = Set<members::password>;
5656- type Name = S::Name;
5757- type CreatedAt = S::CreatedAt;
5858- }
5951 ///State transition - sets the `name` field to Set
6052 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
6153 impl<S: State> sealed::Sealed for SetName<S> {}
6254 impl<S: State> State for SetName<S> {
6363- type Password = S::Password;
6455 type Name = Set<members::name>;
5656+ type Password = S::Password;
5757+ type CreatedAt = S::CreatedAt;
5858+ }
5959+ ///State transition - sets the `password` field to Set
6060+ pub struct SetPassword<S: State = Empty>(PhantomData<fn() -> S>);
6161+ impl<S: State> sealed::Sealed for SetPassword<S> {}
6262+ impl<S: State> State for SetPassword<S> {
6363+ type Name = S::Name;
6464+ type Password = Set<members::password>;
6565 type CreatedAt = S::CreatedAt;
6666 }
6767 ///State transition - sets the `created_at` field to Set
6868 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6969 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
7070 impl<S: State> State for SetCreatedAt<S> {
7171- type Password = S::Password;
7271 type Name = S::Name;
7272+ type Password = S::Password;
7373 type CreatedAt = Set<members::created_at>;
7474 }
7575 /// Marker types for field names
7676 #[allow(non_camel_case_types)]
7777 pub mod members {
7878+ ///Marker type for the `name` field
7979+ pub struct name(());
7880 ///Marker type for the `password` field
7981 pub struct password(());
8080- ///Marker type for the `name` field
8181- pub struct name(());
8282 ///Marker type for the `created_at` field
8383 pub struct created_at(());
8484 }
···187187impl<'a, S> AppPasswordBuilder<'a, S>
188188where
189189 S: app_password_state::State,
190190- S::Password: app_password_state::IsSet,
191190 S::Name: app_password_state::IsSet,
191191+ S::Password: app_password_state::IsSet,
192192 S::CreatedAt: app_password_state::IsSet,
193193{
194194 /// Build the final struct
···361361 }
362362 /// State trait tracking which required fields have been set
363363 pub trait State: sealed::Sealed {
364364- type CodeCount;
365364 type UseCount;
365365+ type CodeCount;
366366 }
367367 /// Empty state - all required fields are unset
368368 pub struct Empty(());
369369 impl sealed::Sealed for Empty {}
370370 impl State for Empty {
371371- type CodeCount = Unset;
372371 type UseCount = Unset;
373373- }
374374- ///State transition - sets the `code_count` field to Set
375375- pub struct SetCodeCount<S: State = Empty>(PhantomData<fn() -> S>);
376376- impl<S: State> sealed::Sealed for SetCodeCount<S> {}
377377- impl<S: State> State for SetCodeCount<S> {
378378- type CodeCount = Set<members::code_count>;
379379- type UseCount = S::UseCount;
372372+ type CodeCount = Unset;
380373 }
381374 ///State transition - sets the `use_count` field to Set
382375 pub struct SetUseCount<S: State = Empty>(PhantomData<fn() -> S>);
383376 impl<S: State> sealed::Sealed for SetUseCount<S> {}
384377 impl<S: State> State for SetUseCount<S> {
385385- type CodeCount = S::CodeCount;
386378 type UseCount = Set<members::use_count>;
379379+ type CodeCount = S::CodeCount;
380380+ }
381381+ ///State transition - sets the `code_count` field to Set
382382+ pub struct SetCodeCount<S: State = Empty>(PhantomData<fn() -> S>);
383383+ impl<S: State> sealed::Sealed for SetCodeCount<S> {}
384384+ impl<S: State> State for SetCodeCount<S> {
385385+ type UseCount = S::UseCount;
386386+ type CodeCount = Set<members::code_count>;
387387 }
388388 /// Marker types for field names
389389 #[allow(non_camel_case_types)]
390390 pub mod members {
391391- ///Marker type for the `code_count` field
392392- pub struct code_count(());
393391 ///Marker type for the `use_count` field
394392 pub struct use_count(());
393393+ ///Marker type for the `code_count` field
394394+ pub struct code_count(());
395395 }
396396}
397397···484484impl<'a, S> CreateInviteCodesBuilder<'a, S>
485485where
486486 S: create_invite_codes_state::State,
487487- S::CodeCount: create_invite_codes_state::IsSet,
488487 S::UseCount: create_invite_codes_state::IsSet,
488488+ S::CodeCount: create_invite_codes_state::IsSet,
489489{
490490 /// Build the final struct
491491 pub fn build(self) -> CreateInviteCodes<'a> {
···3535 }
3636 /// State trait tracking which required fields have been set
3737 pub trait State: sealed::Sealed {
3838+ type Did;
3839 type Password;
3940 type Token;
4040- type Did;
4141 }
4242 /// Empty state - all required fields are unset
4343 pub struct Empty(());
4444 impl sealed::Sealed for Empty {}
4545 impl State for Empty {
4646+ type Did = Unset;
4647 type Password = Unset;
4748 type Token = Unset;
4848- type Did = Unset;
4949+ }
5050+ ///State transition - sets the `did` field to Set
5151+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
5252+ impl<S: State> sealed::Sealed for SetDid<S> {}
5353+ impl<S: State> State for SetDid<S> {
5454+ type Did = Set<members::did>;
5555+ type Password = S::Password;
5656+ type Token = S::Token;
4957 }
5058 ///State transition - sets the `password` field to Set
5159 pub struct SetPassword<S: State = Empty>(PhantomData<fn() -> S>);
5260 impl<S: State> sealed::Sealed for SetPassword<S> {}
5361 impl<S: State> State for SetPassword<S> {
6262+ type Did = S::Did;
5463 type Password = Set<members::password>;
5564 type Token = S::Token;
5656- type Did = S::Did;
5765 }
5866 ///State transition - sets the `token` field to Set
5967 pub struct SetToken<S: State = Empty>(PhantomData<fn() -> S>);
6068 impl<S: State> sealed::Sealed for SetToken<S> {}
6169 impl<S: State> State for SetToken<S> {
6262- type Password = S::Password;
6363- type Token = Set<members::token>;
6470 type Did = S::Did;
6565- }
6666- ///State transition - sets the `did` field to Set
6767- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
6868- impl<S: State> sealed::Sealed for SetDid<S> {}
6969- impl<S: State> State for SetDid<S> {
7071 type Password = S::Password;
7171- type Token = S::Token;
7272- type Did = Set<members::did>;
7272+ type Token = Set<members::token>;
7373 }
7474 /// Marker types for field names
7575 #[allow(non_camel_case_types)]
7676 pub mod members {
7777+ ///Marker type for the `did` field
7878+ pub struct did(());
7779 ///Marker type for the `password` field
7880 pub struct password(());
7981 ///Marker type for the `token` field
8082 pub struct token(());
8181- ///Marker type for the `did` field
8282- pub struct did(());
8383 }
8484}
8585···172172impl<'a, S> DeleteAccountBuilder<'a, S>
173173where
174174 S: delete_account_state::State,
175175+ S::Did: delete_account_state::IsSet,
175176 S::Password: delete_account_state::IsSet,
176177 S::Token: delete_account_state::IsSet,
177177- S::Did: delete_account_state::IsSet,
178178{
179179 /// Build the final struct
180180 pub fn build(self) -> DeleteAccount<'a> {
···3232 }
3333 /// State trait tracking which required fields have been set
3434 pub trait State: sealed::Sealed {
3535- type Cid;
3635 type Did;
3636+ type Cid;
3737 }
3838 /// Empty state - all required fields are unset
3939 pub struct Empty(());
4040 impl sealed::Sealed for Empty {}
4141 impl State for Empty {
4242- type Cid = Unset;
4342 type Did = Unset;
4444- }
4545- ///State transition - sets the `cid` field to Set
4646- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
4747- impl<S: State> sealed::Sealed for SetCid<S> {}
4848- impl<S: State> State for SetCid<S> {
4949- type Cid = Set<members::cid>;
5050- type Did = S::Did;
4343+ type Cid = Unset;
5144 }
5245 ///State transition - sets the `did` field to Set
5346 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
5447 impl<S: State> sealed::Sealed for SetDid<S> {}
5548 impl<S: State> State for SetDid<S> {
5656- type Cid = S::Cid;
5749 type Did = Set<members::did>;
5050+ type Cid = S::Cid;
5151+ }
5252+ ///State transition - sets the `cid` field to Set
5353+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetCid<S> {}
5555+ impl<S: State> State for SetCid<S> {
5656+ type Did = S::Did;
5757+ type Cid = Set<members::cid>;
5858 }
5959 /// Marker types for field names
6060 #[allow(non_camel_case_types)]
6161 pub mod members {
6262- ///Marker type for the `cid` field
6363- pub struct cid(());
6462 ///Marker type for the `did` field
6563 pub struct did(());
6464+ ///Marker type for the `cid` field
6565+ pub struct cid(());
6666 }
6767}
6868···135135impl<'a, S> GetBlobBuilder<'a, S>
136136where
137137 S: get_blob_state::State,
138138- S::Cid: get_blob_state::IsSet,
139138 S::Did: get_blob_state::IsSet,
139139+ S::Cid: get_blob_state::IsSet,
140140{
141141 /// Build the final struct
142142 pub fn build(self) -> GetBlob<'a> {
···3232 }
3333 /// State trait tracking which required fields have been set
3434 pub trait State: sealed::Sealed {
3535- type Did;
3635 type Cids;
3636+ type Did;
3737 }
3838 /// Empty state - all required fields are unset
3939 pub struct Empty(());
4040 impl sealed::Sealed for Empty {}
4141 impl State for Empty {
4242- type Did = Unset;
4342 type Cids = Unset;
4444- }
4545- ///State transition - sets the `did` field to Set
4646- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
4747- impl<S: State> sealed::Sealed for SetDid<S> {}
4848- impl<S: State> State for SetDid<S> {
4949- type Did = Set<members::did>;
5050- type Cids = S::Cids;
4343+ type Did = Unset;
5144 }
5245 ///State transition - sets the `cids` field to Set
5346 pub struct SetCids<S: State = Empty>(PhantomData<fn() -> S>);
5447 impl<S: State> sealed::Sealed for SetCids<S> {}
5548 impl<S: State> State for SetCids<S> {
5656- type Did = S::Did;
5749 type Cids = Set<members::cids>;
5050+ type Did = S::Did;
5151+ }
5252+ ///State transition - sets the `did` field to Set
5353+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetDid<S> {}
5555+ impl<S: State> State for SetDid<S> {
5656+ type Cids = S::Cids;
5757+ type Did = Set<members::did>;
5858 }
5959 /// Marker types for field names
6060 #[allow(non_camel_case_types)]
6161 pub mod members {
6262- ///Marker type for the `did` field
6363- pub struct did(());
6462 ///Marker type for the `cids` field
6563 pub struct cids(());
6464+ ///Marker type for the `did` field
6565+ pub struct did(());
6666 }
6767}
6868···135135impl<'a, S> GetBlocksBuilder<'a, S>
136136where
137137 S: get_blocks_state::State,
138138- S::Did: get_blocks_state::IsSet,
139138 S::Cids: get_blocks_state::IsSet,
139139+ S::Did: get_blocks_state::IsSet,
140140{
141141 /// Build the final struct
142142 pub fn build(self) -> GetBlocks<'a> {
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type Rkey;
4039 type Collection;
4140 type Did;
4141+ type Rkey;
4242 }
4343 /// Empty state - all required fields are unset
4444 pub struct Empty(());
4545 impl sealed::Sealed for Empty {}
4646 impl State for Empty {
4747- type Rkey = Unset;
4847 type Collection = Unset;
4948 type Did = Unset;
5050- }
5151- ///State transition - sets the `rkey` field to Set
5252- pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetRkey<S> {}
5454- impl<S: State> State for SetRkey<S> {
5555- type Rkey = Set<members::rkey>;
5656- type Collection = S::Collection;
5757- type Did = S::Did;
4949+ type Rkey = Unset;
5850 }
5951 ///State transition - sets the `collection` field to Set
6052 pub struct SetCollection<S: State = Empty>(PhantomData<fn() -> S>);
6153 impl<S: State> sealed::Sealed for SetCollection<S> {}
6254 impl<S: State> State for SetCollection<S> {
6363- type Rkey = S::Rkey;
6455 type Collection = Set<members::collection>;
6556 type Did = S::Did;
5757+ type Rkey = S::Rkey;
6658 }
6759 ///State transition - sets the `did` field to Set
6860 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
6961 impl<S: State> sealed::Sealed for SetDid<S> {}
7062 impl<S: State> State for SetDid<S> {
7171- type Rkey = S::Rkey;
7263 type Collection = S::Collection;
7364 type Did = Set<members::did>;
6565+ type Rkey = S::Rkey;
6666+ }
6767+ ///State transition - sets the `rkey` field to Set
6868+ pub struct SetRkey<S: State = Empty>(PhantomData<fn() -> S>);
6969+ impl<S: State> sealed::Sealed for SetRkey<S> {}
7070+ impl<S: State> State for SetRkey<S> {
7171+ type Collection = S::Collection;
7272+ type Did = S::Did;
7373+ type Rkey = Set<members::rkey>;
7474 }
7575 /// Marker types for field names
7676 #[allow(non_camel_case_types)]
7777 pub mod members {
7878- ///Marker type for the `rkey` field
7979- pub struct rkey(());
8078 ///Marker type for the `collection` field
8179 pub struct collection(());
8280 ///Marker type for the `did` field
8381 pub struct did(());
8282+ ///Marker type for the `rkey` field
8383+ pub struct rkey(());
8484 }
8585}
8686···181181impl<'a, S> GetRecordBuilder<'a, S>
182182where
183183 S: get_record_state::State,
184184- S::Rkey: get_record_state::IsSet,
185184 S::Collection: get_record_state::IsSet,
186185 S::Did: get_record_state::IsSet,
186186+ S::Rkey: get_record_state::IsSet,
187187{
188188 /// Build the final struct
189189 pub fn build(self) -> GetRecord<'a> {
···195195 /// State trait tracking which required fields have been set
196196 pub trait State: sealed::Sealed {
197197 type Did;
198198- type Head;
199198 type Rev;
199199+ type Head;
200200 }
201201 /// Empty state - all required fields are unset
202202 pub struct Empty(());
203203 impl sealed::Sealed for Empty {}
204204 impl State for Empty {
205205 type Did = Unset;
206206- type Head = Unset;
207206 type Rev = Unset;
207207+ type Head = Unset;
208208 }
209209 ///State transition - sets the `did` field to Set
210210 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
211211 impl<S: State> sealed::Sealed for SetDid<S> {}
212212 impl<S: State> State for SetDid<S> {
213213 type Did = Set<members::did>;
214214- type Head = S::Head;
215214 type Rev = S::Rev;
216216- }
217217- ///State transition - sets the `head` field to Set
218218- pub struct SetHead<S: State = Empty>(PhantomData<fn() -> S>);
219219- impl<S: State> sealed::Sealed for SetHead<S> {}
220220- impl<S: State> State for SetHead<S> {
221221- type Did = S::Did;
222222- type Head = Set<members::head>;
223223- type Rev = S::Rev;
215215+ type Head = S::Head;
224216 }
225217 ///State transition - sets the `rev` field to Set
226218 pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
227219 impl<S: State> sealed::Sealed for SetRev<S> {}
228220 impl<S: State> State for SetRev<S> {
229221 type Did = S::Did;
230230- type Head = S::Head;
231222 type Rev = Set<members::rev>;
223223+ type Head = S::Head;
224224+ }
225225+ ///State transition - sets the `head` field to Set
226226+ pub struct SetHead<S: State = Empty>(PhantomData<fn() -> S>);
227227+ impl<S: State> sealed::Sealed for SetHead<S> {}
228228+ impl<S: State> State for SetHead<S> {
229229+ type Did = S::Did;
230230+ type Rev = S::Rev;
231231+ type Head = Set<members::head>;
232232 }
233233 /// Marker types for field names
234234 #[allow(non_camel_case_types)]
235235 pub mod members {
236236 ///Marker type for the `did` field
237237 pub struct did(());
238238+ ///Marker type for the `rev` field
239239+ pub struct rev(());
238240 ///Marker type for the `head` field
239241 pub struct head(());
240240- ///Marker type for the `rev` field
241241- pub struct rev(());
242242 }
243243}
244244···360360where
361361 S: repo_state::State,
362362 S::Did: repo_state::IsSet,
363363- S::Head: repo_state::IsSet,
364363 S::Rev: repo_state::IsSet,
364364+ S::Head: repo_state::IsSet,
365365{
366366 /// Build the final struct
367367 pub fn build(self) -> Repo<'a> {
···4242 pub trait State: sealed::Sealed {
4343 type Did;
4444 type Active;
4545- type Seq;
4645 type Time;
4646+ type Seq;
4747 }
4848 /// Empty state - all required fields are unset
4949 pub struct Empty(());
···5151 impl State for Empty {
5252 type Did = Unset;
5353 type Active = Unset;
5454- type Seq = Unset;
5554 type Time = Unset;
5555+ type Seq = Unset;
5656 }
5757 ///State transition - sets the `did` field to Set
5858 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
···6060 impl<S: State> State for SetDid<S> {
6161 type Did = Set<members::did>;
6262 type Active = S::Active;
6363- type Seq = S::Seq;
6463 type Time = S::Time;
6464+ type Seq = S::Seq;
6565 }
6666 ///State transition - sets the `active` field to Set
6767 pub struct SetActive<S: State = Empty>(PhantomData<fn() -> S>);
···6969 impl<S: State> State for SetActive<S> {
7070 type Did = S::Did;
7171 type Active = Set<members::active>;
7272- type Seq = S::Seq;
7373- type Time = S::Time;
7474- }
7575- ///State transition - sets the `seq` field to Set
7676- pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
7777- impl<S: State> sealed::Sealed for SetSeq<S> {}
7878- impl<S: State> State for SetSeq<S> {
7979- type Did = S::Did;
8080- type Active = S::Active;
8181- type Seq = Set<members::seq>;
8272 type Time = S::Time;
7373+ type Seq = S::Seq;
8374 }
8475 ///State transition - sets the `time` field to Set
8576 pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
···8778 impl<S: State> State for SetTime<S> {
8879 type Did = S::Did;
8980 type Active = S::Active;
9090- type Seq = S::Seq;
9181 type Time = Set<members::time>;
8282+ type Seq = S::Seq;
8383+ }
8484+ ///State transition - sets the `seq` field to Set
8585+ pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
8686+ impl<S: State> sealed::Sealed for SetSeq<S> {}
8787+ impl<S: State> State for SetSeq<S> {
8888+ type Did = S::Did;
8989+ type Active = S::Active;
9090+ type Time = S::Time;
9191+ type Seq = Set<members::seq>;
9292 }
9393 /// Marker types for field names
9494 #[allow(non_camel_case_types)]
···9797 pub struct did(());
9898 ///Marker type for the `active` field
9999 pub struct active(());
100100+ ///Marker type for the `time` field
101101+ pub struct time(());
100102 ///Marker type for the `seq` field
101103 pub struct seq(());
102102- ///Marker type for the `time` field
103103- pub struct time(());
104104 }
105105}
106106···229229 S: account_state::State,
230230 S::Did: account_state::IsSet,
231231 S::Active: account_state::IsSet,
232232- S::Seq: account_state::IsSet,
233232 S::Time: account_state::IsSet,
233233+ S::Seq: account_state::IsSet,
234234{
235235 /// Build the final struct
236236 pub fn build(self) -> Account<'a> {
···10731073 }
10741074 /// State trait tracking which required fields have been set
10751075 pub trait State: sealed::Sealed {
10761076- type Seq;
10761076+ type TooBig;
10771077 type Blobs;
10781078- type Blocks;
10781078+ type Repo;
10791079+ type Time;
10791080 type Rev;
10801081 type Commit;
10821082+ type Blocks;
10811083 type Ops;
10821082- type Repo;
10831083- type Time;
10841084 type Rebase;
10851085- type TooBig;
10851085+ type Seq;
10861086 }
10871087 /// Empty state - all required fields are unset
10881088 pub struct Empty(());
10891089 impl sealed::Sealed for Empty {}
10901090 impl State for Empty {
10911091- type Seq = Unset;
10911091+ type TooBig = Unset;
10921092 type Blobs = Unset;
10931093- type Blocks = Unset;
10931093+ type Repo = Unset;
10941094+ type Time = Unset;
10941095 type Rev = Unset;
10951096 type Commit = Unset;
10971097+ type Blocks = Unset;
10961098 type Ops = Unset;
10971097- type Repo = Unset;
10981098- type Time = Unset;
10991099 type Rebase = Unset;
11001100- type TooBig = Unset;
11001100+ type Seq = Unset;
11011101 }
11021102- ///State transition - sets the `seq` field to Set
11031103- pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
11041104- impl<S: State> sealed::Sealed for SetSeq<S> {}
11051105- impl<S: State> State for SetSeq<S> {
11061106- type Seq = Set<members::seq>;
11021102+ ///State transition - sets the `too_big` field to Set
11031103+ pub struct SetTooBig<S: State = Empty>(PhantomData<fn() -> S>);
11041104+ impl<S: State> sealed::Sealed for SetTooBig<S> {}
11051105+ impl<S: State> State for SetTooBig<S> {
11061106+ type TooBig = Set<members::too_big>;
11071107 type Blobs = S::Blobs;
11081108- type Blocks = S::Blocks;
11081108+ type Repo = S::Repo;
11091109+ type Time = S::Time;
11091110 type Rev = S::Rev;
11101111 type Commit = S::Commit;
11121112+ type Blocks = S::Blocks;
11111113 type Ops = S::Ops;
11121112- type Repo = S::Repo;
11131113- type Time = S::Time;
11141114 type Rebase = S::Rebase;
11151115- type TooBig = S::TooBig;
11151115+ type Seq = S::Seq;
11161116 }
11171117 ///State transition - sets the `blobs` field to Set
11181118 pub struct SetBlobs<S: State = Empty>(PhantomData<fn() -> S>);
11191119 impl<S: State> sealed::Sealed for SetBlobs<S> {}
11201120 impl<S: State> State for SetBlobs<S> {
11211121- type Seq = S::Seq;
11211121+ type TooBig = S::TooBig;
11221122 type Blobs = Set<members::blobs>;
11231123+ type Repo = S::Repo;
11241124+ type Time = S::Time;
11251125+ type Rev = S::Rev;
11261126+ type Commit = S::Commit;
11231127 type Blocks = S::Blocks;
11281128+ type Ops = S::Ops;
11291129+ type Rebase = S::Rebase;
11301130+ type Seq = S::Seq;
11311131+ }
11321132+ ///State transition - sets the `repo` field to Set
11331133+ pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
11341134+ impl<S: State> sealed::Sealed for SetRepo<S> {}
11351135+ impl<S: State> State for SetRepo<S> {
11361136+ type TooBig = S::TooBig;
11371137+ type Blobs = S::Blobs;
11381138+ type Repo = Set<members::repo>;
11391139+ type Time = S::Time;
11241140 type Rev = S::Rev;
11251141 type Commit = S::Commit;
11421142+ type Blocks = S::Blocks;
11261143 type Ops = S::Ops;
11271127- type Repo = S::Repo;
11281128- type Time = S::Time;
11291144 type Rebase = S::Rebase;
11301130- type TooBig = S::TooBig;
11311131- }
11321132- ///State transition - sets the `blocks` field to Set
11331133- pub struct SetBlocks<S: State = Empty>(PhantomData<fn() -> S>);
11341134- impl<S: State> sealed::Sealed for SetBlocks<S> {}
11351135- impl<S: State> State for SetBlocks<S> {
11361145 type Seq = S::Seq;
11461146+ }
11471147+ ///State transition - sets the `time` field to Set
11481148+ pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
11491149+ impl<S: State> sealed::Sealed for SetTime<S> {}
11501150+ impl<S: State> State for SetTime<S> {
11511151+ type TooBig = S::TooBig;
11371152 type Blobs = S::Blobs;
11381138- type Blocks = Set<members::blocks>;
11531153+ type Repo = S::Repo;
11541154+ type Time = Set<members::time>;
11391155 type Rev = S::Rev;
11401156 type Commit = S::Commit;
11571157+ type Blocks = S::Blocks;
11411158 type Ops = S::Ops;
11421142- type Repo = S::Repo;
11431143- type Time = S::Time;
11441159 type Rebase = S::Rebase;
11451145- type TooBig = S::TooBig;
11601160+ type Seq = S::Seq;
11461161 }
11471162 ///State transition - sets the `rev` field to Set
11481163 pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
11491164 impl<S: State> sealed::Sealed for SetRev<S> {}
11501165 impl<S: State> State for SetRev<S> {
11511151- type Seq = S::Seq;
11661166+ type TooBig = S::TooBig;
11521167 type Blobs = S::Blobs;
11531153- type Blocks = S::Blocks;
11681168+ type Repo = S::Repo;
11691169+ type Time = S::Time;
11541170 type Rev = Set<members::rev>;
11551171 type Commit = S::Commit;
11721172+ type Blocks = S::Blocks;
11561173 type Ops = S::Ops;
11571157- type Repo = S::Repo;
11581158- type Time = S::Time;
11591174 type Rebase = S::Rebase;
11601160- type TooBig = S::TooBig;
11751175+ type Seq = S::Seq;
11611176 }
11621177 ///State transition - sets the `commit` field to Set
11631178 pub struct SetCommit<S: State = Empty>(PhantomData<fn() -> S>);
11641179 impl<S: State> sealed::Sealed for SetCommit<S> {}
11651180 impl<S: State> State for SetCommit<S> {
11661166- type Seq = S::Seq;
11811181+ type TooBig = S::TooBig;
11671182 type Blobs = S::Blobs;
11681168- type Blocks = S::Blocks;
11831183+ type Repo = S::Repo;
11841184+ type Time = S::Time;
11691185 type Rev = S::Rev;
11701186 type Commit = Set<members::commit>;
11871187+ type Blocks = S::Blocks;
11711188 type Ops = S::Ops;
11891189+ type Rebase = S::Rebase;
11901190+ type Seq = S::Seq;
11911191+ }
11921192+ ///State transition - sets the `blocks` field to Set
11931193+ pub struct SetBlocks<S: State = Empty>(PhantomData<fn() -> S>);
11941194+ impl<S: State> sealed::Sealed for SetBlocks<S> {}
11951195+ impl<S: State> State for SetBlocks<S> {
11961196+ type TooBig = S::TooBig;
11971197+ type Blobs = S::Blobs;
11721198 type Repo = S::Repo;
11731199 type Time = S::Time;
12001200+ type Rev = S::Rev;
12011201+ type Commit = S::Commit;
12021202+ type Blocks = Set<members::blocks>;
12031203+ type Ops = S::Ops;
11741204 type Rebase = S::Rebase;
11751175- type TooBig = S::TooBig;
12051205+ type Seq = S::Seq;
11761206 }
11771207 ///State transition - sets the `ops` field to Set
11781208 pub struct SetOps<S: State = Empty>(PhantomData<fn() -> S>);
11791209 impl<S: State> sealed::Sealed for SetOps<S> {}
11801210 impl<S: State> State for SetOps<S> {
11811181- type Seq = S::Seq;
12111211+ type TooBig = S::TooBig;
11821212 type Blobs = S::Blobs;
11831183- type Blocks = S::Blocks;
11841184- type Rev = S::Rev;
11851185- type Commit = S::Commit;
11861186- type Ops = Set<members::ops>;
11871213 type Repo = S::Repo;
11881214 type Time = S::Time;
11891189- type Rebase = S::Rebase;
11901190- type TooBig = S::TooBig;
11911191- }
11921192- ///State transition - sets the `repo` field to Set
11931193- pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
11941194- impl<S: State> sealed::Sealed for SetRepo<S> {}
11951195- impl<S: State> State for SetRepo<S> {
11961196- type Seq = S::Seq;
11971197- type Blobs = S::Blobs;
11981198- type Blocks = S::Blocks;
11991215 type Rev = S::Rev;
12001216 type Commit = S::Commit;
12011201- type Ops = S::Ops;
12021202- type Repo = Set<members::repo>;
12031203- type Time = S::Time;
12171217+ type Blocks = S::Blocks;
12181218+ type Ops = Set<members::ops>;
12041219 type Rebase = S::Rebase;
12051205- type TooBig = S::TooBig;
12061206- }
12071207- ///State transition - sets the `time` field to Set
12081208- pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
12091209- impl<S: State> sealed::Sealed for SetTime<S> {}
12101210- impl<S: State> State for SetTime<S> {
12111220 type Seq = S::Seq;
12121212- type Blobs = S::Blobs;
12131213- type Blocks = S::Blocks;
12141214- type Rev = S::Rev;
12151215- type Commit = S::Commit;
12161216- type Ops = S::Ops;
12171217- type Repo = S::Repo;
12181218- type Time = Set<members::time>;
12191219- type Rebase = S::Rebase;
12201220- type TooBig = S::TooBig;
12211221 }
12221222 ///State transition - sets the `rebase` field to Set
12231223 pub struct SetRebase<S: State = Empty>(PhantomData<fn() -> S>);
12241224 impl<S: State> sealed::Sealed for SetRebase<S> {}
12251225 impl<S: State> State for SetRebase<S> {
12261226- type Seq = S::Seq;
12261226+ type TooBig = S::TooBig;
12271227 type Blobs = S::Blobs;
12281228- type Blocks = S::Blocks;
12281228+ type Repo = S::Repo;
12291229+ type Time = S::Time;
12291230 type Rev = S::Rev;
12301231 type Commit = S::Commit;
12321232+ type Blocks = S::Blocks;
12311233 type Ops = S::Ops;
12321232- type Repo = S::Repo;
12331233- type Time = S::Time;
12341234 type Rebase = Set<members::rebase>;
12351235+ type Seq = S::Seq;
12361236+ }
12371237+ ///State transition - sets the `seq` field to Set
12381238+ pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
12391239+ impl<S: State> sealed::Sealed for SetSeq<S> {}
12401240+ impl<S: State> State for SetSeq<S> {
12351241 type TooBig = S::TooBig;
12361236- }
12371237- ///State transition - sets the `too_big` field to Set
12381238- pub struct SetTooBig<S: State = Empty>(PhantomData<fn() -> S>);
12391239- impl<S: State> sealed::Sealed for SetTooBig<S> {}
12401240- impl<S: State> State for SetTooBig<S> {
12411241- type Seq = S::Seq;
12421242 type Blobs = S::Blobs;
12431243- type Blocks = S::Blocks;
12431243+ type Repo = S::Repo;
12441244+ type Time = S::Time;
12441245 type Rev = S::Rev;
12451246 type Commit = S::Commit;
12471247+ type Blocks = S::Blocks;
12461248 type Ops = S::Ops;
12471247- type Repo = S::Repo;
12481248- type Time = S::Time;
12491249 type Rebase = S::Rebase;
12501250- type TooBig = Set<members::too_big>;
12501250+ type Seq = Set<members::seq>;
12511251 }
12521252 /// Marker types for field names
12531253 #[allow(non_camel_case_types)]
12541254 pub mod members {
12551255- ///Marker type for the `seq` field
12561256- pub struct seq(());
12551255+ ///Marker type for the `too_big` field
12561256+ pub struct too_big(());
12571257 ///Marker type for the `blobs` field
12581258 pub struct blobs(());
12591259- ///Marker type for the `blocks` field
12601260- pub struct blocks(());
12591259+ ///Marker type for the `repo` field
12601260+ pub struct repo(());
12611261+ ///Marker type for the `time` field
12621262+ pub struct time(());
12611263 ///Marker type for the `rev` field
12621264 pub struct rev(());
12631265 ///Marker type for the `commit` field
12641266 pub struct commit(());
12671267+ ///Marker type for the `blocks` field
12681268+ pub struct blocks(());
12651269 ///Marker type for the `ops` field
12661270 pub struct ops(());
12671267- ///Marker type for the `repo` field
12681268- pub struct repo(());
12691269- ///Marker type for the `time` field
12701270- pub struct time(());
12711271 ///Marker type for the `rebase` field
12721272 pub struct rebase(());
12731273- ///Marker type for the `too_big` field
12741274- pub struct too_big(());
12731273+ ///Marker type for the `seq` field
12741274+ pub struct seq(());
12751275 }
12761276}
12771277···15591559impl<'a, S> CommitBuilder<'a, S>
15601560where
15611561 S: commit_state::State,
15621562- S::Seq: commit_state::IsSet,
15621562+ S::TooBig: commit_state::IsSet,
15631563 S::Blobs: commit_state::IsSet,
15641564- S::Blocks: commit_state::IsSet,
15641564+ S::Repo: commit_state::IsSet,
15651565+ S::Time: commit_state::IsSet,
15651566 S::Rev: commit_state::IsSet,
15661567 S::Commit: commit_state::IsSet,
15681568+ S::Blocks: commit_state::IsSet,
15671569 S::Ops: commit_state::IsSet,
15681568- S::Repo: commit_state::IsSet,
15691569- S::Time: commit_state::IsSet,
15701570 S::Rebase: commit_state::IsSet,
15711571- S::TooBig: commit_state::IsSet,
15711571+ S::Seq: commit_state::IsSet,
15721572{
15731573 /// Build the final struct
15741574 pub fn build(self) -> Commit<'a> {
···16771677 }
16781678 /// State trait tracking which required fields have been set
16791679 pub trait State: sealed::Sealed {
16801680- type Time;
16811681- type Did;
16821680 type Seq;
16811681+ type Did;
16821682+ type Time;
16831683 }
16841684 /// Empty state - all required fields are unset
16851685 pub struct Empty(());
16861686 impl sealed::Sealed for Empty {}
16871687 impl State for Empty {
16881688- type Time = Unset;
16891689- type Did = Unset;
16901688 type Seq = Unset;
16891689+ type Did = Unset;
16901690+ type Time = Unset;
16911691 }
16921692- ///State transition - sets the `time` field to Set
16931693- pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
16941694- impl<S: State> sealed::Sealed for SetTime<S> {}
16951695- impl<S: State> State for SetTime<S> {
16961696- type Time = Set<members::time>;
16921692+ ///State transition - sets the `seq` field to Set
16931693+ pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
16941694+ impl<S: State> sealed::Sealed for SetSeq<S> {}
16951695+ impl<S: State> State for SetSeq<S> {
16961696+ type Seq = Set<members::seq>;
16971697 type Did = S::Did;
16981698- type Seq = S::Seq;
16981698+ type Time = S::Time;
16991699 }
17001700 ///State transition - sets the `did` field to Set
17011701 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
17021702 impl<S: State> sealed::Sealed for SetDid<S> {}
17031703 impl<S: State> State for SetDid<S> {
17041704- type Time = S::Time;
17051705- type Did = Set<members::did>;
17061704 type Seq = S::Seq;
17071707- }
17081708- ///State transition - sets the `seq` field to Set
17091709- pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
17101710- impl<S: State> sealed::Sealed for SetSeq<S> {}
17111711- impl<S: State> State for SetSeq<S> {
17051705+ type Did = Set<members::did>;
17121706 type Time = S::Time;
17071707+ }
17081708+ ///State transition - sets the `time` field to Set
17091709+ pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
17101710+ impl<S: State> sealed::Sealed for SetTime<S> {}
17111711+ impl<S: State> State for SetTime<S> {
17121712+ type Seq = S::Seq;
17131713 type Did = S::Did;
17141714- type Seq = Set<members::seq>;
17141714+ type Time = Set<members::time>;
17151715 }
17161716 /// Marker types for field names
17171717 #[allow(non_camel_case_types)]
17181718 pub mod members {
17191719- ///Marker type for the `time` field
17201720- pub struct time(());
17191719+ ///Marker type for the `seq` field
17201720+ pub struct seq(());
17211721 ///Marker type for the `did` field
17221722 pub struct did(());
17231723- ///Marker type for the `seq` field
17241724- pub struct seq(());
17231723+ ///Marker type for the `time` field
17241724+ pub struct time(());
17251725 }
17261726}
17271727···18341834impl<'a, S> IdentityBuilder<'a, S>
18351835where
18361836 S: identity_state::State,
18371837- S::Time: identity_state::IsSet,
18381838- S::Did: identity_state::IsSet,
18391837 S::Seq: identity_state::IsSet,
18381838+ S::Did: identity_state::IsSet,
18391839+ S::Time: identity_state::IsSet,
18401840{
18411841 /// Build the final struct
18421842 pub fn build(self) -> Identity<'a> {
···22572257 }
22582258 /// State trait tracking which required fields have been set
22592259 pub trait State: sealed::Sealed {
22602260- type Action;
22612260 type Path;
22612261+ type Action;
22622262 }
22632263 /// Empty state - all required fields are unset
22642264 pub struct Empty(());
22652265 impl sealed::Sealed for Empty {}
22662266 impl State for Empty {
22672267+ type Path = Unset;
22672268 type Action = Unset;
22682268- type Path = Unset;
22692269+ }
22702270+ ///State transition - sets the `path` field to Set
22712271+ pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
22722272+ impl<S: State> sealed::Sealed for SetPath<S> {}
22732273+ impl<S: State> State for SetPath<S> {
22742274+ type Path = Set<members::path>;
22752275+ type Action = S::Action;
22692276 }
22702277 ///State transition - sets the `action` field to Set
22712278 pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
22722279 impl<S: State> sealed::Sealed for SetAction<S> {}
22732280 impl<S: State> State for SetAction<S> {
22742274- type Action = Set<members::action>;
22752281 type Path = S::Path;
22762276- }
22772277- ///State transition - sets the `path` field to Set
22782278- pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
22792279- impl<S: State> sealed::Sealed for SetPath<S> {}
22802280- impl<S: State> State for SetPath<S> {
22812281- type Action = S::Action;
22822282- type Path = Set<members::path>;
22822282+ type Action = Set<members::action>;
22832283 }
22842284 /// Marker types for field names
22852285 #[allow(non_camel_case_types)]
22862286 pub mod members {
22872287+ ///Marker type for the `path` field
22882288+ pub struct path(());
22872289 ///Marker type for the `action` field
22882290 pub struct action(());
22892289- ///Marker type for the `path` field
22902290- pub struct path(());
22912291 }
22922292}
22932293···24002400impl<'a, S> RepoOpBuilder<'a, S>
24012401where
24022402 S: repo_op_state::State,
24032403- S::Action: repo_op_state::IsSet,
24042403 S::Path: repo_op_state::IsSet,
24042404+ S::Action: repo_op_state::IsSet,
24052405{
24062406 /// Build the final struct
24072407 pub fn build(self) -> RepoOp<'a> {
···25792579 }
25802580 /// State trait tracking which required fields have been set
25812581 pub trait State: sealed::Sealed {
25822582+ type Rev;
25832583+ type Blocks;
25822584 type Did;
25832583- type Time;
25842585 type Seq;
25852585- type Blocks;
25862586- type Rev;
25862586+ type Time;
25872587 }
25882588 /// Empty state - all required fields are unset
25892589 pub struct Empty(());
25902590 impl sealed::Sealed for Empty {}
25912591 impl State for Empty {
25922592+ type Rev = Unset;
25932593+ type Blocks = Unset;
25922594 type Did = Unset;
25932593- type Time = Unset;
25942595 type Seq = Unset;
25952595- type Blocks = Unset;
25962596- type Rev = Unset;
25962596+ type Time = Unset;
25972597+ }
25982598+ ///State transition - sets the `rev` field to Set
25992599+ pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
26002600+ impl<S: State> sealed::Sealed for SetRev<S> {}
26012601+ impl<S: State> State for SetRev<S> {
26022602+ type Rev = Set<members::rev>;
26032603+ type Blocks = S::Blocks;
26042604+ type Did = S::Did;
26052605+ type Seq = S::Seq;
26062606+ type Time = S::Time;
26072607+ }
26082608+ ///State transition - sets the `blocks` field to Set
26092609+ pub struct SetBlocks<S: State = Empty>(PhantomData<fn() -> S>);
26102610+ impl<S: State> sealed::Sealed for SetBlocks<S> {}
26112611+ impl<S: State> State for SetBlocks<S> {
26122612+ type Rev = S::Rev;
26132613+ type Blocks = Set<members::blocks>;
26142614+ type Did = S::Did;
26152615+ type Seq = S::Seq;
26162616+ type Time = S::Time;
25972617 }
25982618 ///State transition - sets the `did` field to Set
25992619 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
26002620 impl<S: State> sealed::Sealed for SetDid<S> {}
26012621 impl<S: State> State for SetDid<S> {
26222622+ type Rev = S::Rev;
26232623+ type Blocks = S::Blocks;
26022624 type Did = Set<members::did>;
26032603- type Time = S::Time;
26042625 type Seq = S::Seq;
26052605- type Blocks = S::Blocks;
26062606- type Rev = S::Rev;
26072607- }
26082608- ///State transition - sets the `time` field to Set
26092609- pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
26102610- impl<S: State> sealed::Sealed for SetTime<S> {}
26112611- impl<S: State> State for SetTime<S> {
26122612- type Did = S::Did;
26132613- type Time = Set<members::time>;
26142614- type Seq = S::Seq;
26152615- type Blocks = S::Blocks;
26162616- type Rev = S::Rev;
26262626+ type Time = S::Time;
26172627 }
26182628 ///State transition - sets the `seq` field to Set
26192629 pub struct SetSeq<S: State = Empty>(PhantomData<fn() -> S>);
26202630 impl<S: State> sealed::Sealed for SetSeq<S> {}
26212631 impl<S: State> State for SetSeq<S> {
26222622- type Did = S::Did;
26232623- type Time = S::Time;
26242624- type Seq = Set<members::seq>;
26252625- type Blocks = S::Blocks;
26262632 type Rev = S::Rev;
26272627- }
26282628- ///State transition - sets the `blocks` field to Set
26292629- pub struct SetBlocks<S: State = Empty>(PhantomData<fn() -> S>);
26302630- impl<S: State> sealed::Sealed for SetBlocks<S> {}
26312631- impl<S: State> State for SetBlocks<S> {
26332633+ type Blocks = S::Blocks;
26322634 type Did = S::Did;
26352635+ type Seq = Set<members::seq>;
26332636 type Time = S::Time;
26342634- type Seq = S::Seq;
26352635- type Blocks = Set<members::blocks>;
26362636- type Rev = S::Rev;
26372637 }
26382638- ///State transition - sets the `rev` field to Set
26392639- pub struct SetRev<S: State = Empty>(PhantomData<fn() -> S>);
26402640- impl<S: State> sealed::Sealed for SetRev<S> {}
26412641- impl<S: State> State for SetRev<S> {
26382638+ ///State transition - sets the `time` field to Set
26392639+ pub struct SetTime<S: State = Empty>(PhantomData<fn() -> S>);
26402640+ impl<S: State> sealed::Sealed for SetTime<S> {}
26412641+ impl<S: State> State for SetTime<S> {
26422642+ type Rev = S::Rev;
26432643+ type Blocks = S::Blocks;
26422644 type Did = S::Did;
26432643- type Time = S::Time;
26442645 type Seq = S::Seq;
26452645- type Blocks = S::Blocks;
26462646- type Rev = Set<members::rev>;
26462646+ type Time = Set<members::time>;
26472647 }
26482648 /// Marker types for field names
26492649 #[allow(non_camel_case_types)]
26502650 pub mod members {
26512651+ ///Marker type for the `rev` field
26522652+ pub struct rev(());
26532653+ ///Marker type for the `blocks` field
26542654+ pub struct blocks(());
26512655 ///Marker type for the `did` field
26522656 pub struct did(());
26572657+ ///Marker type for the `seq` field
26582658+ pub struct seq(());
26532659 ///Marker type for the `time` field
26542660 pub struct time(());
26552655- ///Marker type for the `seq` field
26562656- pub struct seq(());
26572657- ///Marker type for the `blocks` field
26582658- pub struct blocks(());
26592659- ///Marker type for the `rev` field
26602660- pub struct rev(());
26612661 }
26622662}
26632663···27902790impl<'a, S> SyncBuilder<'a, S>
27912791where
27922792 S: sync_state::State,
27932793+ S::Rev: sync_state::IsSet,
27942794+ S::Blocks: sync_state::IsSet,
27932795 S::Did: sync_state::IsSet,
27942794- S::Time: sync_state::IsSet,
27952796 S::Seq: sync_state::IsSet,
27962796- S::Blocks: sync_state::IsSet,
27972797- S::Rev: sync_state::IsSet,
27972797+ S::Time: sync_state::IsSet,
27982798{
27992799 /// Build the final struct
28002800 pub fn build(self) -> Sync<'a> {
···4242 }
4343 /// State trait tracking which required fields have been set
4444 pub trait State: sealed::Sealed {
4545- type Section;
4645 type ScryfallId;
4746 type Quantity;
4747+ type Section;
4848 }
4949 /// Empty state - all required fields are unset
5050 pub struct Empty(());
5151 impl sealed::Sealed for Empty {}
5252 impl State for Empty {
5353- type Section = Unset;
5453 type ScryfallId = Unset;
5554 type Quantity = Unset;
5656- }
5757- ///State transition - sets the `section` field to Set
5858- pub struct SetSection<S: State = Empty>(PhantomData<fn() -> S>);
5959- impl<S: State> sealed::Sealed for SetSection<S> {}
6060- impl<S: State> State for SetSection<S> {
6161- type Section = Set<members::section>;
6262- type ScryfallId = S::ScryfallId;
6363- type Quantity = S::Quantity;
5555+ type Section = Unset;
6456 }
6557 ///State transition - sets the `scryfall_id` field to Set
6658 pub struct SetScryfallId<S: State = Empty>(PhantomData<fn() -> S>);
6759 impl<S: State> sealed::Sealed for SetScryfallId<S> {}
6860 impl<S: State> State for SetScryfallId<S> {
6969- type Section = S::Section;
7061 type ScryfallId = Set<members::scryfall_id>;
7162 type Quantity = S::Quantity;
6363+ type Section = S::Section;
7264 }
7365 ///State transition - sets the `quantity` field to Set
7466 pub struct SetQuantity<S: State = Empty>(PhantomData<fn() -> S>);
7567 impl<S: State> sealed::Sealed for SetQuantity<S> {}
7668 impl<S: State> State for SetQuantity<S> {
7777- type Section = S::Section;
7869 type ScryfallId = S::ScryfallId;
7970 type Quantity = Set<members::quantity>;
7171+ type Section = S::Section;
7272+ }
7373+ ///State transition - sets the `section` field to Set
7474+ pub struct SetSection<S: State = Empty>(PhantomData<fn() -> S>);
7575+ impl<S: State> sealed::Sealed for SetSection<S> {}
7676+ impl<S: State> State for SetSection<S> {
7777+ type ScryfallId = S::ScryfallId;
7878+ type Quantity = S::Quantity;
7979+ type Section = Set<members::section>;
8080 }
8181 /// Marker types for field names
8282 #[allow(non_camel_case_types)]
8383 pub mod members {
8484- ///Marker type for the `section` field
8585- pub struct section(());
8684 ///Marker type for the `scryfall_id` field
8785 pub struct scryfall_id(());
8886 ///Marker type for the `quantity` field
8987 pub struct quantity(());
8888+ ///Marker type for the `section` field
8989+ pub struct section(());
9090 }
9191}
9292···199199impl<'a, S> CardBuilder<'a, S>
200200where
201201 S: card_state::State,
202202- S::Section: card_state::IsSet,
203202 S::ScryfallId: card_state::IsSet,
204203 S::Quantity: card_state::IsSet,
204204+ S::Section: card_state::IsSet,
205205{
206206 /// Build the final struct
207207 pub fn build(self) -> Card<'a> {
···704704 }
705705 /// State trait tracking which required fields have been set
706706 pub trait State: sealed::Sealed {
707707- type Cards;
708708- type Name;
709707 type CreatedAt;
708708+ type Name;
709709+ type Cards;
710710 }
711711 /// Empty state - all required fields are unset
712712 pub struct Empty(());
713713 impl sealed::Sealed for Empty {}
714714 impl State for Empty {
715715+ type CreatedAt = Unset;
716716+ type Name = Unset;
715717 type Cards = Unset;
716716- type Name = Unset;
717717- type CreatedAt = Unset;
718718 }
719719- ///State transition - sets the `cards` field to Set
720720- pub struct SetCards<S: State = Empty>(PhantomData<fn() -> S>);
721721- impl<S: State> sealed::Sealed for SetCards<S> {}
722722- impl<S: State> State for SetCards<S> {
723723- type Cards = Set<members::cards>;
719719+ ///State transition - sets the `created_at` field to Set
720720+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
721721+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
722722+ impl<S: State> State for SetCreatedAt<S> {
723723+ type CreatedAt = Set<members::created_at>;
724724 type Name = S::Name;
725725- type CreatedAt = S::CreatedAt;
725725+ type Cards = S::Cards;
726726 }
727727 ///State transition - sets the `name` field to Set
728728 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
729729 impl<S: State> sealed::Sealed for SetName<S> {}
730730 impl<S: State> State for SetName<S> {
731731- type Cards = S::Cards;
732732- type Name = Set<members::name>;
733731 type CreatedAt = S::CreatedAt;
732732+ type Name = Set<members::name>;
733733+ type Cards = S::Cards;
734734 }
735735- ///State transition - sets the `created_at` field to Set
736736- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
737737- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
738738- impl<S: State> State for SetCreatedAt<S> {
739739- type Cards = S::Cards;
735735+ ///State transition - sets the `cards` field to Set
736736+ pub struct SetCards<S: State = Empty>(PhantomData<fn() -> S>);
737737+ impl<S: State> sealed::Sealed for SetCards<S> {}
738738+ impl<S: State> State for SetCards<S> {
739739+ type CreatedAt = S::CreatedAt;
740740 type Name = S::Name;
741741- type CreatedAt = Set<members::created_at>;
741741+ type Cards = Set<members::cards>;
742742 }
743743 /// Marker types for field names
744744 #[allow(non_camel_case_types)]
745745 pub mod members {
746746+ ///Marker type for the `created_at` field
747747+ pub struct created_at(());
748748+ ///Marker type for the `name` field
749749+ pub struct name(());
746750 ///Marker type for the `cards` field
747751 pub struct cards(());
748748- ///Marker type for the `name` field
749749- pub struct name(());
750750- ///Marker type for the `created_at` field
751751- pub struct created_at(());
752752 }
753753}
754754···915915impl<'a, S> ListBuilder<'a, S>
916916where
917917 S: list_state::State,
918918- S::Cards: list_state::IsSet,
919919- S::Name: list_state::IsSet,
920918 S::CreatedAt: list_state::IsSet,
919919+ S::Name: list_state::IsSet,
920920+ S::Cards: list_state::IsSet,
921921{
922922 /// Build the final struct
923923 pub fn build(self) -> List<'a> {
···585585 }
586586 /// State trait tracking which required fields have been set
587587 pub trait State: sealed::Sealed {
588588- type Features;
589588 type Index;
589589+ type Features;
590590 }
591591 /// Empty state - all required fields are unset
592592 pub struct Empty(());
593593 impl sealed::Sealed for Empty {}
594594 impl State for Empty {
595595- type Features = Unset;
596595 type Index = Unset;
597597- }
598598- ///State transition - sets the `features` field to Set
599599- pub struct SetFeatures<S: State = Empty>(PhantomData<fn() -> S>);
600600- impl<S: State> sealed::Sealed for SetFeatures<S> {}
601601- impl<S: State> State for SetFeatures<S> {
602602- type Features = Set<members::features>;
603603- type Index = S::Index;
596596+ type Features = Unset;
604597 }
605598 ///State transition - sets the `index` field to Set
606599 pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
607600 impl<S: State> sealed::Sealed for SetIndex<S> {}
608601 impl<S: State> State for SetIndex<S> {
609609- type Features = S::Features;
610602 type Index = Set<members::index>;
603603+ type Features = S::Features;
604604+ }
605605+ ///State transition - sets the `features` field to Set
606606+ pub struct SetFeatures<S: State = Empty>(PhantomData<fn() -> S>);
607607+ impl<S: State> sealed::Sealed for SetFeatures<S> {}
608608+ impl<S: State> State for SetFeatures<S> {
609609+ type Index = S::Index;
610610+ type Features = Set<members::features>;
611611 }
612612 /// Marker types for field names
613613 #[allow(non_camel_case_types)]
614614 pub mod members {
615615- ///Marker type for the `features` field
616616- pub struct features(());
617615 ///Marker type for the `index` field
618616 pub struct index(());
617617+ ///Marker type for the `features` field
618618+ pub struct features(());
619619 }
620620}
621621···688688impl<'a, S> FacetBuilder<'a, S>
689689where
690690 S: facet_state::State,
691691- S::Features: facet_state::IsSet,
692691 S::Index: facet_state::IsSet,
692692+ S::Features: facet_state::IsSet,
693693{
694694 /// Build the final struct
695695 pub fn build(self) -> Facet<'a> {
···3535 }
3636 /// State trait tracking which required fields have been set
3737 pub trait State: sealed::Sealed {
3838- type Subject;
3938 type CreatedAt;
3939+ type Subject;
4040 }
4141 /// Empty state - all required fields are unset
4242 pub struct Empty(());
4343 impl sealed::Sealed for Empty {}
4444 impl State for Empty {
4545- type Subject = Unset;
4645 type CreatedAt = Unset;
4747- }
4848- ///State transition - sets the `subject` field to Set
4949- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5050- impl<S: State> sealed::Sealed for SetSubject<S> {}
5151- impl<S: State> State for SetSubject<S> {
5252- type Subject = Set<members::subject>;
5353- type CreatedAt = S::CreatedAt;
4646+ type Subject = Unset;
5447 }
5548 ///State transition - sets the `created_at` field to Set
5649 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5750 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5851 impl<S: State> State for SetCreatedAt<S> {
5959- type Subject = S::Subject;
6052 type CreatedAt = Set<members::created_at>;
5353+ type Subject = S::Subject;
5454+ }
5555+ ///State transition - sets the `subject` field to Set
5656+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5757+ impl<S: State> sealed::Sealed for SetSubject<S> {}
5858+ impl<S: State> State for SetSubject<S> {
5959+ type CreatedAt = S::CreatedAt;
6060+ type Subject = Set<members::subject>;
6161 }
6262 /// Marker types for field names
6363 #[allow(non_camel_case_types)]
6464 pub mod members {
6565- ///Marker type for the `subject` field
6666- pub struct subject(());
6765 ///Marker type for the `created_at` field
6866 pub struct created_at(());
6767+ ///Marker type for the `subject` field
6868+ pub struct subject(());
6969 }
7070}
7171···138138impl<'a, S> LikeBuilder<'a, S>
139139where
140140 S: like_state::State,
141141- S::Subject: like_state::IsSet,
142141 S::CreatedAt: like_state::IsSet,
142142+ S::Subject: like_state::IsSet,
143143{
144144 /// Build the final struct
145145 pub fn build(self) -> Like<'a> {
+13-13
crates/weaver-api/src/com_whtwnd/blog.rs
···454454 }
455455 /// State trait tracking which required fields have been set
456456 pub trait State: sealed::Sealed {
457457- type Content;
458457 type EntryUri;
458458+ type Content;
459459 }
460460 /// Empty state - all required fields are unset
461461 pub struct Empty(());
462462 impl sealed::Sealed for Empty {}
463463 impl State for Empty {
464464- type Content = Unset;
465464 type EntryUri = Unset;
466466- }
467467- ///State transition - sets the `content` field to Set
468468- pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
469469- impl<S: State> sealed::Sealed for SetContent<S> {}
470470- impl<S: State> State for SetContent<S> {
471471- type Content = Set<members::content>;
472472- type EntryUri = S::EntryUri;
465465+ type Content = Unset;
473466 }
474467 ///State transition - sets the `entry_uri` field to Set
475468 pub struct SetEntryUri<S: State = Empty>(PhantomData<fn() -> S>);
476469 impl<S: State> sealed::Sealed for SetEntryUri<S> {}
477470 impl<S: State> State for SetEntryUri<S> {
478478- type Content = S::Content;
479471 type EntryUri = Set<members::entry_uri>;
472472+ type Content = S::Content;
473473+ }
474474+ ///State transition - sets the `content` field to Set
475475+ pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
476476+ impl<S: State> sealed::Sealed for SetContent<S> {}
477477+ impl<S: State> State for SetContent<S> {
478478+ type EntryUri = S::EntryUri;
479479+ type Content = Set<members::content>;
480480 }
481481 /// Marker types for field names
482482 #[allow(non_camel_case_types)]
483483 pub mod members {
484484- ///Marker type for the `content` field
485485- pub struct content(());
486484 ///Marker type for the `entry_uri` field
487485 pub struct entry_uri(());
486486+ ///Marker type for the `content` field
487487+ pub struct content(());
488488 }
489489}
490490···557557impl<'a, S> CommentBuilder<'a, S>
558558where
559559 S: comment_state::State,
560560- S::Content: comment_state::IsSet,
561560 S::EntryUri: comment_state::IsSet,
561561+ S::Content: comment_state::IsSet,
562562{
563563 /// Build the final struct
564564 pub fn build(self) -> Comment<'a> {
···3232 }
3333 /// State trait tracking which required fields have been set
3434 pub trait State: sealed::Sealed {
3535- type Author;
3635 type EntryTitle;
3636+ type Author;
3737 }
3838 /// Empty state - all required fields are unset
3939 pub struct Empty(());
4040 impl sealed::Sealed for Empty {}
4141 impl State for Empty {
4242- type Author = Unset;
4342 type EntryTitle = Unset;
4444- }
4545- ///State transition - sets the `author` field to Set
4646- pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
4747- impl<S: State> sealed::Sealed for SetAuthor<S> {}
4848- impl<S: State> State for SetAuthor<S> {
4949- type Author = Set<members::author>;
5050- type EntryTitle = S::EntryTitle;
4343+ type Author = Unset;
5144 }
5245 ///State transition - sets the `entry_title` field to Set
5346 pub struct SetEntryTitle<S: State = Empty>(PhantomData<fn() -> S>);
5447 impl<S: State> sealed::Sealed for SetEntryTitle<S> {}
5548 impl<S: State> State for SetEntryTitle<S> {
5656- type Author = S::Author;
5749 type EntryTitle = Set<members::entry_title>;
5050+ type Author = S::Author;
5151+ }
5252+ ///State transition - sets the `author` field to Set
5353+ pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetAuthor<S> {}
5555+ impl<S: State> State for SetAuthor<S> {
5656+ type EntryTitle = S::EntryTitle;
5757+ type Author = Set<members::author>;
5858 }
5959 /// Marker types for field names
6060 #[allow(non_camel_case_types)]
6161 pub mod members {
6262- ///Marker type for the `author` field
6363- pub struct author(());
6462 ///Marker type for the `entry_title` field
6563 pub struct entry_title(());
6464+ ///Marker type for the `author` field
6565+ pub struct author(());
6666 }
6767}
6868···147147impl<'a, S> GetEntryMetadataByNameBuilder<'a, S>
148148where
149149 S: get_entry_metadata_by_name_state::State,
150150- S::Author: get_entry_metadata_by_name_state::IsSet,
151150 S::EntryTitle: get_entry_metadata_by_name_state::IsSet,
151151+ S::Author: get_entry_metadata_by_name_state::IsSet,
152152{
153153 /// Build the final struct
154154 pub fn build(self) -> GetEntryMetadataByName<'a> {
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Url;
3736 type Text;
3737+ type Url;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Url = Unset;
4443 type Text = Unset;
4545- }
4646- ///State transition - sets the `url` field to Set
4747- pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetUrl<S> {}
4949- impl<S: State> State for SetUrl<S> {
5050- type Url = Set<members::url>;
5151- type Text = S::Text;
4444+ type Url = Unset;
5245 }
5346 ///State transition - sets the `text` field to Set
5447 pub struct SetText<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetText<S> {}
5649 impl<S: State> State for SetText<S> {
5757- type Url = S::Url;
5850 type Text = Set<members::text>;
5151+ type Url = S::Url;
5252+ }
5353+ ///State transition - sets the `url` field to Set
5454+ pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetUrl<S> {}
5656+ impl<S: State> State for SetUrl<S> {
5757+ type Text = S::Text;
5858+ type Url = Set<members::url>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `url` field
6464- pub struct url(());
6563 ///Marker type for the `text` field
6664 pub struct text(());
6565+ ///Marker type for the `url` field
6666+ pub struct url(());
6767 }
6868}
6969···136136impl<'a, S> ButtonBuilder<'a, S>
137137where
138138 S: button_state::State,
139139- S::Url: button_state::IsSet,
140139 S::Text: button_state::IsSet,
140140+ S::Url: button_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> Button<'a> {
+15-15
crates/weaver-api/src/pub_leaflet/comment.rs
···443443 }
444444 /// State trait tracking which required fields have been set
445445 pub trait State: sealed::Sealed {
446446+ type CreatedAt;
446447 type Plaintext;
447448 type Subject;
448448- type CreatedAt;
449449 }
450450 /// Empty state - all required fields are unset
451451 pub struct Empty(());
452452 impl sealed::Sealed for Empty {}
453453 impl State for Empty {
454454+ type CreatedAt = Unset;
454455 type Plaintext = Unset;
455456 type Subject = Unset;
456456- type CreatedAt = Unset;
457457+ }
458458+ ///State transition - sets the `created_at` field to Set
459459+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
460460+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
461461+ impl<S: State> State for SetCreatedAt<S> {
462462+ type CreatedAt = Set<members::created_at>;
463463+ type Plaintext = S::Plaintext;
464464+ type Subject = S::Subject;
457465 }
458466 ///State transition - sets the `plaintext` field to Set
459467 pub struct SetPlaintext<S: State = Empty>(PhantomData<fn() -> S>);
460468 impl<S: State> sealed::Sealed for SetPlaintext<S> {}
461469 impl<S: State> State for SetPlaintext<S> {
470470+ type CreatedAt = S::CreatedAt;
462471 type Plaintext = Set<members::plaintext>;
463472 type Subject = S::Subject;
464464- type CreatedAt = S::CreatedAt;
465473 }
466474 ///State transition - sets the `subject` field to Set
467475 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
468476 impl<S: State> sealed::Sealed for SetSubject<S> {}
469477 impl<S: State> State for SetSubject<S> {
470470- type Plaintext = S::Plaintext;
471471- type Subject = Set<members::subject>;
472478 type CreatedAt = S::CreatedAt;
473473- }
474474- ///State transition - sets the `created_at` field to Set
475475- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
476476- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
477477- impl<S: State> State for SetCreatedAt<S> {
478479 type Plaintext = S::Plaintext;
479479- type Subject = S::Subject;
480480- type CreatedAt = Set<members::created_at>;
480480+ type Subject = Set<members::subject>;
481481 }
482482 /// Marker types for field names
483483 #[allow(non_camel_case_types)]
484484 pub mod members {
485485+ ///Marker type for the `created_at` field
486486+ pub struct created_at(());
485487 ///Marker type for the `plaintext` field
486488 pub struct plaintext(());
487489 ///Marker type for the `subject` field
488490 pub struct subject(());
489489- ///Marker type for the `created_at` field
490490- pub struct created_at(());
491491 }
492492}
493493···657657impl<'a, S> CommentBuilder<'a, S>
658658where
659659 S: comment_state::State,
660660+ S::CreatedAt: comment_state::IsSet,
660661 S::Plaintext: comment_state::IsSet,
661662 S::Subject: comment_state::IsSet,
662662- S::CreatedAt: comment_state::IsSet,
663663{
664664 /// Build the final struct
665665 pub fn build(self) -> Comment<'a> {
+15-15
crates/weaver-api/src/pub_leaflet/document.rs
···5555 }
5656 /// State trait tracking which required fields have been set
5757 pub trait State: sealed::Sealed {
5858- type Title;
5958 type Pages;
6059 type Author;
6060+ type Title;
6161 }
6262 /// Empty state - all required fields are unset
6363 pub struct Empty(());
6464 impl sealed::Sealed for Empty {}
6565 impl State for Empty {
6666- type Title = Unset;
6766 type Pages = Unset;
6867 type Author = Unset;
6969- }
7070- ///State transition - sets the `title` field to Set
7171- pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
7272- impl<S: State> sealed::Sealed for SetTitle<S> {}
7373- impl<S: State> State for SetTitle<S> {
7474- type Title = Set<members::title>;
7575- type Pages = S::Pages;
7676- type Author = S::Author;
6868+ type Title = Unset;
7769 }
7870 ///State transition - sets the `pages` field to Set
7971 pub struct SetPages<S: State = Empty>(PhantomData<fn() -> S>);
8072 impl<S: State> sealed::Sealed for SetPages<S> {}
8173 impl<S: State> State for SetPages<S> {
8282- type Title = S::Title;
8374 type Pages = Set<members::pages>;
8475 type Author = S::Author;
7676+ type Title = S::Title;
8577 }
8678 ///State transition - sets the `author` field to Set
8779 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
8880 impl<S: State> sealed::Sealed for SetAuthor<S> {}
8981 impl<S: State> State for SetAuthor<S> {
9090- type Title = S::Title;
9182 type Pages = S::Pages;
9283 type Author = Set<members::author>;
8484+ type Title = S::Title;
8585+ }
8686+ ///State transition - sets the `title` field to Set
8787+ pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
8888+ impl<S: State> sealed::Sealed for SetTitle<S> {}
8989+ impl<S: State> State for SetTitle<S> {
9090+ type Pages = S::Pages;
9191+ type Author = S::Author;
9292+ type Title = Set<members::title>;
9393 }
9494 /// Marker types for field names
9595 #[allow(non_camel_case_types)]
9696 pub mod members {
9797- ///Marker type for the `title` field
9898- pub struct title(());
9997 ///Marker type for the `pages` field
10098 pub struct pages(());
10199 ///Marker type for the `author` field
102100 pub struct author(());
101101+ ///Marker type for the `title` field
102102+ pub struct title(());
103103 }
104104}
105105···322322impl<'a, S> DocumentBuilder<'a, S>
323323where
324324 S: document_state::State,
325325- S::Title: document_state::IsSet,
326325 S::Pages: document_state::IsSet,
327326 S::Author: document_state::IsSet,
327327+ S::Title: document_state::IsSet,
328328{
329329 /// Build the final struct
330330 pub fn build(self) -> Document<'a> {
+45-45
crates/weaver-api/src/pub_leaflet/pages/canvas.rs
···3939 }
4040 /// State trait tracking which required fields have been set
4141 pub trait State: sealed::Sealed {
4242+ type X;
4343+ type Block;
4244 type Width;
4345 type Y;
4444- type Block;
4545- type X;
4646 }
4747 /// Empty state - all required fields are unset
4848 pub struct Empty(());
4949 impl sealed::Sealed for Empty {}
5050 impl State for Empty {
5151+ type X = Unset;
5252+ type Block = Unset;
5153 type Width = Unset;
5254 type Y = Unset;
5353- type Block = Unset;
5454- type X = Unset;
5555+ }
5656+ ///State transition - sets the `x` field to Set
5757+ pub struct SetX<S: State = Empty>(PhantomData<fn() -> S>);
5858+ impl<S: State> sealed::Sealed for SetX<S> {}
5959+ impl<S: State> State for SetX<S> {
6060+ type X = Set<members::x>;
6161+ type Block = S::Block;
6262+ type Width = S::Width;
6363+ type Y = S::Y;
6464+ }
6565+ ///State transition - sets the `block` field to Set
6666+ pub struct SetBlock<S: State = Empty>(PhantomData<fn() -> S>);
6767+ impl<S: State> sealed::Sealed for SetBlock<S> {}
6868+ impl<S: State> State for SetBlock<S> {
6969+ type X = S::X;
7070+ type Block = Set<members::block>;
7171+ type Width = S::Width;
7272+ type Y = S::Y;
5573 }
5674 ///State transition - sets the `width` field to Set
5775 pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
5876 impl<S: State> sealed::Sealed for SetWidth<S> {}
5977 impl<S: State> State for SetWidth<S> {
7878+ type X = S::X;
7979+ type Block = S::Block;
6080 type Width = Set<members::width>;
6181 type Y = S::Y;
6262- type Block = S::Block;
6363- type X = S::X;
6482 }
6583 ///State transition - sets the `y` field to Set
6684 pub struct SetY<S: State = Empty>(PhantomData<fn() -> S>);
6785 impl<S: State> sealed::Sealed for SetY<S> {}
6886 impl<S: State> State for SetY<S> {
6969- type Width = S::Width;
7070- type Y = Set<members::y>;
7171- type Block = S::Block;
7287 type X = S::X;
7373- }
7474- ///State transition - sets the `block` field to Set
7575- pub struct SetBlock<S: State = Empty>(PhantomData<fn() -> S>);
7676- impl<S: State> sealed::Sealed for SetBlock<S> {}
7777- impl<S: State> State for SetBlock<S> {
7878- type Width = S::Width;
7979- type Y = S::Y;
8080- type Block = Set<members::block>;
8181- type X = S::X;
8282- }
8383- ///State transition - sets the `x` field to Set
8484- pub struct SetX<S: State = Empty>(PhantomData<fn() -> S>);
8585- impl<S: State> sealed::Sealed for SetX<S> {}
8686- impl<S: State> State for SetX<S> {
8787- type Width = S::Width;
8888- type Y = S::Y;
8988 type Block = S::Block;
9090- type X = Set<members::x>;
8989+ type Width = S::Width;
9090+ type Y = Set<members::y>;
9191 }
9292 /// Marker types for field names
9393 #[allow(non_camel_case_types)]
9494 pub mod members {
9595+ ///Marker type for the `x` field
9696+ pub struct x(());
9797+ ///Marker type for the `block` field
9898+ pub struct block(());
9599 ///Marker type for the `width` field
96100 pub struct width(());
97101 ///Marker type for the `y` field
98102 pub struct y(());
9999- ///Marker type for the `block` field
100100- pub struct block(());
101101- ///Marker type for the `x` field
102102- pub struct x(());
103103 }
104104}
105105···234234impl<'a, S> BlockBuilder<'a, S>
235235where
236236 S: block_state::State,
237237+ S::X: block_state::IsSet,
238238+ S::Block: block_state::IsSet,
237239 S::Width: block_state::IsSet,
238240 S::Y: block_state::IsSet,
239239- S::Block: block_state::IsSet,
240240- S::X: block_state::IsSet,
241241{
242242 /// Build the final struct
243243 pub fn build(self) -> Block<'a> {
···764764 }
765765 /// State trait tracking which required fields have been set
766766 pub trait State: sealed::Sealed {
767767- type Block;
768767 type Offset;
768768+ type Block;
769769 }
770770 /// Empty state - all required fields are unset
771771 pub struct Empty(());
772772 impl sealed::Sealed for Empty {}
773773 impl State for Empty {
774774- type Block = Unset;
775774 type Offset = Unset;
776776- }
777777- ///State transition - sets the `block` field to Set
778778- pub struct SetBlock<S: State = Empty>(PhantomData<fn() -> S>);
779779- impl<S: State> sealed::Sealed for SetBlock<S> {}
780780- impl<S: State> State for SetBlock<S> {
781781- type Block = Set<members::block>;
782782- type Offset = S::Offset;
775775+ type Block = Unset;
783776 }
784777 ///State transition - sets the `offset` field to Set
785778 pub struct SetOffset<S: State = Empty>(PhantomData<fn() -> S>);
786779 impl<S: State> sealed::Sealed for SetOffset<S> {}
787780 impl<S: State> State for SetOffset<S> {
788788- type Block = S::Block;
789781 type Offset = Set<members::offset>;
782782+ type Block = S::Block;
783783+ }
784784+ ///State transition - sets the `block` field to Set
785785+ pub struct SetBlock<S: State = Empty>(PhantomData<fn() -> S>);
786786+ impl<S: State> sealed::Sealed for SetBlock<S> {}
787787+ impl<S: State> State for SetBlock<S> {
788788+ type Offset = S::Offset;
789789+ type Block = Set<members::block>;
790790 }
791791 /// Marker types for field names
792792 #[allow(non_camel_case_types)]
793793 pub mod members {
794794- ///Marker type for the `block` field
795795- pub struct block(());
796794 ///Marker type for the `offset` field
797795 pub struct offset(());
796796+ ///Marker type for the `block` field
797797+ pub struct block(());
798798 }
799799}
800800···867867impl<'a, S> PositionBuilder<'a, S>
868868where
869869 S: position_state::State,
870870- S::Block: position_state::IsSet,
871870 S::Offset: position_state::IsSet,
871871+ S::Block: position_state::IsSet,
872872{
873873 /// Build the final struct
874874 pub fn build(self) -> Position<'a> {
+13-13
crates/weaver-api/src/pub_leaflet/poll/vote.rs
···3434 }
3535 /// State trait tracking which required fields have been set
3636 pub trait State: sealed::Sealed {
3737- type Option;
3837 type Poll;
3838+ type Option;
3939 }
4040 /// Empty state - all required fields are unset
4141 pub struct Empty(());
4242 impl sealed::Sealed for Empty {}
4343 impl State for Empty {
4444- type Option = Unset;
4544 type Poll = Unset;
4646- }
4747- ///State transition - sets the `option` field to Set
4848- pub struct SetOption<S: State = Empty>(PhantomData<fn() -> S>);
4949- impl<S: State> sealed::Sealed for SetOption<S> {}
5050- impl<S: State> State for SetOption<S> {
5151- type Option = Set<members::option>;
5252- type Poll = S::Poll;
4545+ type Option = Unset;
5346 }
5447 ///State transition - sets the `poll` field to Set
5548 pub struct SetPoll<S: State = Empty>(PhantomData<fn() -> S>);
5649 impl<S: State> sealed::Sealed for SetPoll<S> {}
5750 impl<S: State> State for SetPoll<S> {
5858- type Option = S::Option;
5951 type Poll = Set<members::poll>;
5252+ type Option = S::Option;
5353+ }
5454+ ///State transition - sets the `option` field to Set
5555+ pub struct SetOption<S: State = Empty>(PhantomData<fn() -> S>);
5656+ impl<S: State> sealed::Sealed for SetOption<S> {}
5757+ impl<S: State> State for SetOption<S> {
5858+ type Poll = S::Poll;
5959+ type Option = Set<members::option>;
6060 }
6161 /// Marker types for field names
6262 #[allow(non_camel_case_types)]
6363 pub mod members {
6464- ///Marker type for the `option` field
6565- pub struct option(());
6664 ///Marker type for the `poll` field
6765 pub struct poll(());
6666+ ///Marker type for the `option` field
6767+ pub struct option(());
6868 }
6969}
7070···137137impl<'a, S> VoteBuilder<'a, S>
138138where
139139 S: vote_state::State,
140140- S::Option: vote_state::IsSet,
141140 S::Poll: vote_state::IsSet,
141141+ S::Option: vote_state::IsSet,
142142{
143143 /// Build the final struct
144144 pub fn build(self) -> Vote<'a> {
···556556 }
557557 /// State trait tracking which required fields have been set
558558 pub trait State: sealed::Sealed {
559559- type ByteEnd;
560559 type ByteStart;
560560+ type ByteEnd;
561561 }
562562 /// Empty state - all required fields are unset
563563 pub struct Empty(());
564564 impl sealed::Sealed for Empty {}
565565 impl State for Empty {
566566- type ByteEnd = Unset;
567566 type ByteStart = Unset;
568568- }
569569- ///State transition - sets the `byte_end` field to Set
570570- pub struct SetByteEnd<S: State = Empty>(PhantomData<fn() -> S>);
571571- impl<S: State> sealed::Sealed for SetByteEnd<S> {}
572572- impl<S: State> State for SetByteEnd<S> {
573573- type ByteEnd = Set<members::byte_end>;
574574- type ByteStart = S::ByteStart;
567567+ type ByteEnd = Unset;
575568 }
576569 ///State transition - sets the `byte_start` field to Set
577570 pub struct SetByteStart<S: State = Empty>(PhantomData<fn() -> S>);
578571 impl<S: State> sealed::Sealed for SetByteStart<S> {}
579572 impl<S: State> State for SetByteStart<S> {
580580- type ByteEnd = S::ByteEnd;
581573 type ByteStart = Set<members::byte_start>;
574574+ type ByteEnd = S::ByteEnd;
575575+ }
576576+ ///State transition - sets the `byte_end` field to Set
577577+ pub struct SetByteEnd<S: State = Empty>(PhantomData<fn() -> S>);
578578+ impl<S: State> sealed::Sealed for SetByteEnd<S> {}
579579+ impl<S: State> State for SetByteEnd<S> {
580580+ type ByteStart = S::ByteStart;
581581+ type ByteEnd = Set<members::byte_end>;
582582 }
583583 /// Marker types for field names
584584 #[allow(non_camel_case_types)]
585585 pub mod members {
586586- ///Marker type for the `byte_end` field
587587- pub struct byte_end(());
588586 ///Marker type for the `byte_start` field
589587 pub struct byte_start(());
588588+ ///Marker type for the `byte_end` field
589589+ pub struct byte_end(());
590590 }
591591}
592592···656656impl<'a, S> ByteSliceBuilder<'a, S>
657657where
658658 S: byte_slice_state::State,
659659- S::ByteEnd: byte_slice_state::IsSet,
660659 S::ByteStart: byte_slice_state::IsSet,
660660+ S::ByteEnd: byte_slice_state::IsSet,
661661{
662662 /// Build the final struct
663663 pub fn build(self) -> ByteSlice<'a> {
+32-32
crates/weaver-api/src/pub_leaflet/theme/color.rs
···3232 }
3333 /// State trait tracking which required fields have been set
3434 pub trait State: sealed::Sealed {
3535+ type R;
3536 type G;
3637 type B;
3737- type R;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343+ type R = Unset;
4344 type G = Unset;
4445 type B = Unset;
4545- type R = Unset;
4646+ }
4747+ ///State transition - sets the `r` field to Set
4848+ pub struct SetR<S: State = Empty>(PhantomData<fn() -> S>);
4949+ impl<S: State> sealed::Sealed for SetR<S> {}
5050+ impl<S: State> State for SetR<S> {
5151+ type R = Set<members::r>;
5252+ type G = S::G;
5353+ type B = S::B;
4654 }
4755 ///State transition - sets the `g` field to Set
4856 pub struct SetG<S: State = Empty>(PhantomData<fn() -> S>);
4957 impl<S: State> sealed::Sealed for SetG<S> {}
5058 impl<S: State> State for SetG<S> {
5959+ type R = S::R;
5160 type G = Set<members::g>;
5261 type B = S::B;
5353- type R = S::R;
5462 }
5563 ///State transition - sets the `b` field to Set
5664 pub struct SetB<S: State = Empty>(PhantomData<fn() -> S>);
5765 impl<S: State> sealed::Sealed for SetB<S> {}
5866 impl<S: State> State for SetB<S> {
5959- type G = S::G;
6060- type B = Set<members::b>;
6167 type R = S::R;
6262- }
6363- ///State transition - sets the `r` field to Set
6464- pub struct SetR<S: State = Empty>(PhantomData<fn() -> S>);
6565- impl<S: State> sealed::Sealed for SetR<S> {}
6666- impl<S: State> State for SetR<S> {
6768 type G = S::G;
6868- type B = S::B;
6969- type R = Set<members::r>;
6969+ type B = Set<members::b>;
7070 }
7171 /// Marker types for field names
7272 #[allow(non_camel_case_types)]
7373 pub mod members {
7474+ ///Marker type for the `r` field
7575+ pub struct r(());
7476 ///Marker type for the `g` field
7577 pub struct g(());
7678 ///Marker type for the `b` field
7779 pub struct b(());
7878- ///Marker type for the `r` field
7979- pub struct r(());
8080 }
8181}
8282···160160impl<'a, S> RgbBuilder<'a, S>
161161where
162162 S: rgb_state::State,
163163+ S::R: rgb_state::IsSet,
163164 S::G: rgb_state::IsSet,
164165 S::B: rgb_state::IsSet,
165165- S::R: rgb_state::IsSet,
166166{
167167 /// Build the final struct
168168 pub fn build(self) -> Rgb<'a> {
···439439 /// State trait tracking which required fields have been set
440440 pub trait State: sealed::Sealed {
441441 type R;
442442- type B;
443442 type A;
443443+ type B;
444444 type G;
445445 }
446446 /// Empty state - all required fields are unset
···448448 impl sealed::Sealed for Empty {}
449449 impl State for Empty {
450450 type R = Unset;
451451- type B = Unset;
452451 type A = Unset;
452452+ type B = Unset;
453453 type G = Unset;
454454 }
455455 ///State transition - sets the `r` field to Set
···457457 impl<S: State> sealed::Sealed for SetR<S> {}
458458 impl<S: State> State for SetR<S> {
459459 type R = Set<members::r>;
460460- type B = S::B;
461460 type A = S::A;
462462- type G = S::G;
463463- }
464464- ///State transition - sets the `b` field to Set
465465- pub struct SetB<S: State = Empty>(PhantomData<fn() -> S>);
466466- impl<S: State> sealed::Sealed for SetB<S> {}
467467- impl<S: State> State for SetB<S> {
468468- type R = S::R;
469469- type B = Set<members::b>;
470470- type A = S::A;
461461+ type B = S::B;
471462 type G = S::G;
472463 }
473464 ///State transition - sets the `a` field to Set
···475466 impl<S: State> sealed::Sealed for SetA<S> {}
476467 impl<S: State> State for SetA<S> {
477468 type R = S::R;
478478- type B = S::B;
479469 type A = Set<members::a>;
470470+ type B = S::B;
471471+ type G = S::G;
472472+ }
473473+ ///State transition - sets the `b` field to Set
474474+ pub struct SetB<S: State = Empty>(PhantomData<fn() -> S>);
475475+ impl<S: State> sealed::Sealed for SetB<S> {}
476476+ impl<S: State> State for SetB<S> {
477477+ type R = S::R;
478478+ type A = S::A;
479479+ type B = Set<members::b>;
480480 type G = S::G;
481481 }
482482 ///State transition - sets the `g` field to Set
···484484 impl<S: State> sealed::Sealed for SetG<S> {}
485485 impl<S: State> State for SetG<S> {
486486 type R = S::R;
487487- type B = S::B;
488487 type A = S::A;
488488+ type B = S::B;
489489 type G = Set<members::g>;
490490 }
491491 /// Marker types for field names
···493493 pub mod members {
494494 ///Marker type for the `r` field
495495 pub struct r(());
496496+ ///Marker type for the `a` field
497497+ pub struct a(());
496498 ///Marker type for the `b` field
497499 pub struct b(());
498498- ///Marker type for the `a` field
499499- pub struct a(());
500500 ///Marker type for the `g` field
501501 pub struct g(());
502502 }
···600600where
601601 S: rgba_state::State,
602602 S::R: rgba_state::IsSet,
603603- S::B: rgba_state::IsSet,
604603 S::A: rgba_state::IsSet,
604604+ S::B: rgba_state::IsSet,
605605 S::G: rgba_state::IsSet,
606606{
607607 /// Build the final struct
+28-28
crates/weaver-api/src/sh_weaver/actor.rs
···19791979 }
19801980 /// State trait tracking which required fields have been set
19811981 pub trait State: sealed::Sealed {
19821982- type Handle;
19831982 type Did;
19831983+ type Handle;
19841984 }
19851985 /// Empty state - all required fields are unset
19861986 pub struct Empty(());
19871987 impl sealed::Sealed for Empty {}
19881988 impl State for Empty {
19891989- type Handle = Unset;
19901989 type Did = Unset;
19911991- }
19921992- ///State transition - sets the `handle` field to Set
19931993- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
19941994- impl<S: State> sealed::Sealed for SetHandle<S> {}
19951995- impl<S: State> State for SetHandle<S> {
19961996- type Handle = Set<members::handle>;
19971997- type Did = S::Did;
19901990+ type Handle = Unset;
19981991 }
19991992 ///State transition - sets the `did` field to Set
20001993 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
20011994 impl<S: State> sealed::Sealed for SetDid<S> {}
20021995 impl<S: State> State for SetDid<S> {
20032003- type Handle = S::Handle;
20041996 type Did = Set<members::did>;
19971997+ type Handle = S::Handle;
19981998+ }
19991999+ ///State transition - sets the `handle` field to Set
20002000+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
20012001+ impl<S: State> sealed::Sealed for SetHandle<S> {}
20022002+ impl<S: State> State for SetHandle<S> {
20032003+ type Did = S::Did;
20042004+ type Handle = Set<members::handle>;
20052005 }
20062006 /// Marker types for field names
20072007 #[allow(non_camel_case_types)]
20082008 pub mod members {
20092009- ///Marker type for the `handle` field
20102010- pub struct handle(());
20112009 ///Marker type for the `did` field
20122010 pub struct did(());
20112011+ ///Marker type for the `handle` field
20122012+ pub struct handle(());
20132013 }
20142014}
20152015···23882388impl<'a, S> ProfileViewBuilder<'a, S>
23892389where
23902390 S: profile_view_state::State,
23912391- S::Handle: profile_view_state::IsSet,
23922391 S::Did: profile_view_state::IsSet,
23922392+ S::Handle: profile_view_state::IsSet,
23932393{
23942394 /// Build the final struct
23952395 pub fn build(self) -> ProfileView<'a> {
···31673167 /// State trait tracking which required fields have been set
31683168 pub trait State: sealed::Sealed {
31693169 type Did;
31703170- type Bluesky;
31713170 type Handle;
31713171+ type Bluesky;
31723172 }
31733173 /// Empty state - all required fields are unset
31743174 pub struct Empty(());
31753175 impl sealed::Sealed for Empty {}
31763176 impl State for Empty {
31773177 type Did = Unset;
31783178- type Bluesky = Unset;
31793178 type Handle = Unset;
31793179+ type Bluesky = Unset;
31803180 }
31813181 ///State transition - sets the `did` field to Set
31823182 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
31833183 impl<S: State> sealed::Sealed for SetDid<S> {}
31843184 impl<S: State> State for SetDid<S> {
31853185 type Did = Set<members::did>;
31863186- type Bluesky = S::Bluesky;
31873186 type Handle = S::Handle;
31883188- }
31893189- ///State transition - sets the `bluesky` field to Set
31903190- pub struct SetBluesky<S: State = Empty>(PhantomData<fn() -> S>);
31913191- impl<S: State> sealed::Sealed for SetBluesky<S> {}
31923192- impl<S: State> State for SetBluesky<S> {
31933193- type Did = S::Did;
31943194- type Bluesky = Set<members::bluesky>;
31953195- type Handle = S::Handle;
31873187+ type Bluesky = S::Bluesky;
31963188 }
31973189 ///State transition - sets the `handle` field to Set
31983190 pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
31993191 impl<S: State> sealed::Sealed for SetHandle<S> {}
32003192 impl<S: State> State for SetHandle<S> {
32013193 type Did = S::Did;
32023202- type Bluesky = S::Bluesky;
32033194 type Handle = Set<members::handle>;
31953195+ type Bluesky = S::Bluesky;
31963196+ }
31973197+ ///State transition - sets the `bluesky` field to Set
31983198+ pub struct SetBluesky<S: State = Empty>(PhantomData<fn() -> S>);
31993199+ impl<S: State> sealed::Sealed for SetBluesky<S> {}
32003200+ impl<S: State> State for SetBluesky<S> {
32013201+ type Did = S::Did;
32023202+ type Handle = S::Handle;
32033203+ type Bluesky = Set<members::bluesky>;
32043204 }
32053205 /// Marker types for field names
32063206 #[allow(non_camel_case_types)]
32073207 pub mod members {
32083208 ///Marker type for the `did` field
32093209 pub struct did(());
32103210+ ///Marker type for the `handle` field
32113211+ pub struct handle(());
32103212 ///Marker type for the `bluesky` field
32113213 pub struct bluesky(());
32123212- ///Marker type for the `handle` field
32133213- pub struct handle(());
32143214 }
32153215}
32163216···34013401where
34023402 S: tangled_profile_view_state::State,
34033403 S::Did: tangled_profile_view_state::IsSet,
34043404- S::Bluesky: tangled_profile_view_state::IsSet,
34053404 S::Handle: tangled_profile_view_state::IsSet,
34053405+ S::Bluesky: tangled_profile_view_state::IsSet,
34063406{
34073407 /// Build the final struct
34083408 pub fn build(self) -> TangledProfileView<'a> {
+153-153
crates/weaver-api/src/sh_weaver/collab.rs
···16101610 }
16111611 /// State trait tracking which required fields have been set
16121612 pub trait State: sealed::Sealed {
16131613+ type EndReason;
16131614 type WasActiveFrom;
16141615 type WasActiveUntil;
16151615- type EndReason;
16161616 type User;
16171617 }
16181618 /// Empty state - all required fields are unset
16191619 pub struct Empty(());
16201620 impl sealed::Sealed for Empty {}
16211621 impl State for Empty {
16221622+ type EndReason = Unset;
16221623 type WasActiveFrom = Unset;
16231624 type WasActiveUntil = Unset;
16241624- type EndReason = Unset;
16251625 type User = Unset;
16261626 }
16271627+ ///State transition - sets the `end_reason` field to Set
16281628+ pub struct SetEndReason<S: State = Empty>(PhantomData<fn() -> S>);
16291629+ impl<S: State> sealed::Sealed for SetEndReason<S> {}
16301630+ impl<S: State> State for SetEndReason<S> {
16311631+ type EndReason = Set<members::end_reason>;
16321632+ type WasActiveFrom = S::WasActiveFrom;
16331633+ type WasActiveUntil = S::WasActiveUntil;
16341634+ type User = S::User;
16351635+ }
16271636 ///State transition - sets the `was_active_from` field to Set
16281637 pub struct SetWasActiveFrom<S: State = Empty>(PhantomData<fn() -> S>);
16291638 impl<S: State> sealed::Sealed for SetWasActiveFrom<S> {}
16301639 impl<S: State> State for SetWasActiveFrom<S> {
16401640+ type EndReason = S::EndReason;
16311641 type WasActiveFrom = Set<members::was_active_from>;
16321642 type WasActiveUntil = S::WasActiveUntil;
16331633- type EndReason = S::EndReason;
16341643 type User = S::User;
16351644 }
16361645 ///State transition - sets the `was_active_until` field to Set
16371646 pub struct SetWasActiveUntil<S: State = Empty>(PhantomData<fn() -> S>);
16381647 impl<S: State> sealed::Sealed for SetWasActiveUntil<S> {}
16391648 impl<S: State> State for SetWasActiveUntil<S> {
16491649+ type EndReason = S::EndReason;
16401650 type WasActiveFrom = S::WasActiveFrom;
16411651 type WasActiveUntil = Set<members::was_active_until>;
16421642- type EndReason = S::EndReason;
16431643- type User = S::User;
16441644- }
16451645- ///State transition - sets the `end_reason` field to Set
16461646- pub struct SetEndReason<S: State = Empty>(PhantomData<fn() -> S>);
16471647- impl<S: State> sealed::Sealed for SetEndReason<S> {}
16481648- impl<S: State> State for SetEndReason<S> {
16491649- type WasActiveFrom = S::WasActiveFrom;
16501650- type WasActiveUntil = S::WasActiveUntil;
16511651- type EndReason = Set<members::end_reason>;
16521652 type User = S::User;
16531653 }
16541654 ///State transition - sets the `user` field to Set
16551655 pub struct SetUser<S: State = Empty>(PhantomData<fn() -> S>);
16561656 impl<S: State> sealed::Sealed for SetUser<S> {}
16571657 impl<S: State> State for SetUser<S> {
16581658+ type EndReason = S::EndReason;
16581659 type WasActiveFrom = S::WasActiveFrom;
16591660 type WasActiveUntil = S::WasActiveUntil;
16601660- type EndReason = S::EndReason;
16611661 type User = Set<members::user>;
16621662 }
16631663 /// Marker types for field names
16641664 #[allow(non_camel_case_types)]
16651665 pub mod members {
16661666+ ///Marker type for the `end_reason` field
16671667+ pub struct end_reason(());
16661668 ///Marker type for the `was_active_from` field
16671669 pub struct was_active_from(());
16681670 ///Marker type for the `was_active_until` field
16691671 pub struct was_active_until(());
16701670- ///Marker type for the `end_reason` field
16711671- pub struct end_reason(());
16721672 ///Marker type for the `user` field
16731673 pub struct user(());
16741674 }
···18431843impl<'a, S> FormerCollaboratorViewBuilder<'a, S>
18441844where
18451845 S: former_collaborator_view_state::State,
18461846+ S::EndReason: former_collaborator_view_state::IsSet,
18461847 S::WasActiveFrom: former_collaborator_view_state::IsSet,
18471848 S::WasActiveUntil: former_collaborator_view_state::IsSet,
18481848- S::EndReason: former_collaborator_view_state::IsSet,
18491849 S::User: former_collaborator_view_state::IsSet,
18501850{
18511851 /// Build the final struct
···20612061 }
20622062 /// State trait tracking which required fields have been set
20632063 pub trait State: sealed::Sealed {
20642064+ type Resource;
20652065+ type Invitee;
20662066+ type Cid;
20672067+ type CreatedAt;
20682068+ type Status;
20642069 type Uri;
20652070 type Inviter;
20662066- type CreatedAt;
20672067- type Status;
20682068- type Cid;
20692069- type Resource;
20702070- type Invitee;
20712071 }
20722072 /// Empty state - all required fields are unset
20732073 pub struct Empty(());
20742074 impl sealed::Sealed for Empty {}
20752075 impl State for Empty {
20762076+ type Resource = Unset;
20772077+ type Invitee = Unset;
20782078+ type Cid = Unset;
20792079+ type CreatedAt = Unset;
20802080+ type Status = Unset;
20762081 type Uri = Unset;
20772082 type Inviter = Unset;
20782078- type CreatedAt = Unset;
20792079- type Status = Unset;
20802080- type Cid = Unset;
20812081- type Resource = Unset;
20822082- type Invitee = Unset;
20832083 }
20842084- ///State transition - sets the `uri` field to Set
20852085- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
20862086- impl<S: State> sealed::Sealed for SetUri<S> {}
20872087- impl<S: State> State for SetUri<S> {
20882088- type Uri = Set<members::uri>;
20842084+ ///State transition - sets the `resource` field to Set
20852085+ pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
20862086+ impl<S: State> sealed::Sealed for SetResource<S> {}
20872087+ impl<S: State> State for SetResource<S> {
20882088+ type Resource = Set<members::resource>;
20892089+ type Invitee = S::Invitee;
20902090+ type Cid = S::Cid;
20912091+ type CreatedAt = S::CreatedAt;
20922092+ type Status = S::Status;
20932093+ type Uri = S::Uri;
20892094 type Inviter = S::Inviter;
20952095+ }
20962096+ ///State transition - sets the `invitee` field to Set
20972097+ pub struct SetInvitee<S: State = Empty>(PhantomData<fn() -> S>);
20982098+ impl<S: State> sealed::Sealed for SetInvitee<S> {}
20992099+ impl<S: State> State for SetInvitee<S> {
21002100+ type Resource = S::Resource;
21012101+ type Invitee = Set<members::invitee>;
21022102+ type Cid = S::Cid;
20902103 type CreatedAt = S::CreatedAt;
20912104 type Status = S::Status;
20922092- type Cid = S::Cid;
21052105+ type Uri = S::Uri;
21062106+ type Inviter = S::Inviter;
21072107+ }
21082108+ ///State transition - sets the `cid` field to Set
21092109+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
21102110+ impl<S: State> sealed::Sealed for SetCid<S> {}
21112111+ impl<S: State> State for SetCid<S> {
20932112 type Resource = S::Resource;
20942113 type Invitee = S::Invitee;
20952095- }
20962096- ///State transition - sets the `inviter` field to Set
20972097- pub struct SetInviter<S: State = Empty>(PhantomData<fn() -> S>);
20982098- impl<S: State> sealed::Sealed for SetInviter<S> {}
20992099- impl<S: State> State for SetInviter<S> {
21002100- type Uri = S::Uri;
21012101- type Inviter = Set<members::inviter>;
21142114+ type Cid = Set<members::cid>;
21022115 type CreatedAt = S::CreatedAt;
21032116 type Status = S::Status;
21042104- type Cid = S::Cid;
21052105- type Resource = S::Resource;
21062106- type Invitee = S::Invitee;
21172117+ type Uri = S::Uri;
21182118+ type Inviter = S::Inviter;
21072119 }
21082120 ///State transition - sets the `created_at` field to Set
21092121 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
21102122 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
21112123 impl<S: State> State for SetCreatedAt<S> {
21122112- type Uri = S::Uri;
21132113- type Inviter = S::Inviter;
21242124+ type Resource = S::Resource;
21252125+ type Invitee = S::Invitee;
21262126+ type Cid = S::Cid;
21142127 type CreatedAt = Set<members::created_at>;
21152128 type Status = S::Status;
21162116- type Cid = S::Cid;
21172117- type Resource = S::Resource;
21182118- type Invitee = S::Invitee;
21292129+ type Uri = S::Uri;
21302130+ type Inviter = S::Inviter;
21192131 }
21202132 ///State transition - sets the `status` field to Set
21212133 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
21222134 impl<S: State> sealed::Sealed for SetStatus<S> {}
21232135 impl<S: State> State for SetStatus<S> {
21242124- type Uri = S::Uri;
21252125- type Inviter = S::Inviter;
21262126- type CreatedAt = S::CreatedAt;
21272127- type Status = Set<members::status>;
21282128- type Cid = S::Cid;
21292136 type Resource = S::Resource;
21302137 type Invitee = S::Invitee;
21312131- }
21322132- ///State transition - sets the `cid` field to Set
21332133- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
21342134- impl<S: State> sealed::Sealed for SetCid<S> {}
21352135- impl<S: State> State for SetCid<S> {
21382138+ type Cid = S::Cid;
21392139+ type CreatedAt = S::CreatedAt;
21402140+ type Status = Set<members::status>;
21362141 type Uri = S::Uri;
21372142 type Inviter = S::Inviter;
21382138- type CreatedAt = S::CreatedAt;
21392139- type Status = S::Status;
21402140- type Cid = Set<members::cid>;
21432143+ }
21442144+ ///State transition - sets the `uri` field to Set
21452145+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
21462146+ impl<S: State> sealed::Sealed for SetUri<S> {}
21472147+ impl<S: State> State for SetUri<S> {
21412148 type Resource = S::Resource;
21422149 type Invitee = S::Invitee;
21432143- }
21442144- ///State transition - sets the `resource` field to Set
21452145- pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
21462146- impl<S: State> sealed::Sealed for SetResource<S> {}
21472147- impl<S: State> State for SetResource<S> {
21482148- type Uri = S::Uri;
21492149- type Inviter = S::Inviter;
21502150+ type Cid = S::Cid;
21502151 type CreatedAt = S::CreatedAt;
21512152 type Status = S::Status;
21522152- type Cid = S::Cid;
21532153- type Resource = Set<members::resource>;
21542154- type Invitee = S::Invitee;
21532153+ type Uri = Set<members::uri>;
21542154+ type Inviter = S::Inviter;
21552155 }
21562156- ///State transition - sets the `invitee` field to Set
21572157- pub struct SetInvitee<S: State = Empty>(PhantomData<fn() -> S>);
21582158- impl<S: State> sealed::Sealed for SetInvitee<S> {}
21592159- impl<S: State> State for SetInvitee<S> {
21602160- type Uri = S::Uri;
21612161- type Inviter = S::Inviter;
21562156+ ///State transition - sets the `inviter` field to Set
21572157+ pub struct SetInviter<S: State = Empty>(PhantomData<fn() -> S>);
21582158+ impl<S: State> sealed::Sealed for SetInviter<S> {}
21592159+ impl<S: State> State for SetInviter<S> {
21602160+ type Resource = S::Resource;
21612161+ type Invitee = S::Invitee;
21622162+ type Cid = S::Cid;
21622163 type CreatedAt = S::CreatedAt;
21632164 type Status = S::Status;
21642164- type Cid = S::Cid;
21652165- type Resource = S::Resource;
21662166- type Invitee = Set<members::invitee>;
21652165+ type Uri = S::Uri;
21662166+ type Inviter = Set<members::inviter>;
21672167 }
21682168 /// Marker types for field names
21692169 #[allow(non_camel_case_types)]
21702170 pub mod members {
21712171+ ///Marker type for the `resource` field
21722172+ pub struct resource(());
21732173+ ///Marker type for the `invitee` field
21742174+ pub struct invitee(());
21752175+ ///Marker type for the `cid` field
21762176+ pub struct cid(());
21772177+ ///Marker type for the `created_at` field
21782178+ pub struct created_at(());
21792179+ ///Marker type for the `status` field
21802180+ pub struct status(());
21712181 ///Marker type for the `uri` field
21722182 pub struct uri(());
21732183 ///Marker type for the `inviter` field
21742184 pub struct inviter(());
21752175- ///Marker type for the `created_at` field
21762176- pub struct created_at(());
21772177- ///Marker type for the `status` field
21782178- pub struct status(());
21792179- ///Marker type for the `cid` field
21802180- pub struct cid(());
21812181- ///Marker type for the `resource` field
21822182- pub struct resource(());
21832183- ///Marker type for the `invitee` field
21842184- pub struct invitee(());
21852185 }
21862186}
21872187···24792479impl<'a, S> InviteViewBuilder<'a, S>
24802480where
24812481 S: invite_view_state::State,
24822482- S::Uri: invite_view_state::IsSet,
24832483- S::Inviter: invite_view_state::IsSet,
24842484- S::CreatedAt: invite_view_state::IsSet,
24852485- S::Status: invite_view_state::IsSet,
24862486- S::Cid: invite_view_state::IsSet,
24872482 S::Resource: invite_view_state::IsSet,
24882483 S::Invitee: invite_view_state::IsSet,
24842484+ S::Cid: invite_view_state::IsSet,
24852485+ S::CreatedAt: invite_view_state::IsSet,
24862486+ S::Status: invite_view_state::IsSet,
24872487+ S::Uri: invite_view_state::IsSet,
24882488+ S::Inviter: invite_view_state::IsSet,
24892489{
24902490 /// Build the final struct
24912491 pub fn build(self) -> InviteView<'a> {
···28212821 }
28222822 /// State trait tracking which required fields have been set
28232823 pub trait State: sealed::Sealed {
28242824- type User;
28252824 type Role;
28262825 type Status;
28262826+ type User;
28272827 }
28282828 /// Empty state - all required fields are unset
28292829 pub struct Empty(());
28302830 impl sealed::Sealed for Empty {}
28312831 impl State for Empty {
28322832- type User = Unset;
28332832 type Role = Unset;
28342833 type Status = Unset;
28352835- }
28362836- ///State transition - sets the `user` field to Set
28372837- pub struct SetUser<S: State = Empty>(PhantomData<fn() -> S>);
28382838- impl<S: State> sealed::Sealed for SetUser<S> {}
28392839- impl<S: State> State for SetUser<S> {
28402840- type User = Set<members::user>;
28412841- type Role = S::Role;
28422842- type Status = S::Status;
28342834+ type User = Unset;
28432835 }
28442836 ///State transition - sets the `role` field to Set
28452837 pub struct SetRole<S: State = Empty>(PhantomData<fn() -> S>);
28462838 impl<S: State> sealed::Sealed for SetRole<S> {}
28472839 impl<S: State> State for SetRole<S> {
28482848- type User = S::User;
28492840 type Role = Set<members::role>;
28502841 type Status = S::Status;
28422842+ type User = S::User;
28512843 }
28522844 ///State transition - sets the `status` field to Set
28532845 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
28542846 impl<S: State> sealed::Sealed for SetStatus<S> {}
28552847 impl<S: State> State for SetStatus<S> {
28562856- type User = S::User;
28572848 type Role = S::Role;
28582849 type Status = Set<members::status>;
28502850+ type User = S::User;
28512851+ }
28522852+ ///State transition - sets the `user` field to Set
28532853+ pub struct SetUser<S: State = Empty>(PhantomData<fn() -> S>);
28542854+ impl<S: State> sealed::Sealed for SetUser<S> {}
28552855+ impl<S: State> State for SetUser<S> {
28562856+ type Role = S::Role;
28572857+ type Status = S::Status;
28582858+ type User = Set<members::user>;
28592859 }
28602860 /// Marker types for field names
28612861 #[allow(non_camel_case_types)]
28622862 pub mod members {
28632863- ///Marker type for the `user` field
28642864- pub struct user(());
28652863 ///Marker type for the `role` field
28662864 pub struct role(());
28672865 ///Marker type for the `status` field
28682866 pub struct status(());
28672867+ ///Marker type for the `user` field
28682868+ pub struct user(());
28692869 }
28702870}
28712871···31273127impl<'a, S> ParticipantStateViewBuilder<'a, S>
31283128where
31293129 S: participant_state_view_state::State,
31303130- S::User: participant_state_view_state::IsSet,
31313130 S::Role: participant_state_view_state::IsSet,
31323131 S::Status: participant_state_view_state::IsSet,
31323132+ S::User: participant_state_view_state::IsSet,
31333133{
31343134 /// Build the final struct
31353135 pub fn build(self) -> ParticipantStateView<'a> {
···35433543 }
35443544 /// State trait tracking which required fields have been set
35453545 pub trait State: sealed::Sealed {
35463546- type User;
35463546+ type Resource;
35473547+ type Uri;
35473548 type CreatedAt;
35483549 type NodeId;
35493549- type Resource;
35503550- type Uri;
35503550+ type User;
35513551 }
35523552 /// Empty state - all required fields are unset
35533553 pub struct Empty(());
35543554 impl sealed::Sealed for Empty {}
35553555 impl State for Empty {
35563556- type User = Unset;
35563556+ type Resource = Unset;
35573557+ type Uri = Unset;
35573558 type CreatedAt = Unset;
35583559 type NodeId = Unset;
35593559- type Resource = Unset;
35603560- type Uri = Unset;
35603560+ type User = Unset;
35613561 }
35623562- ///State transition - sets the `user` field to Set
35633563- pub struct SetUser<S: State = Empty>(PhantomData<fn() -> S>);
35643564- impl<S: State> sealed::Sealed for SetUser<S> {}
35653565- impl<S: State> State for SetUser<S> {
35663566- type User = Set<members::user>;
35623562+ ///State transition - sets the `resource` field to Set
35633563+ pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
35643564+ impl<S: State> sealed::Sealed for SetResource<S> {}
35653565+ impl<S: State> State for SetResource<S> {
35663566+ type Resource = Set<members::resource>;
35673567+ type Uri = S::Uri;
35673568 type CreatedAt = S::CreatedAt;
35683569 type NodeId = S::NodeId;
35703570+ type User = S::User;
35713571+ }
35723572+ ///State transition - sets the `uri` field to Set
35733573+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
35743574+ impl<S: State> sealed::Sealed for SetUri<S> {}
35753575+ impl<S: State> State for SetUri<S> {
35693576 type Resource = S::Resource;
35703570- type Uri = S::Uri;
35773577+ type Uri = Set<members::uri>;
35783578+ type CreatedAt = S::CreatedAt;
35793579+ type NodeId = S::NodeId;
35803580+ type User = S::User;
35713581 }
35723582 ///State transition - sets the `created_at` field to Set
35733583 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
35743584 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
35753585 impl<S: State> State for SetCreatedAt<S> {
35763576- type User = S::User;
35863586+ type Resource = S::Resource;
35873587+ type Uri = S::Uri;
35773588 type CreatedAt = Set<members::created_at>;
35783589 type NodeId = S::NodeId;
35793579- type Resource = S::Resource;
35803580- type Uri = S::Uri;
35903590+ type User = S::User;
35813591 }
35823592 ///State transition - sets the `node_id` field to Set
35833593 pub struct SetNodeId<S: State = Empty>(PhantomData<fn() -> S>);
35843594 impl<S: State> sealed::Sealed for SetNodeId<S> {}
35853595 impl<S: State> State for SetNodeId<S> {
35863586- type User = S::User;
35873587- type CreatedAt = S::CreatedAt;
35883588- type NodeId = Set<members::node_id>;
35893596 type Resource = S::Resource;
35903597 type Uri = S::Uri;
35913591- }
35923592- ///State transition - sets the `resource` field to Set
35933593- pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
35943594- impl<S: State> sealed::Sealed for SetResource<S> {}
35953595- impl<S: State> State for SetResource<S> {
35983598+ type CreatedAt = S::CreatedAt;
35993599+ type NodeId = Set<members::node_id>;
35963600 type User = S::User;
35973597- type CreatedAt = S::CreatedAt;
35983598- type NodeId = S::NodeId;
35993599- type Resource = Set<members::resource>;
36003600- type Uri = S::Uri;
36013601 }
36023602- ///State transition - sets the `uri` field to Set
36033603- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
36043604- impl<S: State> sealed::Sealed for SetUri<S> {}
36053605- impl<S: State> State for SetUri<S> {
36063606- type User = S::User;
36023602+ ///State transition - sets the `user` field to Set
36033603+ pub struct SetUser<S: State = Empty>(PhantomData<fn() -> S>);
36043604+ impl<S: State> sealed::Sealed for SetUser<S> {}
36053605+ impl<S: State> State for SetUser<S> {
36063606+ type Resource = S::Resource;
36073607+ type Uri = S::Uri;
36073608 type CreatedAt = S::CreatedAt;
36083609 type NodeId = S::NodeId;
36093609- type Resource = S::Resource;
36103610- type Uri = Set<members::uri>;
36103610+ type User = Set<members::user>;
36113611 }
36123612 /// Marker types for field names
36133613 #[allow(non_camel_case_types)]
36143614 pub mod members {
36153615- ///Marker type for the `user` field
36163616- pub struct user(());
36153615+ ///Marker type for the `resource` field
36163616+ pub struct resource(());
36173617+ ///Marker type for the `uri` field
36183618+ pub struct uri(());
36173619 ///Marker type for the `created_at` field
36183620 pub struct created_at(());
36193621 ///Marker type for the `node_id` field
36203622 pub struct node_id(());
36213621- ///Marker type for the `resource` field
36223622- pub struct resource(());
36233623- ///Marker type for the `uri` field
36243624- pub struct uri(());
36233623+ ///Marker type for the `user` field
36243624+ pub struct user(());
36253625 }
36263626}
36273627···37943794impl<'a, S> SessionViewBuilder<'a, S>
37953795where
37963796 S: session_view_state::State,
37973797- S::User: session_view_state::IsSet,
37983798- S::CreatedAt: session_view_state::IsSet,
37993799- S::NodeId: session_view_state::IsSet,
38003797 S::Resource: session_view_state::IsSet,
38013798 S::Uri: session_view_state::IsSet,
37993799+ S::CreatedAt: session_view_state::IsSet,
38003800+ S::NodeId: session_view_state::IsSet,
38013801+ S::User: session_view_state::IsSet,
38023802{
38033803 /// Build the final struct
38043804 pub fn build(self) -> SessionView<'a> {
+15-15
crates/weaver-api/src/sh_weaver/collab/accept.rs
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040+ type Invite;
4041 type Resource;
4142 type CreatedAt;
4242- type Invite;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848+ type Invite = Unset;
4849 type Resource = Unset;
4950 type CreatedAt = Unset;
5050- type Invite = Unset;
5151+ }
5252+ ///State transition - sets the `invite` field to Set
5353+ pub struct SetInvite<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetInvite<S> {}
5555+ impl<S: State> State for SetInvite<S> {
5656+ type Invite = Set<members::invite>;
5757+ type Resource = S::Resource;
5858+ type CreatedAt = S::CreatedAt;
5159 }
5260 ///State transition - sets the `resource` field to Set
5361 pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
5462 impl<S: State> sealed::Sealed for SetResource<S> {}
5563 impl<S: State> State for SetResource<S> {
6464+ type Invite = S::Invite;
5665 type Resource = Set<members::resource>;
5766 type CreatedAt = S::CreatedAt;
5858- type Invite = S::Invite;
5967 }
6068 ///State transition - sets the `created_at` field to Set
6169 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6270 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
6371 impl<S: State> State for SetCreatedAt<S> {
6464- type Resource = S::Resource;
6565- type CreatedAt = Set<members::created_at>;
6672 type Invite = S::Invite;
6767- }
6868- ///State transition - sets the `invite` field to Set
6969- pub struct SetInvite<S: State = Empty>(PhantomData<fn() -> S>);
7070- impl<S: State> sealed::Sealed for SetInvite<S> {}
7171- impl<S: State> State for SetInvite<S> {
7273 type Resource = S::Resource;
7373- type CreatedAt = S::CreatedAt;
7474- type Invite = Set<members::invite>;
7474+ type CreatedAt = Set<members::created_at>;
7575 }
7676 /// Marker types for field names
7777 #[allow(non_camel_case_types)]
7878 pub mod members {
7979+ ///Marker type for the `invite` field
8080+ pub struct invite(());
7981 ///Marker type for the `resource` field
8082 pub struct resource(());
8183 ///Marker type for the `created_at` field
8284 pub struct created_at(());
8383- ///Marker type for the `invite` field
8484- pub struct invite(());
8585 }
8686}
8787···174174impl<'a, S> AcceptBuilder<'a, S>
175175where
176176 S: accept_state::State,
177177+ S::Invite: accept_state::IsSet,
177178 S::Resource: accept_state::IsSet,
178179 S::CreatedAt: accept_state::IsSet,
179179- S::Invite: accept_state::IsSet,
180180{
181181 /// Build the final struct
182182 pub fn build(self) -> Accept<'a> {
+15-15
crates/weaver-api/src/sh_weaver/collab/invite.rs
···140140 }
141141 /// State trait tracking which required fields have been set
142142 pub trait State: sealed::Sealed {
143143- type CreatedAt;
144143 type Invitee;
144144+ type CreatedAt;
145145 type Resource;
146146 }
147147 /// Empty state - all required fields are unset
148148 pub struct Empty(());
149149 impl sealed::Sealed for Empty {}
150150 impl State for Empty {
151151- type CreatedAt = Unset;
152151 type Invitee = Unset;
152152+ type CreatedAt = Unset;
153153 type Resource = Unset;
154154 }
155155- ///State transition - sets the `created_at` field to Set
156156- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
157157- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
158158- impl<S: State> State for SetCreatedAt<S> {
159159- type CreatedAt = Set<members::created_at>;
160160- type Invitee = S::Invitee;
161161- type Resource = S::Resource;
162162- }
163155 ///State transition - sets the `invitee` field to Set
164156 pub struct SetInvitee<S: State = Empty>(PhantomData<fn() -> S>);
165157 impl<S: State> sealed::Sealed for SetInvitee<S> {}
166158 impl<S: State> State for SetInvitee<S> {
167167- type CreatedAt = S::CreatedAt;
168159 type Invitee = Set<members::invitee>;
160160+ type CreatedAt = S::CreatedAt;
161161+ type Resource = S::Resource;
162162+ }
163163+ ///State transition - sets the `created_at` field to Set
164164+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
165165+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
166166+ impl<S: State> State for SetCreatedAt<S> {
167167+ type Invitee = S::Invitee;
168168+ type CreatedAt = Set<members::created_at>;
169169 type Resource = S::Resource;
170170 }
171171 ///State transition - sets the `resource` field to Set
172172 pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
173173 impl<S: State> sealed::Sealed for SetResource<S> {}
174174 impl<S: State> State for SetResource<S> {
175175- type CreatedAt = S::CreatedAt;
176175 type Invitee = S::Invitee;
176176+ type CreatedAt = S::CreatedAt;
177177 type Resource = Set<members::resource>;
178178 }
179179 /// Marker types for field names
180180 #[allow(non_camel_case_types)]
181181 pub mod members {
182182+ ///Marker type for the `invitee` field
183183+ pub struct invitee(());
182184 ///Marker type for the `created_at` field
183185 pub struct created_at(());
184184- ///Marker type for the `invitee` field
185185- pub struct invitee(());
186186 ///Marker type for the `resource` field
187187 pub struct resource(());
188188 }
···334334impl<'a, S> InviteBuilder<'a, S>
335335where
336336 S: invite_state::State,
337337- S::CreatedAt: invite_state::IsSet,
338337 S::Invitee: invite_state::IsSet,
338338+ S::CreatedAt: invite_state::IsSet,
339339 S::Resource: invite_state::IsSet,
340340{
341341 /// Build the final struct
+15-15
crates/weaver-api/src/sh_weaver/collab/session.rs
···4444 }
4545 /// State trait tracking which required fields have been set
4646 pub trait State: sealed::Sealed {
4747- type NodeId;
4847 type CreatedAt;
4848+ type NodeId;
4949 type Resource;
5050 }
5151 /// Empty state - all required fields are unset
5252 pub struct Empty(());
5353 impl sealed::Sealed for Empty {}
5454 impl State for Empty {
5555- type NodeId = Unset;
5655 type CreatedAt = Unset;
5656+ type NodeId = Unset;
5757 type Resource = Unset;
5858 }
5959- ///State transition - sets the `node_id` field to Set
6060- pub struct SetNodeId<S: State = Empty>(PhantomData<fn() -> S>);
6161- impl<S: State> sealed::Sealed for SetNodeId<S> {}
6262- impl<S: State> State for SetNodeId<S> {
6363- type NodeId = Set<members::node_id>;
6464- type CreatedAt = S::CreatedAt;
6565- type Resource = S::Resource;
6666- }
6759 ///State transition - sets the `created_at` field to Set
6860 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6961 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
7062 impl<S: State> State for SetCreatedAt<S> {
7171- type NodeId = S::NodeId;
7263 type CreatedAt = Set<members::created_at>;
6464+ type NodeId = S::NodeId;
6565+ type Resource = S::Resource;
6666+ }
6767+ ///State transition - sets the `node_id` field to Set
6868+ pub struct SetNodeId<S: State = Empty>(PhantomData<fn() -> S>);
6969+ impl<S: State> sealed::Sealed for SetNodeId<S> {}
7070+ impl<S: State> State for SetNodeId<S> {
7171+ type CreatedAt = S::CreatedAt;
7272+ type NodeId = Set<members::node_id>;
7373 type Resource = S::Resource;
7474 }
7575 ///State transition - sets the `resource` field to Set
7676 pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
7777 impl<S: State> sealed::Sealed for SetResource<S> {}
7878 impl<S: State> State for SetResource<S> {
7979- type NodeId = S::NodeId;
8079 type CreatedAt = S::CreatedAt;
8080+ type NodeId = S::NodeId;
8181 type Resource = Set<members::resource>;
8282 }
8383 /// Marker types for field names
8484 #[allow(non_camel_case_types)]
8585 pub mod members {
8686+ ///Marker type for the `created_at` field
8787+ pub struct created_at(());
8688 ///Marker type for the `node_id` field
8789 pub struct node_id(());
8888- ///Marker type for the `created_at` field
8989- pub struct created_at(());
9090 ///Marker type for the `resource` field
9191 pub struct resource(());
9292 }
···221221impl<'a, S> SessionBuilder<'a, S>
222222where
223223 S: session_state::State,
224224- S::NodeId: session_state::IsSet,
225224 S::CreatedAt: session_state::IsSet,
225225+ S::NodeId: session_state::IsSet,
226226 S::Resource: session_state::IsSet,
227227{
228228 /// Build the final struct
+19-19
crates/weaver-api/src/sh_weaver/edit.rs
···10531053 }
10541054 /// State trait tracking which required fields have been set
10551055 pub trait State: sealed::Sealed {
10561056- type Uri;
10571056 type Cid;
10571057+ type Uri;
10581058 type Author;
10591059 type CreatedAt;
10601060 type Type;
···10631063 pub struct Empty(());
10641064 impl sealed::Sealed for Empty {}
10651065 impl State for Empty {
10661066+ type Cid = Unset;
10661067 type Uri = Unset;
10671067- type Cid = Unset;
10681068 type Author = Unset;
10691069 type CreatedAt = Unset;
10701070 type Type = Unset;
10711071 }
10721072- ///State transition - sets the `uri` field to Set
10731073- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
10741074- impl<S: State> sealed::Sealed for SetUri<S> {}
10751075- impl<S: State> State for SetUri<S> {
10761076- type Uri = Set<members::uri>;
10771077- type Cid = S::Cid;
10781078- type Author = S::Author;
10791079- type CreatedAt = S::CreatedAt;
10801080- type Type = S::Type;
10811081- }
10821072 ///State transition - sets the `cid` field to Set
10831073 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
10841074 impl<S: State> sealed::Sealed for SetCid<S> {}
10851075 impl<S: State> State for SetCid<S> {
10861086- type Uri = S::Uri;
10871076 type Cid = Set<members::cid>;
10771077+ type Uri = S::Uri;
10781078+ type Author = S::Author;
10791079+ type CreatedAt = S::CreatedAt;
10801080+ type Type = S::Type;
10811081+ }
10821082+ ///State transition - sets the `uri` field to Set
10831083+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
10841084+ impl<S: State> sealed::Sealed for SetUri<S> {}
10851085+ impl<S: State> State for SetUri<S> {
10861086+ type Cid = S::Cid;
10871087+ type Uri = Set<members::uri>;
10881088 type Author = S::Author;
10891089 type CreatedAt = S::CreatedAt;
10901090 type Type = S::Type;
···10931093 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
10941094 impl<S: State> sealed::Sealed for SetAuthor<S> {}
10951095 impl<S: State> State for SetAuthor<S> {
10961096- type Uri = S::Uri;
10971096 type Cid = S::Cid;
10971097+ type Uri = S::Uri;
10981098 type Author = Set<members::author>;
10991099 type CreatedAt = S::CreatedAt;
11001100 type Type = S::Type;
···11031103 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
11041104 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
11051105 impl<S: State> State for SetCreatedAt<S> {
11061106- type Uri = S::Uri;
11071106 type Cid = S::Cid;
11071107+ type Uri = S::Uri;
11081108 type Author = S::Author;
11091109 type CreatedAt = Set<members::created_at>;
11101110 type Type = S::Type;
···11131113 pub struct SetType<S: State = Empty>(PhantomData<fn() -> S>);
11141114 impl<S: State> sealed::Sealed for SetType<S> {}
11151115 impl<S: State> State for SetType<S> {
11161116- type Uri = S::Uri;
11171116 type Cid = S::Cid;
11171117+ type Uri = S::Uri;
11181118 type Author = S::Author;
11191119 type CreatedAt = S::CreatedAt;
11201120 type Type = Set<members::r#type>;
···11221122 /// Marker types for field names
11231123 #[allow(non_camel_case_types)]
11241124 pub mod members {
11251125+ ///Marker type for the `cid` field
11261126+ pub struct cid(());
11251127 ///Marker type for the `uri` field
11261128 pub struct uri(());
11271127- ///Marker type for the `cid` field
11281128- pub struct cid(());
11291129 ///Marker type for the `author` field
11301130 pub struct author(());
11311131 ///Marker type for the `created_at` field
···13481348impl<'a, S> EditHistoryEntryBuilder<'a, S>
13491349where
13501350 S: edit_history_entry_state::State,
13511351- S::Uri: edit_history_entry_state::IsSet,
13521351 S::Cid: edit_history_entry_state::IsSet,
13521352+ S::Uri: edit_history_entry_state::IsSet,
13531353 S::Author: edit_history_entry_state::IsSet,
13541354 S::CreatedAt: edit_history_entry_state::IsSet,
13551355 S::Type: edit_history_entry_state::IsSet,
+28-28
crates/weaver-api/src/sh_weaver/edit/cursor.rs
···586586 }
587587 /// State trait tracking which required fields have been set
588588 pub trait State: sealed::Sealed {
589589- type Peer;
590589 type Counter;
590590+ type Peer;
591591 }
592592 /// Empty state - all required fields are unset
593593 pub struct Empty(());
594594 impl sealed::Sealed for Empty {}
595595 impl State for Empty {
596596- type Peer = Unset;
597596 type Counter = Unset;
598598- }
599599- ///State transition - sets the `peer` field to Set
600600- pub struct SetPeer<S: State = Empty>(PhantomData<fn() -> S>);
601601- impl<S: State> sealed::Sealed for SetPeer<S> {}
602602- impl<S: State> State for SetPeer<S> {
603603- type Peer = Set<members::peer>;
604604- type Counter = S::Counter;
597597+ type Peer = Unset;
605598 }
606599 ///State transition - sets the `counter` field to Set
607600 pub struct SetCounter<S: State = Empty>(PhantomData<fn() -> S>);
608601 impl<S: State> sealed::Sealed for SetCounter<S> {}
609602 impl<S: State> State for SetCounter<S> {
610610- type Peer = S::Peer;
611603 type Counter = Set<members::counter>;
604604+ type Peer = S::Peer;
605605+ }
606606+ ///State transition - sets the `peer` field to Set
607607+ pub struct SetPeer<S: State = Empty>(PhantomData<fn() -> S>);
608608+ impl<S: State> sealed::Sealed for SetPeer<S> {}
609609+ impl<S: State> State for SetPeer<S> {
610610+ type Counter = S::Counter;
611611+ type Peer = Set<members::peer>;
612612 }
613613 /// Marker types for field names
614614 #[allow(non_camel_case_types)]
615615 pub mod members {
616616- ///Marker type for the `peer` field
617617- pub struct peer(());
618616 ///Marker type for the `counter` field
619617 pub struct counter(());
618618+ ///Marker type for the `peer` field
619619+ pub struct peer(());
620620 }
621621}
622622···683683impl<'a, S> IdBuilder<'a, S>
684684where
685685 S: id_state::State,
686686- S::Peer: id_state::IsSet,
687686 S::Counter: id_state::IsSet,
687687+ S::Peer: id_state::IsSet,
688688{
689689 /// Build the final struct
690690 pub fn build(self) -> Id<'a> {
···10181018 /// State trait tracking which required fields have been set
10191019 pub trait State: sealed::Sealed {
10201020 type Counter;
10211021- type Peer;
10221021 type ContainerType;
10221022+ type Peer;
10231023 }
10241024 /// Empty state - all required fields are unset
10251025 pub struct Empty(());
10261026 impl sealed::Sealed for Empty {}
10271027 impl State for Empty {
10281028 type Counter = Unset;
10291029- type Peer = Unset;
10301029 type ContainerType = Unset;
10301030+ type Peer = Unset;
10311031 }
10321032 ///State transition - sets the `counter` field to Set
10331033 pub struct SetCounter<S: State = Empty>(PhantomData<fn() -> S>);
10341034 impl<S: State> sealed::Sealed for SetCounter<S> {}
10351035 impl<S: State> State for SetCounter<S> {
10361036 type Counter = Set<members::counter>;
10371037- type Peer = S::Peer;
10381037 type ContainerType = S::ContainerType;
10391039- }
10401040- ///State transition - sets the `peer` field to Set
10411041- pub struct SetPeer<S: State = Empty>(PhantomData<fn() -> S>);
10421042- impl<S: State> sealed::Sealed for SetPeer<S> {}
10431043- impl<S: State> State for SetPeer<S> {
10441044- type Counter = S::Counter;
10451045- type Peer = Set<members::peer>;
10461046- type ContainerType = S::ContainerType;
10381038+ type Peer = S::Peer;
10471039 }
10481040 ///State transition - sets the `container_type` field to Set
10491041 pub struct SetContainerType<S: State = Empty>(PhantomData<fn() -> S>);
10501042 impl<S: State> sealed::Sealed for SetContainerType<S> {}
10511043 impl<S: State> State for SetContainerType<S> {
10521044 type Counter = S::Counter;
10531053- type Peer = S::Peer;
10541045 type ContainerType = Set<members::container_type>;
10461046+ type Peer = S::Peer;
10471047+ }
10481048+ ///State transition - sets the `peer` field to Set
10491049+ pub struct SetPeer<S: State = Empty>(PhantomData<fn() -> S>);
10501050+ impl<S: State> sealed::Sealed for SetPeer<S> {}
10511051+ impl<S: State> State for SetPeer<S> {
10521052+ type Counter = S::Counter;
10531053+ type ContainerType = S::ContainerType;
10541054+ type Peer = Set<members::peer>;
10551055 }
10561056 /// Marker types for field names
10571057 #[allow(non_camel_case_types)]
10581058 pub mod members {
10591059 ///Marker type for the `counter` field
10601060 pub struct counter(());
10611061+ ///Marker type for the `container_type` field
10621062+ pub struct container_type(());
10611063 ///Marker type for the `peer` field
10621064 pub struct peer(());
10631063- ///Marker type for the `container_type` field
10641064- pub struct container_type(());
10651065 }
10661066}
10671067···11551155where
11561156 S: normal_container_id_state::State,
11571157 S::Counter: normal_container_id_state::IsSet,
11581158- S::Peer: normal_container_id_state::IsSet,
11591158 S::ContainerType: normal_container_id_state::IsSet,
11591159+ S::Peer: normal_container_id_state::IsSet,
11601160{
11611161 /// Build the final struct
11621162 pub fn build(self) -> NormalContainerId<'a> {
+13-13
crates/weaver-api/src/sh_weaver/edit/diff.rs
···4747 }
4848 /// State trait tracking which required fields have been set
4949 pub trait State: sealed::Sealed {
5050- type Root;
5150 type Doc;
5151+ type Root;
5252 }
5353 /// Empty state - all required fields are unset
5454 pub struct Empty(());
5555 impl sealed::Sealed for Empty {}
5656 impl State for Empty {
5757- type Root = Unset;
5857 type Doc = Unset;
5959- }
6060- ///State transition - sets the `root` field to Set
6161- pub struct SetRoot<S: State = Empty>(PhantomData<fn() -> S>);
6262- impl<S: State> sealed::Sealed for SetRoot<S> {}
6363- impl<S: State> State for SetRoot<S> {
6464- type Root = Set<members::root>;
6565- type Doc = S::Doc;
5858+ type Root = Unset;
6659 }
6760 ///State transition - sets the `doc` field to Set
6861 pub struct SetDoc<S: State = Empty>(PhantomData<fn() -> S>);
6962 impl<S: State> sealed::Sealed for SetDoc<S> {}
7063 impl<S: State> State for SetDoc<S> {
7171- type Root = S::Root;
7264 type Doc = Set<members::doc>;
6565+ type Root = S::Root;
6666+ }
6767+ ///State transition - sets the `root` field to Set
6868+ pub struct SetRoot<S: State = Empty>(PhantomData<fn() -> S>);
6969+ impl<S: State> sealed::Sealed for SetRoot<S> {}
7070+ impl<S: State> State for SetRoot<S> {
7171+ type Doc = S::Doc;
7272+ type Root = Set<members::root>;
7373 }
7474 /// Marker types for field names
7575 #[allow(non_camel_case_types)]
7676 pub mod members {
7777- ///Marker type for the `root` field
7878- pub struct root(());
7977 ///Marker type for the `doc` field
8078 pub struct doc(());
7979+ ///Marker type for the `root` field
8080+ pub struct root(());
8181 }
8282}
8383···224224impl<'a, S> DiffBuilder<'a, S>
225225where
226226 S: diff_state::State,
227227- S::Root: diff_state::IsSet,
228227 S::Doc: diff_state::IsSet,
228228+ S::Root: diff_state::IsSet,
229229{
230230 /// Build the final struct
231231 pub fn build(self) -> Diff<'a> {
+13-13
crates/weaver-api/src/sh_weaver/embed.rs
···312312 }
313313 /// State trait tracking which required fields have been set
314314 pub trait State: sealed::Sealed {
315315- type Width;
316315 type Height;
316316+ type Width;
317317 }
318318 /// Empty state - all required fields are unset
319319 pub struct Empty(());
320320 impl sealed::Sealed for Empty {}
321321 impl State for Empty {
322322- type Width = Unset;
323322 type Height = Unset;
324324- }
325325- ///State transition - sets the `width` field to Set
326326- pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
327327- impl<S: State> sealed::Sealed for SetWidth<S> {}
328328- impl<S: State> State for SetWidth<S> {
329329- type Width = Set<members::width>;
330330- type Height = S::Height;
323323+ type Width = Unset;
331324 }
332325 ///State transition - sets the `height` field to Set
333326 pub struct SetHeight<S: State = Empty>(PhantomData<fn() -> S>);
334327 impl<S: State> sealed::Sealed for SetHeight<S> {}
335328 impl<S: State> State for SetHeight<S> {
336336- type Width = S::Width;
337329 type Height = Set<members::height>;
330330+ type Width = S::Width;
331331+ }
332332+ ///State transition - sets the `width` field to Set
333333+ pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
334334+ impl<S: State> sealed::Sealed for SetWidth<S> {}
335335+ impl<S: State> State for SetWidth<S> {
336336+ type Height = S::Height;
337337+ type Width = Set<members::width>;
338338 }
339339 /// Marker types for field names
340340 #[allow(non_camel_case_types)]
341341 pub mod members {
342342- ///Marker type for the `width` field
343343- pub struct width(());
344342 ///Marker type for the `height` field
345343 pub struct height(());
344344+ ///Marker type for the `width` field
345345+ pub struct width(());
346346 }
347347}
348348···412412impl<'a, S> PixelSizeBuilder<'a, S>
413413where
414414 S: pixel_size_state::State,
415415- S::Width: pixel_size_state::IsSet,
416415 S::Height: pixel_size_state::IsSet,
416416+ S::Width: pixel_size_state::IsSet,
417417{
418418 /// Build the final struct
419419 pub fn build(self) -> PixelSize<'a> {
+39-39
crates/weaver-api/src/sh_weaver/embed/external.rs
···3838 }
3939 /// State trait tracking which required fields have been set
4040 pub trait State: sealed::Sealed {
4141+ type Description;
4142 type Title;
4243 type Uri;
4343- type Description;
4444 }
4545 /// Empty state - all required fields are unset
4646 pub struct Empty(());
4747 impl sealed::Sealed for Empty {}
4848 impl State for Empty {
4949+ type Description = Unset;
4950 type Title = Unset;
5051 type Uri = Unset;
5151- type Description = Unset;
5252+ }
5353+ ///State transition - sets the `description` field to Set
5454+ pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetDescription<S> {}
5656+ impl<S: State> State for SetDescription<S> {
5757+ type Description = Set<members::description>;
5858+ type Title = S::Title;
5959+ type Uri = S::Uri;
5260 }
5361 ///State transition - sets the `title` field to Set
5462 pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
5563 impl<S: State> sealed::Sealed for SetTitle<S> {}
5664 impl<S: State> State for SetTitle<S> {
6565+ type Description = S::Description;
5766 type Title = Set<members::title>;
5867 type Uri = S::Uri;
5959- type Description = S::Description;
6068 }
6169 ///State transition - sets the `uri` field to Set
6270 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
6371 impl<S: State> sealed::Sealed for SetUri<S> {}
6472 impl<S: State> State for SetUri<S> {
6565- type Title = S::Title;
6666- type Uri = Set<members::uri>;
6773 type Description = S::Description;
6868- }
6969- ///State transition - sets the `description` field to Set
7070- pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
7171- impl<S: State> sealed::Sealed for SetDescription<S> {}
7272- impl<S: State> State for SetDescription<S> {
7374 type Title = S::Title;
7474- type Uri = S::Uri;
7575- type Description = Set<members::description>;
7575+ type Uri = Set<members::uri>;
7676 }
7777 /// Marker types for field names
7878 #[allow(non_camel_case_types)]
7979 pub mod members {
8080+ ///Marker type for the `description` field
8181+ pub struct description(());
8082 ///Marker type for the `title` field
8183 pub struct title(());
8284 ///Marker type for the `uri` field
8385 pub struct uri(());
8484- ///Marker type for the `description` field
8585- pub struct description(());
8686 }
8787}
8888···195195impl<'a, S> ExternalEmbedBuilder<'a, S>
196196where
197197 S: external_embed_state::State,
198198+ S::Description: external_embed_state::IsSet,
198199 S::Title: external_embed_state::IsSet,
199200 S::Uri: external_embed_state::IsSet,
200200- S::Description: external_embed_state::IsSet,
201201{
202202 /// Build the final struct
203203 pub fn build(self) -> ExternalEmbed<'a> {
···817817 }
818818 /// State trait tracking which required fields have been set
819819 pub trait State: sealed::Sealed {
820820- type Title;
821821- type Description;
822820 type Uri;
821821+ type Description;
822822+ type Title;
823823 }
824824 /// Empty state - all required fields are unset
825825 pub struct Empty(());
826826 impl sealed::Sealed for Empty {}
827827 impl State for Empty {
828828+ type Uri = Unset;
829829+ type Description = Unset;
828830 type Title = Unset;
829829- type Description = Unset;
830830- type Uri = Unset;
831831 }
832832- ///State transition - sets the `title` field to Set
833833- pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
834834- impl<S: State> sealed::Sealed for SetTitle<S> {}
835835- impl<S: State> State for SetTitle<S> {
836836- type Title = Set<members::title>;
832832+ ///State transition - sets the `uri` field to Set
833833+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
834834+ impl<S: State> sealed::Sealed for SetUri<S> {}
835835+ impl<S: State> State for SetUri<S> {
836836+ type Uri = Set<members::uri>;
837837 type Description = S::Description;
838838- type Uri = S::Uri;
838838+ type Title = S::Title;
839839 }
840840 ///State transition - sets the `description` field to Set
841841 pub struct SetDescription<S: State = Empty>(PhantomData<fn() -> S>);
842842 impl<S: State> sealed::Sealed for SetDescription<S> {}
843843 impl<S: State> State for SetDescription<S> {
844844- type Title = S::Title;
845845- type Description = Set<members::description>;
846844 type Uri = S::Uri;
845845+ type Description = Set<members::description>;
846846+ type Title = S::Title;
847847 }
848848- ///State transition - sets the `uri` field to Set
849849- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
850850- impl<S: State> sealed::Sealed for SetUri<S> {}
851851- impl<S: State> State for SetUri<S> {
852852- type Title = S::Title;
848848+ ///State transition - sets the `title` field to Set
849849+ pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
850850+ impl<S: State> sealed::Sealed for SetTitle<S> {}
851851+ impl<S: State> State for SetTitle<S> {
852852+ type Uri = S::Uri;
853853 type Description = S::Description;
854854- type Uri = Set<members::uri>;
854854+ type Title = Set<members::title>;
855855 }
856856 /// Marker types for field names
857857 #[allow(non_camel_case_types)]
858858 pub mod members {
859859+ ///Marker type for the `uri` field
860860+ pub struct uri(());
861861+ ///Marker type for the `description` field
862862+ pub struct description(());
859863 ///Marker type for the `title` field
860864 pub struct title(());
861861- ///Marker type for the `description` field
862862- pub struct description(());
863863- ///Marker type for the `uri` field
864864- pub struct uri(());
865865 }
866866}
867867···974974impl<'a, S> ViewExternalBuilder<'a, S>
975975where
976976 S: view_external_state::State,
977977- S::Title: view_external_state::IsSet,
978978- S::Description: view_external_state::IsSet,
979977 S::Uri: view_external_state::IsSet,
978978+ S::Description: view_external_state::IsSet,
979979+ S::Title: view_external_state::IsSet,
980980{
981981 /// Build the final struct
982982 pub fn build(self) -> ViewExternal<'a> {
+15-15
crates/weaver-api/src/sh_weaver/embed/images.rs
···902902 }
903903 /// State trait tracking which required fields have been set
904904 pub trait State: sealed::Sealed {
905905+ type Alt;
905906 type Thumb;
906907 type Fullsize;
907907- type Alt;
908908 }
909909 /// Empty state - all required fields are unset
910910 pub struct Empty(());
911911 impl sealed::Sealed for Empty {}
912912 impl State for Empty {
913913+ type Alt = Unset;
913914 type Thumb = Unset;
914915 type Fullsize = Unset;
915915- type Alt = Unset;
916916+ }
917917+ ///State transition - sets the `alt` field to Set
918918+ pub struct SetAlt<S: State = Empty>(PhantomData<fn() -> S>);
919919+ impl<S: State> sealed::Sealed for SetAlt<S> {}
920920+ impl<S: State> State for SetAlt<S> {
921921+ type Alt = Set<members::alt>;
922922+ type Thumb = S::Thumb;
923923+ type Fullsize = S::Fullsize;
916924 }
917925 ///State transition - sets the `thumb` field to Set
918926 pub struct SetThumb<S: State = Empty>(PhantomData<fn() -> S>);
919927 impl<S: State> sealed::Sealed for SetThumb<S> {}
920928 impl<S: State> State for SetThumb<S> {
929929+ type Alt = S::Alt;
921930 type Thumb = Set<members::thumb>;
922931 type Fullsize = S::Fullsize;
923923- type Alt = S::Alt;
924932 }
925933 ///State transition - sets the `fullsize` field to Set
926934 pub struct SetFullsize<S: State = Empty>(PhantomData<fn() -> S>);
927935 impl<S: State> sealed::Sealed for SetFullsize<S> {}
928936 impl<S: State> State for SetFullsize<S> {
929929- type Thumb = S::Thumb;
930930- type Fullsize = Set<members::fullsize>;
931937 type Alt = S::Alt;
932932- }
933933- ///State transition - sets the `alt` field to Set
934934- pub struct SetAlt<S: State = Empty>(PhantomData<fn() -> S>);
935935- impl<S: State> sealed::Sealed for SetAlt<S> {}
936936- impl<S: State> State for SetAlt<S> {
937938 type Thumb = S::Thumb;
938938- type Fullsize = S::Fullsize;
939939- type Alt = Set<members::alt>;
939939+ type Fullsize = Set<members::fullsize>;
940940 }
941941 /// Marker types for field names
942942 #[allow(non_camel_case_types)]
943943 pub mod members {
944944+ ///Marker type for the `alt` field
945945+ pub struct alt(());
944946 ///Marker type for the `thumb` field
945947 pub struct thumb(());
946948 ///Marker type for the `fullsize` field
947949 pub struct fullsize(());
948948- ///Marker type for the `alt` field
949949- pub struct alt(());
950950 }
951951}
952952···10731073impl<'a, S> ViewImageBuilder<'a, S>
10741074where
10751075 S: view_image_state::State,
10761076+ S::Alt: view_image_state::IsSet,
10761077 S::Thumb: view_image_state::IsSet,
10771078 S::Fullsize: view_image_state::IsSet,
10781078- S::Alt: view_image_state::IsSet,
10791079{
10801080 /// Build the final struct
10811081 pub fn build(self) -> ViewImage<'a> {
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Media;
3736 type Records;
3737+ type Media;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Media = Unset;
4443 type Records = Unset;
4545- }
4646- ///State transition - sets the `media` field to Set
4747- pub struct SetMedia<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetMedia<S> {}
4949- impl<S: State> State for SetMedia<S> {
5050- type Media = Set<members::media>;
5151- type Records = S::Records;
4444+ type Media = Unset;
5245 }
5346 ///State transition - sets the `records` field to Set
5447 pub struct SetRecords<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetRecords<S> {}
5649 impl<S: State> State for SetRecords<S> {
5757- type Media = S::Media;
5850 type Records = Set<members::records>;
5151+ type Media = S::Media;
5252+ }
5353+ ///State transition - sets the `media` field to Set
5454+ pub struct SetMedia<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetMedia<S> {}
5656+ impl<S: State> State for SetMedia<S> {
5757+ type Records = S::Records;
5858+ type Media = Set<members::media>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `media` field
6464- pub struct media(());
6563 ///Marker type for the `records` field
6664 pub struct records(());
6565+ ///Marker type for the `media` field
6666+ pub struct media(());
6767 }
6868}
6969···136136impl<'a, S> RecordWithMediaBuilder<'a, S>
137137where
138138 S: record_with_media_state::State,
139139- S::Media: record_with_media_state::IsSet,
140139 S::Records: record_with_media_state::IsSet,
140140+ S::Media: record_with_media_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> RecordWithMedia<'a> {
+48-48
crates/weaver-api/src/sh_weaver/embed/records.rs
···11881188 /// State trait tracking which required fields have been set
11891189 pub trait State: sealed::Sealed {
11901190 type Author;
11911191- type Blocked;
11921191 type Uri;
11921192+ type Blocked;
11931193 }
11941194 /// Empty state - all required fields are unset
11951195 pub struct Empty(());
11961196 impl sealed::Sealed for Empty {}
11971197 impl State for Empty {
11981198 type Author = Unset;
11991199- type Blocked = Unset;
12001199 type Uri = Unset;
12001200+ type Blocked = Unset;
12011201 }
12021202 ///State transition - sets the `author` field to Set
12031203 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
12041204 impl<S: State> sealed::Sealed for SetAuthor<S> {}
12051205 impl<S: State> State for SetAuthor<S> {
12061206 type Author = Set<members::author>;
12071207- type Blocked = S::Blocked;
12081207 type Uri = S::Uri;
12091209- }
12101210- ///State transition - sets the `blocked` field to Set
12111211- pub struct SetBlocked<S: State = Empty>(PhantomData<fn() -> S>);
12121212- impl<S: State> sealed::Sealed for SetBlocked<S> {}
12131213- impl<S: State> State for SetBlocked<S> {
12141214- type Author = S::Author;
12151215- type Blocked = Set<members::blocked>;
12161216- type Uri = S::Uri;
12081208+ type Blocked = S::Blocked;
12171209 }
12181210 ///State transition - sets the `uri` field to Set
12191211 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
12201212 impl<S: State> sealed::Sealed for SetUri<S> {}
12211213 impl<S: State> State for SetUri<S> {
12221214 type Author = S::Author;
12231223- type Blocked = S::Blocked;
12241215 type Uri = Set<members::uri>;
12161216+ type Blocked = S::Blocked;
12171217+ }
12181218+ ///State transition - sets the `blocked` field to Set
12191219+ pub struct SetBlocked<S: State = Empty>(PhantomData<fn() -> S>);
12201220+ impl<S: State> sealed::Sealed for SetBlocked<S> {}
12211221+ impl<S: State> State for SetBlocked<S> {
12221222+ type Author = S::Author;
12231223+ type Uri = S::Uri;
12241224+ type Blocked = Set<members::blocked>;
12251225 }
12261226 /// Marker types for field names
12271227 #[allow(non_camel_case_types)]
12281228 pub mod members {
12291229 ///Marker type for the `author` field
12301230 pub struct author(());
12311231+ ///Marker type for the `uri` field
12321232+ pub struct uri(());
12311233 ///Marker type for the `blocked` field
12321234 pub struct blocked(());
12331233- ///Marker type for the `uri` field
12341234- pub struct uri(());
12351235 }
12361236}
12371237···13251325where
13261326 S: view_blocked_state::State,
13271327 S::Author: view_blocked_state::IsSet,
13281328- S::Blocked: view_blocked_state::IsSet,
13291328 S::Uri: view_blocked_state::IsSet,
13291329+ S::Blocked: view_blocked_state::IsSet,
13301330{
13311331 /// Build the final struct
13321332 pub fn build(self) -> ViewBlocked<'a> {
···17701770 /// State trait tracking which required fields have been set
17711771 pub trait State: sealed::Sealed {
17721772 type Cid;
17731773- type Value;
17741774- type IndexedAt;
17751773 type Uri;
17741774+ type Value;
17761775 type Author;
17761776+ type IndexedAt;
17771777 }
17781778 /// Empty state - all required fields are unset
17791779 pub struct Empty(());
17801780 impl sealed::Sealed for Empty {}
17811781 impl State for Empty {
17821782 type Cid = Unset;
17831783+ type Uri = Unset;
17831784 type Value = Unset;
17851785+ type Author = Unset;
17841786 type IndexedAt = Unset;
17851785- type Uri = Unset;
17861786- type Author = Unset;
17871787 }
17881788 ///State transition - sets the `cid` field to Set
17891789 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
17901790 impl<S: State> sealed::Sealed for SetCid<S> {}
17911791 impl<S: State> State for SetCid<S> {
17921792 type Cid = Set<members::cid>;
17931793- type Value = S::Value;
17941794- type IndexedAt = S::IndexedAt;
17951793 type Uri = S::Uri;
17961796- type Author = S::Author;
17971797- }
17981798- ///State transition - sets the `value` field to Set
17991799- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
18001800- impl<S: State> sealed::Sealed for SetValue<S> {}
18011801- impl<S: State> State for SetValue<S> {
18021802- type Cid = S::Cid;
18031803- type Value = Set<members::value>;
18041804- type IndexedAt = S::IndexedAt;
18051805- type Uri = S::Uri;
18061806- type Author = S::Author;
18071807- }
18081808- ///State transition - sets the `indexed_at` field to Set
18091809- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
18101810- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
18111811- impl<S: State> State for SetIndexedAt<S> {
18121812- type Cid = S::Cid;
18131794 type Value = S::Value;
18141814- type IndexedAt = Set<members::indexed_at>;
18151815- type Uri = S::Uri;
18161795 type Author = S::Author;
17961796+ type IndexedAt = S::IndexedAt;
18171797 }
18181798 ///State transition - sets the `uri` field to Set
18191799 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
18201800 impl<S: State> sealed::Sealed for SetUri<S> {}
18211801 impl<S: State> State for SetUri<S> {
18221802 type Cid = S::Cid;
18031803+ type Uri = Set<members::uri>;
18231804 type Value = S::Value;
18051805+ type Author = S::Author;
18241806 type IndexedAt = S::IndexedAt;
18251825- type Uri = Set<members::uri>;
18071807+ }
18081808+ ///State transition - sets the `value` field to Set
18091809+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
18101810+ impl<S: State> sealed::Sealed for SetValue<S> {}
18111811+ impl<S: State> State for SetValue<S> {
18121812+ type Cid = S::Cid;
18131813+ type Uri = S::Uri;
18141814+ type Value = Set<members::value>;
18261815 type Author = S::Author;
18161816+ type IndexedAt = S::IndexedAt;
18271817 }
18281818 ///State transition - sets the `author` field to Set
18291819 pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
18301820 impl<S: State> sealed::Sealed for SetAuthor<S> {}
18311821 impl<S: State> State for SetAuthor<S> {
18321822 type Cid = S::Cid;
18231823+ type Uri = S::Uri;
18331824 type Value = S::Value;
18251825+ type Author = Set<members::author>;
18341826 type IndexedAt = S::IndexedAt;
18271827+ }
18281828+ ///State transition - sets the `indexed_at` field to Set
18291829+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
18301830+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
18311831+ impl<S: State> State for SetIndexedAt<S> {
18321832+ type Cid = S::Cid;
18351833 type Uri = S::Uri;
18361836- type Author = Set<members::author>;
18341834+ type Value = S::Value;
18351835+ type Author = S::Author;
18361836+ type IndexedAt = Set<members::indexed_at>;
18371837 }
18381838 /// Marker types for field names
18391839 #[allow(non_camel_case_types)]
18401840 pub mod members {
18411841 ///Marker type for the `cid` field
18421842 pub struct cid(());
18431843+ ///Marker type for the `uri` field
18441844+ pub struct uri(());
18431845 ///Marker type for the `value` field
18441846 pub struct value(());
18471847+ ///Marker type for the `author` field
18481848+ pub struct author(());
18451849 ///Marker type for the `indexed_at` field
18461850 pub struct indexed_at(());
18471847- ///Marker type for the `uri` field
18481848- pub struct uri(());
18491849- ///Marker type for the `author` field
18501850- pub struct author(());
18511851 }
18521852}
18531853···20932093where
20942094 S: view_record_state::State,
20952095 S::Cid: view_record_state::IsSet,
20962096- S::Value: view_record_state::IsSet,
20972097- S::IndexedAt: view_record_state::IsSet,
20982096 S::Uri: view_record_state::IsSet,
20972097+ S::Value: view_record_state::IsSet,
20992098 S::Author: view_record_state::IsSet,
20992099+ S::IndexedAt: view_record_state::IsSet,
21002100{
21012101 /// Build the final struct
21022102 pub fn build(self) -> ViewRecord<'a> {
+13-13
crates/weaver-api/src/sh_weaver/embed/video.rs
···940940 }
941941 /// State trait tracking which required fields have been set
942942 pub trait State: sealed::Sealed {
943943- type Playlist;
944943 type Cid;
944944+ type Playlist;
945945 }
946946 /// Empty state - all required fields are unset
947947 pub struct Empty(());
948948 impl sealed::Sealed for Empty {}
949949 impl State for Empty {
950950- type Playlist = Unset;
951950 type Cid = Unset;
952952- }
953953- ///State transition - sets the `playlist` field to Set
954954- pub struct SetPlaylist<S: State = Empty>(PhantomData<fn() -> S>);
955955- impl<S: State> sealed::Sealed for SetPlaylist<S> {}
956956- impl<S: State> State for SetPlaylist<S> {
957957- type Playlist = Set<members::playlist>;
958958- type Cid = S::Cid;
951951+ type Playlist = Unset;
959952 }
960953 ///State transition - sets the `cid` field to Set
961954 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
962955 impl<S: State> sealed::Sealed for SetCid<S> {}
963956 impl<S: State> State for SetCid<S> {
964964- type Playlist = S::Playlist;
965957 type Cid = Set<members::cid>;
958958+ type Playlist = S::Playlist;
959959+ }
960960+ ///State transition - sets the `playlist` field to Set
961961+ pub struct SetPlaylist<S: State = Empty>(PhantomData<fn() -> S>);
962962+ impl<S: State> sealed::Sealed for SetPlaylist<S> {}
963963+ impl<S: State> State for SetPlaylist<S> {
964964+ type Cid = S::Cid;
965965+ type Playlist = Set<members::playlist>;
966966 }
967967 /// Marker types for field names
968968 #[allow(non_camel_case_types)]
969969 pub mod members {
970970- ///Marker type for the `playlist` field
971971- pub struct playlist(());
972970 ///Marker type for the `cid` field
973971 pub struct cid(());
972972+ ///Marker type for the `playlist` field
973973+ pub struct playlist(());
974974 }
975975}
976976···11081108impl<'a, S> ViewBuilder<'a, S>
11091109where
11101110 S: view_state::State,
11111111- S::Playlist: view_state::IsSet,
11121111 S::Cid: view_state::IsSet,
11121112+ S::Playlist: view_state::IsSet,
11131113{
11141114 /// Build the final struct
11151115 pub fn build(self) -> View<'a> {
+141-141
crates/weaver-api/src/sh_weaver/graph.rs
···5959 }
6060 /// State trait tracking which required fields have been set
6161 pub trait State: sealed::Sealed {
6262- type Count;
6362 type Tag;
6363+ type Count;
6464 }
6565 /// Empty state - all required fields are unset
6666 pub struct Empty(());
6767 impl sealed::Sealed for Empty {}
6868 impl State for Empty {
6969- type Count = Unset;
7069 type Tag = Unset;
7171- }
7272- ///State transition - sets the `count` field to Set
7373- pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
7474- impl<S: State> sealed::Sealed for SetCount<S> {}
7575- impl<S: State> State for SetCount<S> {
7676- type Count = Set<members::count>;
7777- type Tag = S::Tag;
7070+ type Count = Unset;
7871 }
7972 ///State transition - sets the `tag` field to Set
8073 pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
8174 impl<S: State> sealed::Sealed for SetTag<S> {}
8275 impl<S: State> State for SetTag<S> {
8383- type Count = S::Count;
8476 type Tag = Set<members::tag>;
7777+ type Count = S::Count;
7878+ }
7979+ ///State transition - sets the `count` field to Set
8080+ pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
8181+ impl<S: State> sealed::Sealed for SetCount<S> {}
8282+ impl<S: State> State for SetCount<S> {
8383+ type Tag = S::Tag;
8484+ type Count = Set<members::count>;
8585 }
8686 /// Marker types for field names
8787 #[allow(non_camel_case_types)]
8888 pub mod members {
8989- ///Marker type for the `count` field
9090- pub struct count(());
9189 ///Marker type for the `tag` field
9290 pub struct tag(());
9191+ ///Marker type for the `count` field
9292+ pub struct count(());
9393 }
9494}
9595···162162impl<'a, S> CommunityTagCountBuilder<'a, S>
163163where
164164 S: community_tag_count_state::State,
165165- S::Count: community_tag_count_state::IsSet,
166165 S::Tag: community_tag_count_state::IsSet,
166166+ S::Count: community_tag_count_state::IsSet,
167167{
168168 /// Build the final struct
169169 pub fn build(self) -> CommunityTagCount<'a> {
···883883 }
884884 /// State trait tracking which required fields have been set
885885 pub trait State: sealed::Sealed {
886886- type Uri;
887886 type Subject;
887887+ type Uri;
888888 }
889889 /// Empty state - all required fields are unset
890890 pub struct Empty(());
891891 impl sealed::Sealed for Empty {}
892892 impl State for Empty {
893893- type Uri = Unset;
894893 type Subject = Unset;
895895- }
896896- ///State transition - sets the `uri` field to Set
897897- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
898898- impl<S: State> sealed::Sealed for SetUri<S> {}
899899- impl<S: State> State for SetUri<S> {
900900- type Uri = Set<members::uri>;
901901- type Subject = S::Subject;
894894+ type Uri = Unset;
902895 }
903896 ///State transition - sets the `subject` field to Set
904897 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
905898 impl<S: State> sealed::Sealed for SetSubject<S> {}
906899 impl<S: State> State for SetSubject<S> {
907907- type Uri = S::Uri;
908900 type Subject = Set<members::subject>;
901901+ type Uri = S::Uri;
902902+ }
903903+ ///State transition - sets the `uri` field to Set
904904+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
905905+ impl<S: State> sealed::Sealed for SetUri<S> {}
906906+ impl<S: State> State for SetUri<S> {
907907+ type Subject = S::Subject;
908908+ type Uri = Set<members::uri>;
909909 }
910910 /// Marker types for field names
911911 #[allow(non_camel_case_types)]
912912 pub mod members {
913913- ///Marker type for the `uri` field
914914- pub struct uri(());
915913 ///Marker type for the `subject` field
916914 pub struct subject(());
915915+ ///Marker type for the `uri` field
916916+ pub struct uri(());
917917 }
918918}
919919···10061006impl<'a, S> ListItemViewBuilder<'a, S>
10071007where
10081008 S: list_item_view_state::State,
10091009- S::Uri: list_item_view_state::IsSet,
10101009 S::Subject: list_item_view_state::IsSet,
10101010+ S::Uri: list_item_view_state::IsSet,
10111011{
10121012 /// Build the final struct
10131013 pub fn build(self) -> ListItemView<'a> {
···12121212 }
12131213 /// State trait tracking which required fields have been set
12141214 pub trait State: sealed::Sealed {
12151215- type Uri;
12161215 type Name;
12171217- type ItemCount;
12181218- type Cid;
12191216 type Purpose;
12201217 type IndexedAt;
12211218 type Creator;
12191219+ type Uri;
12201220+ type ItemCount;
12211221+ type Cid;
12221222 }
12231223 /// Empty state - all required fields are unset
12241224 pub struct Empty(());
12251225 impl sealed::Sealed for Empty {}
12261226 impl State for Empty {
12271227- type Uri = Unset;
12281227 type Name = Unset;
12291229- type ItemCount = Unset;
12301230- type Cid = Unset;
12311228 type Purpose = Unset;
12321229 type IndexedAt = Unset;
12331230 type Creator = Unset;
12341234- }
12351235- ///State transition - sets the `uri` field to Set
12361236- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
12371237- impl<S: State> sealed::Sealed for SetUri<S> {}
12381238- impl<S: State> State for SetUri<S> {
12391239- type Uri = Set<members::uri>;
12401240- type Name = S::Name;
12411241- type ItemCount = S::ItemCount;
12421242- type Cid = S::Cid;
12431243- type Purpose = S::Purpose;
12441244- type IndexedAt = S::IndexedAt;
12451245- type Creator = S::Creator;
12311231+ type Uri = Unset;
12321232+ type ItemCount = Unset;
12331233+ type Cid = Unset;
12461234 }
12471235 ///State transition - sets the `name` field to Set
12481236 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
12491237 impl<S: State> sealed::Sealed for SetName<S> {}
12501238 impl<S: State> State for SetName<S> {
12511251- type Uri = S::Uri;
12521239 type Name = Set<members::name>;
12531253- type ItemCount = S::ItemCount;
12541254- type Cid = S::Cid;
12551240 type Purpose = S::Purpose;
12561241 type IndexedAt = S::IndexedAt;
12571242 type Creator = S::Creator;
12581258- }
12591259- ///State transition - sets the `item_count` field to Set
12601260- pub struct SetItemCount<S: State = Empty>(PhantomData<fn() -> S>);
12611261- impl<S: State> sealed::Sealed for SetItemCount<S> {}
12621262- impl<S: State> State for SetItemCount<S> {
12631243 type Uri = S::Uri;
12641264- type Name = S::Name;
12651265- type ItemCount = Set<members::item_count>;
12441244+ type ItemCount = S::ItemCount;
12661245 type Cid = S::Cid;
12671267- type Purpose = S::Purpose;
12681268- type IndexedAt = S::IndexedAt;
12691269- type Creator = S::Creator;
12701270- }
12711271- ///State transition - sets the `cid` field to Set
12721272- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
12731273- impl<S: State> sealed::Sealed for SetCid<S> {}
12741274- impl<S: State> State for SetCid<S> {
12751275- type Uri = S::Uri;
12761276- type Name = S::Name;
12771277- type ItemCount = S::ItemCount;
12781278- type Cid = Set<members::cid>;
12791279- type Purpose = S::Purpose;
12801280- type IndexedAt = S::IndexedAt;
12811281- type Creator = S::Creator;
12821246 }
12831247 ///State transition - sets the `purpose` field to Set
12841248 pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
12851249 impl<S: State> sealed::Sealed for SetPurpose<S> {}
12861250 impl<S: State> State for SetPurpose<S> {
12871287- type Uri = S::Uri;
12881251 type Name = S::Name;
12891289- type ItemCount = S::ItemCount;
12901290- type Cid = S::Cid;
12911252 type Purpose = Set<members::purpose>;
12921253 type IndexedAt = S::IndexedAt;
12931254 type Creator = S::Creator;
12551255+ type Uri = S::Uri;
12561256+ type ItemCount = S::ItemCount;
12571257+ type Cid = S::Cid;
12941258 }
12951259 ///State transition - sets the `indexed_at` field to Set
12961260 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
12971261 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
12981262 impl<S: State> State for SetIndexedAt<S> {
12991299- type Uri = S::Uri;
13001263 type Name = S::Name;
13011301- type ItemCount = S::ItemCount;
13021302- type Cid = S::Cid;
13031264 type Purpose = S::Purpose;
13041265 type IndexedAt = Set<members::indexed_at>;
13051266 type Creator = S::Creator;
12671267+ type Uri = S::Uri;
12681268+ type ItemCount = S::ItemCount;
12691269+ type Cid = S::Cid;
13061270 }
13071271 ///State transition - sets the `creator` field to Set
13081272 pub struct SetCreator<S: State = Empty>(PhantomData<fn() -> S>);
13091273 impl<S: State> sealed::Sealed for SetCreator<S> {}
13101274 impl<S: State> State for SetCreator<S> {
12751275+ type Name = S::Name;
12761276+ type Purpose = S::Purpose;
12771277+ type IndexedAt = S::IndexedAt;
12781278+ type Creator = Set<members::creator>;
13111279 type Uri = S::Uri;
12801280+ type ItemCount = S::ItemCount;
12811281+ type Cid = S::Cid;
12821282+ }
12831283+ ///State transition - sets the `uri` field to Set
12841284+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
12851285+ impl<S: State> sealed::Sealed for SetUri<S> {}
12861286+ impl<S: State> State for SetUri<S> {
13121287 type Name = S::Name;
12881288+ type Purpose = S::Purpose;
12891289+ type IndexedAt = S::IndexedAt;
12901290+ type Creator = S::Creator;
12911291+ type Uri = Set<members::uri>;
13131292 type ItemCount = S::ItemCount;
13141293 type Cid = S::Cid;
12941294+ }
12951295+ ///State transition - sets the `item_count` field to Set
12961296+ pub struct SetItemCount<S: State = Empty>(PhantomData<fn() -> S>);
12971297+ impl<S: State> sealed::Sealed for SetItemCount<S> {}
12981298+ impl<S: State> State for SetItemCount<S> {
12991299+ type Name = S::Name;
13151300 type Purpose = S::Purpose;
13161301 type IndexedAt = S::IndexedAt;
13171317- type Creator = Set<members::creator>;
13021302+ type Creator = S::Creator;
13031303+ type Uri = S::Uri;
13041304+ type ItemCount = Set<members::item_count>;
13051305+ type Cid = S::Cid;
13061306+ }
13071307+ ///State transition - sets the `cid` field to Set
13081308+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
13091309+ impl<S: State> sealed::Sealed for SetCid<S> {}
13101310+ impl<S: State> State for SetCid<S> {
13111311+ type Name = S::Name;
13121312+ type Purpose = S::Purpose;
13131313+ type IndexedAt = S::IndexedAt;
13141314+ type Creator = S::Creator;
13151315+ type Uri = S::Uri;
13161316+ type ItemCount = S::ItemCount;
13171317+ type Cid = Set<members::cid>;
13181318 }
13191319 /// Marker types for field names
13201320 #[allow(non_camel_case_types)]
13211321 pub mod members {
13221322- ///Marker type for the `uri` field
13231323- pub struct uri(());
13241322 ///Marker type for the `name` field
13251323 pub struct name(());
13261326- ///Marker type for the `item_count` field
13271327- pub struct item_count(());
13281328- ///Marker type for the `cid` field
13291329- pub struct cid(());
13301324 ///Marker type for the `purpose` field
13311325 pub struct purpose(());
13321326 ///Marker type for the `indexed_at` field
13331327 pub struct indexed_at(());
13341328 ///Marker type for the `creator` field
13351329 pub struct creator(());
13301330+ ///Marker type for the `uri` field
13311331+ pub struct uri(());
13321332+ ///Marker type for the `item_count` field
13331333+ pub struct item_count(());
13341334+ ///Marker type for the `cid` field
13351335+ pub struct cid(());
13361336 }
13371337}
13381338···15761576impl<'a, S> ListViewBuilder<'a, S>
15771577where
15781578 S: list_view_state::State,
15791579- S::Uri: list_view_state::IsSet,
15801579 S::Name: list_view_state::IsSet,
15811581- S::ItemCount: list_view_state::IsSet,
15821582- S::Cid: list_view_state::IsSet,
15831580 S::Purpose: list_view_state::IsSet,
15841581 S::IndexedAt: list_view_state::IsSet,
15851582 S::Creator: list_view_state::IsSet,
15831583+ S::Uri: list_view_state::IsSet,
15841584+ S::ItemCount: list_view_state::IsSet,
15851585+ S::Cid: list_view_state::IsSet,
15861586{
15871587 /// Build the final struct
15881588 pub fn build(self) -> ListView<'a> {
···16961696 }
16971697 /// State trait tracking which required fields have been set
16981698 pub trait State: sealed::Sealed {
16991699- type CommunityTags;
17001700- type Resource;
17011699 type AuthorTags;
17001700+ type Resource;
17011701+ type CommunityTags;
17021702 }
17031703 /// Empty state - all required fields are unset
17041704 pub struct Empty(());
17051705 impl sealed::Sealed for Empty {}
17061706 impl State for Empty {
17071707+ type AuthorTags = Unset;
17081708+ type Resource = Unset;
17071709 type CommunityTags = Unset;
17081708- type Resource = Unset;
17091709- type AuthorTags = Unset;
17101710 }
17111711- ///State transition - sets the `community_tags` field to Set
17121712- pub struct SetCommunityTags<S: State = Empty>(PhantomData<fn() -> S>);
17131713- impl<S: State> sealed::Sealed for SetCommunityTags<S> {}
17141714- impl<S: State> State for SetCommunityTags<S> {
17151715- type CommunityTags = Set<members::community_tags>;
17111711+ ///State transition - sets the `author_tags` field to Set
17121712+ pub struct SetAuthorTags<S: State = Empty>(PhantomData<fn() -> S>);
17131713+ impl<S: State> sealed::Sealed for SetAuthorTags<S> {}
17141714+ impl<S: State> State for SetAuthorTags<S> {
17151715+ type AuthorTags = Set<members::author_tags>;
17161716 type Resource = S::Resource;
17171717- type AuthorTags = S::AuthorTags;
17171717+ type CommunityTags = S::CommunityTags;
17181718 }
17191719 ///State transition - sets the `resource` field to Set
17201720 pub struct SetResource<S: State = Empty>(PhantomData<fn() -> S>);
17211721 impl<S: State> sealed::Sealed for SetResource<S> {}
17221722 impl<S: State> State for SetResource<S> {
17231723- type CommunityTags = S::CommunityTags;
17231723+ type AuthorTags = S::AuthorTags;
17241724 type Resource = Set<members::resource>;
17251725+ type CommunityTags = S::CommunityTags;
17261726+ }
17271727+ ///State transition - sets the `community_tags` field to Set
17281728+ pub struct SetCommunityTags<S: State = Empty>(PhantomData<fn() -> S>);
17291729+ impl<S: State> sealed::Sealed for SetCommunityTags<S> {}
17301730+ impl<S: State> State for SetCommunityTags<S> {
17251731 type AuthorTags = S::AuthorTags;
17261726- }
17271727- ///State transition - sets the `author_tags` field to Set
17281728- pub struct SetAuthorTags<S: State = Empty>(PhantomData<fn() -> S>);
17291729- impl<S: State> sealed::Sealed for SetAuthorTags<S> {}
17301730- impl<S: State> State for SetAuthorTags<S> {
17311731- type CommunityTags = S::CommunityTags;
17321732 type Resource = S::Resource;
17331733- type AuthorTags = Set<members::author_tags>;
17331733+ type CommunityTags = Set<members::community_tags>;
17341734 }
17351735 /// Marker types for field names
17361736 #[allow(non_camel_case_types)]
17371737 pub mod members {
17381738- ///Marker type for the `community_tags` field
17391739- pub struct community_tags(());
17381738+ ///Marker type for the `author_tags` field
17391739+ pub struct author_tags(());
17401740 ///Marker type for the `resource` field
17411741 pub struct resource(());
17421742- ///Marker type for the `author_tags` field
17431743- pub struct author_tags(());
17421742+ ///Marker type for the `community_tags` field
17431743+ pub struct community_tags(());
17441744 }
17451745}
17461746···18531853impl<'a, S> ResourceTagsViewBuilder<'a, S>
18541854where
18551855 S: resource_tags_view_state::State,
18561856- S::CommunityTags: resource_tags_view_state::IsSet,
18571857- S::Resource: resource_tags_view_state::IsSet,
18581856 S::AuthorTags: resource_tags_view_state::IsSet,
18571857+ S::Resource: resource_tags_view_state::IsSet,
18581858+ S::CommunityTags: resource_tags_view_state::IsSet,
18591859{
18601860 /// Build the final struct
18611861 pub fn build(self) -> ResourceTagsView<'a> {
···19521952 }
19531953 /// State trait tracking which required fields have been set
19541954 pub trait State: sealed::Sealed {
19551955+ type Tag;
19561956+ type Uri;
19551957 type CreatedAt;
19561958 type AppliedBy;
19571957- type Uri;
19581958- type Tag;
19591959 }
19601960 /// Empty state - all required fields are unset
19611961 pub struct Empty(());
19621962 impl sealed::Sealed for Empty {}
19631963 impl State for Empty {
19641964+ type Tag = Unset;
19651965+ type Uri = Unset;
19641966 type CreatedAt = Unset;
19651967 type AppliedBy = Unset;
19661966- type Uri = Unset;
19671967- type Tag = Unset;
19681968+ }
19691969+ ///State transition - sets the `tag` field to Set
19701970+ pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
19711971+ impl<S: State> sealed::Sealed for SetTag<S> {}
19721972+ impl<S: State> State for SetTag<S> {
19731973+ type Tag = Set<members::tag>;
19741974+ type Uri = S::Uri;
19751975+ type CreatedAt = S::CreatedAt;
19761976+ type AppliedBy = S::AppliedBy;
19771977+ }
19781978+ ///State transition - sets the `uri` field to Set
19791979+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
19801980+ impl<S: State> sealed::Sealed for SetUri<S> {}
19811981+ impl<S: State> State for SetUri<S> {
19821982+ type Tag = S::Tag;
19831983+ type Uri = Set<members::uri>;
19841984+ type CreatedAt = S::CreatedAt;
19851985+ type AppliedBy = S::AppliedBy;
19681986 }
19691987 ///State transition - sets the `created_at` field to Set
19701988 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
19711989 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
19721990 impl<S: State> State for SetCreatedAt<S> {
19911991+ type Tag = S::Tag;
19921992+ type Uri = S::Uri;
19731993 type CreatedAt = Set<members::created_at>;
19741994 type AppliedBy = S::AppliedBy;
19751975- type Uri = S::Uri;
19761976- type Tag = S::Tag;
19771995 }
19781996 ///State transition - sets the `applied_by` field to Set
19791997 pub struct SetAppliedBy<S: State = Empty>(PhantomData<fn() -> S>);
19801998 impl<S: State> sealed::Sealed for SetAppliedBy<S> {}
19811999 impl<S: State> State for SetAppliedBy<S> {
19821982- type CreatedAt = S::CreatedAt;
19831983- type AppliedBy = Set<members::applied_by>;
19841984- type Uri = S::Uri;
19852000 type Tag = S::Tag;
19861986- }
19871987- ///State transition - sets the `uri` field to Set
19881988- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
19891989- impl<S: State> sealed::Sealed for SetUri<S> {}
19901990- impl<S: State> State for SetUri<S> {
20012001+ type Uri = S::Uri;
19912002 type CreatedAt = S::CreatedAt;
19921992- type AppliedBy = S::AppliedBy;
19931993- type Uri = Set<members::uri>;
19941994- type Tag = S::Tag;
19951995- }
19961996- ///State transition - sets the `tag` field to Set
19971997- pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
19981998- impl<S: State> sealed::Sealed for SetTag<S> {}
19991999- impl<S: State> State for SetTag<S> {
20002000- type CreatedAt = S::CreatedAt;
20012001- type AppliedBy = S::AppliedBy;
20022002- type Uri = S::Uri;
20032003- type Tag = Set<members::tag>;
20032003+ type AppliedBy = Set<members::applied_by>;
20042004 }
20052005 /// Marker types for field names
20062006 #[allow(non_camel_case_types)]
20072007 pub mod members {
20082008+ ///Marker type for the `tag` field
20092009+ pub struct tag(());
20102010+ ///Marker type for the `uri` field
20112011+ pub struct uri(());
20082012 ///Marker type for the `created_at` field
20092013 pub struct created_at(());
20102014 ///Marker type for the `applied_by` field
20112015 pub struct applied_by(());
20122012- ///Marker type for the `uri` field
20132013- pub struct uri(());
20142014- ///Marker type for the `tag` field
20152015- pub struct tag(());
20162016 }
20172017}
20182018···21252125impl<'a, S> TagApplicationViewBuilder<'a, S>
21262126where
21272127 S: tag_application_view_state::State,
21282128+ S::Tag: tag_application_view_state::IsSet,
21292129+ S::Uri: tag_application_view_state::IsSet,
21282130 S::CreatedAt: tag_application_view_state::IsSet,
21292131 S::AppliedBy: tag_application_view_state::IsSet,
21302130- S::Uri: tag_application_view_state::IsSet,
21312131- S::Tag: tag_application_view_state::IsSet,
21322132{
21332133 /// Build the final struct
21342134 pub fn build(self) -> TagApplicationView<'a> {
+13-13
crates/weaver-api/src/sh_weaver/graph/bookmark.rs
···3838 }
3939 /// State trait tracking which required fields have been set
4040 pub trait State: sealed::Sealed {
4141- type CreatedAt;
4241 type Subject;
4242+ type CreatedAt;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848- type CreatedAt = Unset;
4948 type Subject = Unset;
5050- }
5151- ///State transition - sets the `created_at` field to Set
5252- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5454- impl<S: State> State for SetCreatedAt<S> {
5555- type CreatedAt = Set<members::created_at>;
5656- type Subject = S::Subject;
4949+ type CreatedAt = Unset;
5750 }
5851 ///State transition - sets the `subject` field to Set
5952 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
6053 impl<S: State> sealed::Sealed for SetSubject<S> {}
6154 impl<S: State> State for SetSubject<S> {
6262- type CreatedAt = S::CreatedAt;
6355 type Subject = Set<members::subject>;
5656+ type CreatedAt = S::CreatedAt;
5757+ }
5858+ ///State transition - sets the `created_at` field to Set
5959+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6060+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
6161+ impl<S: State> State for SetCreatedAt<S> {
6262+ type Subject = S::Subject;
6363+ type CreatedAt = Set<members::created_at>;
6464 }
6565 /// Marker types for field names
6666 #[allow(non_camel_case_types)]
6767 pub mod members {
6868- ///Marker type for the `created_at` field
6969- pub struct created_at(());
7068 ///Marker type for the `subject` field
7169 pub struct subject(());
7070+ ///Marker type for the `created_at` field
7171+ pub struct created_at(());
7272 }
7373}
7474···158158impl<'a, S> BookmarkBuilder<'a, S>
159159where
160160 S: bookmark_state::State,
161161- S::CreatedAt: bookmark_state::IsSet,
162161 S::Subject: bookmark_state::IsSet,
162162+ S::CreatedAt: bookmark_state::IsSet,
163163{
164164 /// Build the final struct
165165 pub fn build(self) -> Bookmark<'a> {
+13-13
crates/weaver-api/src/sh_weaver/graph/like.rs
···3434 }
3535 /// State trait tracking which required fields have been set
3636 pub trait State: sealed::Sealed {
3737- type Subject;
3837 type CreatedAt;
3838+ type Subject;
3939 }
4040 /// Empty state - all required fields are unset
4141 pub struct Empty(());
4242 impl sealed::Sealed for Empty {}
4343 impl State for Empty {
4444- type Subject = Unset;
4544 type CreatedAt = Unset;
4646- }
4747- ///State transition - sets the `subject` field to Set
4848- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
4949- impl<S: State> sealed::Sealed for SetSubject<S> {}
5050- impl<S: State> State for SetSubject<S> {
5151- type Subject = Set<members::subject>;
5252- type CreatedAt = S::CreatedAt;
4545+ type Subject = Unset;
5346 }
5447 ///State transition - sets the `created_at` field to Set
5548 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5649 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5750 impl<S: State> State for SetCreatedAt<S> {
5858- type Subject = S::Subject;
5951 type CreatedAt = Set<members::created_at>;
5252+ type Subject = S::Subject;
5353+ }
5454+ ///State transition - sets the `subject` field to Set
5555+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5656+ impl<S: State> sealed::Sealed for SetSubject<S> {}
5757+ impl<S: State> State for SetSubject<S> {
5858+ type CreatedAt = S::CreatedAt;
5959+ type Subject = Set<members::subject>;
6060 }
6161 /// Marker types for field names
6262 #[allow(non_camel_case_types)]
6363 pub mod members {
6464- ///Marker type for the `subject` field
6565- pub struct subject(());
6664 ///Marker type for the `created_at` field
6765 pub struct created_at(());
6666+ ///Marker type for the `subject` field
6767+ pub struct subject(());
6868 }
6969}
7070···137137impl<'a, S> LikeBuilder<'a, S>
138138where
139139 S: like_state::State,
140140- S::Subject: like_state::IsSet,
141140 S::CreatedAt: like_state::IsSet,
141141+ S::Subject: like_state::IsSet,
142142{
143143 /// Build the final struct
144144 pub fn build(self) -> Like<'a> {
+15-15
crates/weaver-api/src/sh_weaver/graph/list.rs
···130130 /// State trait tracking which required fields have been set
131131 pub trait State: sealed::Sealed {
132132 type Name;
133133- type CreatedAt;
134133 type Purpose;
134134+ type CreatedAt;
135135 }
136136 /// Empty state - all required fields are unset
137137 pub struct Empty(());
138138 impl sealed::Sealed for Empty {}
139139 impl State for Empty {
140140 type Name = Unset;
141141- type CreatedAt = Unset;
142141 type Purpose = Unset;
142142+ type CreatedAt = Unset;
143143 }
144144 ///State transition - sets the `name` field to Set
145145 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
146146 impl<S: State> sealed::Sealed for SetName<S> {}
147147 impl<S: State> State for SetName<S> {
148148 type Name = Set<members::name>;
149149- type CreatedAt = S::CreatedAt;
150149 type Purpose = S::Purpose;
151151- }
152152- ///State transition - sets the `created_at` field to Set
153153- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
154154- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
155155- impl<S: State> State for SetCreatedAt<S> {
156156- type Name = S::Name;
157157- type CreatedAt = Set<members::created_at>;
158158- type Purpose = S::Purpose;
150150+ type CreatedAt = S::CreatedAt;
159151 }
160152 ///State transition - sets the `purpose` field to Set
161153 pub struct SetPurpose<S: State = Empty>(PhantomData<fn() -> S>);
162154 impl<S: State> sealed::Sealed for SetPurpose<S> {}
163155 impl<S: State> State for SetPurpose<S> {
164156 type Name = S::Name;
165165- type CreatedAt = S::CreatedAt;
166157 type Purpose = Set<members::purpose>;
158158+ type CreatedAt = S::CreatedAt;
159159+ }
160160+ ///State transition - sets the `created_at` field to Set
161161+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
162162+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
163163+ impl<S: State> State for SetCreatedAt<S> {
164164+ type Name = S::Name;
165165+ type Purpose = S::Purpose;
166166+ type CreatedAt = Set<members::created_at>;
167167 }
168168 /// Marker types for field names
169169 #[allow(non_camel_case_types)]
170170 pub mod members {
171171 ///Marker type for the `name` field
172172 pub struct name(());
173173+ ///Marker type for the `purpose` field
174174+ pub struct purpose(());
173175 ///Marker type for the `created_at` field
174176 pub struct created_at(());
175175- ///Marker type for the `purpose` field
176176- pub struct purpose(());
177177 }
178178}
179179···307307where
308308 S: list_state::State,
309309 S::Name: list_state::IsSet,
310310- S::CreatedAt: list_state::IsSet,
311310 S::Purpose: list_state::IsSet,
311311+ S::CreatedAt: list_state::IsSet,
312312{
313313 /// Build the final struct
314314 pub fn build(self) -> List<'a> {
+24-24
crates/weaver-api/src/sh_weaver/graph/listitem.rs
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040- type Subject;
4141- type List;
4240 type CreatedAt;
4141+ type List;
4242+ type Subject;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848+ type CreatedAt = Unset;
4949+ type List = Unset;
4850 type Subject = Unset;
4949- type List = Unset;
5050- type CreatedAt = Unset;
5151 }
5252- ///State transition - sets the `subject` field to Set
5353- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5454- impl<S: State> sealed::Sealed for SetSubject<S> {}
5555- impl<S: State> State for SetSubject<S> {
5656- type Subject = Set<members::subject>;
5252+ ///State transition - sets the `created_at` field to Set
5353+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
5555+ impl<S: State> State for SetCreatedAt<S> {
5656+ type CreatedAt = Set<members::created_at>;
5757 type List = S::List;
5858- type CreatedAt = S::CreatedAt;
5858+ type Subject = S::Subject;
5959 }
6060 ///State transition - sets the `list` field to Set
6161 pub struct SetList<S: State = Empty>(PhantomData<fn() -> S>);
6262 impl<S: State> sealed::Sealed for SetList<S> {}
6363 impl<S: State> State for SetList<S> {
6464- type Subject = S::Subject;
6565- type List = Set<members::list>;
6664 type CreatedAt = S::CreatedAt;
6565+ type List = Set<members::list>;
6666+ type Subject = S::Subject;
6767 }
6868- ///State transition - sets the `created_at` field to Set
6969- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
7070- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
7171- impl<S: State> State for SetCreatedAt<S> {
7272- type Subject = S::Subject;
6868+ ///State transition - sets the `subject` field to Set
6969+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
7070+ impl<S: State> sealed::Sealed for SetSubject<S> {}
7171+ impl<S: State> State for SetSubject<S> {
7272+ type CreatedAt = S::CreatedAt;
7373 type List = S::List;
7474- type CreatedAt = Set<members::created_at>;
7474+ type Subject = Set<members::subject>;
7575 }
7676 /// Marker types for field names
7777 #[allow(non_camel_case_types)]
7878 pub mod members {
7979+ ///Marker type for the `created_at` field
8080+ pub struct created_at(());
8181+ ///Marker type for the `list` field
8282+ pub struct list(());
7983 ///Marker type for the `subject` field
8084 pub struct subject(());
8181- ///Marker type for the `list` field
8282- pub struct list(());
8383- ///Marker type for the `created_at` field
8484- pub struct created_at(());
8585 }
8686}
8787···174174impl<'a, S> ListitemBuilder<'a, S>
175175where
176176 S: listitem_state::State,
177177- S::Subject: listitem_state::IsSet,
178178- S::List: listitem_state::IsSet,
179177 S::CreatedAt: listitem_state::IsSet,
178178+ S::List: listitem_state::IsSet,
179179+ S::Subject: listitem_state::IsSet,
180180{
181181 /// Build the final struct
182182 pub fn build(self) -> Listitem<'a> {
+15-15
crates/weaver-api/src/sh_weaver/graph/tag.rs
···3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040 type Tag;
4141- type CreatedAt;
4241 type Subject;
4242+ type CreatedAt;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848 type Tag = Unset;
4949- type CreatedAt = Unset;
5049 type Subject = Unset;
5050+ type CreatedAt = Unset;
5151 }
5252 ///State transition - sets the `tag` field to Set
5353 pub struct SetTag<S: State = Empty>(PhantomData<fn() -> S>);
5454 impl<S: State> sealed::Sealed for SetTag<S> {}
5555 impl<S: State> State for SetTag<S> {
5656 type Tag = Set<members::tag>;
5757- type CreatedAt = S::CreatedAt;
5857 type Subject = S::Subject;
5959- }
6060- ///State transition - sets the `created_at` field to Set
6161- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
6262- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
6363- impl<S: State> State for SetCreatedAt<S> {
6464- type Tag = S::Tag;
6565- type CreatedAt = Set<members::created_at>;
6666- type Subject = S::Subject;
5858+ type CreatedAt = S::CreatedAt;
6759 }
6860 ///State transition - sets the `subject` field to Set
6961 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
7062 impl<S: State> sealed::Sealed for SetSubject<S> {}
7163 impl<S: State> State for SetSubject<S> {
7264 type Tag = S::Tag;
7373- type CreatedAt = S::CreatedAt;
7465 type Subject = Set<members::subject>;
6666+ type CreatedAt = S::CreatedAt;
6767+ }
6868+ ///State transition - sets the `created_at` field to Set
6969+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
7070+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
7171+ impl<S: State> State for SetCreatedAt<S> {
7272+ type Tag = S::Tag;
7373+ type Subject = S::Subject;
7474+ type CreatedAt = Set<members::created_at>;
7575 }
7676 /// Marker types for field names
7777 #[allow(non_camel_case_types)]
7878 pub mod members {
7979 ///Marker type for the `tag` field
8080 pub struct tag(());
8181+ ///Marker type for the `subject` field
8282+ pub struct subject(());
8183 ///Marker type for the `created_at` field
8284 pub struct created_at(());
8383- ///Marker type for the `subject` field
8484- pub struct subject(());
8585 }
8686}
8787···175175where
176176 S: tag_state::State,
177177 S::Tag: tag_state::IsSet,
178178- S::CreatedAt: tag_state::IsSet,
179178 S::Subject: tag_state::IsSet,
179179+ S::CreatedAt: tag_state::IsSet,
180180{
181181 /// Build the final struct
182182 pub fn build(self) -> Tag<'a> {
+267-266
crates/weaver-api/src/sh_weaver/notebook.rs
···3030pub mod get_suggested_notebooks;
3131pub mod page;
3232pub mod resolve_entry;
3333+pub mod resolve_global_notebook;
3334pub mod resolve_notebook;
3435pub mod resolve_version_conflict;
3536pub mod search_entries;
···23982399 }
23992400 /// State trait tracking which required fields have been set
24002401 pub trait State: sealed::Sealed {
24012401- type Entry;
24022402 type Index;
24032403+ type Entry;
24032404 }
24042405 /// Empty state - all required fields are unset
24052406 pub struct Empty(());
24062407 impl sealed::Sealed for Empty {}
24072408 impl State for Empty {
24092409+ type Index = Unset;
24082410 type Entry = Unset;
24092409- type Index = Unset;
24102410- }
24112411- ///State transition - sets the `entry` field to Set
24122412- pub struct SetEntry<S: State = Empty>(PhantomData<fn() -> S>);
24132413- impl<S: State> sealed::Sealed for SetEntry<S> {}
24142414- impl<S: State> State for SetEntry<S> {
24152415- type Entry = Set<members::entry>;
24162416- type Index = S::Index;
24172411 }
24182412 ///State transition - sets the `index` field to Set
24192413 pub struct SetIndex<S: State = Empty>(PhantomData<fn() -> S>);
24202414 impl<S: State> sealed::Sealed for SetIndex<S> {}
24212415 impl<S: State> State for SetIndex<S> {
24222422- type Entry = S::Entry;
24232416 type Index = Set<members::index>;
24172417+ type Entry = S::Entry;
24182418+ }
24192419+ ///State transition - sets the `entry` field to Set
24202420+ pub struct SetEntry<S: State = Empty>(PhantomData<fn() -> S>);
24212421+ impl<S: State> sealed::Sealed for SetEntry<S> {}
24222422+ impl<S: State> State for SetEntry<S> {
24232423+ type Index = S::Index;
24242424+ type Entry = Set<members::entry>;
24242425 }
24252426 /// Marker types for field names
24262427 #[allow(non_camel_case_types)]
24272428 pub mod members {
24292429+ ///Marker type for the `index` field
24302430+ pub struct index(());
24282431 ///Marker type for the `entry` field
24292432 pub struct entry(());
24302430- ///Marker type for the `index` field
24312431- pub struct index(());
24322433 }
24332434}
24342435···25412542impl<'a, S> ChapterEntryViewBuilder<'a, S>
25422543where
25432544 S: chapter_entry_view_state::State,
25442544- S::Entry: chapter_entry_view_state::IsSet,
25452545 S::Index: chapter_entry_view_state::IsSet,
25462546+ S::Entry: chapter_entry_view_state::IsSet,
25462547{
25472548 /// Build the final struct
25482549 pub fn build(self) -> ChapterEntryView<'a> {
···26342635 /// State trait tracking which required fields have been set
26352636 pub trait State: sealed::Sealed {
26362637 type Cid;
26372637- type Notebook;
26382638 type Authors;
26392639- type Uri;
26402640- type IndexedAt;
26412639 type Record;
26402640+ type IndexedAt;
26412641+ type Uri;
26422642+ type Notebook;
26422643 }
26432644 /// Empty state - all required fields are unset
26442645 pub struct Empty(());
26452646 impl sealed::Sealed for Empty {}
26462647 impl State for Empty {
26472648 type Cid = Unset;
26482648- type Notebook = Unset;
26492649 type Authors = Unset;
26502650- type Uri = Unset;
26502650+ type Record = Unset;
26512651 type IndexedAt = Unset;
26522652- type Record = Unset;
26522652+ type Uri = Unset;
26532653+ type Notebook = Unset;
26532654 }
26542655 ///State transition - sets the `cid` field to Set
26552656 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
26562657 impl<S: State> sealed::Sealed for SetCid<S> {}
26572658 impl<S: State> State for SetCid<S> {
26582659 type Cid = Set<members::cid>;
26592659- type Notebook = S::Notebook;
26602660 type Authors = S::Authors;
26612661- type Uri = S::Uri;
26622662- type IndexedAt = S::IndexedAt;
26632661 type Record = S::Record;
26642664- }
26652665- ///State transition - sets the `notebook` field to Set
26662666- pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
26672667- impl<S: State> sealed::Sealed for SetNotebook<S> {}
26682668- impl<S: State> State for SetNotebook<S> {
26692669- type Cid = S::Cid;
26702670- type Notebook = Set<members::notebook>;
26712671- type Authors = S::Authors;
26622662+ type IndexedAt = S::IndexedAt;
26722663 type Uri = S::Uri;
26732673- type IndexedAt = S::IndexedAt;
26742674- type Record = S::Record;
26642664+ type Notebook = S::Notebook;
26752665 }
26762666 ///State transition - sets the `authors` field to Set
26772667 pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
26782668 impl<S: State> sealed::Sealed for SetAuthors<S> {}
26792669 impl<S: State> State for SetAuthors<S> {
26802670 type Cid = S::Cid;
26812681- type Notebook = S::Notebook;
26822671 type Authors = Set<members::authors>;
26832683- type Uri = S::Uri;
26842684- type IndexedAt = S::IndexedAt;
26852672 type Record = S::Record;
26732673+ type IndexedAt = S::IndexedAt;
26742674+ type Uri = S::Uri;
26752675+ type Notebook = S::Notebook;
26862676 }
26872687- ///State transition - sets the `uri` field to Set
26882688- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
26892689- impl<S: State> sealed::Sealed for SetUri<S> {}
26902690- impl<S: State> State for SetUri<S> {
26772677+ ///State transition - sets the `record` field to Set
26782678+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
26792679+ impl<S: State> sealed::Sealed for SetRecord<S> {}
26802680+ impl<S: State> State for SetRecord<S> {
26912681 type Cid = S::Cid;
26922692- type Notebook = S::Notebook;
26932682 type Authors = S::Authors;
26942694- type Uri = Set<members::uri>;
26832683+ type Record = Set<members::record>;
26952684 type IndexedAt = S::IndexedAt;
26962696- type Record = S::Record;
26852685+ type Uri = S::Uri;
26862686+ type Notebook = S::Notebook;
26972687 }
26982688 ///State transition - sets the `indexed_at` field to Set
26992689 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
27002690 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
27012691 impl<S: State> State for SetIndexedAt<S> {
27022692 type Cid = S::Cid;
27032703- type Notebook = S::Notebook;
27042693 type Authors = S::Authors;
27052705- type Uri = S::Uri;
26942694+ type Record = S::Record;
27062695 type IndexedAt = Set<members::indexed_at>;
26962696+ type Uri = S::Uri;
26972697+ type Notebook = S::Notebook;
26982698+ }
26992699+ ///State transition - sets the `uri` field to Set
27002700+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
27012701+ impl<S: State> sealed::Sealed for SetUri<S> {}
27022702+ impl<S: State> State for SetUri<S> {
27032703+ type Cid = S::Cid;
27042704+ type Authors = S::Authors;
27072705 type Record = S::Record;
27062706+ type IndexedAt = S::IndexedAt;
27072707+ type Uri = Set<members::uri>;
27082708+ type Notebook = S::Notebook;
27082709 }
27092709- ///State transition - sets the `record` field to Set
27102710- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
27112711- impl<S: State> sealed::Sealed for SetRecord<S> {}
27122712- impl<S: State> State for SetRecord<S> {
27102710+ ///State transition - sets the `notebook` field to Set
27112711+ pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
27122712+ impl<S: State> sealed::Sealed for SetNotebook<S> {}
27132713+ impl<S: State> State for SetNotebook<S> {
27132714 type Cid = S::Cid;
27142714- type Notebook = S::Notebook;
27152715 type Authors = S::Authors;
27162716+ type Record = S::Record;
27172717+ type IndexedAt = S::IndexedAt;
27162718 type Uri = S::Uri;
27172717- type IndexedAt = S::IndexedAt;
27182718- type Record = Set<members::record>;
27192719+ type Notebook = Set<members::notebook>;
27192720 }
27202721 /// Marker types for field names
27212722 #[allow(non_camel_case_types)]
27222723 pub mod members {
27232724 ///Marker type for the `cid` field
27242725 pub struct cid(());
27252725- ///Marker type for the `notebook` field
27262726- pub struct notebook(());
27272726 ///Marker type for the `authors` field
27282727 pub struct authors(());
27282728+ ///Marker type for the `record` field
27292729+ pub struct record(());
27302730+ ///Marker type for the `indexed_at` field
27312731+ pub struct indexed_at(());
27292732 ///Marker type for the `uri` field
27302733 pub struct uri(());
27312731- ///Marker type for the `indexed_at` field
27322732- pub struct indexed_at(());
27332733- ///Marker type for the `record` field
27342734- pub struct record(());
27342734+ ///Marker type for the `notebook` field
27352735+ pub struct notebook(());
27352736 }
27362737}
27372738···29492950where
29502951 S: chapter_view_state::State,
29512952 S::Cid: chapter_view_state::IsSet,
29522952- S::Notebook: chapter_view_state::IsSet,
29532953 S::Authors: chapter_view_state::IsSet,
29542954- S::Uri: chapter_view_state::IsSet,
29552955- S::IndexedAt: chapter_view_state::IsSet,
29562954 S::Record: chapter_view_state::IsSet,
29552955+ S::IndexedAt: chapter_view_state::IsSet,
29562956+ S::Uri: chapter_view_state::IsSet,
29572957+ S::Notebook: chapter_view_state::IsSet,
29572958{
29582959 /// Build the final struct
29592960 pub fn build(self) -> ChapterView<'a> {
···33373338 }
33383339 /// State trait tracking which required fields have been set
33393340 pub trait State: sealed::Sealed {
33403340- type Cid;
33413341- type Uri;
33423342- type Record;
33433341 type IndexedAt;
33443342 type Authors;
33433343+ type Record;
33443344+ type Uri;
33453345+ type Cid;
33453346 }
33463347 /// Empty state - all required fields are unset
33473348 pub struct Empty(());
33483349 impl sealed::Sealed for Empty {}
33493350 impl State for Empty {
33503350- type Cid = Unset;
33513351- type Uri = Unset;
33523352- type Record = Unset;
33533351 type IndexedAt = Unset;
33543352 type Authors = Unset;
33533353+ type Record = Unset;
33543354+ type Uri = Unset;
33553355+ type Cid = Unset;
33553356 }
33563356- ///State transition - sets the `cid` field to Set
33573357- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
33583358- impl<S: State> sealed::Sealed for SetCid<S> {}
33593359- impl<S: State> State for SetCid<S> {
33603360- type Cid = Set<members::cid>;
33573357+ ///State transition - sets the `indexed_at` field to Set
33583358+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
33593359+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
33603360+ impl<S: State> State for SetIndexedAt<S> {
33613361+ type IndexedAt = Set<members::indexed_at>;
33623362+ type Authors = S::Authors;
33633363+ type Record = S::Record;
33613364 type Uri = S::Uri;
33653365+ type Cid = S::Cid;
33663366+ }
33673367+ ///State transition - sets the `authors` field to Set
33683368+ pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
33693369+ impl<S: State> sealed::Sealed for SetAuthors<S> {}
33703370+ impl<S: State> State for SetAuthors<S> {
33713371+ type IndexedAt = S::IndexedAt;
33723372+ type Authors = Set<members::authors>;
33623373 type Record = S::Record;
33743374+ type Uri = S::Uri;
33753375+ type Cid = S::Cid;
33763376+ }
33773377+ ///State transition - sets the `record` field to Set
33783378+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
33793379+ impl<S: State> sealed::Sealed for SetRecord<S> {}
33803380+ impl<S: State> State for SetRecord<S> {
33633381 type IndexedAt = S::IndexedAt;
33643382 type Authors = S::Authors;
33833383+ type Record = Set<members::record>;
33843384+ type Uri = S::Uri;
33853385+ type Cid = S::Cid;
33653386 }
33663387 ///State transition - sets the `uri` field to Set
33673388 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
33683389 impl<S: State> sealed::Sealed for SetUri<S> {}
33693390 impl<S: State> State for SetUri<S> {
33703370- type Cid = S::Cid;
33713371- type Uri = Set<members::uri>;
33723372- type Record = S::Record;
33733391 type IndexedAt = S::IndexedAt;
33743392 type Authors = S::Authors;
33933393+ type Record = S::Record;
33943394+ type Uri = Set<members::uri>;
33953395+ type Cid = S::Cid;
33753396 }
33763376- ///State transition - sets the `record` field to Set
33773377- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
33783378- impl<S: State> sealed::Sealed for SetRecord<S> {}
33793379- impl<S: State> State for SetRecord<S> {
33803380- type Cid = S::Cid;
33813381- type Uri = S::Uri;
33823382- type Record = Set<members::record>;
33973397+ ///State transition - sets the `cid` field to Set
33983398+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
33993399+ impl<S: State> sealed::Sealed for SetCid<S> {}
34003400+ impl<S: State> State for SetCid<S> {
33833401 type IndexedAt = S::IndexedAt;
33843402 type Authors = S::Authors;
33853385- }
33863386- ///State transition - sets the `indexed_at` field to Set
33873387- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
33883388- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
33893389- impl<S: State> State for SetIndexedAt<S> {
33903390- type Cid = S::Cid;
33913391- type Uri = S::Uri;
33923403 type Record = S::Record;
33933393- type IndexedAt = Set<members::indexed_at>;
33943394- type Authors = S::Authors;
33953395- }
33963396- ///State transition - sets the `authors` field to Set
33973397- pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
33983398- impl<S: State> sealed::Sealed for SetAuthors<S> {}
33993399- impl<S: State> State for SetAuthors<S> {
34003400- type Cid = S::Cid;
34013404 type Uri = S::Uri;
34023402- type Record = S::Record;
34033403- type IndexedAt = S::IndexedAt;
34043404- type Authors = Set<members::authors>;
34053405+ type Cid = Set<members::cid>;
34053406 }
34063407 /// Marker types for field names
34073408 #[allow(non_camel_case_types)]
34083409 pub mod members {
34093409- ///Marker type for the `cid` field
34103410- pub struct cid(());
34113411- ///Marker type for the `uri` field
34123412- pub struct uri(());
34133413- ///Marker type for the `record` field
34143414- pub struct record(());
34153410 ///Marker type for the `indexed_at` field
34163411 pub struct indexed_at(());
34173412 ///Marker type for the `authors` field
34183413 pub struct authors(());
34143414+ ///Marker type for the `record` field
34153415+ pub struct record(());
34163416+ ///Marker type for the `uri` field
34173417+ pub struct uri(());
34183418+ ///Marker type for the `cid` field
34193419+ pub struct cid(());
34193420 }
34203421}
34213422···37523753impl<'a, S> EntryViewBuilder<'a, S>
37533754where
37543755 S: entry_view_state::State,
37553755- S::Cid: entry_view_state::IsSet,
37563756- S::Uri: entry_view_state::IsSet,
37573757- S::Record: entry_view_state::IsSet,
37583756 S::IndexedAt: entry_view_state::IsSet,
37593757 S::Authors: entry_view_state::IsSet,
37583758+ S::Record: entry_view_state::IsSet,
37593759+ S::Uri: entry_view_state::IsSet,
37603760+ S::Cid: entry_view_state::IsSet,
37603761{
37613762 /// Build the final struct
37623763 pub fn build(self) -> EntryView<'a> {
···43074308 }
43084309 /// State trait tracking which required fields have been set
43094310 pub trait State: sealed::Sealed {
43104310- type Cid;
43114311- type Authors;
43124311 type Record;
43124312+ type Cid;
43134313 type Uri;
43144314+ type Authors;
43144315 type IndexedAt;
43154316 }
43164317 /// Empty state - all required fields are unset
43174318 pub struct Empty(());
43184319 impl sealed::Sealed for Empty {}
43194320 impl State for Empty {
43214321+ type Record = Unset;
43204322 type Cid = Unset;
43234323+ type Uri = Unset;
43214324 type Authors = Unset;
43224322- type Record = Unset;
43234323- type Uri = Unset;
43244325 type IndexedAt = Unset;
43254326 }
43274327+ ///State transition - sets the `record` field to Set
43284328+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
43294329+ impl<S: State> sealed::Sealed for SetRecord<S> {}
43304330+ impl<S: State> State for SetRecord<S> {
43314331+ type Record = Set<members::record>;
43324332+ type Cid = S::Cid;
43334333+ type Uri = S::Uri;
43344334+ type Authors = S::Authors;
43354335+ type IndexedAt = S::IndexedAt;
43364336+ }
43264337 ///State transition - sets the `cid` field to Set
43274338 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
43284339 impl<S: State> sealed::Sealed for SetCid<S> {}
43294340 impl<S: State> State for SetCid<S> {
43414341+ type Record = S::Record;
43304342 type Cid = Set<members::cid>;
43434343+ type Uri = S::Uri;
43314344 type Authors = S::Authors;
43454345+ type IndexedAt = S::IndexedAt;
43464346+ }
43474347+ ///State transition - sets the `uri` field to Set
43484348+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
43494349+ impl<S: State> sealed::Sealed for SetUri<S> {}
43504350+ impl<S: State> State for SetUri<S> {
43324351 type Record = S::Record;
43334333- type Uri = S::Uri;
43524352+ type Cid = S::Cid;
43534353+ type Uri = Set<members::uri>;
43544354+ type Authors = S::Authors;
43344355 type IndexedAt = S::IndexedAt;
43354356 }
43364357 ///State transition - sets the `authors` field to Set
43374358 pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
43384359 impl<S: State> sealed::Sealed for SetAuthors<S> {}
43394360 impl<S: State> State for SetAuthors<S> {
43404340- type Cid = S::Cid;
43414341- type Authors = Set<members::authors>;
43424361 type Record = S::Record;
43434343- type Uri = S::Uri;
43444344- type IndexedAt = S::IndexedAt;
43454345- }
43464346- ///State transition - sets the `record` field to Set
43474347- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
43484348- impl<S: State> sealed::Sealed for SetRecord<S> {}
43494349- impl<S: State> State for SetRecord<S> {
43504362 type Cid = S::Cid;
43514351- type Authors = S::Authors;
43524352- type Record = Set<members::record>;
43534363 type Uri = S::Uri;
43544354- type IndexedAt = S::IndexedAt;
43554355- }
43564356- ///State transition - sets the `uri` field to Set
43574357- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
43584358- impl<S: State> sealed::Sealed for SetUri<S> {}
43594359- impl<S: State> State for SetUri<S> {
43604360- type Cid = S::Cid;
43614361- type Authors = S::Authors;
43624362- type Record = S::Record;
43634363- type Uri = Set<members::uri>;
43644364+ type Authors = Set<members::authors>;
43644365 type IndexedAt = S::IndexedAt;
43654366 }
43664367 ///State transition - sets the `indexed_at` field to Set
43674368 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
43684369 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
43694370 impl<S: State> State for SetIndexedAt<S> {
43714371+ type Record = S::Record;
43704372 type Cid = S::Cid;
43734373+ type Uri = S::Uri;
43714374 type Authors = S::Authors;
43724372- type Record = S::Record;
43734373- type Uri = S::Uri;
43744375 type IndexedAt = Set<members::indexed_at>;
43754376 }
43764377 /// Marker types for field names
43774378 #[allow(non_camel_case_types)]
43784379 pub mod members {
43794379- ///Marker type for the `cid` field
43804380- pub struct cid(());
43814381- ///Marker type for the `authors` field
43824382- pub struct authors(());
43834380 ///Marker type for the `record` field
43844381 pub struct record(());
43824382+ ///Marker type for the `cid` field
43834383+ pub struct cid(());
43854384 ///Marker type for the `uri` field
43864385 pub struct uri(());
43864386+ ///Marker type for the `authors` field
43874387+ pub struct authors(());
43874388 ///Marker type for the `indexed_at` field
43884389 pub struct indexed_at(());
43894390 }
···47524753impl<'a, S> NotebookViewBuilder<'a, S>
47534754where
47544755 S: notebook_view_state::State,
47554755- S::Cid: notebook_view_state::IsSet,
47564756- S::Authors: notebook_view_state::IsSet,
47574756 S::Record: notebook_view_state::IsSet,
47574757+ S::Cid: notebook_view_state::IsSet,
47584758 S::Uri: notebook_view_state::IsSet,
47594759+ S::Authors: notebook_view_state::IsSet,
47594760 S::IndexedAt: notebook_view_state::IsSet,
47604761{
47614762 /// Build the final struct
···48714872 }
48724873 /// State trait tracking which required fields have been set
48734874 pub trait State: sealed::Sealed {
48744874- type IndexedAt;
48754875- type Uri;
48764875 type Notebook;
48764876+ type Uri;
48774877+ type Record;
48774878 type Cid;
48784878- type Record;
48794879+ type IndexedAt;
48794880 }
48804881 /// Empty state - all required fields are unset
48814882 pub struct Empty(());
48824883 impl sealed::Sealed for Empty {}
48834884 impl State for Empty {
48844884- type IndexedAt = Unset;
48854885+ type Notebook = Unset;
48854886 type Uri = Unset;
48864886- type Notebook = Unset;
48874887- type Cid = Unset;
48884887 type Record = Unset;
48884888+ type Cid = Unset;
48894889+ type IndexedAt = Unset;
48894890 }
48904890- ///State transition - sets the `indexed_at` field to Set
48914891- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
48924892- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
48934893- impl<S: State> State for SetIndexedAt<S> {
48944894- type IndexedAt = Set<members::indexed_at>;
48914891+ ///State transition - sets the `notebook` field to Set
48924892+ pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
48934893+ impl<S: State> sealed::Sealed for SetNotebook<S> {}
48944894+ impl<S: State> State for SetNotebook<S> {
48954895+ type Notebook = Set<members::notebook>;
48954896 type Uri = S::Uri;
48964896- type Notebook = S::Notebook;
48974897+ type Record = S::Record;
48974898 type Cid = S::Cid;
48984898- type Record = S::Record;
48994899+ type IndexedAt = S::IndexedAt;
48994900 }
49004901 ///State transition - sets the `uri` field to Set
49014902 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
49024903 impl<S: State> sealed::Sealed for SetUri<S> {}
49034904 impl<S: State> State for SetUri<S> {
49044904- type IndexedAt = S::IndexedAt;
49054905- type Uri = Set<members::uri>;
49064905 type Notebook = S::Notebook;
49074907- type Cid = S::Cid;
49064906+ type Uri = Set<members::uri>;
49084907 type Record = S::Record;
49094909- }
49104910- ///State transition - sets the `notebook` field to Set
49114911- pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
49124912- impl<S: State> sealed::Sealed for SetNotebook<S> {}
49134913- impl<S: State> State for SetNotebook<S> {
49084908+ type Cid = S::Cid;
49144909 type IndexedAt = S::IndexedAt;
49104910+ }
49114911+ ///State transition - sets the `record` field to Set
49124912+ pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
49134913+ impl<S: State> sealed::Sealed for SetRecord<S> {}
49144914+ impl<S: State> State for SetRecord<S> {
49154915+ type Notebook = S::Notebook;
49154916 type Uri = S::Uri;
49164916- type Notebook = Set<members::notebook>;
49174917+ type Record = Set<members::record>;
49174918 type Cid = S::Cid;
49184918- type Record = S::Record;
49194919+ type IndexedAt = S::IndexedAt;
49194920 }
49204921 ///State transition - sets the `cid` field to Set
49214922 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
49224923 impl<S: State> sealed::Sealed for SetCid<S> {}
49234924 impl<S: State> State for SetCid<S> {
49244924- type IndexedAt = S::IndexedAt;
49254925+ type Notebook = S::Notebook;
49254926 type Uri = S::Uri;
49264926- type Notebook = S::Notebook;
49274927+ type Record = S::Record;
49274928 type Cid = Set<members::cid>;
49284928- type Record = S::Record;
49294929+ type IndexedAt = S::IndexedAt;
49294930 }
49304930- ///State transition - sets the `record` field to Set
49314931- pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
49324932- impl<S: State> sealed::Sealed for SetRecord<S> {}
49334933- impl<S: State> State for SetRecord<S> {
49344934- type IndexedAt = S::IndexedAt;
49314931+ ///State transition - sets the `indexed_at` field to Set
49324932+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
49334933+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
49344934+ impl<S: State> State for SetIndexedAt<S> {
49354935+ type Notebook = S::Notebook;
49354936 type Uri = S::Uri;
49364936- type Notebook = S::Notebook;
49374937+ type Record = S::Record;
49374938 type Cid = S::Cid;
49384938- type Record = Set<members::record>;
49394939+ type IndexedAt = Set<members::indexed_at>;
49394940 }
49404941 /// Marker types for field names
49414942 #[allow(non_camel_case_types)]
49424943 pub mod members {
49434943- ///Marker type for the `indexed_at` field
49444944- pub struct indexed_at(());
49454945- ///Marker type for the `uri` field
49464946- pub struct uri(());
49474944 ///Marker type for the `notebook` field
49484945 pub struct notebook(());
49494949- ///Marker type for the `cid` field
49504950- pub struct cid(());
49464946+ ///Marker type for the `uri` field
49474947+ pub struct uri(());
49514948 ///Marker type for the `record` field
49524949 pub struct record(());
49504950+ ///Marker type for the `cid` field
49514951+ pub struct cid(());
49524952+ ///Marker type for the `indexed_at` field
49534953+ pub struct indexed_at(());
49534954 }
49544955}
49554956···51365137impl<'a, S> PageViewBuilder<'a, S>
51375138where
51385139 S: page_view_state::State,
51395139- S::IndexedAt: page_view_state::IsSet,
51405140- S::Uri: page_view_state::IsSet,
51415140 S::Notebook: page_view_state::IsSet,
51425142- S::Cid: page_view_state::IsSet,
51415141+ S::Uri: page_view_state::IsSet,
51435142 S::Record: page_view_state::IsSet,
51435143+ S::Cid: page_view_state::IsSet,
51445144+ S::IndexedAt: page_view_state::IsSet,
51445145{
51455146 /// Build the final struct
51465147 pub fn build(self) -> PageView<'a> {
···52325233 }
52335234 /// State trait tracking which required fields have been set
52345235 pub trait State: sealed::Sealed {
52355235- type Source;
52365236- type Scope;
52375236 type GrantedAt;
52375237+ type Scope;
52385238 type Did;
52395239+ type Source;
52395240 }
52405241 /// Empty state - all required fields are unset
52415242 pub struct Empty(());
52425243 impl sealed::Sealed for Empty {}
52435244 impl State for Empty {
52445244- type Source = Unset;
52455245- type Scope = Unset;
52465245 type GrantedAt = Unset;
52465246+ type Scope = Unset;
52475247 type Did = Unset;
52485248+ type Source = Unset;
52485249 }
52495249- ///State transition - sets the `source` field to Set
52505250- pub struct SetSource<S: State = Empty>(PhantomData<fn() -> S>);
52515251- impl<S: State> sealed::Sealed for SetSource<S> {}
52525252- impl<S: State> State for SetSource<S> {
52535253- type Source = Set<members::source>;
52505250+ ///State transition - sets the `granted_at` field to Set
52515251+ pub struct SetGrantedAt<S: State = Empty>(PhantomData<fn() -> S>);
52525252+ impl<S: State> sealed::Sealed for SetGrantedAt<S> {}
52535253+ impl<S: State> State for SetGrantedAt<S> {
52545254+ type GrantedAt = Set<members::granted_at>;
52545255 type Scope = S::Scope;
52555255- type GrantedAt = S::GrantedAt;
52565256 type Did = S::Did;
52575257+ type Source = S::Source;
52575258 }
52585259 ///State transition - sets the `scope` field to Set
52595260 pub struct SetScope<S: State = Empty>(PhantomData<fn() -> S>);
52605261 impl<S: State> sealed::Sealed for SetScope<S> {}
52615262 impl<S: State> State for SetScope<S> {
52625262- type Source = S::Source;
52635263- type Scope = Set<members::scope>;
52645263 type GrantedAt = S::GrantedAt;
52645264+ type Scope = Set<members::scope>;
52655265 type Did = S::Did;
52665266- }
52675267- ///State transition - sets the `granted_at` field to Set
52685268- pub struct SetGrantedAt<S: State = Empty>(PhantomData<fn() -> S>);
52695269- impl<S: State> sealed::Sealed for SetGrantedAt<S> {}
52705270- impl<S: State> State for SetGrantedAt<S> {
52715266 type Source = S::Source;
52725272- type Scope = S::Scope;
52735273- type GrantedAt = Set<members::granted_at>;
52745274- type Did = S::Did;
52755267 }
52765268 ///State transition - sets the `did` field to Set
52775269 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
52785270 impl<S: State> sealed::Sealed for SetDid<S> {}
52795271 impl<S: State> State for SetDid<S> {
52725272+ type GrantedAt = S::GrantedAt;
52735273+ type Scope = S::Scope;
52745274+ type Did = Set<members::did>;
52805275 type Source = S::Source;
52765276+ }
52775277+ ///State transition - sets the `source` field to Set
52785278+ pub struct SetSource<S: State = Empty>(PhantomData<fn() -> S>);
52795279+ impl<S: State> sealed::Sealed for SetSource<S> {}
52805280+ impl<S: State> State for SetSource<S> {
52815281+ type GrantedAt = S::GrantedAt;
52815282 type Scope = S::Scope;
52825282- type GrantedAt = S::GrantedAt;
52835283- type Did = Set<members::did>;
52835283+ type Did = S::Did;
52845284+ type Source = Set<members::source>;
52845285 }
52855286 /// Marker types for field names
52865287 #[allow(non_camel_case_types)]
52875288 pub mod members {
52885288- ///Marker type for the `source` field
52895289- pub struct source(());
52905290- ///Marker type for the `scope` field
52915291- pub struct scope(());
52925289 ///Marker type for the `granted_at` field
52935290 pub struct granted_at(());
52915291+ ///Marker type for the `scope` field
52925292+ pub struct scope(());
52945293 ///Marker type for the `did` field
52955294 pub struct did(());
52955295+ ///Marker type for the `source` field
52965296+ pub struct source(());
52965297 }
52975298}
52985299···54055406impl<'a, S> PermissionGrantBuilder<'a, S>
54065407where
54075408 S: permission_grant_state::State,
54085408- S::Source: permission_grant_state::IsSet,
54095409- S::Scope: permission_grant_state::IsSet,
54105409 S::GrantedAt: permission_grant_state::IsSet,
54105410+ S::Scope: permission_grant_state::IsSet,
54115411 S::Did: permission_grant_state::IsSet,
54125412+ S::Source: permission_grant_state::IsSet,
54125413{
54135414 /// Build the final struct
54145415 pub fn build(self) -> PermissionGrant<'a> {
···57575758 }
57585759 /// State trait tracking which required fields have been set
57595760 pub trait State: sealed::Sealed {
57615761+ type Publisher;
57625762+ type PublishedAt;
57605763 type Cid;
57615761- type PublishedAt;
57625764 type Uri;
57635763- type Publisher;
57645765 }
57655766 /// Empty state - all required fields are unset
57665767 pub struct Empty(());
57675768 impl sealed::Sealed for Empty {}
57685769 impl State for Empty {
57705770+ type Publisher = Unset;
57715771+ type PublishedAt = Unset;
57695772 type Cid = Unset;
57705770- type PublishedAt = Unset;
57715773 type Uri = Unset;
57725772- type Publisher = Unset;
57735774 }
57745774- ///State transition - sets the `cid` field to Set
57755775- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
57765776- impl<S: State> sealed::Sealed for SetCid<S> {}
57775777- impl<S: State> State for SetCid<S> {
57785778- type Cid = Set<members::cid>;
57755775+ ///State transition - sets the `publisher` field to Set
57765776+ pub struct SetPublisher<S: State = Empty>(PhantomData<fn() -> S>);
57775777+ impl<S: State> sealed::Sealed for SetPublisher<S> {}
57785778+ impl<S: State> State for SetPublisher<S> {
57795779+ type Publisher = Set<members::publisher>;
57795780 type PublishedAt = S::PublishedAt;
57815781+ type Cid = S::Cid;
57805782 type Uri = S::Uri;
57815781- type Publisher = S::Publisher;
57825783 }
57835784 ///State transition - sets the `published_at` field to Set
57845785 pub struct SetPublishedAt<S: State = Empty>(PhantomData<fn() -> S>);
57855786 impl<S: State> sealed::Sealed for SetPublishedAt<S> {}
57865787 impl<S: State> State for SetPublishedAt<S> {
57875787- type Cid = S::Cid;
57885788+ type Publisher = S::Publisher;
57885789 type PublishedAt = Set<members::published_at>;
57905790+ type Cid = S::Cid;
57895791 type Uri = S::Uri;
57925792+ }
57935793+ ///State transition - sets the `cid` field to Set
57945794+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
57955795+ impl<S: State> sealed::Sealed for SetCid<S> {}
57965796+ impl<S: State> State for SetCid<S> {
57905797 type Publisher = S::Publisher;
57985798+ type PublishedAt = S::PublishedAt;
57995799+ type Cid = Set<members::cid>;
58005800+ type Uri = S::Uri;
57915801 }
57925802 ///State transition - sets the `uri` field to Set
57935803 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
57945804 impl<S: State> sealed::Sealed for SetUri<S> {}
57955805 impl<S: State> State for SetUri<S> {
57965796- type Cid = S::Cid;
58065806+ type Publisher = S::Publisher;
57975807 type PublishedAt = S::PublishedAt;
58085808+ type Cid = S::Cid;
57985809 type Uri = Set<members::uri>;
57995799- type Publisher = S::Publisher;
58005800- }
58015801- ///State transition - sets the `publisher` field to Set
58025802- pub struct SetPublisher<S: State = Empty>(PhantomData<fn() -> S>);
58035803- impl<S: State> sealed::Sealed for SetPublisher<S> {}
58045804- impl<S: State> State for SetPublisher<S> {
58055805- type Cid = S::Cid;
58065806- type PublishedAt = S::PublishedAt;
58075807- type Uri = S::Uri;
58085808- type Publisher = Set<members::publisher>;
58095810 }
58105811 /// Marker types for field names
58115812 #[allow(non_camel_case_types)]
58125813 pub mod members {
58135813- ///Marker type for the `cid` field
58145814- pub struct cid(());
58145814+ ///Marker type for the `publisher` field
58155815+ pub struct publisher(());
58155816 ///Marker type for the `published_at` field
58165817 pub struct published_at(());
58185818+ ///Marker type for the `cid` field
58195819+ pub struct cid(());
58175820 ///Marker type for the `uri` field
58185821 pub struct uri(());
58195819- ///Marker type for the `publisher` field
58205820- pub struct publisher(());
58215822 }
58225823}
58235824···59905991impl<'a, S> PublishedVersionViewBuilder<'a, S>
59915992where
59925993 S: published_version_view_state::State,
59935993- S::Cid: published_version_view_state::IsSet,
59945994+ S::Publisher: published_version_view_state::IsSet,
59945995 S::PublishedAt: published_version_view_state::IsSet,
59965996+ S::Cid: published_version_view_state::IsSet,
59955997 S::Uri: published_version_view_state::IsSet,
59965996- S::Publisher: published_version_view_state::IsSet,
59975998{
59985999 /// Build the final struct
59996000 pub fn build(self) -> PublishedVersionView<'a> {
···62436244 }
62446245 /// State trait tracking which required fields have been set
62456246 pub trait State: sealed::Sealed {
62466246- type IndexedAt;
62476247 type By;
62486248+ type IndexedAt;
62486249 }
62496250 /// Empty state - all required fields are unset
62506251 pub struct Empty(());
62516252 impl sealed::Sealed for Empty {}
62526253 impl State for Empty {
62546254+ type By = Unset;
62536255 type IndexedAt = Unset;
62546254- type By = Unset;
62556255- }
62566256- ///State transition - sets the `indexed_at` field to Set
62576257- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
62586258- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
62596259- impl<S: State> State for SetIndexedAt<S> {
62606260- type IndexedAt = Set<members::indexed_at>;
62616261- type By = S::By;
62626256 }
62636257 ///State transition - sets the `by` field to Set
62646258 pub struct SetBy<S: State = Empty>(PhantomData<fn() -> S>);
62656259 impl<S: State> sealed::Sealed for SetBy<S> {}
62666260 impl<S: State> State for SetBy<S> {
62676267- type IndexedAt = S::IndexedAt;
62686261 type By = Set<members::by>;
62626262+ type IndexedAt = S::IndexedAt;
62636263+ }
62646264+ ///State transition - sets the `indexed_at` field to Set
62656265+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
62666266+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
62676267+ impl<S: State> State for SetIndexedAt<S> {
62686268+ type By = S::By;
62696269+ type IndexedAt = Set<members::indexed_at>;
62696270 }
62706271 /// Marker types for field names
62716272 #[allow(non_camel_case_types)]
62726273 pub mod members {
62746274+ ///Marker type for the `by` field
62756275+ pub struct by(());
62736276 ///Marker type for the `indexed_at` field
62746277 pub struct indexed_at(());
62756275- ///Marker type for the `by` field
62766276- pub struct by(());
62776278 }
62786279}
62796280···63466347impl<'a, S> ReasonBookmarkBuilder<'a, S>
63476348where
63486349 S: reason_bookmark_state::State,
63496349- S::IndexedAt: reason_bookmark_state::IsSet,
63506350 S::By: reason_bookmark_state::IsSet,
63516351+ S::IndexedAt: reason_bookmark_state::IsSet,
63516352{
63526353 /// Build the final struct
63536354 pub fn build(self) -> ReasonBookmark<'a> {
···64176418 }
64186419 /// State trait tracking which required fields have been set
64196420 pub trait State: sealed::Sealed {
64206420- type IndexedAt;
64216421 type By;
64226422+ type IndexedAt;
64226423 }
64236424 /// Empty state - all required fields are unset
64246425 pub struct Empty(());
64256426 impl sealed::Sealed for Empty {}
64266427 impl State for Empty {
64286428+ type By = Unset;
64276429 type IndexedAt = Unset;
64286428- type By = Unset;
64306430+ }
64316431+ ///State transition - sets the `by` field to Set
64326432+ pub struct SetBy<S: State = Empty>(PhantomData<fn() -> S>);
64336433+ impl<S: State> sealed::Sealed for SetBy<S> {}
64346434+ impl<S: State> State for SetBy<S> {
64356435+ type By = Set<members::by>;
64366436+ type IndexedAt = S::IndexedAt;
64296437 }
64306438 ///State transition - sets the `indexed_at` field to Set
64316439 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
64326440 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
64336441 impl<S: State> State for SetIndexedAt<S> {
64346434- type IndexedAt = Set<members::indexed_at>;
64356442 type By = S::By;
64366436- }
64376437- ///State transition - sets the `by` field to Set
64386438- pub struct SetBy<S: State = Empty>(PhantomData<fn() -> S>);
64396439- impl<S: State> sealed::Sealed for SetBy<S> {}
64406440- impl<S: State> State for SetBy<S> {
64416441- type IndexedAt = S::IndexedAt;
64426442- type By = Set<members::by>;
64436443+ type IndexedAt = Set<members::indexed_at>;
64436444 }
64446445 /// Marker types for field names
64456446 #[allow(non_camel_case_types)]
64466447 pub mod members {
64486448+ ///Marker type for the `by` field
64496449+ pub struct by(());
64476450 ///Marker type for the `indexed_at` field
64486451 pub struct indexed_at(());
64496449- ///Marker type for the `by` field
64506450- pub struct by(());
64516452 }
64526453}
64536454···65206521impl<'a, S> ReasonLikeBuilder<'a, S>
65216522where
65226523 S: reason_like_state::State,
65236523- S::IndexedAt: reason_like_state::IsSet,
65246524 S::By: reason_like_state::IsSet,
65256525+ S::IndexedAt: reason_like_state::IsSet,
65256526{
65266527 /// Build the final struct
65276528 pub fn build(self) -> ReasonLike<'a> {
···5454 }
5555 /// State trait tracking which required fields have been set
5656 pub trait State: sealed::Sealed {
5757- type EntryList;
5857 type Notebook;
5858+ type EntryList;
5959 type Authors;
6060 }
6161 /// Empty state - all required fields are unset
6262 pub struct Empty(());
6363 impl sealed::Sealed for Empty {}
6464 impl State for Empty {
6565- type EntryList = Unset;
6665 type Notebook = Unset;
6666+ type EntryList = Unset;
6767 type Authors = Unset;
6868 }
6969- ///State transition - sets the `entry_list` field to Set
7070- pub struct SetEntryList<S: State = Empty>(PhantomData<fn() -> S>);
7171- impl<S: State> sealed::Sealed for SetEntryList<S> {}
7272- impl<S: State> State for SetEntryList<S> {
7373- type EntryList = Set<members::entry_list>;
7474- type Notebook = S::Notebook;
7575- type Authors = S::Authors;
7676- }
7769 ///State transition - sets the `notebook` field to Set
7870 pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
7971 impl<S: State> sealed::Sealed for SetNotebook<S> {}
8072 impl<S: State> State for SetNotebook<S> {
8181- type EntryList = S::EntryList;
8273 type Notebook = Set<members::notebook>;
7474+ type EntryList = S::EntryList;
7575+ type Authors = S::Authors;
7676+ }
7777+ ///State transition - sets the `entry_list` field to Set
7878+ pub struct SetEntryList<S: State = Empty>(PhantomData<fn() -> S>);
7979+ impl<S: State> sealed::Sealed for SetEntryList<S> {}
8080+ impl<S: State> State for SetEntryList<S> {
8181+ type Notebook = S::Notebook;
8282+ type EntryList = Set<members::entry_list>;
8383 type Authors = S::Authors;
8484 }
8585 ///State transition - sets the `authors` field to Set
8686 pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
8787 impl<S: State> sealed::Sealed for SetAuthors<S> {}
8888 impl<S: State> State for SetAuthors<S> {
8989- type EntryList = S::EntryList;
9089 type Notebook = S::Notebook;
9090+ type EntryList = S::EntryList;
9191 type Authors = Set<members::authors>;
9292 }
9393 /// Marker types for field names
9494 #[allow(non_camel_case_types)]
9595 pub mod members {
9696+ ///Marker type for the `notebook` field
9797+ pub struct notebook(());
9698 ///Marker type for the `entry_list` field
9799 pub struct entry_list(());
9898- ///Marker type for the `notebook` field
9999- pub struct notebook(());
100100 ///Marker type for the `authors` field
101101 pub struct authors(());
102102 }
···291291impl<'a, S> ChapterBuilder<'a, S>
292292where
293293 S: chapter_state::State,
294294- S::EntryList: chapter_state::IsSet,
295294 S::Notebook: chapter_state::IsSet,
295295+ S::EntryList: chapter_state::IsSet,
296296 S::Authors: chapter_state::IsSet,
297297{
298298 /// Build the final struct
+39-39
crates/weaver-api/src/sh_weaver/notebook/entry.rs
···6060 }
6161 /// State trait tracking which required fields have been set
6262 pub trait State: sealed::Sealed {
6363+ type Path;
6464+ type Title;
6565+ type Content;
6366 type CreatedAt;
6464- type Content;
6565- type Title;
6666- type Path;
6767 }
6868 /// Empty state - all required fields are unset
6969 pub struct Empty(());
7070 impl sealed::Sealed for Empty {}
7171 impl State for Empty {
7272- type CreatedAt = Unset;
7373- type Content = Unset;
7474- type Title = Unset;
7572 type Path = Unset;
7373+ type Title = Unset;
7474+ type Content = Unset;
7575+ type CreatedAt = Unset;
7676 }
7777- ///State transition - sets the `created_at` field to Set
7878- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
7979- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
8080- impl<S: State> State for SetCreatedAt<S> {
8181- type CreatedAt = Set<members::created_at>;
8282- type Content = S::Content;
7777+ ///State transition - sets the `path` field to Set
7878+ pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
7979+ impl<S: State> sealed::Sealed for SetPath<S> {}
8080+ impl<S: State> State for SetPath<S> {
8181+ type Path = Set<members::path>;
8382 type Title = S::Title;
8484- type Path = S::Path;
8585- }
8686- ///State transition - sets the `content` field to Set
8787- pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
8888- impl<S: State> sealed::Sealed for SetContent<S> {}
8989- impl<S: State> State for SetContent<S> {
8383+ type Content = S::Content;
9084 type CreatedAt = S::CreatedAt;
9191- type Content = Set<members::content>;
9292- type Title = S::Title;
9393- type Path = S::Path;
9485 }
9586 ///State transition - sets the `title` field to Set
9687 pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
9788 impl<S: State> sealed::Sealed for SetTitle<S> {}
9889 impl<S: State> State for SetTitle<S> {
9999- type CreatedAt = S::CreatedAt;
100100- type Content = S::Content;
101101- type Title = Set<members::title>;
10290 type Path = S::Path;
9191+ type Title = Set<members::title>;
9292+ type Content = S::Content;
9393+ type CreatedAt = S::CreatedAt;
10394 }
104104- ///State transition - sets the `path` field to Set
105105- pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
106106- impl<S: State> sealed::Sealed for SetPath<S> {}
107107- impl<S: State> State for SetPath<S> {
9595+ ///State transition - sets the `content` field to Set
9696+ pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
9797+ impl<S: State> sealed::Sealed for SetContent<S> {}
9898+ impl<S: State> State for SetContent<S> {
9999+ type Path = S::Path;
100100+ type Title = S::Title;
101101+ type Content = Set<members::content>;
108102 type CreatedAt = S::CreatedAt;
109109- type Content = S::Content;
103103+ }
104104+ ///State transition - sets the `created_at` field to Set
105105+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
106106+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
107107+ impl<S: State> State for SetCreatedAt<S> {
108108+ type Path = S::Path;
110109 type Title = S::Title;
111111- type Path = Set<members::path>;
110110+ type Content = S::Content;
111111+ type CreatedAt = Set<members::created_at>;
112112 }
113113 /// Marker types for field names
114114 #[allow(non_camel_case_types)]
115115 pub mod members {
116116- ///Marker type for the `created_at` field
117117- pub struct created_at(());
118118- ///Marker type for the `content` field
119119- pub struct content(());
116116+ ///Marker type for the `path` field
117117+ pub struct path(());
120118 ///Marker type for the `title` field
121119 pub struct title(());
122122- ///Marker type for the `path` field
123123- pub struct path(());
120120+ ///Marker type for the `content` field
121121+ pub struct content(());
122122+ ///Marker type for the `created_at` field
123123+ pub struct created_at(());
124124 }
125125}
126126···358358impl<'a, S> EntryBuilder<'a, S>
359359where
360360 S: entry_state::State,
361361- S::CreatedAt: entry_state::IsSet,
362362- S::Content: entry_state::IsSet,
363363- S::Title: entry_state::IsSet,
364361 S::Path: entry_state::IsSet,
362362+ S::Title: entry_state::IsSet,
363363+ S::Content: entry_state::IsSet,
364364+ S::CreatedAt: entry_state::IsSet,
365365{
366366 /// Build the final struct
367367 pub fn build(self) -> Entry<'a> {
···188188 }
189189 /// State trait tracking which required fields have been set
190190 pub trait State: sealed::Sealed {
191191- type Cid;
192191 type Uri;
192192+ type Cid;
193193 }
194194 /// Empty state - all required fields are unset
195195 pub struct Empty(());
196196 impl sealed::Sealed for Empty {}
197197 impl State for Empty {
198198- type Cid = Unset;
199198 type Uri = Unset;
200200- }
201201- ///State transition - sets the `cid` field to Set
202202- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
203203- impl<S: State> sealed::Sealed for SetCid<S> {}
204204- impl<S: State> State for SetCid<S> {
205205- type Cid = Set<members::cid>;
206206- type Uri = S::Uri;
199199+ type Cid = Unset;
207200 }
208201 ///State transition - sets the `uri` field to Set
209202 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
210203 impl<S: State> sealed::Sealed for SetUri<S> {}
211204 impl<S: State> State for SetUri<S> {
212212- type Cid = S::Cid;
213205 type Uri = Set<members::uri>;
206206+ type Cid = S::Cid;
207207+ }
208208+ ///State transition - sets the `cid` field to Set
209209+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
210210+ impl<S: State> sealed::Sealed for SetCid<S> {}
211211+ impl<S: State> State for SetCid<S> {
212212+ type Uri = S::Uri;
213213+ type Cid = Set<members::cid>;
214214 }
215215 /// Marker types for field names
216216 #[allow(non_camel_case_types)]
217217 pub mod members {
218218- ///Marker type for the `cid` field
219219- pub struct cid(());
220218 ///Marker type for the `uri` field
221219 pub struct uri(());
220220+ ///Marker type for the `cid` field
221221+ pub struct cid(());
222222 }
223223}
224224···328328impl<'a, S> NotebookRefBuilder<'a, S>
329329where
330330 S: notebook_ref_state::State,
331331- S::Cid: notebook_ref_state::IsSet,
332331 S::Uri: notebook_ref_state::IsSet,
332332+ S::Cid: notebook_ref_state::IsSet,
333333{
334334 /// Build the final struct
335335 pub fn build(self) -> NotebookRef<'a> {
···3232 }
3333 /// State trait tracking which required fields have been set
3434 pub trait State: sealed::Sealed {
3535- type Actor;
3635 type Title;
3636+ type Actor;
3737 }
3838 /// Empty state - all required fields are unset
3939 pub struct Empty(());
4040 impl sealed::Sealed for Empty {}
4141 impl State for Empty {
4242- type Actor = Unset;
4342 type Title = Unset;
4444- }
4545- ///State transition - sets the `actor` field to Set
4646- pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
4747- impl<S: State> sealed::Sealed for SetActor<S> {}
4848- impl<S: State> State for SetActor<S> {
4949- type Actor = Set<members::actor>;
5050- type Title = S::Title;
4343+ type Actor = Unset;
5144 }
5245 ///State transition - sets the `title` field to Set
5346 pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
5447 impl<S: State> sealed::Sealed for SetTitle<S> {}
5548 impl<S: State> State for SetTitle<S> {
5656- type Actor = S::Actor;
5749 type Title = Set<members::title>;
5050+ type Actor = S::Actor;
5151+ }
5252+ ///State transition - sets the `actor` field to Set
5353+ pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
5454+ impl<S: State> sealed::Sealed for SetActor<S> {}
5555+ impl<S: State> State for SetActor<S> {
5656+ type Title = S::Title;
5757+ type Actor = Set<members::actor>;
5858 }
5959 /// Marker types for field names
6060 #[allow(non_camel_case_types)]
6161 pub mod members {
6262- ///Marker type for the `actor` field
6363- pub struct actor(());
6462 ///Marker type for the `title` field
6563 pub struct title(());
6464+ ///Marker type for the `actor` field
6565+ pub struct actor(());
6666 }
6767}
6868···135135impl<'a, S> GetNotebookByTitleBuilder<'a, S>
136136where
137137 S: get_notebook_by_title_state::State,
138138- S::Actor: get_notebook_by_title_state::IsSet,
139138 S::Title: get_notebook_by_title_state::IsSet,
139139+ S::Actor: get_notebook_by_title_state::IsSet,
140140{
141141 /// Build the final struct
142142 pub fn build(self) -> GetNotebookByTitle<'a> {
···214214 }
215215 /// State trait tracking which required fields have been set
216216 pub trait State: sealed::Sealed {
217217- type Notebook;
218217 type Progress;
218218+ type Notebook;
219219 }
220220 /// Empty state - all required fields are unset
221221 pub struct Empty(());
222222 impl sealed::Sealed for Empty {}
223223 impl State for Empty {
224224- type Notebook = Unset;
225224 type Progress = Unset;
226226- }
227227- ///State transition - sets the `notebook` field to Set
228228- pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
229229- impl<S: State> sealed::Sealed for SetNotebook<S> {}
230230- impl<S: State> State for SetNotebook<S> {
231231- type Notebook = Set<members::notebook>;
232232- type Progress = S::Progress;
225225+ type Notebook = Unset;
233226 }
234227 ///State transition - sets the `progress` field to Set
235228 pub struct SetProgress<S: State = Empty>(PhantomData<fn() -> S>);
236229 impl<S: State> sealed::Sealed for SetProgress<S> {}
237230 impl<S: State> State for SetProgress<S> {
238238- type Notebook = S::Notebook;
239231 type Progress = Set<members::progress>;
232232+ type Notebook = S::Notebook;
233233+ }
234234+ ///State transition - sets the `notebook` field to Set
235235+ pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
236236+ impl<S: State> sealed::Sealed for SetNotebook<S> {}
237237+ impl<S: State> State for SetNotebook<S> {
238238+ type Progress = S::Progress;
239239+ type Notebook = Set<members::notebook>;
240240 }
241241 /// Marker types for field names
242242 #[allow(non_camel_case_types)]
243243 pub mod members {
244244- ///Marker type for the `notebook` field
245245- pub struct notebook(());
246244 ///Marker type for the `progress` field
247245 pub struct progress(());
246246+ ///Marker type for the `notebook` field
247247+ pub struct notebook(());
248248 }
249249}
250250···337337impl<'a, S> ReadingHistoryItemBuilder<'a, S>
338338where
339339 S: reading_history_item_state::State,
340340- S::Notebook: reading_history_item_state::IsSet,
341340 S::Progress: reading_history_item_state::IsSet,
341341+ S::Notebook: reading_history_item_state::IsSet,
342342{
343343 /// Build the final struct
344344 pub fn build(self) -> ReadingHistoryItem<'a> {
+24-24
crates/weaver-api/src/sh_weaver/notebook/page.rs
···4444 }
4545 /// State trait tracking which required fields have been set
4646 pub trait State: sealed::Sealed {
4747- type Notebook;
4848- type EntryList;
4947 type Authors;
4848+ type EntryList;
4949+ type Notebook;
5050 }
5151 /// Empty state - all required fields are unset
5252 pub struct Empty(());
5353 impl sealed::Sealed for Empty {}
5454 impl State for Empty {
5555+ type Authors = Unset;
5656+ type EntryList = Unset;
5557 type Notebook = Unset;
5656- type EntryList = Unset;
5757- type Authors = Unset;
5858 }
5959- ///State transition - sets the `notebook` field to Set
6060- pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
6161- impl<S: State> sealed::Sealed for SetNotebook<S> {}
6262- impl<S: State> State for SetNotebook<S> {
6363- type Notebook = Set<members::notebook>;
5959+ ///State transition - sets the `authors` field to Set
6060+ pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
6161+ impl<S: State> sealed::Sealed for SetAuthors<S> {}
6262+ impl<S: State> State for SetAuthors<S> {
6363+ type Authors = Set<members::authors>;
6464 type EntryList = S::EntryList;
6565- type Authors = S::Authors;
6565+ type Notebook = S::Notebook;
6666 }
6767 ///State transition - sets the `entry_list` field to Set
6868 pub struct SetEntryList<S: State = Empty>(PhantomData<fn() -> S>);
6969 impl<S: State> sealed::Sealed for SetEntryList<S> {}
7070 impl<S: State> State for SetEntryList<S> {
7171- type Notebook = S::Notebook;
7272- type EntryList = Set<members::entry_list>;
7371 type Authors = S::Authors;
7272+ type EntryList = Set<members::entry_list>;
7373+ type Notebook = S::Notebook;
7474 }
7575- ///State transition - sets the `authors` field to Set
7676- pub struct SetAuthors<S: State = Empty>(PhantomData<fn() -> S>);
7777- impl<S: State> sealed::Sealed for SetAuthors<S> {}
7878- impl<S: State> State for SetAuthors<S> {
7979- type Notebook = S::Notebook;
7575+ ///State transition - sets the `notebook` field to Set
7676+ pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
7777+ impl<S: State> sealed::Sealed for SetNotebook<S> {}
7878+ impl<S: State> State for SetNotebook<S> {
7979+ type Authors = S::Authors;
8080 type EntryList = S::EntryList;
8181- type Authors = Set<members::authors>;
8181+ type Notebook = Set<members::notebook>;
8282 }
8383 /// Marker types for field names
8484 #[allow(non_camel_case_types)]
8585 pub mod members {
8686+ ///Marker type for the `authors` field
8787+ pub struct authors(());
8888+ ///Marker type for the `entry_list` field
8989+ pub struct entry_list(());
8690 ///Marker type for the `notebook` field
8791 pub struct notebook(());
8888- ///Marker type for the `entry_list` field
8989- pub struct entry_list(());
9090- ///Marker type for the `authors` field
9191- pub struct authors(());
9292 }
9393}
9494···221221impl<'a, S> PageBuilder<'a, S>
222222where
223223 S: page_state::State,
224224- S::Notebook: page_state::IsSet,
225225- S::EntryList: page_state::IsSet,
226224 S::Authors: page_state::IsSet,
225225+ S::EntryList: page_state::IsSet,
226226+ S::Notebook: page_state::IsSet,
227227{
228228 /// Build the final struct
229229 pub fn build(self) -> Page<'a> {
···3434 }
3535 /// State trait tracking which required fields have been set
3636 pub trait State: sealed::Sealed {
3737- type Actor;
3838- type Entry;
3937 type Notebook;
3838+ type Entry;
3939+ type Actor;
4040 }
4141 /// Empty state - all required fields are unset
4242 pub struct Empty(());
4343 impl sealed::Sealed for Empty {}
4444 impl State for Empty {
4545+ type Notebook = Unset;
4646+ type Entry = Unset;
4547 type Actor = Unset;
4646- type Entry = Unset;
4747- type Notebook = Unset;
4848 }
4949- ///State transition - sets the `actor` field to Set
5050- pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
5151- impl<S: State> sealed::Sealed for SetActor<S> {}
5252- impl<S: State> State for SetActor<S> {
5353- type Actor = Set<members::actor>;
4949+ ///State transition - sets the `notebook` field to Set
5050+ pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
5151+ impl<S: State> sealed::Sealed for SetNotebook<S> {}
5252+ impl<S: State> State for SetNotebook<S> {
5353+ type Notebook = Set<members::notebook>;
5454 type Entry = S::Entry;
5555- type Notebook = S::Notebook;
5555+ type Actor = S::Actor;
5656 }
5757 ///State transition - sets the `entry` field to Set
5858 pub struct SetEntry<S: State = Empty>(PhantomData<fn() -> S>);
5959 impl<S: State> sealed::Sealed for SetEntry<S> {}
6060 impl<S: State> State for SetEntry<S> {
6161- type Actor = S::Actor;
6262- type Entry = Set<members::entry>;
6361 type Notebook = S::Notebook;
6262+ type Entry = Set<members::entry>;
6363+ type Actor = S::Actor;
6464 }
6565- ///State transition - sets the `notebook` field to Set
6666- pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
6767- impl<S: State> sealed::Sealed for SetNotebook<S> {}
6868- impl<S: State> State for SetNotebook<S> {
6969- type Actor = S::Actor;
6565+ ///State transition - sets the `actor` field to Set
6666+ pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
6767+ impl<S: State> sealed::Sealed for SetActor<S> {}
6868+ impl<S: State> State for SetActor<S> {
6969+ type Notebook = S::Notebook;
7070 type Entry = S::Entry;
7171- type Notebook = Set<members::notebook>;
7171+ type Actor = Set<members::actor>;
7272 }
7373 /// Marker types for field names
7474 #[allow(non_camel_case_types)]
7575 pub mod members {
7676+ ///Marker type for the `notebook` field
7777+ pub struct notebook(());
7878+ ///Marker type for the `entry` field
7979+ pub struct entry(());
7680 ///Marker type for the `actor` field
7781 pub struct actor(());
7878- ///Marker type for the `entry` field
7979- pub struct entry(());
8080- ///Marker type for the `notebook` field
8181- pub struct notebook(());
8282 }
8383}
8484···171171impl<'a, S> ResolveEntryBuilder<'a, S>
172172where
173173 S: resolve_entry_state::State,
174174- S::Actor: resolve_entry_state::IsSet,
175175- S::Entry: resolve_entry_state::IsSet,
176174 S::Notebook: resolve_entry_state::IsSet,
175175+ S::Entry: resolve_entry_state::IsSet,
176176+ S::Actor: resolve_entry_state::IsSet,
177177{
178178 /// Build the final struct
179179 pub fn build(self) -> ResolveEntry<'a> {
···3838 }
3939 /// State trait tracking which required fields have been set
4040 pub trait State: sealed::Sealed {
4141- type Name;
4241 type Actor;
4242+ type Name;
4343 }
4444 /// Empty state - all required fields are unset
4545 pub struct Empty(());
4646 impl sealed::Sealed for Empty {}
4747 impl State for Empty {
4848- type Name = Unset;
4948 type Actor = Unset;
5050- }
5151- ///State transition - sets the `name` field to Set
5252- pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetName<S> {}
5454- impl<S: State> State for SetName<S> {
5555- type Name = Set<members::name>;
5656- type Actor = S::Actor;
4949+ type Name = Unset;
5750 }
5851 ///State transition - sets the `actor` field to Set
5952 pub struct SetActor<S: State = Empty>(PhantomData<fn() -> S>);
6053 impl<S: State> sealed::Sealed for SetActor<S> {}
6154 impl<S: State> State for SetActor<S> {
6262- type Name = S::Name;
6355 type Actor = Set<members::actor>;
5656+ type Name = S::Name;
5757+ }
5858+ ///State transition - sets the `name` field to Set
5959+ pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
6060+ impl<S: State> sealed::Sealed for SetName<S> {}
6161+ impl<S: State> State for SetName<S> {
6262+ type Actor = S::Actor;
6363+ type Name = Set<members::name>;
6464 }
6565 /// Marker types for field names
6666 #[allow(non_camel_case_types)]
6767 pub mod members {
6868- ///Marker type for the `name` field
6969- pub struct name(());
7068 ///Marker type for the `actor` field
7169 pub struct actor(());
7070+ ///Marker type for the `name` field
7171+ pub struct name(());
7272 }
7373}
7474···175175impl<'a, S> ResolveNotebookBuilder<'a, S>
176176where
177177 S: resolve_notebook_state::State,
178178- S::Name: resolve_notebook_state::IsSet,
179178 S::Actor: resolve_notebook_state::IsSet,
179179+ S::Name: resolve_notebook_state::IsSet,
180180{
181181 /// Build the final struct
182182 pub fn build(self) -> ResolveNotebook<'a> {
+107-107
crates/weaver-api/src/sh_weaver/notebook/theme.rs
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type Content;
4039 type Name;
4140 type Did;
4141+ type Content;
4242 }
4343 /// Empty state - all required fields are unset
4444 pub struct Empty(());
4545 impl sealed::Sealed for Empty {}
4646 impl State for Empty {
4747- type Content = Unset;
4847 type Name = Unset;
4948 type Did = Unset;
5050- }
5151- ///State transition - sets the `content` field to Set
5252- pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
5353- impl<S: State> sealed::Sealed for SetContent<S> {}
5454- impl<S: State> State for SetContent<S> {
5555- type Content = Set<members::content>;
5656- type Name = S::Name;
5757- type Did = S::Did;
4949+ type Content = Unset;
5850 }
5951 ///State transition - sets the `name` field to Set
6052 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
6153 impl<S: State> sealed::Sealed for SetName<S> {}
6254 impl<S: State> State for SetName<S> {
6363- type Content = S::Content;
6455 type Name = Set<members::name>;
6556 type Did = S::Did;
5757+ type Content = S::Content;
6658 }
6759 ///State transition - sets the `did` field to Set
6860 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
6961 impl<S: State> sealed::Sealed for SetDid<S> {}
7062 impl<S: State> State for SetDid<S> {
7171- type Content = S::Content;
7263 type Name = S::Name;
7364 type Did = Set<members::did>;
6565+ type Content = S::Content;
6666+ }
6767+ ///State transition - sets the `content` field to Set
6868+ pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
6969+ impl<S: State> sealed::Sealed for SetContent<S> {}
7070+ impl<S: State> State for SetContent<S> {
7171+ type Name = S::Name;
7272+ type Did = S::Did;
7373+ type Content = Set<members::content>;
7474 }
7575 /// Marker types for field names
7676 #[allow(non_camel_case_types)]
7777 pub mod members {
7878- ///Marker type for the `content` field
7979- pub struct content(());
8078 ///Marker type for the `name` field
8179 pub struct name(());
8280 ///Marker type for the `did` field
8381 pub struct did(());
8282+ ///Marker type for the `content` field
8383+ pub struct content(());
8484 }
8585}
8686···173173impl<'a, S> CodeThemeFileBuilder<'a, S>
174174where
175175 S: code_theme_file_state::State,
176176- S::Content: code_theme_file_state::IsSet,
177176 S::Name: code_theme_file_state::IsSet,
178177 S::Did: code_theme_file_state::IsSet,
178178+ S::Content: code_theme_file_state::IsSet,
179179{
180180 /// Build the final struct
181181 pub fn build(self) -> CodeThemeFile<'a> {
···838838 /// State trait tracking which required fields have been set
839839 pub trait State: sealed::Sealed {
840840 type Content;
841841- type Did;
842841 type Name;
842842+ type Did;
843843 }
844844 /// Empty state - all required fields are unset
845845 pub struct Empty(());
846846 impl sealed::Sealed for Empty {}
847847 impl State for Empty {
848848 type Content = Unset;
849849+ type Name = Unset;
849850 type Did = Unset;
850850- type Name = Unset;
851851 }
852852 ///State transition - sets the `content` field to Set
853853 pub struct SetContent<S: State = Empty>(PhantomData<fn() -> S>);
854854 impl<S: State> sealed::Sealed for SetContent<S> {}
855855 impl<S: State> State for SetContent<S> {
856856 type Content = Set<members::content>;
857857- type Did = S::Did;
858857 type Name = S::Name;
858858+ type Did = S::Did;
859859+ }
860860+ ///State transition - sets the `name` field to Set
861861+ pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
862862+ impl<S: State> sealed::Sealed for SetName<S> {}
863863+ impl<S: State> State for SetName<S> {
864864+ type Content = S::Content;
865865+ type Name = Set<members::name>;
866866+ type Did = S::Did;
859867 }
860868 ///State transition - sets the `did` field to Set
861869 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
862870 impl<S: State> sealed::Sealed for SetDid<S> {}
863871 impl<S: State> State for SetDid<S> {
864872 type Content = S::Content;
865865- type Did = Set<members::did>;
866873 type Name = S::Name;
867867- }
868868- ///State transition - sets the `name` field to Set
869869- pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
870870- impl<S: State> sealed::Sealed for SetName<S> {}
871871- impl<S: State> State for SetName<S> {
872872- type Content = S::Content;
873873- type Did = S::Did;
874874- type Name = Set<members::name>;
874874+ type Did = Set<members::did>;
875875 }
876876 /// Marker types for field names
877877 #[allow(non_camel_case_types)]
878878 pub mod members {
879879 ///Marker type for the `content` field
880880 pub struct content(());
881881+ ///Marker type for the `name` field
882882+ pub struct name(());
881883 ///Marker type for the `did` field
882884 pub struct did(());
883883- ///Marker type for the `name` field
884884- pub struct name(());
885885 }
886886}
887887···975975where
976976 S: font_file_state::State,
977977 S::Content: font_file_state::IsSet,
978978- S::Did: font_file_state::IsSet,
979978 S::Name: font_file_state::IsSet,
979979+ S::Did: font_file_state::IsSet,
980980{
981981 /// Build the final struct
982982 pub fn build(self) -> FontFile<'a> {
···10671067 }
10681068 /// State trait tracking which required fields have been set
10691069 pub trait State: sealed::Sealed {
10701070- type LightScheme;
10711071- type Spacing;
10721072- type LightCodeTheme;
10731070 type DarkScheme;
10741071 type DarkCodeTheme;
10721072+ type Spacing;
10731073+ type LightScheme;
10751074 type Fonts;
10751075+ type LightCodeTheme;
10761076 }
10771077 /// Empty state - all required fields are unset
10781078 pub struct Empty(());
10791079 impl sealed::Sealed for Empty {}
10801080 impl State for Empty {
10811081- type LightScheme = Unset;
10821082- type Spacing = Unset;
10831083- type LightCodeTheme = Unset;
10841081 type DarkScheme = Unset;
10851082 type DarkCodeTheme = Unset;
10831083+ type Spacing = Unset;
10841084+ type LightScheme = Unset;
10861085 type Fonts = Unset;
10861086+ type LightCodeTheme = Unset;
10871087 }
10881088- ///State transition - sets the `light_scheme` field to Set
10891089- pub struct SetLightScheme<S: State = Empty>(PhantomData<fn() -> S>);
10901090- impl<S: State> sealed::Sealed for SetLightScheme<S> {}
10911091- impl<S: State> State for SetLightScheme<S> {
10921092- type LightScheme = Set<members::light_scheme>;
10881088+ ///State transition - sets the `dark_scheme` field to Set
10891089+ pub struct SetDarkScheme<S: State = Empty>(PhantomData<fn() -> S>);
10901090+ impl<S: State> sealed::Sealed for SetDarkScheme<S> {}
10911091+ impl<S: State> State for SetDarkScheme<S> {
10921092+ type DarkScheme = Set<members::dark_scheme>;
10931093+ type DarkCodeTheme = S::DarkCodeTheme;
10931094 type Spacing = S::Spacing;
10951095+ type LightScheme = S::LightScheme;
10961096+ type Fonts = S::Fonts;
10941097 type LightCodeTheme = S::LightCodeTheme;
10981098+ }
10991099+ ///State transition - sets the `dark_code_theme` field to Set
11001100+ pub struct SetDarkCodeTheme<S: State = Empty>(PhantomData<fn() -> S>);
11011101+ impl<S: State> sealed::Sealed for SetDarkCodeTheme<S> {}
11021102+ impl<S: State> State for SetDarkCodeTheme<S> {
10951103 type DarkScheme = S::DarkScheme;
10961096- type DarkCodeTheme = S::DarkCodeTheme;
11041104+ type DarkCodeTheme = Set<members::dark_code_theme>;
11051105+ type Spacing = S::Spacing;
11061106+ type LightScheme = S::LightScheme;
10971107 type Fonts = S::Fonts;
11081108+ type LightCodeTheme = S::LightCodeTheme;
10981109 }
10991110 ///State transition - sets the `spacing` field to Set
11001111 pub struct SetSpacing<S: State = Empty>(PhantomData<fn() -> S>);
11011112 impl<S: State> sealed::Sealed for SetSpacing<S> {}
11021113 impl<S: State> State for SetSpacing<S> {
11031103- type LightScheme = S::LightScheme;
11041104- type Spacing = Set<members::spacing>;
11051105- type LightCodeTheme = S::LightCodeTheme;
11061114 type DarkScheme = S::DarkScheme;
11071115 type DarkCodeTheme = S::DarkCodeTheme;
11161116+ type Spacing = Set<members::spacing>;
11171117+ type LightScheme = S::LightScheme;
11081118 type Fonts = S::Fonts;
11191119+ type LightCodeTheme = S::LightCodeTheme;
11091120 }
11101110- ///State transition - sets the `light_code_theme` field to Set
11111111- pub struct SetLightCodeTheme<S: State = Empty>(PhantomData<fn() -> S>);
11121112- impl<S: State> sealed::Sealed for SetLightCodeTheme<S> {}
11131113- impl<S: State> State for SetLightCodeTheme<S> {
11141114- type LightScheme = S::LightScheme;
11151115- type Spacing = S::Spacing;
11161116- type LightCodeTheme = Set<members::light_code_theme>;
11211121+ ///State transition - sets the `light_scheme` field to Set
11221122+ pub struct SetLightScheme<S: State = Empty>(PhantomData<fn() -> S>);
11231123+ impl<S: State> sealed::Sealed for SetLightScheme<S> {}
11241124+ impl<S: State> State for SetLightScheme<S> {
11171125 type DarkScheme = S::DarkScheme;
11181126 type DarkCodeTheme = S::DarkCodeTheme;
11191119- type Fonts = S::Fonts;
11201120- }
11211121- ///State transition - sets the `dark_scheme` field to Set
11221122- pub struct SetDarkScheme<S: State = Empty>(PhantomData<fn() -> S>);
11231123- impl<S: State> sealed::Sealed for SetDarkScheme<S> {}
11241124- impl<S: State> State for SetDarkScheme<S> {
11251125- type LightScheme = S::LightScheme;
11261127 type Spacing = S::Spacing;
11271127- type LightCodeTheme = S::LightCodeTheme;
11281128- type DarkScheme = Set<members::dark_scheme>;
11291129- type DarkCodeTheme = S::DarkCodeTheme;
11281128+ type LightScheme = Set<members::light_scheme>;
11301129 type Fonts = S::Fonts;
11311131- }
11321132- ///State transition - sets the `dark_code_theme` field to Set
11331133- pub struct SetDarkCodeTheme<S: State = Empty>(PhantomData<fn() -> S>);
11341134- impl<S: State> sealed::Sealed for SetDarkCodeTheme<S> {}
11351135- impl<S: State> State for SetDarkCodeTheme<S> {
11361136- type LightScheme = S::LightScheme;
11371137- type Spacing = S::Spacing;
11381130 type LightCodeTheme = S::LightCodeTheme;
11391139- type DarkScheme = S::DarkScheme;
11401140- type DarkCodeTheme = Set<members::dark_code_theme>;
11411141- type Fonts = S::Fonts;
11421131 }
11431132 ///State transition - sets the `fonts` field to Set
11441133 pub struct SetFonts<S: State = Empty>(PhantomData<fn() -> S>);
11451134 impl<S: State> sealed::Sealed for SetFonts<S> {}
11461135 impl<S: State> State for SetFonts<S> {
11471147- type LightScheme = S::LightScheme;
11361136+ type DarkScheme = S::DarkScheme;
11371137+ type DarkCodeTheme = S::DarkCodeTheme;
11481138 type Spacing = S::Spacing;
11391139+ type LightScheme = S::LightScheme;
11401140+ type Fonts = Set<members::fonts>;
11491141 type LightCodeTheme = S::LightCodeTheme;
11421142+ }
11431143+ ///State transition - sets the `light_code_theme` field to Set
11441144+ pub struct SetLightCodeTheme<S: State = Empty>(PhantomData<fn() -> S>);
11451145+ impl<S: State> sealed::Sealed for SetLightCodeTheme<S> {}
11461146+ impl<S: State> State for SetLightCodeTheme<S> {
11501147 type DarkScheme = S::DarkScheme;
11511148 type DarkCodeTheme = S::DarkCodeTheme;
11521152- type Fonts = Set<members::fonts>;
11491149+ type Spacing = S::Spacing;
11501150+ type LightScheme = S::LightScheme;
11511151+ type Fonts = S::Fonts;
11521152+ type LightCodeTheme = Set<members::light_code_theme>;
11531153 }
11541154 /// Marker types for field names
11551155 #[allow(non_camel_case_types)]
11561156 pub mod members {
11571157- ///Marker type for the `light_scheme` field
11581158- pub struct light_scheme(());
11591159- ///Marker type for the `spacing` field
11601160- pub struct spacing(());
11611161- ///Marker type for the `light_code_theme` field
11621162- pub struct light_code_theme(());
11631157 ///Marker type for the `dark_scheme` field
11641158 pub struct dark_scheme(());
11651159 ///Marker type for the `dark_code_theme` field
11661160 pub struct dark_code_theme(());
11611161+ ///Marker type for the `spacing` field
11621162+ pub struct spacing(());
11631163+ ///Marker type for the `light_scheme` field
11641164+ pub struct light_scheme(());
11671165 ///Marker type for the `fonts` field
11681166 pub struct fonts(());
11671167+ ///Marker type for the `light_code_theme` field
11681168+ pub struct light_code_theme(());
11691169 }
11701170}
11711171···13381338impl<'a, S> ThemeBuilder<'a, S>
13391339where
13401340 S: theme_state::State,
13411341- S::LightScheme: theme_state::IsSet,
13421342- S::Spacing: theme_state::IsSet,
13431343- S::LightCodeTheme: theme_state::IsSet,
13441341 S::DarkScheme: theme_state::IsSet,
13451342 S::DarkCodeTheme: theme_state::IsSet,
13431343+ S::Spacing: theme_state::IsSet,
13441344+ S::LightScheme: theme_state::IsSet,
13461345 S::Fonts: theme_state::IsSet,
13461346+ S::LightCodeTheme: theme_state::IsSet,
13471347{
13481348 /// Build the final struct
13491349 pub fn build(self) -> Theme<'a> {
···14421442 }
14431443 /// State trait tracking which required fields have been set
14441444 pub trait State: sealed::Sealed {
14451445- type Body;
14461446- type Heading;
14471445 type Monospace;
14461446+ type Heading;
14471447+ type Body;
14481448 }
14491449 /// Empty state - all required fields are unset
14501450 pub struct Empty(());
14511451 impl sealed::Sealed for Empty {}
14521452 impl State for Empty {
14531453+ type Monospace = Unset;
14541454+ type Heading = Unset;
14531455 type Body = Unset;
14541454- type Heading = Unset;
14551455- type Monospace = Unset;
14561456 }
14571457- ///State transition - sets the `body` field to Set
14581458- pub struct SetBody<S: State = Empty>(PhantomData<fn() -> S>);
14591459- impl<S: State> sealed::Sealed for SetBody<S> {}
14601460- impl<S: State> State for SetBody<S> {
14611461- type Body = Set<members::body>;
14571457+ ///State transition - sets the `monospace` field to Set
14581458+ pub struct SetMonospace<S: State = Empty>(PhantomData<fn() -> S>);
14591459+ impl<S: State> sealed::Sealed for SetMonospace<S> {}
14601460+ impl<S: State> State for SetMonospace<S> {
14611461+ type Monospace = Set<members::monospace>;
14621462 type Heading = S::Heading;
14631463- type Monospace = S::Monospace;
14631463+ type Body = S::Body;
14641464 }
14651465 ///State transition - sets the `heading` field to Set
14661466 pub struct SetHeading<S: State = Empty>(PhantomData<fn() -> S>);
14671467 impl<S: State> sealed::Sealed for SetHeading<S> {}
14681468 impl<S: State> State for SetHeading<S> {
14691469+ type Monospace = S::Monospace;
14701470+ type Heading = Set<members::heading>;
14691471 type Body = S::Body;
14701470- type Heading = Set<members::heading>;
14711471- type Monospace = S::Monospace;
14721472 }
14731473- ///State transition - sets the `monospace` field to Set
14741474- pub struct SetMonospace<S: State = Empty>(PhantomData<fn() -> S>);
14751475- impl<S: State> sealed::Sealed for SetMonospace<S> {}
14761476- impl<S: State> State for SetMonospace<S> {
14771477- type Body = S::Body;
14731473+ ///State transition - sets the `body` field to Set
14741474+ pub struct SetBody<S: State = Empty>(PhantomData<fn() -> S>);
14751475+ impl<S: State> sealed::Sealed for SetBody<S> {}
14761476+ impl<S: State> State for SetBody<S> {
14771477+ type Monospace = S::Monospace;
14781478 type Heading = S::Heading;
14791479- type Monospace = Set<members::monospace>;
14791479+ type Body = Set<members::body>;
14801480 }
14811481 /// Marker types for field names
14821482 #[allow(non_camel_case_types)]
14831483 pub mod members {
14841484+ ///Marker type for the `monospace` field
14851485+ pub struct monospace(());
14861486+ ///Marker type for the `heading` field
14871487+ pub struct heading(());
14841488 ///Marker type for the `body` field
14851489 pub struct body(());
14861486- ///Marker type for the `heading` field
14871487- pub struct heading(());
14881488- ///Marker type for the `monospace` field
14891489- pub struct monospace(());
14901490 }
14911491}
14921492···15791579impl<'a, S> ThemeFontsBuilder<'a, S>
15801580where
15811581 S: theme_fonts_state::State,
15821582- S::Body: theme_fonts_state::IsSet,
15831583- S::Heading: theme_fonts_state::IsSet,
15841582 S::Monospace: theme_fonts_state::IsSet,
15831583+ S::Heading: theme_fonts_state::IsSet,
15841584+ S::Body: theme_fonts_state::IsSet,
15851585{
15861586 /// Build the final struct
15871587 pub fn build(self) -> ThemeFonts<'a> {
+111-111
crates/weaver-api/src/sh_weaver/notification.rs
···5252 }
5353 /// State trait tracking which required fields have been set
5454 pub trait State: sealed::Sealed {
5555+ type Reason;
5656+ type Uri;
5557 type Cid;
5858+ type Author;
5659 type IndexedAt;
5760 type IsRead;
5858- type Author;
5959- type Reason;
6060- type Uri;
6161 }
6262 /// Empty state - all required fields are unset
6363 pub struct Empty(());
6464 impl sealed::Sealed for Empty {}
6565 impl State for Empty {
6666+ type Reason = Unset;
6767+ type Uri = Unset;
6668 type Cid = Unset;
6969+ type Author = Unset;
6770 type IndexedAt = Unset;
6871 type IsRead = Unset;
6969- type Author = Unset;
7070- type Reason = Unset;
7171- type Uri = Unset;
7272+ }
7373+ ///State transition - sets the `reason` field to Set
7474+ pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
7575+ impl<S: State> sealed::Sealed for SetReason<S> {}
7676+ impl<S: State> State for SetReason<S> {
7777+ type Reason = Set<members::reason>;
7878+ type Uri = S::Uri;
7979+ type Cid = S::Cid;
8080+ type Author = S::Author;
8181+ type IndexedAt = S::IndexedAt;
8282+ type IsRead = S::IsRead;
8383+ }
8484+ ///State transition - sets the `uri` field to Set
8585+ pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
8686+ impl<S: State> sealed::Sealed for SetUri<S> {}
8787+ impl<S: State> State for SetUri<S> {
8888+ type Reason = S::Reason;
8989+ type Uri = Set<members::uri>;
9090+ type Cid = S::Cid;
9191+ type Author = S::Author;
9292+ type IndexedAt = S::IndexedAt;
9393+ type IsRead = S::IsRead;
7294 }
7395 ///State transition - sets the `cid` field to Set
7496 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
7597 impl<S: State> sealed::Sealed for SetCid<S> {}
7698 impl<S: State> State for SetCid<S> {
9999+ type Reason = S::Reason;
100100+ type Uri = S::Uri;
77101 type Cid = Set<members::cid>;
102102+ type Author = S::Author;
78103 type IndexedAt = S::IndexedAt;
79104 type IsRead = S::IsRead;
8080- type Author = S::Author;
105105+ }
106106+ ///State transition - sets the `author` field to Set
107107+ pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
108108+ impl<S: State> sealed::Sealed for SetAuthor<S> {}
109109+ impl<S: State> State for SetAuthor<S> {
81110 type Reason = S::Reason;
82111 type Uri = S::Uri;
112112+ type Cid = S::Cid;
113113+ type Author = Set<members::author>;
114114+ type IndexedAt = S::IndexedAt;
115115+ type IsRead = S::IsRead;
83116 }
84117 ///State transition - sets the `indexed_at` field to Set
85118 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
86119 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
87120 impl<S: State> State for SetIndexedAt<S> {
121121+ type Reason = S::Reason;
122122+ type Uri = S::Uri;
88123 type Cid = S::Cid;
124124+ type Author = S::Author;
89125 type IndexedAt = Set<members::indexed_at>;
90126 type IsRead = S::IsRead;
9191- type Author = S::Author;
9292- type Reason = S::Reason;
9393- type Uri = S::Uri;
94127 }
95128 ///State transition - sets the `is_read` field to Set
96129 pub struct SetIsRead<S: State = Empty>(PhantomData<fn() -> S>);
97130 impl<S: State> sealed::Sealed for SetIsRead<S> {}
98131 impl<S: State> State for SetIsRead<S> {
9999- type Cid = S::Cid;
100100- type IndexedAt = S::IndexedAt;
101101- type IsRead = Set<members::is_read>;
102102- type Author = S::Author;
103132 type Reason = S::Reason;
104133 type Uri = S::Uri;
105105- }
106106- ///State transition - sets the `author` field to Set
107107- pub struct SetAuthor<S: State = Empty>(PhantomData<fn() -> S>);
108108- impl<S: State> sealed::Sealed for SetAuthor<S> {}
109109- impl<S: State> State for SetAuthor<S> {
110134 type Cid = S::Cid;
111111- type IndexedAt = S::IndexedAt;
112112- type IsRead = S::IsRead;
113113- type Author = Set<members::author>;
114114- type Reason = S::Reason;
115115- type Uri = S::Uri;
116116- }
117117- ///State transition - sets the `reason` field to Set
118118- pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
119119- impl<S: State> sealed::Sealed for SetReason<S> {}
120120- impl<S: State> State for SetReason<S> {
121121- type Cid = S::Cid;
122122- type IndexedAt = S::IndexedAt;
123123- type IsRead = S::IsRead;
124135 type Author = S::Author;
125125- type Reason = Set<members::reason>;
126126- type Uri = S::Uri;
127127- }
128128- ///State transition - sets the `uri` field to Set
129129- pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
130130- impl<S: State> sealed::Sealed for SetUri<S> {}
131131- impl<S: State> State for SetUri<S> {
132132- type Cid = S::Cid;
133136 type IndexedAt = S::IndexedAt;
134134- type IsRead = S::IsRead;
135135- type Author = S::Author;
136136- type Reason = S::Reason;
137137- type Uri = Set<members::uri>;
137137+ type IsRead = Set<members::is_read>;
138138 }
139139 /// Marker types for field names
140140 #[allow(non_camel_case_types)]
141141 pub mod members {
142142+ ///Marker type for the `reason` field
143143+ pub struct reason(());
144144+ ///Marker type for the `uri` field
145145+ pub struct uri(());
142146 ///Marker type for the `cid` field
143147 pub struct cid(());
148148+ ///Marker type for the `author` field
149149+ pub struct author(());
144150 ///Marker type for the `indexed_at` field
145151 pub struct indexed_at(());
146152 ///Marker type for the `is_read` field
147153 pub struct is_read(());
148148- ///Marker type for the `author` field
149149- pub struct author(());
150150- ///Marker type for the `reason` field
151151- pub struct reason(());
152152- ///Marker type for the `uri` field
153153- pub struct uri(());
154154 }
155155}
156156···343343impl<'a, S> NotificationBuilder<'a, S>
344344where
345345 S: notification_state::State,
346346+ S::Reason: notification_state::IsSet,
347347+ S::Uri: notification_state::IsSet,
346348 S::Cid: notification_state::IsSet,
349349+ S::Author: notification_state::IsSet,
347350 S::IndexedAt: notification_state::IsSet,
348351 S::IsRead: notification_state::IsSet,
349349- S::Author: notification_state::IsSet,
350350- S::Reason: notification_state::IsSet,
351351- S::Uri: notification_state::IsSet,
352352{
353353 /// Build the final struct
354354 pub fn build(self) -> Notification<'a> {
···801801 }
802802 /// State trait tracking which required fields have been set
803803 pub trait State: sealed::Sealed {
804804- type Reason;
804804+ type Subject;
805805 type Actors;
806806- type Subject;
807807- type Count;
808806 type MostRecentAt;
807807+ type Reason;
808808+ type Count;
809809 }
810810 /// Empty state - all required fields are unset
811811 pub struct Empty(());
812812 impl sealed::Sealed for Empty {}
813813 impl State for Empty {
814814+ type Subject = Unset;
815815+ type Actors = Unset;
816816+ type MostRecentAt = Unset;
814817 type Reason = Unset;
815815- type Actors = Unset;
816816- type Subject = Unset;
817818 type Count = Unset;
818818- type MostRecentAt = Unset;
819819 }
820820- ///State transition - sets the `reason` field to Set
821821- pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
822822- impl<S: State> sealed::Sealed for SetReason<S> {}
823823- impl<S: State> State for SetReason<S> {
824824- type Reason = Set<members::reason>;
820820+ ///State transition - sets the `subject` field to Set
821821+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
822822+ impl<S: State> sealed::Sealed for SetSubject<S> {}
823823+ impl<S: State> State for SetSubject<S> {
824824+ type Subject = Set<members::subject>;
825825 type Actors = S::Actors;
826826- type Subject = S::Subject;
826826+ type MostRecentAt = S::MostRecentAt;
827827+ type Reason = S::Reason;
827828 type Count = S::Count;
828828- type MostRecentAt = S::MostRecentAt;
829829 }
830830 ///State transition - sets the `actors` field to Set
831831 pub struct SetActors<S: State = Empty>(PhantomData<fn() -> S>);
832832 impl<S: State> sealed::Sealed for SetActors<S> {}
833833 impl<S: State> State for SetActors<S> {
834834- type Reason = S::Reason;
835835- type Actors = Set<members::actors>;
836834 type Subject = S::Subject;
837837- type Count = S::Count;
835835+ type Actors = Set<members::actors>;
838836 type MostRecentAt = S::MostRecentAt;
839839- }
840840- ///State transition - sets the `subject` field to Set
841841- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
842842- impl<S: State> sealed::Sealed for SetSubject<S> {}
843843- impl<S: State> State for SetSubject<S> {
844837 type Reason = S::Reason;
838838+ type Count = S::Count;
839839+ }
840840+ ///State transition - sets the `most_recent_at` field to Set
841841+ pub struct SetMostRecentAt<S: State = Empty>(PhantomData<fn() -> S>);
842842+ impl<S: State> sealed::Sealed for SetMostRecentAt<S> {}
843843+ impl<S: State> State for SetMostRecentAt<S> {
844844+ type Subject = S::Subject;
845845 type Actors = S::Actors;
846846- type Subject = Set<members::subject>;
846846+ type MostRecentAt = Set<members::most_recent_at>;
847847+ type Reason = S::Reason;
847848 type Count = S::Count;
849849+ }
850850+ ///State transition - sets the `reason` field to Set
851851+ pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
852852+ impl<S: State> sealed::Sealed for SetReason<S> {}
853853+ impl<S: State> State for SetReason<S> {
854854+ type Subject = S::Subject;
855855+ type Actors = S::Actors;
848856 type MostRecentAt = S::MostRecentAt;
857857+ type Reason = Set<members::reason>;
858858+ type Count = S::Count;
849859 }
850860 ///State transition - sets the `count` field to Set
851861 pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
852862 impl<S: State> sealed::Sealed for SetCount<S> {}
853863 impl<S: State> State for SetCount<S> {
854854- type Reason = S::Reason;
855855- type Actors = S::Actors;
856864 type Subject = S::Subject;
857857- type Count = Set<members::count>;
865865+ type Actors = S::Actors;
858866 type MostRecentAt = S::MostRecentAt;
859859- }
860860- ///State transition - sets the `most_recent_at` field to Set
861861- pub struct SetMostRecentAt<S: State = Empty>(PhantomData<fn() -> S>);
862862- impl<S: State> sealed::Sealed for SetMostRecentAt<S> {}
863863- impl<S: State> State for SetMostRecentAt<S> {
864867 type Reason = S::Reason;
865865- type Actors = S::Actors;
866866- type Subject = S::Subject;
867867- type Count = S::Count;
868868- type MostRecentAt = Set<members::most_recent_at>;
868868+ type Count = Set<members::count>;
869869 }
870870 /// Marker types for field names
871871 #[allow(non_camel_case_types)]
872872 pub mod members {
873873+ ///Marker type for the `subject` field
874874+ pub struct subject(());
875875+ ///Marker type for the `actors` field
876876+ pub struct actors(());
877877+ ///Marker type for the `most_recent_at` field
878878+ pub struct most_recent_at(());
873879 ///Marker type for the `reason` field
874880 pub struct reason(());
875875- ///Marker type for the `actors` field
876876- pub struct actors(());
877877- ///Marker type for the `subject` field
878878- pub struct subject(());
879881 ///Marker type for the `count` field
880882 pub struct count(());
881881- ///Marker type for the `most_recent_at` field
882882- pub struct most_recent_at(());
883883 }
884884}
885885···10261026impl<'a, S> NotificationGroupBuilder<'a, S>
10271027where
10281028 S: notification_group_state::State,
10291029- S::Reason: notification_group_state::IsSet,
10301030- S::Actors: notification_group_state::IsSet,
10311029 S::Subject: notification_group_state::IsSet,
10321032- S::Count: notification_group_state::IsSet,
10301030+ S::Actors: notification_group_state::IsSet,
10331031 S::MostRecentAt: notification_group_state::IsSet,
10321032+ S::Reason: notification_group_state::IsSet,
10331033+ S::Count: notification_group_state::IsSet,
10341034{
10351035 /// Build the final struct
10361036 pub fn build(self) -> NotificationGroup<'a> {
···12931293 /// State trait tracking which required fields have been set
12941294 pub trait State: sealed::Sealed {
12951295 type NewEntries;
12961296- type Notebook;
12971296 type UpdatedAt;
12971297+ type Notebook;
12981298 }
12991299 /// Empty state - all required fields are unset
13001300 pub struct Empty(());
13011301 impl sealed::Sealed for Empty {}
13021302 impl State for Empty {
13031303 type NewEntries = Unset;
13041304+ type UpdatedAt = Unset;
13041305 type Notebook = Unset;
13051305- type UpdatedAt = Unset;
13061306 }
13071307 ///State transition - sets the `new_entries` field to Set
13081308 pub struct SetNewEntries<S: State = Empty>(PhantomData<fn() -> S>);
13091309 impl<S: State> sealed::Sealed for SetNewEntries<S> {}
13101310 impl<S: State> State for SetNewEntries<S> {
13111311 type NewEntries = Set<members::new_entries>;
13121312+ type UpdatedAt = S::UpdatedAt;
13121313 type Notebook = S::Notebook;
13131313- type UpdatedAt = S::UpdatedAt;
13141314+ }
13151315+ ///State transition - sets the `updated_at` field to Set
13161316+ pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
13171317+ impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
13181318+ impl<S: State> State for SetUpdatedAt<S> {
13191319+ type NewEntries = S::NewEntries;
13201320+ type UpdatedAt = Set<members::updated_at>;
13211321+ type Notebook = S::Notebook;
13141322 }
13151323 ///State transition - sets the `notebook` field to Set
13161324 pub struct SetNotebook<S: State = Empty>(PhantomData<fn() -> S>);
13171325 impl<S: State> sealed::Sealed for SetNotebook<S> {}
13181326 impl<S: State> State for SetNotebook<S> {
13191327 type NewEntries = S::NewEntries;
13201320- type Notebook = Set<members::notebook>;
13211328 type UpdatedAt = S::UpdatedAt;
13221322- }
13231323- ///State transition - sets the `updated_at` field to Set
13241324- pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
13251325- impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
13261326- impl<S: State> State for SetUpdatedAt<S> {
13271327- type NewEntries = S::NewEntries;
13281328- type Notebook = S::Notebook;
13291329- type UpdatedAt = Set<members::updated_at>;
13291329+ type Notebook = Set<members::notebook>;
13301330 }
13311331 /// Marker types for field names
13321332 #[allow(non_camel_case_types)]
13331333 pub mod members {
13341334 ///Marker type for the `new_entries` field
13351335 pub struct new_entries(());
13361336- ///Marker type for the `notebook` field
13371337- pub struct notebook(());
13381336 ///Marker type for the `updated_at` field
13391337 pub struct updated_at(());
13381338+ ///Marker type for the `notebook` field
13391339+ pub struct notebook(());
13401340 }
13411341}
13421342···14621462where
14631463 S: subscription_update_view_state::State,
14641464 S::NewEntries: subscription_update_view_state::IsSet,
14651465- S::Notebook: subscription_update_view_state::IsSet,
14661465 S::UpdatedAt: subscription_update_view_state::IsSet,
14661466+ S::Notebook: subscription_update_view_state::IsSet,
14671467{
14681468 /// Build the final struct
14691469 pub fn build(self) -> SubscriptionUpdateView<'a> {
+13-13
crates/weaver-api/src/sh_weaver/publish/blob.rs
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type Path;
4039 type Upload;
4040+ type Path;
4141 }
4242 /// Empty state - all required fields are unset
4343 pub struct Empty(());
4444 impl sealed::Sealed for Empty {}
4545 impl State for Empty {
4646- type Path = Unset;
4746 type Upload = Unset;
4848- }
4949- ///State transition - sets the `path` field to Set
5050- pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
5151- impl<S: State> sealed::Sealed for SetPath<S> {}
5252- impl<S: State> State for SetPath<S> {
5353- type Path = Set<members::path>;
5454- type Upload = S::Upload;
4747+ type Path = Unset;
5548 }
5649 ///State transition - sets the `upload` field to Set
5750 pub struct SetUpload<S: State = Empty>(PhantomData<fn() -> S>);
5851 impl<S: State> sealed::Sealed for SetUpload<S> {}
5952 impl<S: State> State for SetUpload<S> {
6060- type Path = S::Path;
6153 type Upload = Set<members::upload>;
5454+ type Path = S::Path;
5555+ }
5656+ ///State transition - sets the `path` field to Set
5757+ pub struct SetPath<S: State = Empty>(PhantomData<fn() -> S>);
5858+ impl<S: State> sealed::Sealed for SetPath<S> {}
5959+ impl<S: State> State for SetPath<S> {
6060+ type Upload = S::Upload;
6161+ type Path = Set<members::path>;
6262 }
6363 /// Marker types for field names
6464 #[allow(non_camel_case_types)]
6565 pub mod members {
6666- ///Marker type for the `path` field
6767- pub struct path(());
6866 ///Marker type for the `upload` field
6967 pub struct upload(());
6868+ ///Marker type for the `path` field
6969+ pub struct path(());
7070 }
7171}
7272···139139impl<'a, S> BlobBuilder<'a, S>
140140where
141141 S: blob_state::State,
142142- S::Path: blob_state::IsSet,
143142 S::Upload: blob_state::IsSet,
143143+ S::Path: blob_state::IsSet,
144144{
145145 /// Build the final struct
146146 pub fn build(self) -> Blob<'a> {
+24-24
crates/weaver-api/src/site_standard/document.rs
···6060 }
6161 /// State trait tracking which required fields have been set
6262 pub trait State: sealed::Sealed {
6363- type Title;
6464- type Publication;
6563 type PublishedAt;
6464+ type Publication;
6565+ type Title;
6666 }
6767 /// Empty state - all required fields are unset
6868 pub struct Empty(());
6969 impl sealed::Sealed for Empty {}
7070 impl State for Empty {
7171+ type PublishedAt = Unset;
7272+ type Publication = Unset;
7173 type Title = Unset;
7272- type Publication = Unset;
7373- type PublishedAt = Unset;
7474 }
7575- ///State transition - sets the `title` field to Set
7676- pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
7777- impl<S: State> sealed::Sealed for SetTitle<S> {}
7878- impl<S: State> State for SetTitle<S> {
7979- type Title = Set<members::title>;
7575+ ///State transition - sets the `published_at` field to Set
7676+ pub struct SetPublishedAt<S: State = Empty>(PhantomData<fn() -> S>);
7777+ impl<S: State> sealed::Sealed for SetPublishedAt<S> {}
7878+ impl<S: State> State for SetPublishedAt<S> {
7979+ type PublishedAt = Set<members::published_at>;
8080 type Publication = S::Publication;
8181- type PublishedAt = S::PublishedAt;
8181+ type Title = S::Title;
8282 }
8383 ///State transition - sets the `publication` field to Set
8484 pub struct SetPublication<S: State = Empty>(PhantomData<fn() -> S>);
8585 impl<S: State> sealed::Sealed for SetPublication<S> {}
8686 impl<S: State> State for SetPublication<S> {
8787- type Title = S::Title;
8888- type Publication = Set<members::publication>;
8987 type PublishedAt = S::PublishedAt;
8888+ type Publication = Set<members::publication>;
8989+ type Title = S::Title;
9090 }
9191- ///State transition - sets the `published_at` field to Set
9292- pub struct SetPublishedAt<S: State = Empty>(PhantomData<fn() -> S>);
9393- impl<S: State> sealed::Sealed for SetPublishedAt<S> {}
9494- impl<S: State> State for SetPublishedAt<S> {
9595- type Title = S::Title;
9191+ ///State transition - sets the `title` field to Set
9292+ pub struct SetTitle<S: State = Empty>(PhantomData<fn() -> S>);
9393+ impl<S: State> sealed::Sealed for SetTitle<S> {}
9494+ impl<S: State> State for SetTitle<S> {
9595+ type PublishedAt = S::PublishedAt;
9696 type Publication = S::Publication;
9797- type PublishedAt = Set<members::published_at>;
9797+ type Title = Set<members::title>;
9898 }
9999 /// Marker types for field names
100100 #[allow(non_camel_case_types)]
101101 pub mod members {
102102+ ///Marker type for the `published_at` field
103103+ pub struct published_at(());
104104+ ///Marker type for the `publication` field
105105+ pub struct publication(());
102106 ///Marker type for the `title` field
103107 pub struct title(());
104104- ///Marker type for the `publication` field
105105- pub struct publication(());
106106- ///Marker type for the `published_at` field
107107- pub struct published_at(());
108108 }
109109}
110110···366366impl<'a, S> DocumentBuilder<'a, S>
367367where
368368 S: document_state::State,
369369- S::Title: document_state::IsSet,
370370- S::Publication: document_state::IsSet,
371369 S::PublishedAt: document_state::IsSet,
370370+ S::Publication: document_state::IsSet,
371371+ S::Title: document_state::IsSet,
372372{
373373 /// Build the final struct
374374 pub fn build(self) -> Document<'a> {
···3737 }
3838 /// State trait tracking which required fields have been set
3939 pub trait State: sealed::Sealed {
4040+ type AccentForeground;
4141+ type Accent;
4042 type Background;
4143 type Foreground;
4242- type AccentForeground;
4343- type Accent;
4444 }
4545 /// Empty state - all required fields are unset
4646 pub struct Empty(());
4747 impl sealed::Sealed for Empty {}
4848 impl State for Empty {
4949+ type AccentForeground = Unset;
5050+ type Accent = Unset;
4951 type Background = Unset;
5052 type Foreground = Unset;
5151- type AccentForeground = Unset;
5252- type Accent = Unset;
5353- }
5454- ///State transition - sets the `background` field to Set
5555- pub struct SetBackground<S: State = Empty>(PhantomData<fn() -> S>);
5656- impl<S: State> sealed::Sealed for SetBackground<S> {}
5757- impl<S: State> State for SetBackground<S> {
5858- type Background = Set<members::background>;
5959- type Foreground = S::Foreground;
6060- type AccentForeground = S::AccentForeground;
6161- type Accent = S::Accent;
6262- }
6363- ///State transition - sets the `foreground` field to Set
6464- pub struct SetForeground<S: State = Empty>(PhantomData<fn() -> S>);
6565- impl<S: State> sealed::Sealed for SetForeground<S> {}
6666- impl<S: State> State for SetForeground<S> {
6767- type Background = S::Background;
6868- type Foreground = Set<members::foreground>;
6969- type AccentForeground = S::AccentForeground;
7070- type Accent = S::Accent;
7153 }
7254 ///State transition - sets the `accent_foreground` field to Set
7355 pub struct SetAccentForeground<S: State = Empty>(PhantomData<fn() -> S>);
7456 impl<S: State> sealed::Sealed for SetAccentForeground<S> {}
7557 impl<S: State> State for SetAccentForeground<S> {
7676- type Background = S::Background;
7777- type Foreground = S::Foreground;
7858 type AccentForeground = Set<members::accent_foreground>;
7959 type Accent = S::Accent;
6060+ type Background = S::Background;
6161+ type Foreground = S::Foreground;
8062 }
8163 ///State transition - sets the `accent` field to Set
8264 pub struct SetAccent<S: State = Empty>(PhantomData<fn() -> S>);
8365 impl<S: State> sealed::Sealed for SetAccent<S> {}
8466 impl<S: State> State for SetAccent<S> {
6767+ type AccentForeground = S::AccentForeground;
6868+ type Accent = Set<members::accent>;
8569 type Background = S::Background;
8670 type Foreground = S::Foreground;
7171+ }
7272+ ///State transition - sets the `background` field to Set
7373+ pub struct SetBackground<S: State = Empty>(PhantomData<fn() -> S>);
7474+ impl<S: State> sealed::Sealed for SetBackground<S> {}
7575+ impl<S: State> State for SetBackground<S> {
8776 type AccentForeground = S::AccentForeground;
8888- type Accent = Set<members::accent>;
7777+ type Accent = S::Accent;
7878+ type Background = Set<members::background>;
7979+ type Foreground = S::Foreground;
8080+ }
8181+ ///State transition - sets the `foreground` field to Set
8282+ pub struct SetForeground<S: State = Empty>(PhantomData<fn() -> S>);
8383+ impl<S: State> sealed::Sealed for SetForeground<S> {}
8484+ impl<S: State> State for SetForeground<S> {
8585+ type AccentForeground = S::AccentForeground;
8686+ type Accent = S::Accent;
8787+ type Background = S::Background;
8888+ type Foreground = Set<members::foreground>;
8989 }
9090 /// Marker types for field names
9191 #[allow(non_camel_case_types)]
9292 pub mod members {
9393- ///Marker type for the `background` field
9494- pub struct background(());
9595- ///Marker type for the `foreground` field
9696- pub struct foreground(());
9793 ///Marker type for the `accent_foreground` field
9894 pub struct accent_foreground(());
9995 ///Marker type for the `accent` field
10096 pub struct accent(());
9797+ ///Marker type for the `background` field
9898+ pub struct background(());
9999+ ///Marker type for the `foreground` field
100100+ pub struct foreground(());
101101 }
102102}
103103···210210impl<'a, S> BasicBuilder<'a, S>
211211where
212212 S: basic_state::State,
213213+ S::AccentForeground: basic_state::IsSet,
214214+ S::Accent: basic_state::IsSet,
213215 S::Background: basic_state::IsSet,
214216 S::Foreground: basic_state::IsSet,
215215- S::AccentForeground: basic_state::IsSet,
216216- S::Accent: basic_state::IsSet,
217217{
218218 /// Build the final struct
219219 pub fn build(self) -> Basic<'a> {
···438438 }
439439 /// State trait tracking which required fields have been set
440440 pub trait State: sealed::Sealed {
441441- type A;
441441+ type G;
442442 type R;
443443+ type A;
443444 type B;
444444- type G;
445445 }
446446 /// Empty state - all required fields are unset
447447 pub struct Empty(());
448448 impl sealed::Sealed for Empty {}
449449 impl State for Empty {
450450+ type G = Unset;
451451+ type R = Unset;
450452 type A = Unset;
451451- type R = Unset;
452453 type B = Unset;
453453- type G = Unset;
454454 }
455455- ///State transition - sets the `a` field to Set
456456- pub struct SetA<S: State = Empty>(PhantomData<fn() -> S>);
457457- impl<S: State> sealed::Sealed for SetA<S> {}
458458- impl<S: State> State for SetA<S> {
459459- type A = Set<members::a>;
455455+ ///State transition - sets the `g` field to Set
456456+ pub struct SetG<S: State = Empty>(PhantomData<fn() -> S>);
457457+ impl<S: State> sealed::Sealed for SetG<S> {}
458458+ impl<S: State> State for SetG<S> {
459459+ type G = Set<members::g>;
460460 type R = S::R;
461461+ type A = S::A;
461462 type B = S::B;
462462- type G = S::G;
463463 }
464464 ///State transition - sets the `r` field to Set
465465 pub struct SetR<S: State = Empty>(PhantomData<fn() -> S>);
466466 impl<S: State> sealed::Sealed for SetR<S> {}
467467 impl<S: State> State for SetR<S> {
468468+ type G = S::G;
469469+ type R = Set<members::r>;
468470 type A = S::A;
469469- type R = Set<members::r>;
470471 type B = S::B;
472472+ }
473473+ ///State transition - sets the `a` field to Set
474474+ pub struct SetA<S: State = Empty>(PhantomData<fn() -> S>);
475475+ impl<S: State> sealed::Sealed for SetA<S> {}
476476+ impl<S: State> State for SetA<S> {
471477 type G = S::G;
478478+ type R = S::R;
479479+ type A = Set<members::a>;
480480+ type B = S::B;
472481 }
473482 ///State transition - sets the `b` field to Set
474483 pub struct SetB<S: State = Empty>(PhantomData<fn() -> S>);
475484 impl<S: State> sealed::Sealed for SetB<S> {}
476485 impl<S: State> State for SetB<S> {
477477- type A = S::A;
478478- type R = S::R;
479479- type B = Set<members::b>;
480486 type G = S::G;
481481- }
482482- ///State transition - sets the `g` field to Set
483483- pub struct SetG<S: State = Empty>(PhantomData<fn() -> S>);
484484- impl<S: State> sealed::Sealed for SetG<S> {}
485485- impl<S: State> State for SetG<S> {
486486- type A = S::A;
487487 type R = S::R;
488488- type B = S::B;
489489- type G = Set<members::g>;
488488+ type A = S::A;
489489+ type B = Set<members::b>;
490490 }
491491 /// Marker types for field names
492492 #[allow(non_camel_case_types)]
493493 pub mod members {
494494- ///Marker type for the `a` field
495495- pub struct a(());
494494+ ///Marker type for the `g` field
495495+ pub struct g(());
496496 ///Marker type for the `r` field
497497 pub struct r(());
498498+ ///Marker type for the `a` field
499499+ pub struct a(());
498500 ///Marker type for the `b` field
499501 pub struct b(());
500500- ///Marker type for the `g` field
501501- pub struct g(());
502502 }
503503}
504504···599599impl<'a, S> RgbaBuilder<'a, S>
600600where
601601 S: rgba_state::State,
602602- S::A: rgba_state::IsSet,
602602+ S::G: rgba_state::IsSet,
603603 S::R: rgba_state::IsSet,
604604+ S::A: rgba_state::IsSet,
604605 S::B: rgba_state::IsSet,
605605- S::G: rgba_state::IsSet,
606606{
607607 /// Build the final struct
608608 pub fn build(self) -> Rgba<'a> {
···5555 }
5656 /// State trait tracking which required fields have been set
5757 pub trait State: sealed::Sealed {
5858- type CreatedAt;
5958 type ContentMarkdown;
6060- type Id;
5959+ type Disabled;
6160 type LastUpdatedBy;
6262- type UpdatedAt;
6161+ type CreatedAt;
6362 type Name;
6464- type Disabled;
6363+ type UpdatedAt;
6464+ type Id;
6565 }
6666 /// Empty state - all required fields are unset
6767 pub struct Empty(());
6868 impl sealed::Sealed for Empty {}
6969 impl State for Empty {
7070- type CreatedAt = Unset;
7170 type ContentMarkdown = Unset;
7272- type Id = Unset;
7171+ type Disabled = Unset;
7372 type LastUpdatedBy = Unset;
7474- type UpdatedAt = Unset;
7373+ type CreatedAt = Unset;
7574 type Name = Unset;
7676- type Disabled = Unset;
7777- }
7878- ///State transition - sets the `created_at` field to Set
7979- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
8080- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
8181- impl<S: State> State for SetCreatedAt<S> {
8282- type CreatedAt = Set<members::created_at>;
8383- type ContentMarkdown = S::ContentMarkdown;
8484- type Id = S::Id;
8585- type LastUpdatedBy = S::LastUpdatedBy;
8686- type UpdatedAt = S::UpdatedAt;
8787- type Name = S::Name;
8888- type Disabled = S::Disabled;
7575+ type UpdatedAt = Unset;
7676+ type Id = Unset;
8977 }
9078 ///State transition - sets the `content_markdown` field to Set
9179 pub struct SetContentMarkdown<S: State = Empty>(PhantomData<fn() -> S>);
9280 impl<S: State> sealed::Sealed for SetContentMarkdown<S> {}
9381 impl<S: State> State for SetContentMarkdown<S> {
9494- type CreatedAt = S::CreatedAt;
9582 type ContentMarkdown = Set<members::content_markdown>;
9696- type Id = S::Id;
8383+ type Disabled = S::Disabled;
9784 type LastUpdatedBy = S::LastUpdatedBy;
9898- type UpdatedAt = S::UpdatedAt;
8585+ type CreatedAt = S::CreatedAt;
9986 type Name = S::Name;
100100- type Disabled = S::Disabled;
8787+ type UpdatedAt = S::UpdatedAt;
8888+ type Id = S::Id;
10189 }
102102- ///State transition - sets the `id` field to Set
103103- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
104104- impl<S: State> sealed::Sealed for SetId<S> {}
105105- impl<S: State> State for SetId<S> {
106106- type CreatedAt = S::CreatedAt;
9090+ ///State transition - sets the `disabled` field to Set
9191+ pub struct SetDisabled<S: State = Empty>(PhantomData<fn() -> S>);
9292+ impl<S: State> sealed::Sealed for SetDisabled<S> {}
9393+ impl<S: State> State for SetDisabled<S> {
10794 type ContentMarkdown = S::ContentMarkdown;
108108- type Id = Set<members::id>;
9595+ type Disabled = Set<members::disabled>;
10996 type LastUpdatedBy = S::LastUpdatedBy;
110110- type UpdatedAt = S::UpdatedAt;
9797+ type CreatedAt = S::CreatedAt;
11198 type Name = S::Name;
112112- type Disabled = S::Disabled;
9999+ type UpdatedAt = S::UpdatedAt;
100100+ type Id = S::Id;
113101 }
114102 ///State transition - sets the `last_updated_by` field to Set
115103 pub struct SetLastUpdatedBy<S: State = Empty>(PhantomData<fn() -> S>);
116104 impl<S: State> sealed::Sealed for SetLastUpdatedBy<S> {}
117105 impl<S: State> State for SetLastUpdatedBy<S> {
118118- type CreatedAt = S::CreatedAt;
119106 type ContentMarkdown = S::ContentMarkdown;
120120- type Id = S::Id;
107107+ type Disabled = S::Disabled;
121108 type LastUpdatedBy = Set<members::last_updated_by>;
122122- type UpdatedAt = S::UpdatedAt;
109109+ type CreatedAt = S::CreatedAt;
123110 type Name = S::Name;
124124- type Disabled = S::Disabled;
111111+ type UpdatedAt = S::UpdatedAt;
112112+ type Id = S::Id;
125113 }
126126- ///State transition - sets the `updated_at` field to Set
127127- pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
128128- impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
129129- impl<S: State> State for SetUpdatedAt<S> {
130130- type CreatedAt = S::CreatedAt;
114114+ ///State transition - sets the `created_at` field to Set
115115+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
116116+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
117117+ impl<S: State> State for SetCreatedAt<S> {
131118 type ContentMarkdown = S::ContentMarkdown;
132132- type Id = S::Id;
119119+ type Disabled = S::Disabled;
133120 type LastUpdatedBy = S::LastUpdatedBy;
134134- type UpdatedAt = Set<members::updated_at>;
121121+ type CreatedAt = Set<members::created_at>;
135122 type Name = S::Name;
136136- type Disabled = S::Disabled;
123123+ type UpdatedAt = S::UpdatedAt;
124124+ type Id = S::Id;
137125 }
138126 ///State transition - sets the `name` field to Set
139127 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
140128 impl<S: State> sealed::Sealed for SetName<S> {}
141129 impl<S: State> State for SetName<S> {
142142- type CreatedAt = S::CreatedAt;
143130 type ContentMarkdown = S::ContentMarkdown;
144144- type Id = S::Id;
131131+ type Disabled = S::Disabled;
145132 type LastUpdatedBy = S::LastUpdatedBy;
146146- type UpdatedAt = S::UpdatedAt;
133133+ type CreatedAt = S::CreatedAt;
147134 type Name = Set<members::name>;
135135+ type UpdatedAt = S::UpdatedAt;
136136+ type Id = S::Id;
137137+ }
138138+ ///State transition - sets the `updated_at` field to Set
139139+ pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
140140+ impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
141141+ impl<S: State> State for SetUpdatedAt<S> {
142142+ type ContentMarkdown = S::ContentMarkdown;
148143 type Disabled = S::Disabled;
144144+ type LastUpdatedBy = S::LastUpdatedBy;
145145+ type CreatedAt = S::CreatedAt;
146146+ type Name = S::Name;
147147+ type UpdatedAt = Set<members::updated_at>;
148148+ type Id = S::Id;
149149 }
150150- ///State transition - sets the `disabled` field to Set
151151- pub struct SetDisabled<S: State = Empty>(PhantomData<fn() -> S>);
152152- impl<S: State> sealed::Sealed for SetDisabled<S> {}
153153- impl<S: State> State for SetDisabled<S> {
154154- type CreatedAt = S::CreatedAt;
150150+ ///State transition - sets the `id` field to Set
151151+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
152152+ impl<S: State> sealed::Sealed for SetId<S> {}
153153+ impl<S: State> State for SetId<S> {
155154 type ContentMarkdown = S::ContentMarkdown;
156156- type Id = S::Id;
155155+ type Disabled = S::Disabled;
157156 type LastUpdatedBy = S::LastUpdatedBy;
158158- type UpdatedAt = S::UpdatedAt;
157157+ type CreatedAt = S::CreatedAt;
159158 type Name = S::Name;
160160- type Disabled = Set<members::disabled>;
159159+ type UpdatedAt = S::UpdatedAt;
160160+ type Id = Set<members::id>;
161161 }
162162 /// Marker types for field names
163163 #[allow(non_camel_case_types)]
164164 pub mod members {
165165- ///Marker type for the `created_at` field
166166- pub struct created_at(());
167165 ///Marker type for the `content_markdown` field
168166 pub struct content_markdown(());
169169- ///Marker type for the `id` field
170170- pub struct id(());
167167+ ///Marker type for the `disabled` field
168168+ pub struct disabled(());
171169 ///Marker type for the `last_updated_by` field
172170 pub struct last_updated_by(());
171171+ ///Marker type for the `created_at` field
172172+ pub struct created_at(());
173173+ ///Marker type for the `name` field
174174+ pub struct name(());
173175 ///Marker type for the `updated_at` field
174176 pub struct updated_at(());
175175- ///Marker type for the `name` field
176176- pub struct name(());
177177- ///Marker type for the `disabled` field
178178- pub struct disabled(());
177177+ ///Marker type for the `id` field
178178+ pub struct id(());
179179 }
180180}
181181···395395impl<'a, S> TemplateViewBuilder<'a, S>
396396where
397397 S: template_view_state::State,
398398- S::CreatedAt: template_view_state::IsSet,
399398 S::ContentMarkdown: template_view_state::IsSet,
400400- S::Id: template_view_state::IsSet,
399399+ S::Disabled: template_view_state::IsSet,
401400 S::LastUpdatedBy: template_view_state::IsSet,
402402- S::UpdatedAt: template_view_state::IsSet,
401401+ S::CreatedAt: template_view_state::IsSet,
403402 S::Name: template_view_state::IsSet,
404404- S::Disabled: template_view_state::IsSet,
403403+ S::UpdatedAt: template_view_state::IsSet,
404404+ S::Id: template_view_state::IsSet,
405405{
406406 /// Build the final struct
407407 pub fn build(self) -> TemplateView<'a> {
+617-617
crates/weaver-api/src/tools_ozone/moderation.rs
···53075307 }
53085308 /// State trait tracking which required fields have been set
53095309 pub trait State: sealed::Sealed {
53105310- type AttemptId;
53115311- type Status;
53125310 type CreatedAt;
53115311+ type Status;
53125312+ type AttemptId;
53135313 }
53145314 /// Empty state - all required fields are unset
53155315 pub struct Empty(());
53165316 impl sealed::Sealed for Empty {}
53175317 impl State for Empty {
53185318+ type CreatedAt = Unset;
53195319+ type Status = Unset;
53185320 type AttemptId = Unset;
53195319- type Status = Unset;
53205320- type CreatedAt = Unset;
53215321 }
53225322- ///State transition - sets the `attempt_id` field to Set
53235323- pub struct SetAttemptId<S: State = Empty>(PhantomData<fn() -> S>);
53245324- impl<S: State> sealed::Sealed for SetAttemptId<S> {}
53255325- impl<S: State> State for SetAttemptId<S> {
53265326- type AttemptId = Set<members::attempt_id>;
53225322+ ///State transition - sets the `created_at` field to Set
53235323+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
53245324+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
53255325+ impl<S: State> State for SetCreatedAt<S> {
53265326+ type CreatedAt = Set<members::created_at>;
53275327 type Status = S::Status;
53285328- type CreatedAt = S::CreatedAt;
53285328+ type AttemptId = S::AttemptId;
53295329 }
53305330 ///State transition - sets the `status` field to Set
53315331 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
53325332 impl<S: State> sealed::Sealed for SetStatus<S> {}
53335333 impl<S: State> State for SetStatus<S> {
53345334- type AttemptId = S::AttemptId;
53355335- type Status = Set<members::status>;
53365334 type CreatedAt = S::CreatedAt;
53355335+ type Status = Set<members::status>;
53365336+ type AttemptId = S::AttemptId;
53375337 }
53385338- ///State transition - sets the `created_at` field to Set
53395339- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
53405340- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
53415341- impl<S: State> State for SetCreatedAt<S> {
53425342- type AttemptId = S::AttemptId;
53385338+ ///State transition - sets the `attempt_id` field to Set
53395339+ pub struct SetAttemptId<S: State = Empty>(PhantomData<fn() -> S>);
53405340+ impl<S: State> sealed::Sealed for SetAttemptId<S> {}
53415341+ impl<S: State> State for SetAttemptId<S> {
53425342+ type CreatedAt = S::CreatedAt;
53435343 type Status = S::Status;
53445344- type CreatedAt = Set<members::created_at>;
53445344+ type AttemptId = Set<members::attempt_id>;
53455345 }
53465346 /// Marker types for field names
53475347 #[allow(non_camel_case_types)]
53485348 pub mod members {
53495349+ ///Marker type for the `created_at` field
53505350+ pub struct created_at(());
53515351+ ///Marker type for the `status` field
53525352+ pub struct status(());
53495353 ///Marker type for the `attempt_id` field
53505354 pub struct attempt_id(());
53515351- ///Marker type for the `status` field
53525352- pub struct status(());
53535353- ///Marker type for the `created_at` field
53545354- pub struct created_at(());
53555355 }
53565356}
53575357···55895589impl<'a, S> AgeAssuranceEventBuilder<'a, S>
55905590where
55915591 S: age_assurance_event_state::State,
55925592- S::AttemptId: age_assurance_event_state::IsSet,
55935593- S::Status: age_assurance_event_state::IsSet,
55945592 S::CreatedAt: age_assurance_event_state::IsSet,
55935593+ S::Status: age_assurance_event_state::IsSet,
55945594+ S::AttemptId: age_assurance_event_state::IsSet,
55955595{
55965596 /// Build the final struct
55975597 pub fn build(self) -> AgeAssuranceEvent<'a> {
···59265926 }
59275927 /// State trait tracking which required fields have been set
59285928 pub trait State: sealed::Sealed {
59295929- type Cid;
59305930- type MimeType;
59315929 type Size;
59305930+ type MimeType;
59315931+ type Cid;
59325932 type CreatedAt;
59335933 }
59345934 /// Empty state - all required fields are unset
59355935 pub struct Empty(());
59365936 impl sealed::Sealed for Empty {}
59375937 impl State for Empty {
59385938- type Cid = Unset;
59395939- type MimeType = Unset;
59405938 type Size = Unset;
59395939+ type MimeType = Unset;
59405940+ type Cid = Unset;
59415941 type CreatedAt = Unset;
59425942 }
59435943- ///State transition - sets the `cid` field to Set
59445944- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
59455945- impl<S: State> sealed::Sealed for SetCid<S> {}
59465946- impl<S: State> State for SetCid<S> {
59475947- type Cid = Set<members::cid>;
59435943+ ///State transition - sets the `size` field to Set
59445944+ pub struct SetSize<S: State = Empty>(PhantomData<fn() -> S>);
59455945+ impl<S: State> sealed::Sealed for SetSize<S> {}
59465946+ impl<S: State> State for SetSize<S> {
59475947+ type Size = Set<members::size>;
59485948 type MimeType = S::MimeType;
59495949- type Size = S::Size;
59495949+ type Cid = S::Cid;
59505950 type CreatedAt = S::CreatedAt;
59515951 }
59525952 ///State transition - sets the `mime_type` field to Set
59535953 pub struct SetMimeType<S: State = Empty>(PhantomData<fn() -> S>);
59545954 impl<S: State> sealed::Sealed for SetMimeType<S> {}
59555955 impl<S: State> State for SetMimeType<S> {
59565956+ type Size = S::Size;
59575957+ type MimeType = Set<members::mime_type>;
59565958 type Cid = S::Cid;
59575957- type MimeType = Set<members::mime_type>;
59585958- type Size = S::Size;
59595959 type CreatedAt = S::CreatedAt;
59605960 }
59615961- ///State transition - sets the `size` field to Set
59625962- pub struct SetSize<S: State = Empty>(PhantomData<fn() -> S>);
59635963- impl<S: State> sealed::Sealed for SetSize<S> {}
59645964- impl<S: State> State for SetSize<S> {
59655965- type Cid = S::Cid;
59615961+ ///State transition - sets the `cid` field to Set
59625962+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
59635963+ impl<S: State> sealed::Sealed for SetCid<S> {}
59645964+ impl<S: State> State for SetCid<S> {
59655965+ type Size = S::Size;
59665966 type MimeType = S::MimeType;
59675967- type Size = Set<members::size>;
59675967+ type Cid = Set<members::cid>;
59685968 type CreatedAt = S::CreatedAt;
59695969 }
59705970 ///State transition - sets the `created_at` field to Set
59715971 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
59725972 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
59735973 impl<S: State> State for SetCreatedAt<S> {
59745974- type Cid = S::Cid;
59745974+ type Size = S::Size;
59755975 type MimeType = S::MimeType;
59765976- type Size = S::Size;
59765976+ type Cid = S::Cid;
59775977 type CreatedAt = Set<members::created_at>;
59785978 }
59795979 /// Marker types for field names
59805980 #[allow(non_camel_case_types)]
59815981 pub mod members {
59825982+ ///Marker type for the `size` field
59835983+ pub struct size(());
59845984+ ///Marker type for the `mime_type` field
59855985+ pub struct mime_type(());
59825986 ///Marker type for the `cid` field
59835987 pub struct cid(());
59845984- ///Marker type for the `mime_type` field
59855985- pub struct mime_type(());
59865986- ///Marker type for the `size` field
59875987- pub struct size(());
59885988 ///Marker type for the `created_at` field
59895989 pub struct created_at(());
59905990 }
···61336133impl<'a, S> BlobViewBuilder<'a, S>
61346134where
61356135 S: blob_view_state::State,
61366136- S::Cid: blob_view_state::IsSet,
61376137- S::MimeType: blob_view_state::IsSet,
61386136 S::Size: blob_view_state::IsSet,
61376137+ S::MimeType: blob_view_state::IsSet,
61386138+ S::Cid: blob_view_state::IsSet,
61396139 S::CreatedAt: blob_view_state::IsSet,
61406140{
61416141 /// Build the final struct
···64966496 }
64976497 /// State trait tracking which required fields have been set
64986498 pub trait State: sealed::Sealed {
64996499- type Height;
65006499 type Width;
65006500+ type Height;
65016501 }
65026502 /// Empty state - all required fields are unset
65036503 pub struct Empty(());
65046504 impl sealed::Sealed for Empty {}
65056505 impl State for Empty {
65066506+ type Width = Unset;
65066507 type Height = Unset;
65076507- type Width = Unset;
65086508+ }
65096509+ ///State transition - sets the `width` field to Set
65106510+ pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
65116511+ impl<S: State> sealed::Sealed for SetWidth<S> {}
65126512+ impl<S: State> State for SetWidth<S> {
65136513+ type Width = Set<members::width>;
65146514+ type Height = S::Height;
65086515 }
65096516 ///State transition - sets the `height` field to Set
65106517 pub struct SetHeight<S: State = Empty>(PhantomData<fn() -> S>);
65116518 impl<S: State> sealed::Sealed for SetHeight<S> {}
65126519 impl<S: State> State for SetHeight<S> {
65136513- type Height = Set<members::height>;
65146520 type Width = S::Width;
65156515- }
65166516- ///State transition - sets the `width` field to Set
65176517- pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
65186518- impl<S: State> sealed::Sealed for SetWidth<S> {}
65196519- impl<S: State> State for SetWidth<S> {
65206520- type Height = S::Height;
65216521- type Width = Set<members::width>;
65216521+ type Height = Set<members::height>;
65226522 }
65236523 /// Marker types for field names
65246524 #[allow(non_camel_case_types)]
65256525 pub mod members {
65266526+ ///Marker type for the `width` field
65276527+ pub struct width(());
65266528 ///Marker type for the `height` field
65276529 pub struct height(());
65286528- ///Marker type for the `width` field
65296529- pub struct width(());
65306530 }
65316531}
65326532···65966596impl<'a, S> ImageDetailsBuilder<'a, S>
65976597where
65986598 S: image_details_state::State,
65996599- S::Height: image_details_state::IsSet,
66006599 S::Width: image_details_state::IsSet,
66006600+ S::Height: image_details_state::IsSet,
66016601{
66026602 /// Build the final struct
66036603 pub fn build(self) -> ImageDetails<'a> {
···68966896 }
68976897 /// State trait tracking which required fields have been set
68986898 pub trait State: sealed::Sealed {
68996899- type NegateLabelVals;
69006899 type CreateLabelVals;
69006900+ type NegateLabelVals;
69016901 }
69026902 /// Empty state - all required fields are unset
69036903 pub struct Empty(());
69046904 impl sealed::Sealed for Empty {}
69056905 impl State for Empty {
69066906- type NegateLabelVals = Unset;
69076906 type CreateLabelVals = Unset;
69086908- }
69096909- ///State transition - sets the `negate_label_vals` field to Set
69106910- pub struct SetNegateLabelVals<S: State = Empty>(PhantomData<fn() -> S>);
69116911- impl<S: State> sealed::Sealed for SetNegateLabelVals<S> {}
69126912- impl<S: State> State for SetNegateLabelVals<S> {
69136913- type NegateLabelVals = Set<members::negate_label_vals>;
69146914- type CreateLabelVals = S::CreateLabelVals;
69076907+ type NegateLabelVals = Unset;
69156908 }
69166909 ///State transition - sets the `create_label_vals` field to Set
69176910 pub struct SetCreateLabelVals<S: State = Empty>(PhantomData<fn() -> S>);
69186911 impl<S: State> sealed::Sealed for SetCreateLabelVals<S> {}
69196912 impl<S: State> State for SetCreateLabelVals<S> {
69206920- type NegateLabelVals = S::NegateLabelVals;
69216913 type CreateLabelVals = Set<members::create_label_vals>;
69146914+ type NegateLabelVals = S::NegateLabelVals;
69156915+ }
69166916+ ///State transition - sets the `negate_label_vals` field to Set
69176917+ pub struct SetNegateLabelVals<S: State = Empty>(PhantomData<fn() -> S>);
69186918+ impl<S: State> sealed::Sealed for SetNegateLabelVals<S> {}
69196919+ impl<S: State> State for SetNegateLabelVals<S> {
69206920+ type CreateLabelVals = S::CreateLabelVals;
69216921+ type NegateLabelVals = Set<members::negate_label_vals>;
69226922 }
69236923 /// Marker types for field names
69246924 #[allow(non_camel_case_types)]
69256925 pub mod members {
69266926- ///Marker type for the `negate_label_vals` field
69276927- pub struct negate_label_vals(());
69286926 ///Marker type for the `create_label_vals` field
69296927 pub struct create_label_vals(());
69286928+ ///Marker type for the `negate_label_vals` field
69296929+ pub struct negate_label_vals(());
69306930 }
69316931}
69326932···70307030impl<'a, S> ModEventLabelBuilder<'a, S>
70317031where
70327032 S: mod_event_label_state::State,
70337033- S::NegateLabelVals: mod_event_label_state::IsSet,
70347033 S::CreateLabelVals: mod_event_label_state::IsSet,
70347034+ S::NegateLabelVals: mod_event_label_state::IsSet,
70357035{
70367036 /// Build the final struct
70377037 pub fn build(self) -> ModEventLabel<'a> {
···77777777 }
77787778 /// State trait tracking which required fields have been set
77797779 pub trait State: sealed::Sealed {
77807780- type Remove;
77817780 type Add;
77817781+ type Remove;
77827782 }
77837783 /// Empty state - all required fields are unset
77847784 pub struct Empty(());
77857785 impl sealed::Sealed for Empty {}
77867786 impl State for Empty {
77877787+ type Add = Unset;
77877788 type Remove = Unset;
77887788- type Add = Unset;
77897789+ }
77907790+ ///State transition - sets the `add` field to Set
77917791+ pub struct SetAdd<S: State = Empty>(PhantomData<fn() -> S>);
77927792+ impl<S: State> sealed::Sealed for SetAdd<S> {}
77937793+ impl<S: State> State for SetAdd<S> {
77947794+ type Add = Set<members::add>;
77957795+ type Remove = S::Remove;
77897796 }
77907797 ///State transition - sets the `remove` field to Set
77917798 pub struct SetRemove<S: State = Empty>(PhantomData<fn() -> S>);
77927799 impl<S: State> sealed::Sealed for SetRemove<S> {}
77937800 impl<S: State> State for SetRemove<S> {
77947794- type Remove = Set<members::remove>;
77957801 type Add = S::Add;
77967796- }
77977797- ///State transition - sets the `add` field to Set
77987798- pub struct SetAdd<S: State = Empty>(PhantomData<fn() -> S>);
77997799- impl<S: State> sealed::Sealed for SetAdd<S> {}
78007800- impl<S: State> State for SetAdd<S> {
78017801- type Remove = S::Remove;
78027802- type Add = Set<members::add>;
78027802+ type Remove = Set<members::remove>;
78037803 }
78047804 /// Marker types for field names
78057805 #[allow(non_camel_case_types)]
78067806 pub mod members {
78077807+ ///Marker type for the `add` field
78087808+ pub struct add(());
78077809 ///Marker type for the `remove` field
78087810 pub struct remove(());
78097809- ///Marker type for the `add` field
78107810- pub struct add(());
78117811 }
78127812}
78137813···78977897impl<'a, S> ModEventTagBuilder<'a, S>
78987898where
78997899 S: mod_event_tag_state::State,
79007900- S::Remove: mod_event_tag_state::IsSet,
79017900 S::Add: mod_event_tag_state::IsSet,
79017901+ S::Remove: mod_event_tag_state::IsSet,
79027902{
79037903 /// Build the final struct
79047904 pub fn build(self) -> ModEventTag<'a> {
···81328132 }
81338133 /// State trait tracking which required fields have been set
81348134 pub trait State: sealed::Sealed {
81358135- type Event;
81368136- type Subject;
81378135 type SubjectBlobCids;
81368136+ type CreatedBy;
81378137+ type CreatedAt;
81388138 type Id;
81398139- type CreatedAt;
81408140- type CreatedBy;
81398139+ type Event;
81408140+ type Subject;
81418141 }
81428142 /// Empty state - all required fields are unset
81438143 pub struct Empty(());
81448144 impl sealed::Sealed for Empty {}
81458145 impl State for Empty {
81468146- type Event = Unset;
81478147- type Subject = Unset;
81488146 type SubjectBlobCids = Unset;
81498149- type Id = Unset;
81508150- type CreatedAt = Unset;
81518147 type CreatedBy = Unset;
81528152- }
81538153- ///State transition - sets the `event` field to Set
81548154- pub struct SetEvent<S: State = Empty>(PhantomData<fn() -> S>);
81558155- impl<S: State> sealed::Sealed for SetEvent<S> {}
81568156- impl<S: State> State for SetEvent<S> {
81578157- type Event = Set<members::event>;
81588158- type Subject = S::Subject;
81598159- type SubjectBlobCids = S::SubjectBlobCids;
81608160- type Id = S::Id;
81618161- type CreatedAt = S::CreatedAt;
81628162- type CreatedBy = S::CreatedBy;
81638163- }
81648164- ///State transition - sets the `subject` field to Set
81658165- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
81668166- impl<S: State> sealed::Sealed for SetSubject<S> {}
81678167- impl<S: State> State for SetSubject<S> {
81688168- type Event = S::Event;
81698169- type Subject = Set<members::subject>;
81708170- type SubjectBlobCids = S::SubjectBlobCids;
81718171- type Id = S::Id;
81728172- type CreatedAt = S::CreatedAt;
81738173- type CreatedBy = S::CreatedBy;
81488148+ type CreatedAt = Unset;
81498149+ type Id = Unset;
81508150+ type Event = Unset;
81518151+ type Subject = Unset;
81748152 }
81758153 ///State transition - sets the `subject_blob_cids` field to Set
81768154 pub struct SetSubjectBlobCids<S: State = Empty>(PhantomData<fn() -> S>);
81778155 impl<S: State> sealed::Sealed for SetSubjectBlobCids<S> {}
81788156 impl<S: State> State for SetSubjectBlobCids<S> {
81798179- type Event = S::Event;
81808180- type Subject = S::Subject;
81818157 type SubjectBlobCids = Set<members::subject_blob_cids>;
81828182- type Id = S::Id;
81588158+ type CreatedBy = S::CreatedBy;
81838159 type CreatedAt = S::CreatedAt;
81848184- type CreatedBy = S::CreatedBy;
81858185- }
81868186- ///State transition - sets the `id` field to Set
81878187- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
81888188- impl<S: State> sealed::Sealed for SetId<S> {}
81898189- impl<S: State> State for SetId<S> {
81608160+ type Id = S::Id;
81908161 type Event = S::Event;
81918162 type Subject = S::Subject;
81638163+ }
81648164+ ///State transition - sets the `created_by` field to Set
81658165+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
81668166+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
81678167+ impl<S: State> State for SetCreatedBy<S> {
81928168 type SubjectBlobCids = S::SubjectBlobCids;
81938193- type Id = Set<members::id>;
81698169+ type CreatedBy = Set<members::created_by>;
81948170 type CreatedAt = S::CreatedAt;
81958195- type CreatedBy = S::CreatedBy;
81718171+ type Id = S::Id;
81728172+ type Event = S::Event;
81738173+ type Subject = S::Subject;
81968174 }
81978175 ///State transition - sets the `created_at` field to Set
81988176 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
81998177 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
82008178 impl<S: State> State for SetCreatedAt<S> {
81798179+ type SubjectBlobCids = S::SubjectBlobCids;
81808180+ type CreatedBy = S::CreatedBy;
81818181+ type CreatedAt = Set<members::created_at>;
81828182+ type Id = S::Id;
82018183 type Event = S::Event;
82028184 type Subject = S::Subject;
81858185+ }
81868186+ ///State transition - sets the `id` field to Set
81878187+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
81888188+ impl<S: State> sealed::Sealed for SetId<S> {}
81898189+ impl<S: State> State for SetId<S> {
82038190 type SubjectBlobCids = S::SubjectBlobCids;
82048204- type Id = S::Id;
82058205- type CreatedAt = Set<members::created_at>;
82068191 type CreatedBy = S::CreatedBy;
82078207- }
82088208- ///State transition - sets the `created_by` field to Set
82098209- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
82108210- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
82118211- impl<S: State> State for SetCreatedBy<S> {
81928192+ type CreatedAt = S::CreatedAt;
81938193+ type Id = Set<members::id>;
82128194 type Event = S::Event;
82138195 type Subject = S::Subject;
81968196+ }
81978197+ ///State transition - sets the `event` field to Set
81988198+ pub struct SetEvent<S: State = Empty>(PhantomData<fn() -> S>);
81998199+ impl<S: State> sealed::Sealed for SetEvent<S> {}
82008200+ impl<S: State> State for SetEvent<S> {
82148201 type SubjectBlobCids = S::SubjectBlobCids;
82028202+ type CreatedBy = S::CreatedBy;
82038203+ type CreatedAt = S::CreatedAt;
82158204 type Id = S::Id;
82058205+ type Event = Set<members::event>;
82068206+ type Subject = S::Subject;
82078207+ }
82088208+ ///State transition - sets the `subject` field to Set
82098209+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
82108210+ impl<S: State> sealed::Sealed for SetSubject<S> {}
82118211+ impl<S: State> State for SetSubject<S> {
82128212+ type SubjectBlobCids = S::SubjectBlobCids;
82138213+ type CreatedBy = S::CreatedBy;
82168214 type CreatedAt = S::CreatedAt;
82178217- type CreatedBy = Set<members::created_by>;
82158215+ type Id = S::Id;
82168216+ type Event = S::Event;
82178217+ type Subject = Set<members::subject>;
82188218 }
82198219 /// Marker types for field names
82208220 #[allow(non_camel_case_types)]
82218221 pub mod members {
82228222- ///Marker type for the `event` field
82238223- pub struct event(());
82248224- ///Marker type for the `subject` field
82258225- pub struct subject(());
82268222 ///Marker type for the `subject_blob_cids` field
82278223 pub struct subject_blob_cids(());
82248224+ ///Marker type for the `created_by` field
82258225+ pub struct created_by(());
82268226+ ///Marker type for the `created_at` field
82278227+ pub struct created_at(());
82288228 ///Marker type for the `id` field
82298229 pub struct id(());
82308230- ///Marker type for the `created_at` field
82318231- pub struct created_at(());
82328232- ///Marker type for the `created_by` field
82338233- pub struct created_by(());
82308230+ ///Marker type for the `event` field
82318231+ pub struct event(());
82328232+ ///Marker type for the `subject` field
82338233+ pub struct subject(());
82348234 }
82358235}
82368236···84538453impl<'a, S> ModEventViewBuilder<'a, S>
84548454where
84558455 S: mod_event_view_state::State,
84568456- S::Event: mod_event_view_state::IsSet,
84578457- S::Subject: mod_event_view_state::IsSet,
84588456 S::SubjectBlobCids: mod_event_view_state::IsSet,
84598459- S::Id: mod_event_view_state::IsSet,
84608460- S::CreatedAt: mod_event_view_state::IsSet,
84618457 S::CreatedBy: mod_event_view_state::IsSet,
84588458+ S::CreatedAt: mod_event_view_state::IsSet,
84598459+ S::Id: mod_event_view_state::IsSet,
84608460+ S::Event: mod_event_view_state::IsSet,
84618461+ S::Subject: mod_event_view_state::IsSet,
84628462{
84638463 /// Build the final struct
84648464 pub fn build(self) -> ModEventView<'a> {
···86528652 }
86538653 /// State trait tracking which required fields have been set
86548654 pub trait State: sealed::Sealed {
86558655+ type CreatedBy;
86568656+ type CreatedAt;
86578657+ type Id;
86558658 type Subject;
86568659 type Event;
86578657- type Id;
86588660 type SubjectBlobs;
86598659- type CreatedAt;
86608660- type CreatedBy;
86618661 }
86628662 /// Empty state - all required fields are unset
86638663 pub struct Empty(());
86648664 impl sealed::Sealed for Empty {}
86658665 impl State for Empty {
86668666+ type CreatedBy = Unset;
86678667+ type CreatedAt = Unset;
86688668+ type Id = Unset;
86668669 type Subject = Unset;
86678670 type Event = Unset;
86688668- type Id = Unset;
86698671 type SubjectBlobs = Unset;
86708670- type CreatedAt = Unset;
86718671- type CreatedBy = Unset;
86728672+ }
86738673+ ///State transition - sets the `created_by` field to Set
86748674+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
86758675+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
86768676+ impl<S: State> State for SetCreatedBy<S> {
86778677+ type CreatedBy = Set<members::created_by>;
86788678+ type CreatedAt = S::CreatedAt;
86798679+ type Id = S::Id;
86808680+ type Subject = S::Subject;
86818681+ type Event = S::Event;
86828682+ type SubjectBlobs = S::SubjectBlobs;
86838683+ }
86848684+ ///State transition - sets the `created_at` field to Set
86858685+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
86868686+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
86878687+ impl<S: State> State for SetCreatedAt<S> {
86888688+ type CreatedBy = S::CreatedBy;
86898689+ type CreatedAt = Set<members::created_at>;
86908690+ type Id = S::Id;
86918691+ type Subject = S::Subject;
86928692+ type Event = S::Event;
86938693+ type SubjectBlobs = S::SubjectBlobs;
86948694+ }
86958695+ ///State transition - sets the `id` field to Set
86968696+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
86978697+ impl<S: State> sealed::Sealed for SetId<S> {}
86988698+ impl<S: State> State for SetId<S> {
86998699+ type CreatedBy = S::CreatedBy;
87008700+ type CreatedAt = S::CreatedAt;
87018701+ type Id = Set<members::id>;
87028702+ type Subject = S::Subject;
87038703+ type Event = S::Event;
87048704+ type SubjectBlobs = S::SubjectBlobs;
86728705 }
86738706 ///State transition - sets the `subject` field to Set
86748707 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
86758708 impl<S: State> sealed::Sealed for SetSubject<S> {}
86768709 impl<S: State> State for SetSubject<S> {
87108710+ type CreatedBy = S::CreatedBy;
87118711+ type CreatedAt = S::CreatedAt;
87128712+ type Id = S::Id;
86778713 type Subject = Set<members::subject>;
86788714 type Event = S::Event;
86798679- type Id = S::Id;
86808715 type SubjectBlobs = S::SubjectBlobs;
86818681- type CreatedAt = S::CreatedAt;
86828682- type CreatedBy = S::CreatedBy;
86838716 }
86848717 ///State transition - sets the `event` field to Set
86858718 pub struct SetEvent<S: State = Empty>(PhantomData<fn() -> S>);
86868719 impl<S: State> sealed::Sealed for SetEvent<S> {}
86878720 impl<S: State> State for SetEvent<S> {
87218721+ type CreatedBy = S::CreatedBy;
87228722+ type CreatedAt = S::CreatedAt;
87238723+ type Id = S::Id;
86888724 type Subject = S::Subject;
86898725 type Event = Set<members::event>;
86908690- type Id = S::Id;
86918726 type SubjectBlobs = S::SubjectBlobs;
86928692- type CreatedAt = S::CreatedAt;
86938693- type CreatedBy = S::CreatedBy;
86948694- }
86958695- ///State transition - sets the `id` field to Set
86968696- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
86978697- impl<S: State> sealed::Sealed for SetId<S> {}
86988698- impl<S: State> State for SetId<S> {
86998699- type Subject = S::Subject;
87008700- type Event = S::Event;
87018701- type Id = Set<members::id>;
87028702- type SubjectBlobs = S::SubjectBlobs;
87038703- type CreatedAt = S::CreatedAt;
87048704- type CreatedBy = S::CreatedBy;
87058727 }
87068728 ///State transition - sets the `subject_blobs` field to Set
87078729 pub struct SetSubjectBlobs<S: State = Empty>(PhantomData<fn() -> S>);
87088730 impl<S: State> sealed::Sealed for SetSubjectBlobs<S> {}
87098731 impl<S: State> State for SetSubjectBlobs<S> {
87108710- type Subject = S::Subject;
87118711- type Event = S::Event;
87128712- type Id = S::Id;
87138713- type SubjectBlobs = Set<members::subject_blobs>;
87148714- type CreatedAt = S::CreatedAt;
87158732 type CreatedBy = S::CreatedBy;
87168716- }
87178717- ///State transition - sets the `created_at` field to Set
87188718- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
87198719- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
87208720- impl<S: State> State for SetCreatedAt<S> {
87218721- type Subject = S::Subject;
87228722- type Event = S::Event;
87338733+ type CreatedAt = S::CreatedAt;
87238734 type Id = S::Id;
87248724- type SubjectBlobs = S::SubjectBlobs;
87258725- type CreatedAt = Set<members::created_at>;
87268726- type CreatedBy = S::CreatedBy;
87278727- }
87288728- ///State transition - sets the `created_by` field to Set
87298729- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
87308730- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
87318731- impl<S: State> State for SetCreatedBy<S> {
87328735 type Subject = S::Subject;
87338736 type Event = S::Event;
87348734- type Id = S::Id;
87358735- type SubjectBlobs = S::SubjectBlobs;
87368736- type CreatedAt = S::CreatedAt;
87378737- type CreatedBy = Set<members::created_by>;
87378737+ type SubjectBlobs = Set<members::subject_blobs>;
87388738 }
87398739 /// Marker types for field names
87408740 #[allow(non_camel_case_types)]
87418741 pub mod members {
87428742+ ///Marker type for the `created_by` field
87438743+ pub struct created_by(());
87448744+ ///Marker type for the `created_at` field
87458745+ pub struct created_at(());
87468746+ ///Marker type for the `id` field
87478747+ pub struct id(());
87428748 ///Marker type for the `subject` field
87438749 pub struct subject(());
87448750 ///Marker type for the `event` field
87458751 pub struct event(());
87468746- ///Marker type for the `id` field
87478747- pub struct id(());
87488752 ///Marker type for the `subject_blobs` field
87498753 pub struct subject_blobs(());
87508750- ///Marker type for the `created_at` field
87518751- pub struct created_at(());
87528752- ///Marker type for the `created_by` field
87538753- pub struct created_by(());
87548754 }
87558755}
87568756···89238923impl<'a, S> ModEventViewDetailBuilder<'a, S>
89248924where
89258925 S: mod_event_view_detail_state::State,
89268926+ S::CreatedBy: mod_event_view_detail_state::IsSet,
89278927+ S::CreatedAt: mod_event_view_detail_state::IsSet,
89288928+ S::Id: mod_event_view_detail_state::IsSet,
89268929 S::Subject: mod_event_view_detail_state::IsSet,
89278930 S::Event: mod_event_view_detail_state::IsSet,
89288928- S::Id: mod_event_view_detail_state::IsSet,
89298931 S::SubjectBlobs: mod_event_view_detail_state::IsSet,
89308930- S::CreatedAt: mod_event_view_detail_state::IsSet,
89318931- S::CreatedBy: mod_event_view_detail_state::IsSet,
89328932{
89338933 /// Build the final struct
89348934 pub fn build(self) -> ModEventViewDetail<'a> {
···96779677 }
96789678 /// State trait tracking which required fields have been set
96799679 pub trait State: sealed::Sealed {
96809680- type Cid;
96819681- type Moderation;
96829680 type Repo;
96839681 type Uri;
96829682+ type Moderation;
96839683+ type IndexedAt;
96849684+ type Cid;
96849685 type BlobCids;
96859685- type IndexedAt;
96869686 type Value;
96879687 }
96889688 /// Empty state - all required fields are unset
96899689 pub struct Empty(());
96909690 impl sealed::Sealed for Empty {}
96919691 impl State for Empty {
96929692- type Cid = Unset;
96939693- type Moderation = Unset;
96949692 type Repo = Unset;
96959693 type Uri = Unset;
96969696- type BlobCids = Unset;
96949694+ type Moderation = Unset;
96979695 type IndexedAt = Unset;
96969696+ type Cid = Unset;
96979697+ type BlobCids = Unset;
96989698 type Value = Unset;
96999699 }
97009700- ///State transition - sets the `cid` field to Set
97019701- pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
97029702- impl<S: State> sealed::Sealed for SetCid<S> {}
97039703- impl<S: State> State for SetCid<S> {
97049704- type Cid = Set<members::cid>;
97059705- type Moderation = S::Moderation;
97069706- type Repo = S::Repo;
97079707- type Uri = S::Uri;
97089708- type BlobCids = S::BlobCids;
97099709- type IndexedAt = S::IndexedAt;
97109710- type Value = S::Value;
97119711- }
97129712- ///State transition - sets the `moderation` field to Set
97139713- pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
97149714- impl<S: State> sealed::Sealed for SetModeration<S> {}
97159715- impl<S: State> State for SetModeration<S> {
97169716- type Cid = S::Cid;
97179717- type Moderation = Set<members::moderation>;
97189718- type Repo = S::Repo;
97199719- type Uri = S::Uri;
97209720- type BlobCids = S::BlobCids;
97219721- type IndexedAt = S::IndexedAt;
97229722- type Value = S::Value;
97239723- }
97249700 ///State transition - sets the `repo` field to Set
97259701 pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
97269702 impl<S: State> sealed::Sealed for SetRepo<S> {}
97279703 impl<S: State> State for SetRepo<S> {
97289728- type Cid = S::Cid;
97299729- type Moderation = S::Moderation;
97309704 type Repo = Set<members::repo>;
97319705 type Uri = S::Uri;
97069706+ type Moderation = S::Moderation;
97079707+ type IndexedAt = S::IndexedAt;
97089708+ type Cid = S::Cid;
97329709 type BlobCids = S::BlobCids;
97339733- type IndexedAt = S::IndexedAt;
97349710 type Value = S::Value;
97359711 }
97369712 ///State transition - sets the `uri` field to Set
97379713 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
97389714 impl<S: State> sealed::Sealed for SetUri<S> {}
97399715 impl<S: State> State for SetUri<S> {
97409740- type Cid = S::Cid;
97419741- type Moderation = S::Moderation;
97429716 type Repo = S::Repo;
97439717 type Uri = Set<members::uri>;
97449744- type BlobCids = S::BlobCids;
97189718+ type Moderation = S::Moderation;
97459719 type IndexedAt = S::IndexedAt;
97209720+ type Cid = S::Cid;
97219721+ type BlobCids = S::BlobCids;
97469722 type Value = S::Value;
97479723 }
97489748- ///State transition - sets the `blob_cids` field to Set
97499749- pub struct SetBlobCids<S: State = Empty>(PhantomData<fn() -> S>);
97509750- impl<S: State> sealed::Sealed for SetBlobCids<S> {}
97519751- impl<S: State> State for SetBlobCids<S> {
97529752- type Cid = S::Cid;
97539753- type Moderation = S::Moderation;
97249724+ ///State transition - sets the `moderation` field to Set
97259725+ pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
97269726+ impl<S: State> sealed::Sealed for SetModeration<S> {}
97279727+ impl<S: State> State for SetModeration<S> {
97549728 type Repo = S::Repo;
97559729 type Uri = S::Uri;
97569756- type BlobCids = Set<members::blob_cids>;
97309730+ type Moderation = Set<members::moderation>;
97579731 type IndexedAt = S::IndexedAt;
97329732+ type Cid = S::Cid;
97339733+ type BlobCids = S::BlobCids;
97589734 type Value = S::Value;
97599735 }
97609736 ///State transition - sets the `indexed_at` field to Set
97619737 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
97629738 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
97639739 impl<S: State> State for SetIndexedAt<S> {
97409740+ type Repo = S::Repo;
97419741+ type Uri = S::Uri;
97429742+ type Moderation = S::Moderation;
97439743+ type IndexedAt = Set<members::indexed_at>;
97649744 type Cid = S::Cid;
97459745+ type BlobCids = S::BlobCids;
97469746+ type Value = S::Value;
97479747+ }
97489748+ ///State transition - sets the `cid` field to Set
97499749+ pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
97509750+ impl<S: State> sealed::Sealed for SetCid<S> {}
97519751+ impl<S: State> State for SetCid<S> {
97529752+ type Repo = S::Repo;
97539753+ type Uri = S::Uri;
97659754 type Moderation = S::Moderation;
97559755+ type IndexedAt = S::IndexedAt;
97569756+ type Cid = Set<members::cid>;
97579757+ type BlobCids = S::BlobCids;
97589758+ type Value = S::Value;
97599759+ }
97609760+ ///State transition - sets the `blob_cids` field to Set
97619761+ pub struct SetBlobCids<S: State = Empty>(PhantomData<fn() -> S>);
97629762+ impl<S: State> sealed::Sealed for SetBlobCids<S> {}
97639763+ impl<S: State> State for SetBlobCids<S> {
97669764 type Repo = S::Repo;
97679765 type Uri = S::Uri;
97689768- type BlobCids = S::BlobCids;
97699769- type IndexedAt = Set<members::indexed_at>;
97669766+ type Moderation = S::Moderation;
97679767+ type IndexedAt = S::IndexedAt;
97689768+ type Cid = S::Cid;
97699769+ type BlobCids = Set<members::blob_cids>;
97709770 type Value = S::Value;
97719771 }
97729772 ///State transition - sets the `value` field to Set
97739773 pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
97749774 impl<S: State> sealed::Sealed for SetValue<S> {}
97759775 impl<S: State> State for SetValue<S> {
97769776- type Cid = S::Cid;
97779777- type Moderation = S::Moderation;
97789776 type Repo = S::Repo;
97799777 type Uri = S::Uri;
97789778+ type Moderation = S::Moderation;
97799779+ type IndexedAt = S::IndexedAt;
97809780+ type Cid = S::Cid;
97809781 type BlobCids = S::BlobCids;
97819781- type IndexedAt = S::IndexedAt;
97829782 type Value = Set<members::value>;
97839783 }
97849784 /// Marker types for field names
97859785 #[allow(non_camel_case_types)]
97869786 pub mod members {
97879787- ///Marker type for the `cid` field
97889788- pub struct cid(());
97899789- ///Marker type for the `moderation` field
97909790- pub struct moderation(());
97919787 ///Marker type for the `repo` field
97929788 pub struct repo(());
97939789 ///Marker type for the `uri` field
97949790 pub struct uri(());
97919791+ ///Marker type for the `moderation` field
97929792+ pub struct moderation(());
97939793+ ///Marker type for the `indexed_at` field
97949794+ pub struct indexed_at(());
97959795+ ///Marker type for the `cid` field
97969796+ pub struct cid(());
97959797 ///Marker type for the `blob_cids` field
97969798 pub struct blob_cids(());
97979797- ///Marker type for the `indexed_at` field
97989798- pub struct indexed_at(());
97999799 ///Marker type for the `value` field
98009800 pub struct value(());
98019801 }
···99709970impl<'a, S> RecordViewBuilder<'a, S>
99719971where
99729972 S: record_view_state::State,
99739973- S::Cid: record_view_state::IsSet,
99749974- S::Moderation: record_view_state::IsSet,
99759973 S::Repo: record_view_state::IsSet,
99769974 S::Uri: record_view_state::IsSet,
99779977- S::BlobCids: record_view_state::IsSet,
99759975+ S::Moderation: record_view_state::IsSet,
99789976 S::IndexedAt: record_view_state::IsSet,
99779977+ S::Cid: record_view_state::IsSet,
99789978+ S::BlobCids: record_view_state::IsSet,
99799979 S::Value: record_view_state::IsSet,
99809980{
99819981 /// Build the final struct
···1006910069 }
1007010070 /// State trait tracking which required fields have been set
1007110071 pub trait State: sealed::Sealed {
1007210072- type Value;
1007310073- type Repo;
1007410072 type Blobs;
1007510075- type Uri;
1007610076- type Cid;
1007710073 type IndexedAt;
1007410074+ type Repo;
1007510075+ type Value;
1007810076 type Moderation;
1007710077+ type Uri;
1007810078+ type Cid;
1007910079 }
1008010080 /// Empty state - all required fields are unset
1008110081 pub struct Empty(());
1008210082 impl sealed::Sealed for Empty {}
1008310083 impl State for Empty {
1008410084- type Value = Unset;
1008510085- type Repo = Unset;
1008610084 type Blobs = Unset;
1008710087- type Uri = Unset;
1008810088- type Cid = Unset;
1008910085 type IndexedAt = Unset;
1008610086+ type Repo = Unset;
1008710087+ type Value = Unset;
1009010088 type Moderation = Unset;
1008910089+ type Uri = Unset;
1009010090+ type Cid = Unset;
1009110091 }
1009210092- ///State transition - sets the `value` field to Set
1009310093- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
1009410094- impl<S: State> sealed::Sealed for SetValue<S> {}
1009510095- impl<S: State> State for SetValue<S> {
1009610096- type Value = Set<members::value>;
1009210092+ ///State transition - sets the `blobs` field to Set
1009310093+ pub struct SetBlobs<S: State = Empty>(PhantomData<fn() -> S>);
1009410094+ impl<S: State> sealed::Sealed for SetBlobs<S> {}
1009510095+ impl<S: State> State for SetBlobs<S> {
1009610096+ type Blobs = Set<members::blobs>;
1009710097+ type IndexedAt = S::IndexedAt;
1009710098 type Repo = S::Repo;
1009910099+ type Value = S::Value;
1010010100+ type Moderation = S::Moderation;
1010110101+ type Uri = S::Uri;
1010210102+ type Cid = S::Cid;
1010310103+ }
1010410104+ ///State transition - sets the `indexed_at` field to Set
1010510105+ pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
1010610106+ impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
1010710107+ impl<S: State> State for SetIndexedAt<S> {
1009810108 type Blobs = S::Blobs;
1010910109+ type IndexedAt = Set<members::indexed_at>;
1011010110+ type Repo = S::Repo;
1011110111+ type Value = S::Value;
1011210112+ type Moderation = S::Moderation;
1009910113 type Uri = S::Uri;
1010010114 type Cid = S::Cid;
1010110101- type IndexedAt = S::IndexedAt;
1010210102- type Moderation = S::Moderation;
1010310115 }
1010410116 ///State transition - sets the `repo` field to Set
1010510117 pub struct SetRepo<S: State = Empty>(PhantomData<fn() -> S>);
1010610118 impl<S: State> sealed::Sealed for SetRepo<S> {}
1010710119 impl<S: State> State for SetRepo<S> {
1012010120+ type Blobs = S::Blobs;
1012110121+ type IndexedAt = S::IndexedAt;
1012210122+ type Repo = Set<members::repo>;
1010810123 type Value = S::Value;
1010910109- type Repo = Set<members::repo>;
1011010110- type Blobs = S::Blobs;
1012410124+ type Moderation = S::Moderation;
1011110125 type Uri = S::Uri;
1011210126 type Cid = S::Cid;
1012710127+ }
1012810128+ ///State transition - sets the `value` field to Set
1012910129+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
1013010130+ impl<S: State> sealed::Sealed for SetValue<S> {}
1013110131+ impl<S: State> State for SetValue<S> {
1013210132+ type Blobs = S::Blobs;
1011310133 type IndexedAt = S::IndexedAt;
1013410134+ type Repo = S::Repo;
1013510135+ type Value = Set<members::value>;
1011410136 type Moderation = S::Moderation;
1013710137+ type Uri = S::Uri;
1013810138+ type Cid = S::Cid;
1011510139 }
1011610116- ///State transition - sets the `blobs` field to Set
1011710117- pub struct SetBlobs<S: State = Empty>(PhantomData<fn() -> S>);
1011810118- impl<S: State> sealed::Sealed for SetBlobs<S> {}
1011910119- impl<S: State> State for SetBlobs<S> {
1014010140+ ///State transition - sets the `moderation` field to Set
1014110141+ pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
1014210142+ impl<S: State> sealed::Sealed for SetModeration<S> {}
1014310143+ impl<S: State> State for SetModeration<S> {
1014410144+ type Blobs = S::Blobs;
1014510145+ type IndexedAt = S::IndexedAt;
1014610146+ type Repo = S::Repo;
1012010147 type Value = S::Value;
1012110121- type Repo = S::Repo;
1012210122- type Blobs = Set<members::blobs>;
1014810148+ type Moderation = Set<members::moderation>;
1012310149 type Uri = S::Uri;
1012410150 type Cid = S::Cid;
1012510125- type IndexedAt = S::IndexedAt;
1012610126- type Moderation = S::Moderation;
1012710151 }
1012810152 ///State transition - sets the `uri` field to Set
1012910153 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
1013010154 impl<S: State> sealed::Sealed for SetUri<S> {}
1013110155 impl<S: State> State for SetUri<S> {
1013210132- type Value = S::Value;
1013310133- type Repo = S::Repo;
1013410156 type Blobs = S::Blobs;
1013510135- type Uri = Set<members::uri>;
1013610136- type Cid = S::Cid;
1013710157 type IndexedAt = S::IndexedAt;
1015810158+ type Repo = S::Repo;
1015910159+ type Value = S::Value;
1013810160 type Moderation = S::Moderation;
1016110161+ type Uri = Set<members::uri>;
1016210162+ type Cid = S::Cid;
1013910163 }
1014010164 ///State transition - sets the `cid` field to Set
1014110165 pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
1014210166 impl<S: State> sealed::Sealed for SetCid<S> {}
1014310167 impl<S: State> State for SetCid<S> {
1014410144- type Value = S::Value;
1014510145- type Repo = S::Repo;
1014610168 type Blobs = S::Blobs;
1014710147- type Uri = S::Uri;
1014810148- type Cid = Set<members::cid>;
1014910169 type IndexedAt = S::IndexedAt;
1015010150- type Moderation = S::Moderation;
1015110151- }
1015210152- ///State transition - sets the `indexed_at` field to Set
1015310153- pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
1015410154- impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
1015510155- impl<S: State> State for SetIndexedAt<S> {
1015610156- type Value = S::Value;
1015710170 type Repo = S::Repo;
1015810158- type Blobs = S::Blobs;
1015910159- type Uri = S::Uri;
1016010160- type Cid = S::Cid;
1016110161- type IndexedAt = Set<members::indexed_at>;
1016210162- type Moderation = S::Moderation;
1016310163- }
1016410164- ///State transition - sets the `moderation` field to Set
1016510165- pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
1016610166- impl<S: State> sealed::Sealed for SetModeration<S> {}
1016710167- impl<S: State> State for SetModeration<S> {
1016810171 type Value = S::Value;
1016910169- type Repo = S::Repo;
1017010170- type Blobs = S::Blobs;
1017210172+ type Moderation = S::Moderation;
1017110173 type Uri = S::Uri;
1017210172- type Cid = S::Cid;
1017310173- type IndexedAt = S::IndexedAt;
1017410174- type Moderation = Set<members::moderation>;
1017410174+ type Cid = Set<members::cid>;
1017510175 }
1017610176 /// Marker types for field names
1017710177 #[allow(non_camel_case_types)]
1017810178 pub mod members {
1017910179+ ///Marker type for the `blobs` field
1018010180+ pub struct blobs(());
1018110181+ ///Marker type for the `indexed_at` field
1018210182+ pub struct indexed_at(());
1018310183+ ///Marker type for the `repo` field
1018410184+ pub struct repo(());
1017910185 ///Marker type for the `value` field
1018010186 pub struct value(());
1018110181- ///Marker type for the `repo` field
1018210182- pub struct repo(());
1018310183- ///Marker type for the `blobs` field
1018410184- pub struct blobs(());
1018710187+ ///Marker type for the `moderation` field
1018810188+ pub struct moderation(());
1018510189 ///Marker type for the `uri` field
1018610190 pub struct uri(());
1018710191 ///Marker type for the `cid` field
1018810192 pub struct cid(());
1018910189- ///Marker type for the `indexed_at` field
1019010190- pub struct indexed_at(());
1019110191- ///Marker type for the `moderation` field
1019210192- pub struct moderation(());
1019310193 }
1019410194}
1019510195···1038210382impl<'a, S> RecordViewDetailBuilder<'a, S>
1038310383where
1038410384 S: record_view_detail_state::State,
1038510385- S::Value: record_view_detail_state::IsSet,
1038610386- S::Repo: record_view_detail_state::IsSet,
1038710385 S::Blobs: record_view_detail_state::IsSet,
1038810388- S::Uri: record_view_detail_state::IsSet,
1038910389- S::Cid: record_view_detail_state::IsSet,
1039010386 S::IndexedAt: record_view_detail_state::IsSet,
1038710387+ S::Repo: record_view_detail_state::IsSet,
1038810388+ S::Value: record_view_detail_state::IsSet,
1039110389 S::Moderation: record_view_detail_state::IsSet,
1039010390+ S::Uri: record_view_detail_state::IsSet,
1039110391+ S::Cid: record_view_detail_state::IsSet,
1039210392{
1039310393 /// Build the final struct
1039410394 pub fn build(self) -> RecordViewDetail<'a> {
···1068910689 }
1069010690 /// State trait tracking which required fields have been set
1069110691 pub trait State: sealed::Sealed {
1069210692+ type RelatedRecords;
1069210693 type Handle;
1069310693- type Did;
1069410694 type IndexedAt;
1069510695 type Moderation;
1069610696- type RelatedRecords;
1069610696+ type Did;
1069710697 }
1069810698 /// Empty state - all required fields are unset
1069910699 pub struct Empty(());
1070010700 impl sealed::Sealed for Empty {}
1070110701 impl State for Empty {
1070210702+ type RelatedRecords = Unset;
1070210703 type Handle = Unset;
1070310703- type Did = Unset;
1070410704 type IndexedAt = Unset;
1070510705 type Moderation = Unset;
1070610706- type RelatedRecords = Unset;
1070610706+ type Did = Unset;
1070710707+ }
1070810708+ ///State transition - sets the `related_records` field to Set
1070910709+ pub struct SetRelatedRecords<S: State = Empty>(PhantomData<fn() -> S>);
1071010710+ impl<S: State> sealed::Sealed for SetRelatedRecords<S> {}
1071110711+ impl<S: State> State for SetRelatedRecords<S> {
1071210712+ type RelatedRecords = Set<members::related_records>;
1071310713+ type Handle = S::Handle;
1071410714+ type IndexedAt = S::IndexedAt;
1071510715+ type Moderation = S::Moderation;
1071610716+ type Did = S::Did;
1070710717 }
1070810718 ///State transition - sets the `handle` field to Set
1070910719 pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
1071010720 impl<S: State> sealed::Sealed for SetHandle<S> {}
1071110721 impl<S: State> State for SetHandle<S> {
1072210722+ type RelatedRecords = S::RelatedRecords;
1071210723 type Handle = Set<members::handle>;
1071310713- type Did = S::Did;
1071410724 type IndexedAt = S::IndexedAt;
1071510725 type Moderation = S::Moderation;
1071610716- type RelatedRecords = S::RelatedRecords;
1071710717- }
1071810718- ///State transition - sets the `did` field to Set
1071910719- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1072010720- impl<S: State> sealed::Sealed for SetDid<S> {}
1072110721- impl<S: State> State for SetDid<S> {
1072210722- type Handle = S::Handle;
1072310723- type Did = Set<members::did>;
1072410724- type IndexedAt = S::IndexedAt;
1072510725- type Moderation = S::Moderation;
1072610726- type RelatedRecords = S::RelatedRecords;
1072610726+ type Did = S::Did;
1072710727 }
1072810728 ///State transition - sets the `indexed_at` field to Set
1072910729 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
1073010730 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
1073110731 impl<S: State> State for SetIndexedAt<S> {
1073210732+ type RelatedRecords = S::RelatedRecords;
1073210733 type Handle = S::Handle;
1073310733- type Did = S::Did;
1073410734 type IndexedAt = Set<members::indexed_at>;
1073510735 type Moderation = S::Moderation;
1073610736- type RelatedRecords = S::RelatedRecords;
1073610736+ type Did = S::Did;
1073710737 }
1073810738 ///State transition - sets the `moderation` field to Set
1073910739 pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
1074010740 impl<S: State> sealed::Sealed for SetModeration<S> {}
1074110741 impl<S: State> State for SetModeration<S> {
1074210742+ type RelatedRecords = S::RelatedRecords;
1074210743 type Handle = S::Handle;
1074310743- type Did = S::Did;
1074410744 type IndexedAt = S::IndexedAt;
1074510745 type Moderation = Set<members::moderation>;
1074610746+ type Did = S::Did;
1074710747+ }
1074810748+ ///State transition - sets the `did` field to Set
1074910749+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1075010750+ impl<S: State> sealed::Sealed for SetDid<S> {}
1075110751+ impl<S: State> State for SetDid<S> {
1074610752 type RelatedRecords = S::RelatedRecords;
1074710747- }
1074810748- ///State transition - sets the `related_records` field to Set
1074910749- pub struct SetRelatedRecords<S: State = Empty>(PhantomData<fn() -> S>);
1075010750- impl<S: State> sealed::Sealed for SetRelatedRecords<S> {}
1075110751- impl<S: State> State for SetRelatedRecords<S> {
1075210753 type Handle = S::Handle;
1075310753- type Did = S::Did;
1075410754 type IndexedAt = S::IndexedAt;
1075510755 type Moderation = S::Moderation;
1075610756- type RelatedRecords = Set<members::related_records>;
1075610756+ type Did = Set<members::did>;
1075710757 }
1075810758 /// Marker types for field names
1075910759 #[allow(non_camel_case_types)]
1076010760 pub mod members {
1076110761+ ///Marker type for the `related_records` field
1076210762+ pub struct related_records(());
1076110763 ///Marker type for the `handle` field
1076210764 pub struct handle(());
1076310763- ///Marker type for the `did` field
1076410764- pub struct did(());
1076510765 ///Marker type for the `indexed_at` field
1076610766 pub struct indexed_at(());
1076710767 ///Marker type for the `moderation` field
1076810768 pub struct moderation(());
1076910769- ///Marker type for the `related_records` field
1077010770- pub struct related_records(());
1076910769+ ///Marker type for the `did` field
1077010770+ pub struct did(());
1077110771 }
1077210772}
1077310773···1102311023impl<'a, S> RepoViewBuilder<'a, S>
1102411024where
1102511025 S: repo_view_state::State,
1102611026+ S::RelatedRecords: repo_view_state::IsSet,
1102611027 S::Handle: repo_view_state::IsSet,
1102711027- S::Did: repo_view_state::IsSet,
1102811028 S::IndexedAt: repo_view_state::IsSet,
1102911029 S::Moderation: repo_view_state::IsSet,
1103011030- S::RelatedRecords: repo_view_state::IsSet,
1103011030+ S::Did: repo_view_state::IsSet,
1103111031{
1103211032 /// Build the final struct
1103311033 pub fn build(self) -> RepoView<'a> {
···1114911149 }
1115011150 /// State trait tracking which required fields have been set
1115111151 pub trait State: sealed::Sealed {
1115211152- type RelatedRecords;
1115311152 type IndexedAt;
1115411154- type Handle;
1115511155- type Did;
1115311153+ type RelatedRecords;
1115611154 type Moderation;
1115511155+ type Did;
1115611156+ type Handle;
1115711157 }
1115811158 /// Empty state - all required fields are unset
1115911159 pub struct Empty(());
1116011160 impl sealed::Sealed for Empty {}
1116111161 impl State for Empty {
1116211162- type RelatedRecords = Unset;
1116311162 type IndexedAt = Unset;
1116411164- type Handle = Unset;
1116511165- type Did = Unset;
1116311163+ type RelatedRecords = Unset;
1116611164 type Moderation = Unset;
1116711167- }
1116811168- ///State transition - sets the `related_records` field to Set
1116911169- pub struct SetRelatedRecords<S: State = Empty>(PhantomData<fn() -> S>);
1117011170- impl<S: State> sealed::Sealed for SetRelatedRecords<S> {}
1117111171- impl<S: State> State for SetRelatedRecords<S> {
1117211172- type RelatedRecords = Set<members::related_records>;
1117311173- type IndexedAt = S::IndexedAt;
1117411174- type Handle = S::Handle;
1117511175- type Did = S::Did;
1117611176- type Moderation = S::Moderation;
1116511165+ type Did = Unset;
1116611166+ type Handle = Unset;
1117711167 }
1117811168 ///State transition - sets the `indexed_at` field to Set
1117911169 pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
1118011170 impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
1118111171 impl<S: State> State for SetIndexedAt<S> {
1118211182- type RelatedRecords = S::RelatedRecords;
1118311172 type IndexedAt = Set<members::indexed_at>;
1118411184- type Handle = S::Handle;
1117311173+ type RelatedRecords = S::RelatedRecords;
1117411174+ type Moderation = S::Moderation;
1118511175 type Did = S::Did;
1117611176+ type Handle = S::Handle;
1117711177+ }
1117811178+ ///State transition - sets the `related_records` field to Set
1117911179+ pub struct SetRelatedRecords<S: State = Empty>(PhantomData<fn() -> S>);
1118011180+ impl<S: State> sealed::Sealed for SetRelatedRecords<S> {}
1118111181+ impl<S: State> State for SetRelatedRecords<S> {
1118211182+ type IndexedAt = S::IndexedAt;
1118311183+ type RelatedRecords = Set<members::related_records>;
1118611184 type Moderation = S::Moderation;
1118511185+ type Did = S::Did;
1118611186+ type Handle = S::Handle;
1118711187 }
1118811188- ///State transition - sets the `handle` field to Set
1118911189- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
1119011190- impl<S: State> sealed::Sealed for SetHandle<S> {}
1119111191- impl<S: State> State for SetHandle<S> {
1119211192- type RelatedRecords = S::RelatedRecords;
1118811188+ ///State transition - sets the `moderation` field to Set
1118911189+ pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
1119011190+ impl<S: State> sealed::Sealed for SetModeration<S> {}
1119111191+ impl<S: State> State for SetModeration<S> {
1119311192 type IndexedAt = S::IndexedAt;
1119411194- type Handle = Set<members::handle>;
1119311193+ type RelatedRecords = S::RelatedRecords;
1119411194+ type Moderation = Set<members::moderation>;
1119511195 type Did = S::Did;
1119611196- type Moderation = S::Moderation;
1119611196+ type Handle = S::Handle;
1119711197 }
1119811198 ///State transition - sets the `did` field to Set
1119911199 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1120011200 impl<S: State> sealed::Sealed for SetDid<S> {}
1120111201 impl<S: State> State for SetDid<S> {
1120211202+ type IndexedAt = S::IndexedAt;
1120211203 type RelatedRecords = S::RelatedRecords;
1120311203- type IndexedAt = S::IndexedAt;
1120411204+ type Moderation = S::Moderation;
1120511205+ type Did = Set<members::did>;
1120411206 type Handle = S::Handle;
1120511205- type Did = Set<members::did>;
1120611206- type Moderation = S::Moderation;
1120711207 }
1120811208- ///State transition - sets the `moderation` field to Set
1120911209- pub struct SetModeration<S: State = Empty>(PhantomData<fn() -> S>);
1121011210- impl<S: State> sealed::Sealed for SetModeration<S> {}
1121111211- impl<S: State> State for SetModeration<S> {
1121211212- type RelatedRecords = S::RelatedRecords;
1120811208+ ///State transition - sets the `handle` field to Set
1120911209+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
1121011210+ impl<S: State> sealed::Sealed for SetHandle<S> {}
1121111211+ impl<S: State> State for SetHandle<S> {
1121311212 type IndexedAt = S::IndexedAt;
1121411214- type Handle = S::Handle;
1121311213+ type RelatedRecords = S::RelatedRecords;
1121411214+ type Moderation = S::Moderation;
1121511215 type Did = S::Did;
1121611216- type Moderation = Set<members::moderation>;
1121611216+ type Handle = Set<members::handle>;
1121711217 }
1121811218 /// Marker types for field names
1121911219 #[allow(non_camel_case_types)]
1122011220 pub mod members {
1122111221+ ///Marker type for the `indexed_at` field
1122211222+ pub struct indexed_at(());
1122111223 ///Marker type for the `related_records` field
1122211224 pub struct related_records(());
1122311223- ///Marker type for the `indexed_at` field
1122411224- pub struct indexed_at(());
1122511225- ///Marker type for the `handle` field
1122611226- pub struct handle(());
1122511225+ ///Marker type for the `moderation` field
1122611226+ pub struct moderation(());
1122711227 ///Marker type for the `did` field
1122811228 pub struct did(());
1122911229- ///Marker type for the `moderation` field
1123011230- pub struct moderation(());
1122911229+ ///Marker type for the `handle` field
1123011230+ pub struct handle(());
1123111231 }
1123211232}
1123311233···1154611546impl<'a, S> RepoViewDetailBuilder<'a, S>
1154711547where
1154811548 S: repo_view_detail_state::State,
1154911549+ S::IndexedAt: repo_view_detail_state::IsSet,
1154911550 S::RelatedRecords: repo_view_detail_state::IsSet,
1155011550- S::IndexedAt: repo_view_detail_state::IsSet,
1155111551+ S::Moderation: repo_view_detail_state::IsSet,
1155211552+ S::Did: repo_view_detail_state::IsSet,
1155111553 S::Handle: repo_view_detail_state::IsSet,
1155211552- S::Did: repo_view_detail_state::IsSet,
1155311553- S::Moderation: repo_view_detail_state::IsSet,
1155411554{
1155511555 /// Build the final struct
1155611556 pub fn build(self) -> RepoViewDetail<'a> {
···1179711797 }
1179811798 /// State trait tracking which required fields have been set
1179911799 pub trait State: sealed::Sealed {
1180011800- type ReportedRecordCount;
1180011800+ type Did;
1180111801+ type LabeledRecordCount;
1180211802+ type ReportedAccountCount;
1180111803 type RecordReportCount;
1180411804+ type ReportedRecordCount;
1180511805+ type LabeledAccountCount;
1180611806+ type AccountReportCount;
1180211807 type TakendownRecordCount;
1180311808 type TakendownAccountCount;
1180411804- type ReportedAccountCount;
1180511805- type LabeledRecordCount;
1180611806- type Did;
1180711807- type LabeledAccountCount;
1180811808- type AccountReportCount;
1180911809 }
1181011810 /// Empty state - all required fields are unset
1181111811 pub struct Empty(());
1181211812 impl sealed::Sealed for Empty {}
1181311813 impl State for Empty {
1181411814- type ReportedRecordCount = Unset;
1181411814+ type Did = Unset;
1181511815+ type LabeledRecordCount = Unset;
1181611816+ type ReportedAccountCount = Unset;
1181511817 type RecordReportCount = Unset;
1181811818+ type ReportedRecordCount = Unset;
1181911819+ type LabeledAccountCount = Unset;
1182011820+ type AccountReportCount = Unset;
1181611821 type TakendownRecordCount = Unset;
1181711822 type TakendownAccountCount = Unset;
1181811818- type ReportedAccountCount = Unset;
1181911819- type LabeledRecordCount = Unset;
1182011820- type Did = Unset;
1182111821- type LabeledAccountCount = Unset;
1182211822- type AccountReportCount = Unset;
1182311823 }
1182411824- ///State transition - sets the `reported_record_count` field to Set
1182511825- pub struct SetReportedRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1182611826- impl<S: State> sealed::Sealed for SetReportedRecordCount<S> {}
1182711827- impl<S: State> State for SetReportedRecordCount<S> {
1182811828- type ReportedRecordCount = Set<members::reported_record_count>;
1182911829- type RecordReportCount = S::RecordReportCount;
1183011830- type TakendownRecordCount = S::TakendownRecordCount;
1183111831- type TakendownAccountCount = S::TakendownAccountCount;
1183211832- type ReportedAccountCount = S::ReportedAccountCount;
1182411824+ ///State transition - sets the `did` field to Set
1182511825+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1182611826+ impl<S: State> sealed::Sealed for SetDid<S> {}
1182711827+ impl<S: State> State for SetDid<S> {
1182811828+ type Did = Set<members::did>;
1183311829 type LabeledRecordCount = S::LabeledRecordCount;
1183411834- type Did = S::Did;
1183011830+ type ReportedAccountCount = S::ReportedAccountCount;
1183111831+ type RecordReportCount = S::RecordReportCount;
1183211832+ type ReportedRecordCount = S::ReportedRecordCount;
1183511833 type LabeledAccountCount = S::LabeledAccountCount;
1183611834 type AccountReportCount = S::AccountReportCount;
1183711837- }
1183811838- ///State transition - sets the `record_report_count` field to Set
1183911839- pub struct SetRecordReportCount<S: State = Empty>(PhantomData<fn() -> S>);
1184011840- impl<S: State> sealed::Sealed for SetRecordReportCount<S> {}
1184111841- impl<S: State> State for SetRecordReportCount<S> {
1184211842- type ReportedRecordCount = S::ReportedRecordCount;
1184311843- type RecordReportCount = Set<members::record_report_count>;
1184411835 type TakendownRecordCount = S::TakendownRecordCount;
1184511836 type TakendownAccountCount = S::TakendownAccountCount;
1183711837+ }
1183811838+ ///State transition - sets the `labeled_record_count` field to Set
1183911839+ pub struct SetLabeledRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1184011840+ impl<S: State> sealed::Sealed for SetLabeledRecordCount<S> {}
1184111841+ impl<S: State> State for SetLabeledRecordCount<S> {
1184211842+ type Did = S::Did;
1184311843+ type LabeledRecordCount = Set<members::labeled_record_count>;
1184611844 type ReportedAccountCount = S::ReportedAccountCount;
1184711847- type LabeledRecordCount = S::LabeledRecordCount;
1184811848- type Did = S::Did;
1184911849- type LabeledAccountCount = S::LabeledAccountCount;
1185011850- type AccountReportCount = S::AccountReportCount;
1185111851- }
1185211852- ///State transition - sets the `takendown_record_count` field to Set
1185311853- pub struct SetTakendownRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1185411854- impl<S: State> sealed::Sealed for SetTakendownRecordCount<S> {}
1185511855- impl<S: State> State for SetTakendownRecordCount<S> {
1184511845+ type RecordReportCount = S::RecordReportCount;
1185611846 type ReportedRecordCount = S::ReportedRecordCount;
1185711857- type RecordReportCount = S::RecordReportCount;
1185811858- type TakendownRecordCount = Set<members::takendown_record_count>;
1185911859- type TakendownAccountCount = S::TakendownAccountCount;
1186011860- type ReportedAccountCount = S::ReportedAccountCount;
1186111861- type LabeledRecordCount = S::LabeledRecordCount;
1186211862- type Did = S::Did;
1186311847 type LabeledAccountCount = S::LabeledAccountCount;
1186411848 type AccountReportCount = S::AccountReportCount;
1186511865- }
1186611866- ///State transition - sets the `takendown_account_count` field to Set
1186711867- pub struct SetTakendownAccountCount<S: State = Empty>(PhantomData<fn() -> S>);
1186811868- impl<S: State> sealed::Sealed for SetTakendownAccountCount<S> {}
1186911869- impl<S: State> State for SetTakendownAccountCount<S> {
1187011870- type ReportedRecordCount = S::ReportedRecordCount;
1187111871- type RecordReportCount = S::RecordReportCount;
1187211849 type TakendownRecordCount = S::TakendownRecordCount;
1187311873- type TakendownAccountCount = Set<members::takendown_account_count>;
1187411874- type ReportedAccountCount = S::ReportedAccountCount;
1187511875- type LabeledRecordCount = S::LabeledRecordCount;
1187611876- type Did = S::Did;
1187711877- type LabeledAccountCount = S::LabeledAccountCount;
1187811878- type AccountReportCount = S::AccountReportCount;
1185011850+ type TakendownAccountCount = S::TakendownAccountCount;
1187911851 }
1188011852 ///State transition - sets the `reported_account_count` field to Set
1188111853 pub struct SetReportedAccountCount<S: State = Empty>(PhantomData<fn() -> S>);
1188211854 impl<S: State> sealed::Sealed for SetReportedAccountCount<S> {}
1188311855 impl<S: State> State for SetReportedAccountCount<S> {
1185611856+ type Did = S::Did;
1185711857+ type LabeledRecordCount = S::LabeledRecordCount;
1185811858+ type ReportedAccountCount = Set<members::reported_account_count>;
1185911859+ type RecordReportCount = S::RecordReportCount;
1188411860 type ReportedRecordCount = S::ReportedRecordCount;
1188511885- type RecordReportCount = S::RecordReportCount;
1186111861+ type LabeledAccountCount = S::LabeledAccountCount;
1186211862+ type AccountReportCount = S::AccountReportCount;
1188611863 type TakendownRecordCount = S::TakendownRecordCount;
1188711864 type TakendownAccountCount = S::TakendownAccountCount;
1188811888- type ReportedAccountCount = Set<members::reported_account_count>;
1188911889- type LabeledRecordCount = S::LabeledRecordCount;
1186511865+ }
1186611866+ ///State transition - sets the `record_report_count` field to Set
1186711867+ pub struct SetRecordReportCount<S: State = Empty>(PhantomData<fn() -> S>);
1186811868+ impl<S: State> sealed::Sealed for SetRecordReportCount<S> {}
1186911869+ impl<S: State> State for SetRecordReportCount<S> {
1189011870 type Did = S::Did;
1187111871+ type LabeledRecordCount = S::LabeledRecordCount;
1187211872+ type ReportedAccountCount = S::ReportedAccountCount;
1187311873+ type RecordReportCount = Set<members::record_report_count>;
1187411874+ type ReportedRecordCount = S::ReportedRecordCount;
1189111875 type LabeledAccountCount = S::LabeledAccountCount;
1189211876 type AccountReportCount = S::AccountReportCount;
1189311893- }
1189411894- ///State transition - sets the `labeled_record_count` field to Set
1189511895- pub struct SetLabeledRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1189611896- impl<S: State> sealed::Sealed for SetLabeledRecordCount<S> {}
1189711897- impl<S: State> State for SetLabeledRecordCount<S> {
1189811898- type ReportedRecordCount = S::ReportedRecordCount;
1189911899- type RecordReportCount = S::RecordReportCount;
1190011877 type TakendownRecordCount = S::TakendownRecordCount;
1190111878 type TakendownAccountCount = S::TakendownAccountCount;
1190211902- type ReportedAccountCount = S::ReportedAccountCount;
1190311903- type LabeledRecordCount = Set<members::labeled_record_count>;
1187911879+ }
1188011880+ ///State transition - sets the `reported_record_count` field to Set
1188111881+ pub struct SetReportedRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1188211882+ impl<S: State> sealed::Sealed for SetReportedRecordCount<S> {}
1188311883+ impl<S: State> State for SetReportedRecordCount<S> {
1190411884 type Did = S::Did;
1188511885+ type LabeledRecordCount = S::LabeledRecordCount;
1188611886+ type ReportedAccountCount = S::ReportedAccountCount;
1188711887+ type RecordReportCount = S::RecordReportCount;
1188811888+ type ReportedRecordCount = Set<members::reported_record_count>;
1190511889 type LabeledAccountCount = S::LabeledAccountCount;
1190611890 type AccountReportCount = S::AccountReportCount;
1190711907- }
1190811908- ///State transition - sets the `did` field to Set
1190911909- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1191011910- impl<S: State> sealed::Sealed for SetDid<S> {}
1191111911- impl<S: State> State for SetDid<S> {
1191211912- type ReportedRecordCount = S::ReportedRecordCount;
1191311913- type RecordReportCount = S::RecordReportCount;
1191411891 type TakendownRecordCount = S::TakendownRecordCount;
1191511892 type TakendownAccountCount = S::TakendownAccountCount;
1191611916- type ReportedAccountCount = S::ReportedAccountCount;
1191711917- type LabeledRecordCount = S::LabeledRecordCount;
1191811918- type Did = Set<members::did>;
1191911919- type LabeledAccountCount = S::LabeledAccountCount;
1192011920- type AccountReportCount = S::AccountReportCount;
1192111893 }
1192211894 ///State transition - sets the `labeled_account_count` field to Set
1192311895 pub struct SetLabeledAccountCount<S: State = Empty>(PhantomData<fn() -> S>);
1192411896 impl<S: State> sealed::Sealed for SetLabeledAccountCount<S> {}
1192511897 impl<S: State> State for SetLabeledAccountCount<S> {
1192611926- type ReportedRecordCount = S::ReportedRecordCount;
1189811898+ type Did = S::Did;
1189911899+ type LabeledRecordCount = S::LabeledRecordCount;
1190011900+ type ReportedAccountCount = S::ReportedAccountCount;
1192711901 type RecordReportCount = S::RecordReportCount;
1190211902+ type ReportedRecordCount = S::ReportedRecordCount;
1190311903+ type LabeledAccountCount = Set<members::labeled_account_count>;
1190411904+ type AccountReportCount = S::AccountReportCount;
1192811905 type TakendownRecordCount = S::TakendownRecordCount;
1192911906 type TakendownAccountCount = S::TakendownAccountCount;
1193011930- type ReportedAccountCount = S::ReportedAccountCount;
1193111931- type LabeledRecordCount = S::LabeledRecordCount;
1193211932- type Did = S::Did;
1193311933- type LabeledAccountCount = Set<members::labeled_account_count>;
1193411934- type AccountReportCount = S::AccountReportCount;
1193511907 }
1193611908 ///State transition - sets the `account_report_count` field to Set
1193711909 pub struct SetAccountReportCount<S: State = Empty>(PhantomData<fn() -> S>);
1193811910 impl<S: State> sealed::Sealed for SetAccountReportCount<S> {}
1193911911 impl<S: State> State for SetAccountReportCount<S> {
1194011940- type ReportedRecordCount = S::ReportedRecordCount;
1191211912+ type Did = S::Did;
1191311913+ type LabeledRecordCount = S::LabeledRecordCount;
1191411914+ type ReportedAccountCount = S::ReportedAccountCount;
1194111915 type RecordReportCount = S::RecordReportCount;
1191611916+ type ReportedRecordCount = S::ReportedRecordCount;
1191711917+ type LabeledAccountCount = S::LabeledAccountCount;
1191811918+ type AccountReportCount = Set<members::account_report_count>;
1194211919 type TakendownRecordCount = S::TakendownRecordCount;
1194311920 type TakendownAccountCount = S::TakendownAccountCount;
1192111921+ }
1192211922+ ///State transition - sets the `takendown_record_count` field to Set
1192311923+ pub struct SetTakendownRecordCount<S: State = Empty>(PhantomData<fn() -> S>);
1192411924+ impl<S: State> sealed::Sealed for SetTakendownRecordCount<S> {}
1192511925+ impl<S: State> State for SetTakendownRecordCount<S> {
1192611926+ type Did = S::Did;
1192711927+ type LabeledRecordCount = S::LabeledRecordCount;
1194411928 type ReportedAccountCount = S::ReportedAccountCount;
1194511945- type LabeledRecordCount = S::LabeledRecordCount;
1192911929+ type RecordReportCount = S::RecordReportCount;
1193011930+ type ReportedRecordCount = S::ReportedRecordCount;
1193111931+ type LabeledAccountCount = S::LabeledAccountCount;
1193211932+ type AccountReportCount = S::AccountReportCount;
1193311933+ type TakendownRecordCount = Set<members::takendown_record_count>;
1193411934+ type TakendownAccountCount = S::TakendownAccountCount;
1193511935+ }
1193611936+ ///State transition - sets the `takendown_account_count` field to Set
1193711937+ pub struct SetTakendownAccountCount<S: State = Empty>(PhantomData<fn() -> S>);
1193811938+ impl<S: State> sealed::Sealed for SetTakendownAccountCount<S> {}
1193911939+ impl<S: State> State for SetTakendownAccountCount<S> {
1194611940 type Did = S::Did;
1194111941+ type LabeledRecordCount = S::LabeledRecordCount;
1194211942+ type ReportedAccountCount = S::ReportedAccountCount;
1194311943+ type RecordReportCount = S::RecordReportCount;
1194411944+ type ReportedRecordCount = S::ReportedRecordCount;
1194711945 type LabeledAccountCount = S::LabeledAccountCount;
1194811948- type AccountReportCount = Set<members::account_report_count>;
1194611946+ type AccountReportCount = S::AccountReportCount;
1194711947+ type TakendownRecordCount = S::TakendownRecordCount;
1194811948+ type TakendownAccountCount = Set<members::takendown_account_count>;
1194911949 }
1195011950 /// Marker types for field names
1195111951 #[allow(non_camel_case_types)]
1195211952 pub mod members {
1195311953- ///Marker type for the `reported_record_count` field
1195411954- pub struct reported_record_count(());
1195511955- ///Marker type for the `record_report_count` field
1195611956- pub struct record_report_count(());
1195711957- ///Marker type for the `takendown_record_count` field
1195811958- pub struct takendown_record_count(());
1195911959- ///Marker type for the `takendown_account_count` field
1196011960- pub struct takendown_account_count(());
1196111961- ///Marker type for the `reported_account_count` field
1196211962- pub struct reported_account_count(());
1196311963- ///Marker type for the `labeled_record_count` field
1196411964- pub struct labeled_record_count(());
1196511953 ///Marker type for the `did` field
1196611954 pub struct did(());
1195511955+ ///Marker type for the `labeled_record_count` field
1195611956+ pub struct labeled_record_count(());
1195711957+ ///Marker type for the `reported_account_count` field
1195811958+ pub struct reported_account_count(());
1195911959+ ///Marker type for the `record_report_count` field
1196011960+ pub struct record_report_count(());
1196111961+ ///Marker type for the `reported_record_count` field
1196211962+ pub struct reported_record_count(());
1196711963 ///Marker type for the `labeled_account_count` field
1196811964 pub struct labeled_account_count(());
1196911965 ///Marker type for the `account_report_count` field
1197011966 pub struct account_report_count(());
1196711967+ ///Marker type for the `takendown_record_count` field
1196811968+ pub struct takendown_record_count(());
1196911969+ ///Marker type for the `takendown_account_count` field
1197011970+ pub struct takendown_account_count(());
1197111971 }
1197211972}
1197311973···1219012190impl<'a, S> ReporterStatsBuilder<'a, S>
1219112191where
1219212192 S: reporter_stats_state::State,
1219312193- S::ReportedRecordCount: reporter_stats_state::IsSet,
1219412194- S::RecordReportCount: reporter_stats_state::IsSet,
1219512195- S::TakendownRecordCount: reporter_stats_state::IsSet,
1219612196- S::TakendownAccountCount: reporter_stats_state::IsSet,
1219712197- S::ReportedAccountCount: reporter_stats_state::IsSet,
1219812198- S::LabeledRecordCount: reporter_stats_state::IsSet,
1219912193 S::Did: reporter_stats_state::IsSet,
1219412194+ S::LabeledRecordCount: reporter_stats_state::IsSet,
1219512195+ S::ReportedAccountCount: reporter_stats_state::IsSet,
1219612196+ S::RecordReportCount: reporter_stats_state::IsSet,
1219712197+ S::ReportedRecordCount: reporter_stats_state::IsSet,
1220012198 S::LabeledAccountCount: reporter_stats_state::IsSet,
1220112199 S::AccountReportCount: reporter_stats_state::IsSet,
1220012200+ S::TakendownRecordCount: reporter_stats_state::IsSet,
1220112201+ S::TakendownAccountCount: reporter_stats_state::IsSet,
1220212202{
1220312203 /// Build the final struct
1220412204 pub fn build(self) -> ReporterStats<'a> {
···1247612476 }
1247712477 /// State trait tracking which required fields have been set
1247812478 pub trait State: sealed::Sealed {
1247912479- type Id;
1247912479+ type CreatedBy;
1248012480 type CreatedAt;
1248112481 type Status;
1248212482+ type Id;
1248312483+ type Did;
1248212484 type Action;
1248312483- type Did;
1248412484- type CreatedBy;
1248512485 }
1248612486 /// Empty state - all required fields are unset
1248712487 pub struct Empty(());
1248812488 impl sealed::Sealed for Empty {}
1248912489 impl State for Empty {
1249012490- type Id = Unset;
1249012490+ type CreatedBy = Unset;
1249112491 type CreatedAt = Unset;
1249212492 type Status = Unset;
1249312493- type Action = Unset;
1249312493+ type Id = Unset;
1249412494 type Did = Unset;
1249512495- type CreatedBy = Unset;
1249512495+ type Action = Unset;
1249612496 }
1249712497- ///State transition - sets the `id` field to Set
1249812498- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
1249912499- impl<S: State> sealed::Sealed for SetId<S> {}
1250012500- impl<S: State> State for SetId<S> {
1250112501- type Id = Set<members::id>;
1249712497+ ///State transition - sets the `created_by` field to Set
1249812498+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
1249912499+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
1250012500+ impl<S: State> State for SetCreatedBy<S> {
1250112501+ type CreatedBy = Set<members::created_by>;
1250212502 type CreatedAt = S::CreatedAt;
1250312503 type Status = S::Status;
1250412504+ type Id = S::Id;
1250512505+ type Did = S::Did;
1250412506 type Action = S::Action;
1250512505- type Did = S::Did;
1250612506- type CreatedBy = S::CreatedBy;
1250712507 }
1250812508 ///State transition - sets the `created_at` field to Set
1250912509 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
1251012510 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
1251112511 impl<S: State> State for SetCreatedAt<S> {
1251212512- type Id = S::Id;
1251212512+ type CreatedBy = S::CreatedBy;
1251312513 type CreatedAt = Set<members::created_at>;
1251412514 type Status = S::Status;
1251512515- type Action = S::Action;
1251512515+ type Id = S::Id;
1251612516 type Did = S::Did;
1251712517- type CreatedBy = S::CreatedBy;
1251712517+ type Action = S::Action;
1251812518 }
1251912519 ///State transition - sets the `status` field to Set
1252012520 pub struct SetStatus<S: State = Empty>(PhantomData<fn() -> S>);
1252112521 impl<S: State> sealed::Sealed for SetStatus<S> {}
1252212522 impl<S: State> State for SetStatus<S> {
1252312523- type Id = S::Id;
1252312523+ type CreatedBy = S::CreatedBy;
1252412524 type CreatedAt = S::CreatedAt;
1252512525 type Status = Set<members::status>;
1252612526+ type Id = S::Id;
1252712527+ type Did = S::Did;
1252612528 type Action = S::Action;
1252712527- type Did = S::Did;
1252812528- type CreatedBy = S::CreatedBy;
1252912529 }
1253012530- ///State transition - sets the `action` field to Set
1253112531- pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
1253212532- impl<S: State> sealed::Sealed for SetAction<S> {}
1253312533- impl<S: State> State for SetAction<S> {
1253412534- type Id = S::Id;
1253012530+ ///State transition - sets the `id` field to Set
1253112531+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
1253212532+ impl<S: State> sealed::Sealed for SetId<S> {}
1253312533+ impl<S: State> State for SetId<S> {
1253412534+ type CreatedBy = S::CreatedBy;
1253512535 type CreatedAt = S::CreatedAt;
1253612536 type Status = S::Status;
1253712537- type Action = Set<members::action>;
1253712537+ type Id = Set<members::id>;
1253812538 type Did = S::Did;
1253912539- type CreatedBy = S::CreatedBy;
1253912539+ type Action = S::Action;
1254012540 }
1254112541 ///State transition - sets the `did` field to Set
1254212542 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
1254312543 impl<S: State> sealed::Sealed for SetDid<S> {}
1254412544 impl<S: State> State for SetDid<S> {
1254512545- type Id = S::Id;
1254512545+ type CreatedBy = S::CreatedBy;
1254612546 type CreatedAt = S::CreatedAt;
1254712547 type Status = S::Status;
1254812548- type Action = S::Action;
1254812548+ type Id = S::Id;
1254912549 type Did = Set<members::did>;
1255012550- type CreatedBy = S::CreatedBy;
1255012550+ type Action = S::Action;
1255112551 }
1255212552- ///State transition - sets the `created_by` field to Set
1255312553- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
1255412554- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
1255512555- impl<S: State> State for SetCreatedBy<S> {
1255612556- type Id = S::Id;
1255212552+ ///State transition - sets the `action` field to Set
1255312553+ pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
1255412554+ impl<S: State> sealed::Sealed for SetAction<S> {}
1255512555+ impl<S: State> State for SetAction<S> {
1255612556+ type CreatedBy = S::CreatedBy;
1255712557 type CreatedAt = S::CreatedAt;
1255812558 type Status = S::Status;
1255912559- type Action = S::Action;
1255912559+ type Id = S::Id;
1256012560 type Did = S::Did;
1256112561- type CreatedBy = Set<members::created_by>;
1256112561+ type Action = Set<members::action>;
1256212562 }
1256312563 /// Marker types for field names
1256412564 #[allow(non_camel_case_types)]
1256512565 pub mod members {
1256612566- ///Marker type for the `id` field
1256712567- pub struct id(());
1256612566+ ///Marker type for the `created_by` field
1256712567+ pub struct created_by(());
1256812568 ///Marker type for the `created_at` field
1256912569 pub struct created_at(());
1257012570 ///Marker type for the `status` field
1257112571 pub struct status(());
1257212572- ///Marker type for the `action` field
1257312573- pub struct action(());
1257212572+ ///Marker type for the `id` field
1257312573+ pub struct id(());
1257412574 ///Marker type for the `did` field
1257512575 pub struct did(());
1257612576- ///Marker type for the `created_by` field
1257712577- pub struct created_by(());
1257612576+ ///Marker type for the `action` field
1257712577+ pub struct action(());
1257812578 }
1257912579}
1258012580···1291112911impl<'a, S> ScheduledActionViewBuilder<'a, S>
1291212912where
1291312913 S: scheduled_action_view_state::State,
1291412914- S::Id: scheduled_action_view_state::IsSet,
1291412914+ S::CreatedBy: scheduled_action_view_state::IsSet,
1291512915 S::CreatedAt: scheduled_action_view_state::IsSet,
1291612916 S::Status: scheduled_action_view_state::IsSet,
1291712917- S::Action: scheduled_action_view_state::IsSet,
1291712917+ S::Id: scheduled_action_view_state::IsSet,
1291812918 S::Did: scheduled_action_view_state::IsSet,
1291912919- S::CreatedBy: scheduled_action_view_state::IsSet,
1291912919+ S::Action: scheduled_action_view_state::IsSet,
1292012920{
1292112921 /// Build the final struct
1292212922 pub fn build(self) -> ScheduledActionView<'a> {
···1340113401 }
1340213402 /// State trait tracking which required fields have been set
1340313403 pub trait State: sealed::Sealed {
1340413404- type CreatedAt;
1340413404+ type Id;
1340513405+ type Subject;
1340513406 type UpdatedAt;
1340613406- type Subject;
1340713407 type ReviewState;
1340813408- type Id;
1340813408+ type CreatedAt;
1340913409 }
1341013410 /// Empty state - all required fields are unset
1341113411 pub struct Empty(());
1341213412 impl sealed::Sealed for Empty {}
1341313413 impl State for Empty {
1341413414- type CreatedAt = Unset;
1341513415- type UpdatedAt = Unset;
1341413414+ type Id = Unset;
1341613415 type Subject = Unset;
1341613416+ type UpdatedAt = Unset;
1341713417 type ReviewState = Unset;
1341813418- type Id = Unset;
1341813418+ type CreatedAt = Unset;
1341913419 }
1342013420- ///State transition - sets the `created_at` field to Set
1342113421- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
1342213422- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
1342313423- impl<S: State> State for SetCreatedAt<S> {
1342413424- type CreatedAt = Set<members::created_at>;
1342013420+ ///State transition - sets the `id` field to Set
1342113421+ pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
1342213422+ impl<S: State> sealed::Sealed for SetId<S> {}
1342313423+ impl<S: State> State for SetId<S> {
1342413424+ type Id = Set<members::id>;
1342513425+ type Subject = S::Subject;
1342513426 type UpdatedAt = S::UpdatedAt;
1342613426- type Subject = S::Subject;
1342713427 type ReviewState = S::ReviewState;
1342813428- type Id = S::Id;
1342913429- }
1343013430- ///State transition - sets the `updated_at` field to Set
1343113431- pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
1343213432- impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
1343313433- impl<S: State> State for SetUpdatedAt<S> {
1343413428 type CreatedAt = S::CreatedAt;
1343513435- type UpdatedAt = Set<members::updated_at>;
1343613436- type Subject = S::Subject;
1343713437- type ReviewState = S::ReviewState;
1343813438- type Id = S::Id;
1343913429 }
1344013430 ///State transition - sets the `subject` field to Set
1344113431 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
1344213432 impl<S: State> sealed::Sealed for SetSubject<S> {}
1344313433 impl<S: State> State for SetSubject<S> {
1344413444- type CreatedAt = S::CreatedAt;
1344513445- type UpdatedAt = S::UpdatedAt;
1343413434+ type Id = S::Id;
1344613435 type Subject = Set<members::subject>;
1343613436+ type UpdatedAt = S::UpdatedAt;
1344713437 type ReviewState = S::ReviewState;
1343813438+ type CreatedAt = S::CreatedAt;
1343913439+ }
1344013440+ ///State transition - sets the `updated_at` field to Set
1344113441+ pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
1344213442+ impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
1344313443+ impl<S: State> State for SetUpdatedAt<S> {
1344813444 type Id = S::Id;
1344513445+ type Subject = S::Subject;
1344613446+ type UpdatedAt = Set<members::updated_at>;
1344713447+ type ReviewState = S::ReviewState;
1344813448+ type CreatedAt = S::CreatedAt;
1344913449 }
1345013450 ///State transition - sets the `review_state` field to Set
1345113451 pub struct SetReviewState<S: State = Empty>(PhantomData<fn() -> S>);
1345213452 impl<S: State> sealed::Sealed for SetReviewState<S> {}
1345313453 impl<S: State> State for SetReviewState<S> {
1345413454- type CreatedAt = S::CreatedAt;
1345413454+ type Id = S::Id;
1345513455+ type Subject = S::Subject;
1345513456 type UpdatedAt = S::UpdatedAt;
1345613456- type Subject = S::Subject;
1345713457 type ReviewState = Set<members::review_state>;
1345813458- type Id = S::Id;
1345813458+ type CreatedAt = S::CreatedAt;
1345913459 }
1346013460- ///State transition - sets the `id` field to Set
1346113461- pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
1346213462- impl<S: State> sealed::Sealed for SetId<S> {}
1346313463- impl<S: State> State for SetId<S> {
1346413464- type CreatedAt = S::CreatedAt;
1346013460+ ///State transition - sets the `created_at` field to Set
1346113461+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
1346213462+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
1346313463+ impl<S: State> State for SetCreatedAt<S> {
1346413464+ type Id = S::Id;
1346513465+ type Subject = S::Subject;
1346513466 type UpdatedAt = S::UpdatedAt;
1346613466- type Subject = S::Subject;
1346713467 type ReviewState = S::ReviewState;
1346813468- type Id = Set<members::id>;
1346813468+ type CreatedAt = Set<members::created_at>;
1346913469 }
1347013470 /// Marker types for field names
1347113471 #[allow(non_camel_case_types)]
1347213472 pub mod members {
1347313473- ///Marker type for the `created_at` field
1347413474- pub struct created_at(());
1347513475- ///Marker type for the `updated_at` field
1347613476- pub struct updated_at(());
1347313473+ ///Marker type for the `id` field
1347413474+ pub struct id(());
1347713475 ///Marker type for the `subject` field
1347813476 pub struct subject(());
1347713477+ ///Marker type for the `updated_at` field
1347813478+ pub struct updated_at(());
1347913479 ///Marker type for the `review_state` field
1348013480 pub struct review_state(());
1348113481- ///Marker type for the `id` field
1348213482- pub struct id(());
1348113481+ ///Marker type for the `created_at` field
1348213482+ pub struct created_at(());
1348313483 }
1348413484}
1348513485···1401414014impl<'a, S> SubjectStatusViewBuilder<'a, S>
1401514015where
1401614016 S: subject_status_view_state::State,
1401714017- S::CreatedAt: subject_status_view_state::IsSet,
1401814018- S::UpdatedAt: subject_status_view_state::IsSet,
1401714017+ S::Id: subject_status_view_state::IsSet,
1401914018 S::Subject: subject_status_view_state::IsSet,
1401914019+ S::UpdatedAt: subject_status_view_state::IsSet,
1402014020 S::ReviewState: subject_status_view_state::IsSet,
1402114021- S::Id: subject_status_view_state::IsSet,
1402114021+ S::CreatedAt: subject_status_view_state::IsSet,
1402214022{
1402314023 /// Build the final struct
1402414024 pub fn build(self) -> SubjectStatusView<'a> {
···1474114741 }
1474214742 /// State trait tracking which required fields have been set
1474314743 pub trait State: sealed::Sealed {
1474414744- type Width;
1474514744 type Length;
1474514745+ type Width;
1474614746 type Height;
1474714747 }
1474814748 /// Empty state - all required fields are unset
1474914749 pub struct Empty(());
1475014750 impl sealed::Sealed for Empty {}
1475114751 impl State for Empty {
1475214752- type Width = Unset;
1475314752 type Length = Unset;
1475314753+ type Width = Unset;
1475414754 type Height = Unset;
1475514755 }
1475614756- ///State transition - sets the `width` field to Set
1475714757- pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
1475814758- impl<S: State> sealed::Sealed for SetWidth<S> {}
1475914759- impl<S: State> State for SetWidth<S> {
1476014760- type Width = Set<members::width>;
1476114761- type Length = S::Length;
1476214762- type Height = S::Height;
1476314763- }
1476414756 ///State transition - sets the `length` field to Set
1476514757 pub struct SetLength<S: State = Empty>(PhantomData<fn() -> S>);
1476614758 impl<S: State> sealed::Sealed for SetLength<S> {}
1476714759 impl<S: State> State for SetLength<S> {
1476814768- type Width = S::Width;
1476914760 type Length = Set<members::length>;
1476114761+ type Width = S::Width;
1476214762+ type Height = S::Height;
1476314763+ }
1476414764+ ///State transition - sets the `width` field to Set
1476514765+ pub struct SetWidth<S: State = Empty>(PhantomData<fn() -> S>);
1476614766+ impl<S: State> sealed::Sealed for SetWidth<S> {}
1476714767+ impl<S: State> State for SetWidth<S> {
1476814768+ type Length = S::Length;
1476914769+ type Width = Set<members::width>;
1477014770 type Height = S::Height;
1477114771 }
1477214772 ///State transition - sets the `height` field to Set
1477314773 pub struct SetHeight<S: State = Empty>(PhantomData<fn() -> S>);
1477414774 impl<S: State> sealed::Sealed for SetHeight<S> {}
1477514775 impl<S: State> State for SetHeight<S> {
1477614776- type Width = S::Width;
1477714776 type Length = S::Length;
1477714777+ type Width = S::Width;
1477814778 type Height = Set<members::height>;
1477914779 }
1478014780 /// Marker types for field names
1478114781 #[allow(non_camel_case_types)]
1478214782 pub mod members {
1478314783+ ///Marker type for the `length` field
1478414784+ pub struct length(());
1478314785 ///Marker type for the `width` field
1478414786 pub struct width(());
1478514785- ///Marker type for the `length` field
1478614786- pub struct length(());
1478714787 ///Marker type for the `height` field
1478814788 pub struct height(());
1478914789 }
···1487814878impl<'a, S> VideoDetailsBuilder<'a, S>
1487914879where
1488014880 S: video_details_state::State,
1488114881- S::Width: video_details_state::IsSet,
1488214881 S::Length: video_details_state::IsSet,
1488214882+ S::Width: video_details_state::IsSet,
1488314883 S::Height: video_details_state::IsSet,
1488414884{
1488514885 /// Build the final struct
···4747 }
4848 /// State trait tracking which required fields have been set
4949 pub trait State: sealed::Sealed {
5050+ type Event;
5051 type Subject;
5152 type CreatedBy;
5252- type Event;
5353 }
5454 /// Empty state - all required fields are unset
5555 pub struct Empty(());
5656 impl sealed::Sealed for Empty {}
5757 impl State for Empty {
5858+ type Event = Unset;
5859 type Subject = Unset;
5960 type CreatedBy = Unset;
6060- type Event = Unset;
6161+ }
6262+ ///State transition - sets the `event` field to Set
6363+ pub struct SetEvent<S: State = Empty>(PhantomData<fn() -> S>);
6464+ impl<S: State> sealed::Sealed for SetEvent<S> {}
6565+ impl<S: State> State for SetEvent<S> {
6666+ type Event = Set<members::event>;
6767+ type Subject = S::Subject;
6868+ type CreatedBy = S::CreatedBy;
6169 }
6270 ///State transition - sets the `subject` field to Set
6371 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
6472 impl<S: State> sealed::Sealed for SetSubject<S> {}
6573 impl<S: State> State for SetSubject<S> {
7474+ type Event = S::Event;
6675 type Subject = Set<members::subject>;
6776 type CreatedBy = S::CreatedBy;
6868- type Event = S::Event;
6977 }
7078 ///State transition - sets the `created_by` field to Set
7179 pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
7280 impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
7381 impl<S: State> State for SetCreatedBy<S> {
7474- type Subject = S::Subject;
7575- type CreatedBy = Set<members::created_by>;
7682 type Event = S::Event;
7777- }
7878- ///State transition - sets the `event` field to Set
7979- pub struct SetEvent<S: State = Empty>(PhantomData<fn() -> S>);
8080- impl<S: State> sealed::Sealed for SetEvent<S> {}
8181- impl<S: State> State for SetEvent<S> {
8283 type Subject = S::Subject;
8383- type CreatedBy = S::CreatedBy;
8484- type Event = Set<members::event>;
8484+ type CreatedBy = Set<members::created_by>;
8585 }
8686 /// Marker types for field names
8787 #[allow(non_camel_case_types)]
8888 pub mod members {
8989+ ///Marker type for the `event` field
9090+ pub struct event(());
8991 ///Marker type for the `subject` field
9092 pub struct subject(());
9193 ///Marker type for the `created_by` field
9294 pub struct created_by(());
9393- ///Marker type for the `event` field
9494- pub struct event(());
9595 }
9696}
9797···244244impl<'a, S> EmitEventBuilder<'a, S>
245245where
246246 S: emit_event_state::State,
247247+ S::Event: emit_event_state::IsSet,
247248 S::Subject: emit_event_state::IsSet,
248249 S::CreatedBy: emit_event_state::IsSet,
249249- S::Event: emit_event_state::IsSet,
250250{
251251 /// Build the final struct
252252 pub fn build(self) -> EmitEvent<'a> {
···219219 }
220220 /// State trait tracking which required fields have been set
221221 pub trait State: sealed::Sealed {
222222- type Summary;
223222 type Day;
223223+ type Summary;
224224 }
225225 /// Empty state - all required fields are unset
226226 pub struct Empty(());
227227 impl sealed::Sealed for Empty {}
228228 impl State for Empty {
229229- type Summary = Unset;
230229 type Day = Unset;
231231- }
232232- ///State transition - sets the `summary` field to Set
233233- pub struct SetSummary<S: State = Empty>(PhantomData<fn() -> S>);
234234- impl<S: State> sealed::Sealed for SetSummary<S> {}
235235- impl<S: State> State for SetSummary<S> {
236236- type Summary = Set<members::summary>;
237237- type Day = S::Day;
230230+ type Summary = Unset;
238231 }
239232 ///State transition - sets the `day` field to Set
240233 pub struct SetDay<S: State = Empty>(PhantomData<fn() -> S>);
241234 impl<S: State> sealed::Sealed for SetDay<S> {}
242235 impl<S: State> State for SetDay<S> {
243243- type Summary = S::Summary;
244236 type Day = Set<members::day>;
237237+ type Summary = S::Summary;
238238+ }
239239+ ///State transition - sets the `summary` field to Set
240240+ pub struct SetSummary<S: State = Empty>(PhantomData<fn() -> S>);
241241+ impl<S: State> sealed::Sealed for SetSummary<S> {}
242242+ impl<S: State> State for SetSummary<S> {
243243+ type Day = S::Day;
244244+ type Summary = Set<members::summary>;
245245 }
246246 /// Marker types for field names
247247 #[allow(non_camel_case_types)]
248248 pub mod members {
249249- ///Marker type for the `summary` field
250250- pub struct summary(());
251249 ///Marker type for the `day` field
252250 pub struct day(());
251251+ ///Marker type for the `summary` field
252252+ pub struct summary(());
253253 }
254254}
255255···334334impl<'a, S> TimelineItemBuilder<'a, S>
335335where
336336 S: timeline_item_state::State,
337337- S::Summary: timeline_item_state::IsSet,
338337 S::Day: timeline_item_state::IsSet,
338338+ S::Summary: timeline_item_state::IsSet,
339339{
340340 /// Build the final struct
341341 pub fn build(self) -> TimelineItem<'a> {
···575575 }
576576 /// State trait tracking which required fields have been set
577577 pub trait State: sealed::Sealed {
578578- type Count;
579578 type EventSubjectType;
580579 type EventType;
580580+ type Count;
581581 }
582582 /// Empty state - all required fields are unset
583583 pub struct Empty(());
584584 impl sealed::Sealed for Empty {}
585585 impl State for Empty {
586586- type Count = Unset;
587586 type EventSubjectType = Unset;
588587 type EventType = Unset;
589589- }
590590- ///State transition - sets the `count` field to Set
591591- pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
592592- impl<S: State> sealed::Sealed for SetCount<S> {}
593593- impl<S: State> State for SetCount<S> {
594594- type Count = Set<members::count>;
595595- type EventSubjectType = S::EventSubjectType;
596596- type EventType = S::EventType;
588588+ type Count = Unset;
597589 }
598590 ///State transition - sets the `event_subject_type` field to Set
599591 pub struct SetEventSubjectType<S: State = Empty>(PhantomData<fn() -> S>);
600592 impl<S: State> sealed::Sealed for SetEventSubjectType<S> {}
601593 impl<S: State> State for SetEventSubjectType<S> {
602602- type Count = S::Count;
603594 type EventSubjectType = Set<members::event_subject_type>;
604595 type EventType = S::EventType;
596596+ type Count = S::Count;
605597 }
606598 ///State transition - sets the `event_type` field to Set
607599 pub struct SetEventType<S: State = Empty>(PhantomData<fn() -> S>);
608600 impl<S: State> sealed::Sealed for SetEventType<S> {}
609601 impl<S: State> State for SetEventType<S> {
610610- type Count = S::Count;
611602 type EventSubjectType = S::EventSubjectType;
612603 type EventType = Set<members::event_type>;
604604+ type Count = S::Count;
605605+ }
606606+ ///State transition - sets the `count` field to Set
607607+ pub struct SetCount<S: State = Empty>(PhantomData<fn() -> S>);
608608+ impl<S: State> sealed::Sealed for SetCount<S> {}
609609+ impl<S: State> State for SetCount<S> {
610610+ type EventSubjectType = S::EventSubjectType;
611611+ type EventType = S::EventType;
612612+ type Count = Set<members::count>;
613613 }
614614 /// Marker types for field names
615615 #[allow(non_camel_case_types)]
616616 pub mod members {
617617- ///Marker type for the `count` field
618618- pub struct count(());
619617 ///Marker type for the `event_subject_type` field
620618 pub struct event_subject_type(());
621619 ///Marker type for the `event_type` field
622620 pub struct event_type(());
621621+ ///Marker type for the `count` field
622622+ pub struct count(());
623623 }
624624}
625625···715715impl<'a, S> TimelineItemSummaryBuilder<'a, S>
716716where
717717 S: timeline_item_summary_state::State,
718718- S::Count: timeline_item_summary_state::IsSet,
719718 S::EventSubjectType: timeline_item_summary_state::IsSet,
720719 S::EventType: timeline_item_summary_state::IsSet,
720720+ S::Count: timeline_item_summary_state::IsSet,
721721{
722722 /// Build the final struct
723723 pub fn build(self) -> TimelineItemSummary<'a> {
···761761 }
762762 /// State trait tracking which required fields have been set
763763 pub trait State: sealed::Sealed {
764764- type Subjects;
765765- type CreatedBy;
766764 type Action;
767765 type Scheduling;
766766+ type Subjects;
767767+ type CreatedBy;
768768 }
769769 /// Empty state - all required fields are unset
770770 pub struct Empty(());
771771 impl sealed::Sealed for Empty {}
772772 impl State for Empty {
773773- type Subjects = Unset;
774774- type CreatedBy = Unset;
775773 type Action = Unset;
776774 type Scheduling = Unset;
777777- }
778778- ///State transition - sets the `subjects` field to Set
779779- pub struct SetSubjects<S: State = Empty>(PhantomData<fn() -> S>);
780780- impl<S: State> sealed::Sealed for SetSubjects<S> {}
781781- impl<S: State> State for SetSubjects<S> {
782782- type Subjects = Set<members::subjects>;
783783- type CreatedBy = S::CreatedBy;
784784- type Action = S::Action;
785785- type Scheduling = S::Scheduling;
786786- }
787787- ///State transition - sets the `created_by` field to Set
788788- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
789789- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
790790- impl<S: State> State for SetCreatedBy<S> {
791791- type Subjects = S::Subjects;
792792- type CreatedBy = Set<members::created_by>;
793793- type Action = S::Action;
794794- type Scheduling = S::Scheduling;
775775+ type Subjects = Unset;
776776+ type CreatedBy = Unset;
795777 }
796778 ///State transition - sets the `action` field to Set
797779 pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
798780 impl<S: State> sealed::Sealed for SetAction<S> {}
799781 impl<S: State> State for SetAction<S> {
782782+ type Action = Set<members::action>;
783783+ type Scheduling = S::Scheduling;
800784 type Subjects = S::Subjects;
801785 type CreatedBy = S::CreatedBy;
802802- type Action = Set<members::action>;
803803- type Scheduling = S::Scheduling;
804786 }
805787 ///State transition - sets the `scheduling` field to Set
806788 pub struct SetScheduling<S: State = Empty>(PhantomData<fn() -> S>);
807789 impl<S: State> sealed::Sealed for SetScheduling<S> {}
808790 impl<S: State> State for SetScheduling<S> {
791791+ type Action = S::Action;
792792+ type Scheduling = Set<members::scheduling>;
809793 type Subjects = S::Subjects;
810794 type CreatedBy = S::CreatedBy;
795795+ }
796796+ ///State transition - sets the `subjects` field to Set
797797+ pub struct SetSubjects<S: State = Empty>(PhantomData<fn() -> S>);
798798+ impl<S: State> sealed::Sealed for SetSubjects<S> {}
799799+ impl<S: State> State for SetSubjects<S> {
811800 type Action = S::Action;
812812- type Scheduling = Set<members::scheduling>;
801801+ type Scheduling = S::Scheduling;
802802+ type Subjects = Set<members::subjects>;
803803+ type CreatedBy = S::CreatedBy;
804804+ }
805805+ ///State transition - sets the `created_by` field to Set
806806+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
807807+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
808808+ impl<S: State> State for SetCreatedBy<S> {
809809+ type Action = S::Action;
810810+ type Scheduling = S::Scheduling;
811811+ type Subjects = S::Subjects;
812812+ type CreatedBy = Set<members::created_by>;
813813 }
814814 /// Marker types for field names
815815 #[allow(non_camel_case_types)]
816816 pub mod members {
817817- ///Marker type for the `subjects` field
818818- pub struct subjects(());
819819- ///Marker type for the `created_by` field
820820- pub struct created_by(());
821817 ///Marker type for the `action` field
822818 pub struct action(());
823819 ///Marker type for the `scheduling` field
824820 pub struct scheduling(());
821821+ ///Marker type for the `subjects` field
822822+ pub struct subjects(());
823823+ ///Marker type for the `created_by` field
824824+ pub struct created_by(());
825825 }
826826}
827827···960960impl<'a, S> ScheduleActionBuilder<'a, S>
961961where
962962 S: schedule_action_state::State,
963963+ S::Action: schedule_action_state::IsSet,
964964+ S::Scheduling: schedule_action_state::IsSet,
963965 S::Subjects: schedule_action_state::IsSet,
964966 S::CreatedBy: schedule_action_state::IsSet,
965965- S::Action: schedule_action_state::IsSet,
966966- S::Scheduling: schedule_action_state::IsSet,
967967{
968968 /// Build the final struct
969969 pub fn build(self) -> ScheduleAction<'a> {
···10721072 }
10731073 /// State trait tracking which required fields have been set
10741074 pub trait State: sealed::Sealed {
10751075- type Succeeded;
10761075 type Failed;
10761076+ type Succeeded;
10771077 }
10781078 /// Empty state - all required fields are unset
10791079 pub struct Empty(());
10801080 impl sealed::Sealed for Empty {}
10811081 impl State for Empty {
10821082- type Succeeded = Unset;
10831082 type Failed = Unset;
10841084- }
10851085- ///State transition - sets the `succeeded` field to Set
10861086- pub struct SetSucceeded<S: State = Empty>(PhantomData<fn() -> S>);
10871087- impl<S: State> sealed::Sealed for SetSucceeded<S> {}
10881088- impl<S: State> State for SetSucceeded<S> {
10891089- type Succeeded = Set<members::succeeded>;
10901090- type Failed = S::Failed;
10831083+ type Succeeded = Unset;
10911084 }
10921085 ///State transition - sets the `failed` field to Set
10931086 pub struct SetFailed<S: State = Empty>(PhantomData<fn() -> S>);
10941087 impl<S: State> sealed::Sealed for SetFailed<S> {}
10951088 impl<S: State> State for SetFailed<S> {
10961096- type Succeeded = S::Succeeded;
10971089 type Failed = Set<members::failed>;
10901090+ type Succeeded = S::Succeeded;
10911091+ }
10921092+ ///State transition - sets the `succeeded` field to Set
10931093+ pub struct SetSucceeded<S: State = Empty>(PhantomData<fn() -> S>);
10941094+ impl<S: State> sealed::Sealed for SetSucceeded<S> {}
10951095+ impl<S: State> State for SetSucceeded<S> {
10961096+ type Failed = S::Failed;
10971097+ type Succeeded = Set<members::succeeded>;
10981098 }
10991099 /// Marker types for field names
11001100 #[allow(non_camel_case_types)]
11011101 pub mod members {
11021102+ ///Marker type for the `failed` field
11031103+ pub struct failed(());
11021104 ///Marker type for the `succeeded` field
11031105 pub struct succeeded(());
11041104- ///Marker type for the `failed` field
11051105- pub struct failed(());
11061106 }
11071107}
11081108···11881188impl<'a, S> ScheduledActionResultsBuilder<'a, S>
11891189where
11901190 S: scheduled_action_results_state::State,
11911191- S::Succeeded: scheduled_action_results_state::IsSet,
11921191 S::Failed: scheduled_action_results_state::IsSet,
11921192+ S::Succeeded: scheduled_action_results_state::IsSet,
11931193{
11941194 /// Build the final struct
11951195 pub fn build(self) -> ScheduledActionResults<'a> {
+140-140
crates/weaver-api/src/tools_ozone/safelink.rs
···144144 }
145145 /// State trait tracking which required fields have been set
146146 pub trait State: sealed::Sealed {
147147- type Pattern;
148148- type Url;
149149- type CreatedAt;
147147+ type CreatedBy;
150148 type Action;
151149 type Id;
150150+ type CreatedAt;
152151 type EventType;
152152+ type Url;
153153 type Reason;
154154- type CreatedBy;
154154+ type Pattern;
155155 }
156156 /// Empty state - all required fields are unset
157157 pub struct Empty(());
158158 impl sealed::Sealed for Empty {}
159159 impl State for Empty {
160160- type Pattern = Unset;
161161- type Url = Unset;
162162- type CreatedAt = Unset;
160160+ type CreatedBy = Unset;
163161 type Action = Unset;
164162 type Id = Unset;
163163+ type CreatedAt = Unset;
165164 type EventType = Unset;
165165+ type Url = Unset;
166166 type Reason = Unset;
167167- type CreatedBy = Unset;
167167+ type Pattern = Unset;
168168 }
169169- ///State transition - sets the `pattern` field to Set
170170- pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
171171- impl<S: State> sealed::Sealed for SetPattern<S> {}
172172- impl<S: State> State for SetPattern<S> {
173173- type Pattern = Set<members::pattern>;
174174- type Url = S::Url;
175175- type CreatedAt = S::CreatedAt;
169169+ ///State transition - sets the `created_by` field to Set
170170+ pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
171171+ impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
172172+ impl<S: State> State for SetCreatedBy<S> {
173173+ type CreatedBy = Set<members::created_by>;
176174 type Action = S::Action;
177175 type Id = S::Id;
178178- type EventType = S::EventType;
179179- type Reason = S::Reason;
180180- type CreatedBy = S::CreatedBy;
181181- }
182182- ///State transition - sets the `url` field to Set
183183- pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
184184- impl<S: State> sealed::Sealed for SetUrl<S> {}
185185- impl<S: State> State for SetUrl<S> {
186186- type Pattern = S::Pattern;
187187- type Url = Set<members::url>;
188176 type CreatedAt = S::CreatedAt;
189189- type Action = S::Action;
190190- type Id = S::Id;
191177 type EventType = S::EventType;
192192- type Reason = S::Reason;
193193- type CreatedBy = S::CreatedBy;
194194- }
195195- ///State transition - sets the `created_at` field to Set
196196- pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
197197- impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
198198- impl<S: State> State for SetCreatedAt<S> {
199199- type Pattern = S::Pattern;
200178 type Url = S::Url;
201201- type CreatedAt = Set<members::created_at>;
202202- type Action = S::Action;
203203- type Id = S::Id;
204204- type EventType = S::EventType;
205179 type Reason = S::Reason;
206206- type CreatedBy = S::CreatedBy;
180180+ type Pattern = S::Pattern;
207181 }
208182 ///State transition - sets the `action` field to Set
209183 pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
210184 impl<S: State> sealed::Sealed for SetAction<S> {}
211185 impl<S: State> State for SetAction<S> {
212212- type Pattern = S::Pattern;
213213- type Url = S::Url;
214214- type CreatedAt = S::CreatedAt;
186186+ type CreatedBy = S::CreatedBy;
215187 type Action = Set<members::action>;
216188 type Id = S::Id;
189189+ type CreatedAt = S::CreatedAt;
217190 type EventType = S::EventType;
191191+ type Url = S::Url;
218192 type Reason = S::Reason;
219219- type CreatedBy = S::CreatedBy;
193193+ type Pattern = S::Pattern;
220194 }
221195 ///State transition - sets the `id` field to Set
222196 pub struct SetId<S: State = Empty>(PhantomData<fn() -> S>);
223197 impl<S: State> sealed::Sealed for SetId<S> {}
224198 impl<S: State> State for SetId<S> {
225225- type Pattern = S::Pattern;
226226- type Url = S::Url;
227227- type CreatedAt = S::CreatedAt;
199199+ type CreatedBy = S::CreatedBy;
228200 type Action = S::Action;
229201 type Id = Set<members::id>;
202202+ type CreatedAt = S::CreatedAt;
230203 type EventType = S::EventType;
204204+ type Url = S::Url;
231205 type Reason = S::Reason;
206206+ type Pattern = S::Pattern;
207207+ }
208208+ ///State transition - sets the `created_at` field to Set
209209+ pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
210210+ impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
211211+ impl<S: State> State for SetCreatedAt<S> {
232212 type CreatedBy = S::CreatedBy;
213213+ type Action = S::Action;
214214+ type Id = S::Id;
215215+ type CreatedAt = Set<members::created_at>;
216216+ type EventType = S::EventType;
217217+ type Url = S::Url;
218218+ type Reason = S::Reason;
219219+ type Pattern = S::Pattern;
233220 }
234221 ///State transition - sets the `event_type` field to Set
235222 pub struct SetEventType<S: State = Empty>(PhantomData<fn() -> S>);
236223 impl<S: State> sealed::Sealed for SetEventType<S> {}
237224 impl<S: State> State for SetEventType<S> {
238238- type Pattern = S::Pattern;
239239- type Url = S::Url;
240240- type CreatedAt = S::CreatedAt;
225225+ type CreatedBy = S::CreatedBy;
241226 type Action = S::Action;
242227 type Id = S::Id;
228228+ type CreatedAt = S::CreatedAt;
243229 type EventType = Set<members::event_type>;
230230+ type Url = S::Url;
244231 type Reason = S::Reason;
232232+ type Pattern = S::Pattern;
233233+ }
234234+ ///State transition - sets the `url` field to Set
235235+ pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
236236+ impl<S: State> sealed::Sealed for SetUrl<S> {}
237237+ impl<S: State> State for SetUrl<S> {
245238 type CreatedBy = S::CreatedBy;
239239+ type Action = S::Action;
240240+ type Id = S::Id;
241241+ type CreatedAt = S::CreatedAt;
242242+ type EventType = S::EventType;
243243+ type Url = Set<members::url>;
244244+ type Reason = S::Reason;
245245+ type Pattern = S::Pattern;
246246 }
247247 ///State transition - sets the `reason` field to Set
248248 pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
249249 impl<S: State> sealed::Sealed for SetReason<S> {}
250250 impl<S: State> State for SetReason<S> {
251251- type Pattern = S::Pattern;
252252- type Url = S::Url;
253253- type CreatedAt = S::CreatedAt;
251251+ type CreatedBy = S::CreatedBy;
254252 type Action = S::Action;
255253 type Id = S::Id;
254254+ type CreatedAt = S::CreatedAt;
256255 type EventType = S::EventType;
256256+ type Url = S::Url;
257257 type Reason = Set<members::reason>;
258258- type CreatedBy = S::CreatedBy;
259259- }
260260- ///State transition - sets the `created_by` field to Set
261261- pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
262262- impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
263263- impl<S: State> State for SetCreatedBy<S> {
264258 type Pattern = S::Pattern;
265265- type Url = S::Url;
266266- type CreatedAt = S::CreatedAt;
259259+ }
260260+ ///State transition - sets the `pattern` field to Set
261261+ pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
262262+ impl<S: State> sealed::Sealed for SetPattern<S> {}
263263+ impl<S: State> State for SetPattern<S> {
264264+ type CreatedBy = S::CreatedBy;
267265 type Action = S::Action;
268266 type Id = S::Id;
267267+ type CreatedAt = S::CreatedAt;
269268 type EventType = S::EventType;
269269+ type Url = S::Url;
270270 type Reason = S::Reason;
271271- type CreatedBy = Set<members::created_by>;
271271+ type Pattern = Set<members::pattern>;
272272 }
273273 /// Marker types for field names
274274 #[allow(non_camel_case_types)]
275275 pub mod members {
276276- ///Marker type for the `pattern` field
277277- pub struct pattern(());
278278- ///Marker type for the `url` field
279279- pub struct url(());
280280- ///Marker type for the `created_at` field
281281- pub struct created_at(());
276276+ ///Marker type for the `created_by` field
277277+ pub struct created_by(());
282278 ///Marker type for the `action` field
283279 pub struct action(());
284280 ///Marker type for the `id` field
285281 pub struct id(());
282282+ ///Marker type for the `created_at` field
283283+ pub struct created_at(());
286284 ///Marker type for the `event_type` field
287285 pub struct event_type(());
286286+ ///Marker type for the `url` field
287287+ pub struct url(());
288288 ///Marker type for the `reason` field
289289 pub struct reason(());
290290- ///Marker type for the `created_by` field
291291- pub struct created_by(());
290290+ ///Marker type for the `pattern` field
291291+ pub struct pattern(());
292292 }
293293}
294294···508508impl<'a, S> EventBuilder<'a, S>
509509where
510510 S: event_state::State,
511511- S::Pattern: event_state::IsSet,
512512- S::Url: event_state::IsSet,
513513- S::CreatedAt: event_state::IsSet,
511511+ S::CreatedBy: event_state::IsSet,
514512 S::Action: event_state::IsSet,
515513 S::Id: event_state::IsSet,
514514+ S::CreatedAt: event_state::IsSet,
516515 S::EventType: event_state::IsSet,
516516+ S::Url: event_state::IsSet,
517517 S::Reason: event_state::IsSet,
518518- S::CreatedBy: event_state::IsSet,
518518+ S::Pattern: event_state::IsSet,
519519{
520520 /// Build the final struct
521521 pub fn build(self) -> Event<'a> {
···12571257 }
12581258 /// State trait tracking which required fields have been set
12591259 pub trait State: sealed::Sealed {
12601260- type Url;
12611261- type CreatedBy;
12621262- type CreatedAt;
12631263- type Pattern;
12641260 type Reason;
12611261+ type CreatedBy;
12651262 type UpdatedAt;
12631263+ type CreatedAt;
12641264+ type Url;
12661265 type Action;
12661266+ type Pattern;
12671267 }
12681268 /// Empty state - all required fields are unset
12691269 pub struct Empty(());
12701270 impl sealed::Sealed for Empty {}
12711271 impl State for Empty {
12721272- type Url = Unset;
12731273- type CreatedBy = Unset;
12741274- type CreatedAt = Unset;
12751275- type Pattern = Unset;
12761272 type Reason = Unset;
12731273+ type CreatedBy = Unset;
12771274 type UpdatedAt = Unset;
12751275+ type CreatedAt = Unset;
12761276+ type Url = Unset;
12781277 type Action = Unset;
12781278+ type Pattern = Unset;
12791279 }
12801280- ///State transition - sets the `url` field to Set
12811281- pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
12821282- impl<S: State> sealed::Sealed for SetUrl<S> {}
12831283- impl<S: State> State for SetUrl<S> {
12841284- type Url = Set<members::url>;
12801280+ ///State transition - sets the `reason` field to Set
12811281+ pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
12821282+ impl<S: State> sealed::Sealed for SetReason<S> {}
12831283+ impl<S: State> State for SetReason<S> {
12841284+ type Reason = Set<members::reason>;
12851285 type CreatedBy = S::CreatedBy;
12861286+ type UpdatedAt = S::UpdatedAt;
12861287 type CreatedAt = S::CreatedAt;
12871287- type Pattern = S::Pattern;
12881288- type Reason = S::Reason;
12891289- type UpdatedAt = S::UpdatedAt;
12881288+ type Url = S::Url;
12901289 type Action = S::Action;
12901290+ type Pattern = S::Pattern;
12911291 }
12921292 ///State transition - sets the `created_by` field to Set
12931293 pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
12941294 impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
12951295 impl<S: State> State for SetCreatedBy<S> {
12961296- type Url = S::Url;
12961296+ type Reason = S::Reason;
12971297 type CreatedBy = Set<members::created_by>;
12981298+ type UpdatedAt = S::UpdatedAt;
12981299 type CreatedAt = S::CreatedAt;
13001300+ type Url = S::Url;
13011301+ type Action = S::Action;
12991302 type Pattern = S::Pattern;
13031303+ }
13041304+ ///State transition - sets the `updated_at` field to Set
13051305+ pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
13061306+ impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
13071307+ impl<S: State> State for SetUpdatedAt<S> {
13001308 type Reason = S::Reason;
13011301- type UpdatedAt = S::UpdatedAt;
13091309+ type CreatedBy = S::CreatedBy;
13101310+ type UpdatedAt = Set<members::updated_at>;
13111311+ type CreatedAt = S::CreatedAt;
13121312+ type Url = S::Url;
13021313 type Action = S::Action;
13141314+ type Pattern = S::Pattern;
13031315 }
13041316 ///State transition - sets the `created_at` field to Set
13051317 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
13061318 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
13071319 impl<S: State> State for SetCreatedAt<S> {
13081308- type Url = S::Url;
13091309- type CreatedBy = S::CreatedBy;
13101310- type CreatedAt = Set<members::created_at>;
13111311- type Pattern = S::Pattern;
13121320 type Reason = S::Reason;
13131313- type UpdatedAt = S::UpdatedAt;
13141314- type Action = S::Action;
13151315- }
13161316- ///State transition - sets the `pattern` field to Set
13171317- pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
13181318- impl<S: State> sealed::Sealed for SetPattern<S> {}
13191319- impl<S: State> State for SetPattern<S> {
13201320- type Url = S::Url;
13211321 type CreatedBy = S::CreatedBy;
13221322- type CreatedAt = S::CreatedAt;
13231323- type Pattern = Set<members::pattern>;
13241324- type Reason = S::Reason;
13251322 type UpdatedAt = S::UpdatedAt;
13231323+ type CreatedAt = Set<members::created_at>;
13241324+ type Url = S::Url;
13261325 type Action = S::Action;
13261326+ type Pattern = S::Pattern;
13271327 }
13281328- ///State transition - sets the `reason` field to Set
13291329- pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
13301330- impl<S: State> sealed::Sealed for SetReason<S> {}
13311331- impl<S: State> State for SetReason<S> {
13321332- type Url = S::Url;
13281328+ ///State transition - sets the `url` field to Set
13291329+ pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
13301330+ impl<S: State> sealed::Sealed for SetUrl<S> {}
13311331+ impl<S: State> State for SetUrl<S> {
13321332+ type Reason = S::Reason;
13331333 type CreatedBy = S::CreatedBy;
13341334+ type UpdatedAt = S::UpdatedAt;
13341335 type CreatedAt = S::CreatedAt;
13351335- type Pattern = S::Pattern;
13361336- type Reason = Set<members::reason>;
13371337- type UpdatedAt = S::UpdatedAt;
13361336+ type Url = Set<members::url>;
13381337 type Action = S::Action;
13391339- }
13401340- ///State transition - sets the `updated_at` field to Set
13411341- pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
13421342- impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
13431343- impl<S: State> State for SetUpdatedAt<S> {
13441344- type Url = S::Url;
13451345- type CreatedBy = S::CreatedBy;
13461346- type CreatedAt = S::CreatedAt;
13471338 type Pattern = S::Pattern;
13481348- type Reason = S::Reason;
13491349- type UpdatedAt = Set<members::updated_at>;
13501350- type Action = S::Action;
13511339 }
13521340 ///State transition - sets the `action` field to Set
13531341 pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
13541342 impl<S: State> sealed::Sealed for SetAction<S> {}
13551343 impl<S: State> State for SetAction<S> {
13561356- type Url = S::Url;
13441344+ type Reason = S::Reason;
13571345 type CreatedBy = S::CreatedBy;
13461346+ type UpdatedAt = S::UpdatedAt;
13581347 type CreatedAt = S::CreatedAt;
13481348+ type Url = S::Url;
13491349+ type Action = Set<members::action>;
13591350 type Pattern = S::Pattern;
13511351+ }
13521352+ ///State transition - sets the `pattern` field to Set
13531353+ pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
13541354+ impl<S: State> sealed::Sealed for SetPattern<S> {}
13551355+ impl<S: State> State for SetPattern<S> {
13601356 type Reason = S::Reason;
13571357+ type CreatedBy = S::CreatedBy;
13611358 type UpdatedAt = S::UpdatedAt;
13621362- type Action = Set<members::action>;
13591359+ type CreatedAt = S::CreatedAt;
13601360+ type Url = S::Url;
13611361+ type Action = S::Action;
13621362+ type Pattern = Set<members::pattern>;
13631363 }
13641364 /// Marker types for field names
13651365 #[allow(non_camel_case_types)]
13661366 pub mod members {
13671367- ///Marker type for the `url` field
13681368- pub struct url(());
13671367+ ///Marker type for the `reason` field
13681368+ pub struct reason(());
13691369 ///Marker type for the `created_by` field
13701370 pub struct created_by(());
13711371+ ///Marker type for the `updated_at` field
13721372+ pub struct updated_at(());
13711373 ///Marker type for the `created_at` field
13721374 pub struct created_at(());
13751375+ ///Marker type for the `url` field
13761376+ pub struct url(());
13771377+ ///Marker type for the `action` field
13781378+ pub struct action(());
13731379 ///Marker type for the `pattern` field
13741380 pub struct pattern(());
13751375- ///Marker type for the `reason` field
13761376- pub struct reason(());
13771377- ///Marker type for the `updated_at` field
13781378- pub struct updated_at(());
13791379- ///Marker type for the `action` field
13801380- pub struct action(());
13811381 }
13821382}
13831383···15671567impl<'a, S> UrlRuleBuilder<'a, S>
15681568where
15691569 S: url_rule_state::State,
15701570- S::Url: url_rule_state::IsSet,
15711571- S::CreatedBy: url_rule_state::IsSet,
15721572- S::CreatedAt: url_rule_state::IsSet,
15731573- S::Pattern: url_rule_state::IsSet,
15741570 S::Reason: url_rule_state::IsSet,
15711571+ S::CreatedBy: url_rule_state::IsSet,
15751572 S::UpdatedAt: url_rule_state::IsSet,
15731573+ S::CreatedAt: url_rule_state::IsSet,
15741574+ S::Url: url_rule_state::IsSet,
15761575 S::Action: url_rule_state::IsSet,
15761576+ S::Pattern: url_rule_state::IsSet,
15771577{
15781578 /// Build the final struct
15791579 pub fn build(self) -> UrlRule<'a> {
···4646 }
4747 /// State trait tracking which required fields have been set
4848 pub trait State: sealed::Sealed {
4949- type Action;
4949+ type Reason;
5050 type Url;
5151+ type Action;
5152 type Pattern;
5252- type Reason;
5353 }
5454 /// Empty state - all required fields are unset
5555 pub struct Empty(());
5656 impl sealed::Sealed for Empty {}
5757 impl State for Empty {
5858+ type Reason = Unset;
5959+ type Url = Unset;
5860 type Action = Unset;
5959- type Url = Unset;
6061 type Pattern = Unset;
6161- type Reason = Unset;
6262 }
6363- ///State transition - sets the `action` field to Set
6464- pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
6565- impl<S: State> sealed::Sealed for SetAction<S> {}
6666- impl<S: State> State for SetAction<S> {
6767- type Action = Set<members::action>;
6363+ ///State transition - sets the `reason` field to Set
6464+ pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
6565+ impl<S: State> sealed::Sealed for SetReason<S> {}
6666+ impl<S: State> State for SetReason<S> {
6767+ type Reason = Set<members::reason>;
6868 type Url = S::Url;
6969+ type Action = S::Action;
6970 type Pattern = S::Pattern;
7070- type Reason = S::Reason;
7171 }
7272 ///State transition - sets the `url` field to Set
7373 pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
7474 impl<S: State> sealed::Sealed for SetUrl<S> {}
7575 impl<S: State> State for SetUrl<S> {
7676+ type Reason = S::Reason;
7777+ type Url = Set<members::url>;
7678 type Action = S::Action;
7777- type Url = Set<members::url>;
7879 type Pattern = S::Pattern;
8080+ }
8181+ ///State transition - sets the `action` field to Set
8282+ pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
8383+ impl<S: State> sealed::Sealed for SetAction<S> {}
8484+ impl<S: State> State for SetAction<S> {
7985 type Reason = S::Reason;
8686+ type Url = S::Url;
8787+ type Action = Set<members::action>;
8888+ type Pattern = S::Pattern;
8089 }
8190 ///State transition - sets the `pattern` field to Set
8291 pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
8392 impl<S: State> sealed::Sealed for SetPattern<S> {}
8493 impl<S: State> State for SetPattern<S> {
8585- type Action = S::Action;
8686- type Url = S::Url;
8787- type Pattern = Set<members::pattern>;
8894 type Reason = S::Reason;
8989- }
9090- ///State transition - sets the `reason` field to Set
9191- pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
9292- impl<S: State> sealed::Sealed for SetReason<S> {}
9393- impl<S: State> State for SetReason<S> {
9494- type Action = S::Action;
9595 type Url = S::Url;
9696- type Pattern = S::Pattern;
9797- type Reason = Set<members::reason>;
9696+ type Action = S::Action;
9797+ type Pattern = Set<members::pattern>;
9898 }
9999 /// Marker types for field names
100100 #[allow(non_camel_case_types)]
101101 pub mod members {
102102- ///Marker type for the `action` field
103103- pub struct action(());
102102+ ///Marker type for the `reason` field
103103+ pub struct reason(());
104104 ///Marker type for the `url` field
105105 pub struct url(());
106106+ ///Marker type for the `action` field
107107+ pub struct action(());
106108 ///Marker type for the `pattern` field
107109 pub struct pattern(());
108108- ///Marker type for the `reason` field
109109- pub struct reason(());
110110 }
111111}
112112···256256impl<'a, S> AddRuleBuilder<'a, S>
257257where
258258 S: add_rule_state::State,
259259- S::Action: add_rule_state::IsSet,
259259+ S::Reason: add_rule_state::IsSet,
260260 S::Url: add_rule_state::IsSet,
261261+ S::Action: add_rule_state::IsSet,
261262 S::Pattern: add_rule_state::IsSet,
262262- S::Reason: add_rule_state::IsSet,
263263{
264264 /// Build the final struct
265265 pub fn build(self) -> AddRule<'a> {
···4848 pub trait State: sealed::Sealed {
4949 type Action;
5050 type Pattern;
5151- type Reason;
5251 type Url;
5252+ type Reason;
5353 }
5454 /// Empty state - all required fields are unset
5555 pub struct Empty(());
···5757 impl State for Empty {
5858 type Action = Unset;
5959 type Pattern = Unset;
6060- type Reason = Unset;
6160 type Url = Unset;
6161+ type Reason = Unset;
6262 }
6363 ///State transition - sets the `action` field to Set
6464 pub struct SetAction<S: State = Empty>(PhantomData<fn() -> S>);
···6666 impl<S: State> State for SetAction<S> {
6767 type Action = Set<members::action>;
6868 type Pattern = S::Pattern;
6969- type Reason = S::Reason;
7069 type Url = S::Url;
7070+ type Reason = S::Reason;
7171 }
7272 ///State transition - sets the `pattern` field to Set
7373 pub struct SetPattern<S: State = Empty>(PhantomData<fn() -> S>);
···7575 impl<S: State> State for SetPattern<S> {
7676 type Action = S::Action;
7777 type Pattern = Set<members::pattern>;
7878- type Reason = S::Reason;
7979- type Url = S::Url;
8080- }
8181- ///State transition - sets the `reason` field to Set
8282- pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
8383- impl<S: State> sealed::Sealed for SetReason<S> {}
8484- impl<S: State> State for SetReason<S> {
8585- type Action = S::Action;
8686- type Pattern = S::Pattern;
8787- type Reason = Set<members::reason>;
8878 type Url = S::Url;
7979+ type Reason = S::Reason;
8980 }
9081 ///State transition - sets the `url` field to Set
9182 pub struct SetUrl<S: State = Empty>(PhantomData<fn() -> S>);
···9384 impl<S: State> State for SetUrl<S> {
9485 type Action = S::Action;
9586 type Pattern = S::Pattern;
9696- type Reason = S::Reason;
9787 type Url = Set<members::url>;
8888+ type Reason = S::Reason;
8989+ }
9090+ ///State transition - sets the `reason` field to Set
9191+ pub struct SetReason<S: State = Empty>(PhantomData<fn() -> S>);
9292+ impl<S: State> sealed::Sealed for SetReason<S> {}
9393+ impl<S: State> State for SetReason<S> {
9494+ type Action = S::Action;
9595+ type Pattern = S::Pattern;
9696+ type Url = S::Url;
9797+ type Reason = Set<members::reason>;
9898 }
9999 /// Marker types for field names
100100 #[allow(non_camel_case_types)]
···103103 pub struct action(());
104104 ///Marker type for the `pattern` field
105105 pub struct pattern(());
106106+ ///Marker type for the `url` field
107107+ pub struct url(());
106108 ///Marker type for the `reason` field
107109 pub struct reason(());
108108- ///Marker type for the `url` field
109109- pub struct url(());
110110 }
111111}
112112···258258 S: update_rule_state::State,
259259 S::Action: update_rule_state::IsSet,
260260 S::Pattern: update_rule_state::IsSet,
261261- S::Reason: update_rule_state::IsSet,
262261 S::Url: update_rule_state::IsSet,
262262+ S::Reason: update_rule_state::IsSet,
263263{
264264 /// Build the final struct
265265 pub fn build(self) -> UpdateRule<'a> {
+29-29
crates/weaver-api/src/tools_ozone/set.rs
···300300 }
301301 /// State trait tracking which required fields have been set
302302 pub trait State: sealed::Sealed {
303303- type SetSize;
304303 type Name;
305305- type UpdatedAt;
304304+ type SetSize;
306305 type CreatedAt;
306306+ type UpdatedAt;
307307 }
308308 /// Empty state - all required fields are unset
309309 pub struct Empty(());
310310 impl sealed::Sealed for Empty {}
311311 impl State for Empty {
312312- type SetSize = Unset;
313312 type Name = Unset;
314314- type UpdatedAt = Unset;
313313+ type SetSize = Unset;
315314 type CreatedAt = Unset;
316316- }
317317- ///State transition - sets the `set_size` field to Set
318318- pub struct SetSetSize<S: State = Empty>(PhantomData<fn() -> S>);
319319- impl<S: State> sealed::Sealed for SetSetSize<S> {}
320320- impl<S: State> State for SetSetSize<S> {
321321- type SetSize = Set<members::set_size>;
322322- type Name = S::Name;
323323- type UpdatedAt = S::UpdatedAt;
324324- type CreatedAt = S::CreatedAt;
315315+ type UpdatedAt = Unset;
325316 }
326317 ///State transition - sets the `name` field to Set
327318 pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
328319 impl<S: State> sealed::Sealed for SetName<S> {}
329320 impl<S: State> State for SetName<S> {
321321+ type Name = Set<members::name>;
330322 type SetSize = S::SetSize;
331331- type Name = Set<members::name>;
323323+ type CreatedAt = S::CreatedAt;
332324 type UpdatedAt = S::UpdatedAt;
333333- type CreatedAt = S::CreatedAt;
334325 }
335335- ///State transition - sets the `updated_at` field to Set
336336- pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
337337- impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
338338- impl<S: State> State for SetUpdatedAt<S> {
339339- type SetSize = S::SetSize;
326326+ ///State transition - sets the `set_size` field to Set
327327+ pub struct SetSetSize<S: State = Empty>(PhantomData<fn() -> S>);
328328+ impl<S: State> sealed::Sealed for SetSetSize<S> {}
329329+ impl<S: State> State for SetSetSize<S> {
340330 type Name = S::Name;
341341- type UpdatedAt = Set<members::updated_at>;
331331+ type SetSize = Set<members::set_size>;
342332 type CreatedAt = S::CreatedAt;
333333+ type UpdatedAt = S::UpdatedAt;
343334 }
344335 ///State transition - sets the `created_at` field to Set
345336 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
346337 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
347338 impl<S: State> State for SetCreatedAt<S> {
339339+ type Name = S::Name;
348340 type SetSize = S::SetSize;
341341+ type CreatedAt = Set<members::created_at>;
342342+ type UpdatedAt = S::UpdatedAt;
343343+ }
344344+ ///State transition - sets the `updated_at` field to Set
345345+ pub struct SetUpdatedAt<S: State = Empty>(PhantomData<fn() -> S>);
346346+ impl<S: State> sealed::Sealed for SetUpdatedAt<S> {}
347347+ impl<S: State> State for SetUpdatedAt<S> {
349348 type Name = S::Name;
350350- type UpdatedAt = S::UpdatedAt;
351351- type CreatedAt = Set<members::created_at>;
349349+ type SetSize = S::SetSize;
350350+ type CreatedAt = S::CreatedAt;
351351+ type UpdatedAt = Set<members::updated_at>;
352352 }
353353 /// Marker types for field names
354354 #[allow(non_camel_case_types)]
355355 pub mod members {
356356+ ///Marker type for the `name` field
357357+ pub struct name(());
356358 ///Marker type for the `set_size` field
357359 pub struct set_size(());
358358- ///Marker type for the `name` field
359359- pub struct name(());
360360- ///Marker type for the `updated_at` field
361361- pub struct updated_at(());
362360 ///Marker type for the `created_at` field
363361 pub struct created_at(());
362362+ ///Marker type for the `updated_at` field
363363+ pub struct updated_at(());
364364 }
365365}
366366···493493impl<'a, S> SetViewBuilder<'a, S>
494494where
495495 S: set_view_state::State,
496496- S::SetSize: set_view_state::IsSet,
497496 S::Name: set_view_state::IsSet,
498498- S::UpdatedAt: set_view_state::IsSet,
497497+ S::SetSize: set_view_state::IsSet,
499498 S::CreatedAt: set_view_state::IsSet,
499499+ S::UpdatedAt: set_view_state::IsSet,
500500{
501501 /// Build the final struct
502502 pub fn build(self) -> SetView<'a> {
···3535 }
3636 /// State trait tracking which required fields have been set
3737 pub trait State: sealed::Sealed {
3838- type Name;
3938 type Values;
3939+ type Name;
4040 }
4141 /// Empty state - all required fields are unset
4242 pub struct Empty(());
4343 impl sealed::Sealed for Empty {}
4444 impl State for Empty {
4545- type Name = Unset;
4645 type Values = Unset;
4747- }
4848- ///State transition - sets the `name` field to Set
4949- pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
5050- impl<S: State> sealed::Sealed for SetName<S> {}
5151- impl<S: State> State for SetName<S> {
5252- type Name = Set<members::name>;
5353- type Values = S::Values;
4646+ type Name = Unset;
5447 }
5548 ///State transition - sets the `values` field to Set
5649 pub struct SetValues<S: State = Empty>(PhantomData<fn() -> S>);
5750 impl<S: State> sealed::Sealed for SetValues<S> {}
5851 impl<S: State> State for SetValues<S> {
5959- type Name = S::Name;
6052 type Values = Set<members::values>;
5353+ type Name = S::Name;
5454+ }
5555+ ///State transition - sets the `name` field to Set
5656+ pub struct SetName<S: State = Empty>(PhantomData<fn() -> S>);
5757+ impl<S: State> sealed::Sealed for SetName<S> {}
5858+ impl<S: State> State for SetName<S> {
5959+ type Values = S::Values;
6060+ type Name = Set<members::name>;
6161 }
6262 /// Marker types for field names
6363 #[allow(non_camel_case_types)]
6464 pub mod members {
6565- ///Marker type for the `name` field
6666- pub struct name(());
6765 ///Marker type for the `values` field
6866 pub struct values(());
6767+ ///Marker type for the `name` field
6868+ pub struct name(());
6969 }
7070}
7171···138138impl<'a, S> AddValuesBuilder<'a, S>
139139where
140140 S: add_values_state::State,
141141- S::Name: add_values_state::IsSet,
142141 S::Values: add_values_state::IsSet,
142142+ S::Name: add_values_state::IsSet,
143143{
144144 /// Build the final struct
145145 pub fn build(self) -> AddValues<'a> {
+48-48
crates/weaver-api/src/tools_ozone/setting.rs
···5555 }
5656 /// State trait tracking which required fields have been set
5757 pub trait State: sealed::Sealed {
5858- type Scope;
5858+ type LastUpdatedBy;
5959 type Key;
6060+ type Value;
6061 type Did;
6161- type LastUpdatedBy;
6262+ type Scope;
6263 type CreatedBy;
6363- type Value;
6464 }
6565 /// Empty state - all required fields are unset
6666 pub struct Empty(());
6767 impl sealed::Sealed for Empty {}
6868 impl State for Empty {
6969- type Scope = Unset;
6969+ type LastUpdatedBy = Unset;
7070 type Key = Unset;
7171+ type Value = Unset;
7172 type Did = Unset;
7272- type LastUpdatedBy = Unset;
7373+ type Scope = Unset;
7374 type CreatedBy = Unset;
7474- type Value = Unset;
7575 }
7676- ///State transition - sets the `scope` field to Set
7777- pub struct SetScope<S: State = Empty>(PhantomData<fn() -> S>);
7878- impl<S: State> sealed::Sealed for SetScope<S> {}
7979- impl<S: State> State for SetScope<S> {
8080- type Scope = Set<members::scope>;
7676+ ///State transition - sets the `last_updated_by` field to Set
7777+ pub struct SetLastUpdatedBy<S: State = Empty>(PhantomData<fn() -> S>);
7878+ impl<S: State> sealed::Sealed for SetLastUpdatedBy<S> {}
7979+ impl<S: State> State for SetLastUpdatedBy<S> {
8080+ type LastUpdatedBy = Set<members::last_updated_by>;
8181 type Key = S::Key;
8282+ type Value = S::Value;
8283 type Did = S::Did;
8383- type LastUpdatedBy = S::LastUpdatedBy;
8484+ type Scope = S::Scope;
8485 type CreatedBy = S::CreatedBy;
8585- type Value = S::Value;
8686 }
8787 ///State transition - sets the `key` field to Set
8888 pub struct SetKey<S: State = Empty>(PhantomData<fn() -> S>);
8989 impl<S: State> sealed::Sealed for SetKey<S> {}
9090 impl<S: State> State for SetKey<S> {
9191- type Scope = S::Scope;
9191+ type LastUpdatedBy = S::LastUpdatedBy;
9292 type Key = Set<members::key>;
9393+ type Value = S::Value;
9394 type Did = S::Did;
9595+ type Scope = S::Scope;
9696+ type CreatedBy = S::CreatedBy;
9797+ }
9898+ ///State transition - sets the `value` field to Set
9999+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
100100+ impl<S: State> sealed::Sealed for SetValue<S> {}
101101+ impl<S: State> State for SetValue<S> {
94102 type LastUpdatedBy = S::LastUpdatedBy;
103103+ type Key = S::Key;
104104+ type Value = Set<members::value>;
105105+ type Did = S::Did;
106106+ type Scope = S::Scope;
95107 type CreatedBy = S::CreatedBy;
9696- type Value = S::Value;
97108 }
98109 ///State transition - sets the `did` field to Set
99110 pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
100111 impl<S: State> sealed::Sealed for SetDid<S> {}
101112 impl<S: State> State for SetDid<S> {
102102- type Scope = S::Scope;
113113+ type LastUpdatedBy = S::LastUpdatedBy;
103114 type Key = S::Key;
115115+ type Value = S::Value;
104116 type Did = Set<members::did>;
105105- type LastUpdatedBy = S::LastUpdatedBy;
117117+ type Scope = S::Scope;
106118 type CreatedBy = S::CreatedBy;
107107- type Value = S::Value;
108119 }
109109- ///State transition - sets the `last_updated_by` field to Set
110110- pub struct SetLastUpdatedBy<S: State = Empty>(PhantomData<fn() -> S>);
111111- impl<S: State> sealed::Sealed for SetLastUpdatedBy<S> {}
112112- impl<S: State> State for SetLastUpdatedBy<S> {
113113- type Scope = S::Scope;
120120+ ///State transition - sets the `scope` field to Set
121121+ pub struct SetScope<S: State = Empty>(PhantomData<fn() -> S>);
122122+ impl<S: State> sealed::Sealed for SetScope<S> {}
123123+ impl<S: State> State for SetScope<S> {
124124+ type LastUpdatedBy = S::LastUpdatedBy;
114125 type Key = S::Key;
126126+ type Value = S::Value;
115127 type Did = S::Did;
116116- type LastUpdatedBy = Set<members::last_updated_by>;
128128+ type Scope = Set<members::scope>;
117129 type CreatedBy = S::CreatedBy;
118118- type Value = S::Value;
119130 }
120131 ///State transition - sets the `created_by` field to Set
121132 pub struct SetCreatedBy<S: State = Empty>(PhantomData<fn() -> S>);
122133 impl<S: State> sealed::Sealed for SetCreatedBy<S> {}
123134 impl<S: State> State for SetCreatedBy<S> {
124124- type Scope = S::Scope;
135135+ type LastUpdatedBy = S::LastUpdatedBy;
125136 type Key = S::Key;
137137+ type Value = S::Value;
126138 type Did = S::Did;
127127- type LastUpdatedBy = S::LastUpdatedBy;
139139+ type Scope = S::Scope;
128140 type CreatedBy = Set<members::created_by>;
129129- type Value = S::Value;
130130- }
131131- ///State transition - sets the `value` field to Set
132132- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
133133- impl<S: State> sealed::Sealed for SetValue<S> {}
134134- impl<S: State> State for SetValue<S> {
135135- type Scope = S::Scope;
136136- type Key = S::Key;
137137- type Did = S::Did;
138138- type LastUpdatedBy = S::LastUpdatedBy;
139139- type CreatedBy = S::CreatedBy;
140140- type Value = Set<members::value>;
141141 }
142142 /// Marker types for field names
143143 #[allow(non_camel_case_types)]
144144 pub mod members {
145145- ///Marker type for the `scope` field
146146- pub struct scope(());
145145+ ///Marker type for the `last_updated_by` field
146146+ pub struct last_updated_by(());
147147 ///Marker type for the `key` field
148148 pub struct key(());
149149+ ///Marker type for the `value` field
150150+ pub struct value(());
149151 ///Marker type for the `did` field
150152 pub struct did(());
151151- ///Marker type for the `last_updated_by` field
152152- pub struct last_updated_by(());
153153+ ///Marker type for the `scope` field
154154+ pub struct scope(());
153155 ///Marker type for the `created_by` field
154156 pub struct created_by(());
155155- ///Marker type for the `value` field
156156- pub struct value(());
157157 }
158158}
159159···397397impl<'a, S> DefsOptionBuilder<'a, S>
398398where
399399 S: defs_option_state::State,
400400- S::Scope: defs_option_state::IsSet,
400400+ S::LastUpdatedBy: defs_option_state::IsSet,
401401 S::Key: defs_option_state::IsSet,
402402+ S::Value: defs_option_state::IsSet,
402403 S::Did: defs_option_state::IsSet,
403403- S::LastUpdatedBy: defs_option_state::IsSet,
404404+ S::Scope: defs_option_state::IsSet,
404405 S::CreatedBy: defs_option_state::IsSet,
405405- S::Value: defs_option_state::IsSet,
406406{
407407 /// Build the final struct
408408 pub fn build(self) -> DefsOption<'a> {
···4141 }
4242 /// State trait tracking which required fields have been set
4343 pub trait State: sealed::Sealed {
4444+ type Value;
4445 type Key;
4546 type Scope;
4646- type Value;
4747 }
4848 /// Empty state - all required fields are unset
4949 pub struct Empty(());
5050 impl sealed::Sealed for Empty {}
5151 impl State for Empty {
5252+ type Value = Unset;
5253 type Key = Unset;
5354 type Scope = Unset;
5454- type Value = Unset;
5555+ }
5656+ ///State transition - sets the `value` field to Set
5757+ pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
5858+ impl<S: State> sealed::Sealed for SetValue<S> {}
5959+ impl<S: State> State for SetValue<S> {
6060+ type Value = Set<members::value>;
6161+ type Key = S::Key;
6262+ type Scope = S::Scope;
5563 }
5664 ///State transition - sets the `key` field to Set
5765 pub struct SetKey<S: State = Empty>(PhantomData<fn() -> S>);
5866 impl<S: State> sealed::Sealed for SetKey<S> {}
5967 impl<S: State> State for SetKey<S> {
6868+ type Value = S::Value;
6069 type Key = Set<members::key>;
6170 type Scope = S::Scope;
6262- type Value = S::Value;
6371 }
6472 ///State transition - sets the `scope` field to Set
6573 pub struct SetScope<S: State = Empty>(PhantomData<fn() -> S>);
6674 impl<S: State> sealed::Sealed for SetScope<S> {}
6775 impl<S: State> State for SetScope<S> {
6868- type Key = S::Key;
6969- type Scope = Set<members::scope>;
7076 type Value = S::Value;
7171- }
7272- ///State transition - sets the `value` field to Set
7373- pub struct SetValue<S: State = Empty>(PhantomData<fn() -> S>);
7474- impl<S: State> sealed::Sealed for SetValue<S> {}
7575- impl<S: State> State for SetValue<S> {
7677 type Key = S::Key;
7777- type Scope = S::Scope;
7878- type Value = Set<members::value>;
7878+ type Scope = Set<members::scope>;
7979 }
8080 /// Marker types for field names
8181 #[allow(non_camel_case_types)]
8282 pub mod members {
8383+ ///Marker type for the `value` field
8484+ pub struct value(());
8385 ///Marker type for the `key` field
8486 pub struct key(());
8587 ///Marker type for the `scope` field
8688 pub struct scope(());
8787- ///Marker type for the `value` field
8888- pub struct value(());
8989 }
9090}
9191···218218impl<'a, S> UpsertOptionBuilder<'a, S>
219219where
220220 S: upsert_option_state::State,
221221+ S::Value: upsert_option_state::IsSet,
221222 S::Key: upsert_option_state::IsSet,
222223 S::Scope: upsert_option_state::IsSet,
223223- S::Value: upsert_option_state::IsSet,
224224{
225225 /// Build the final struct
226226 pub fn build(self) -> UpsertOption<'a> {
···3333 }
3434 /// State trait tracking which required fields have been set
3535 pub trait State: sealed::Sealed {
3636- type Did;
3736 type Role;
3737+ type Did;
3838 }
3939 /// Empty state - all required fields are unset
4040 pub struct Empty(());
4141 impl sealed::Sealed for Empty {}
4242 impl State for Empty {
4343- type Did = Unset;
4443 type Role = Unset;
4545- }
4646- ///State transition - sets the `did` field to Set
4747- pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
4848- impl<S: State> sealed::Sealed for SetDid<S> {}
4949- impl<S: State> State for SetDid<S> {
5050- type Did = Set<members::did>;
5151- type Role = S::Role;
4444+ type Did = Unset;
5245 }
5346 ///State transition - sets the `role` field to Set
5447 pub struct SetRole<S: State = Empty>(PhantomData<fn() -> S>);
5548 impl<S: State> sealed::Sealed for SetRole<S> {}
5649 impl<S: State> State for SetRole<S> {
5757- type Did = S::Did;
5850 type Role = Set<members::role>;
5151+ type Did = S::Did;
5252+ }
5353+ ///State transition - sets the `did` field to Set
5454+ pub struct SetDid<S: State = Empty>(PhantomData<fn() -> S>);
5555+ impl<S: State> sealed::Sealed for SetDid<S> {}
5656+ impl<S: State> State for SetDid<S> {
5757+ type Role = S::Role;
5858+ type Did = Set<members::did>;
5959 }
6060 /// Marker types for field names
6161 #[allow(non_camel_case_types)]
6262 pub mod members {
6363- ///Marker type for the `did` field
6464- pub struct did(());
6563 ///Marker type for the `role` field
6664 pub struct role(());
6565+ ///Marker type for the `did` field
6666+ pub struct did(());
6767 }
6868}
6969···136136impl<'a, S> AddMemberBuilder<'a, S>
137137where
138138 S: add_member_state::State,
139139- S::Did: add_member_state::IsSet,
140139 S::Role: add_member_state::IsSet,
140140+ S::Did: add_member_state::IsSet,
141141{
142142 /// Build the final struct
143143 pub fn build(self) -> AddMember<'a> {
+48-48
crates/weaver-api/src/tools_ozone/verification.rs
···7474 }
7575 /// State trait tracking which required fields have been set
7676 pub trait State: sealed::Sealed {
7777+ type Issuer;
7778 type Subject;
7878- type Handle;
7979- type Uri;
8079 type DisplayName;
8181- type Issuer;
8080+ type Uri;
8181+ type Handle;
8282 type CreatedAt;
8383 }
8484 /// Empty state - all required fields are unset
8585 pub struct Empty(());
8686 impl sealed::Sealed for Empty {}
8787 impl State for Empty {
8888+ type Issuer = Unset;
8889 type Subject = Unset;
8989- type Handle = Unset;
9090- type Uri = Unset;
9190 type DisplayName = Unset;
9292- type Issuer = Unset;
9191+ type Uri = Unset;
9292+ type Handle = Unset;
9393 type CreatedAt = Unset;
9494+ }
9595+ ///State transition - sets the `issuer` field to Set
9696+ pub struct SetIssuer<S: State = Empty>(PhantomData<fn() -> S>);
9797+ impl<S: State> sealed::Sealed for SetIssuer<S> {}
9898+ impl<S: State> State for SetIssuer<S> {
9999+ type Issuer = Set<members::issuer>;
100100+ type Subject = S::Subject;
101101+ type DisplayName = S::DisplayName;
102102+ type Uri = S::Uri;
103103+ type Handle = S::Handle;
104104+ type CreatedAt = S::CreatedAt;
94105 }
95106 ///State transition - sets the `subject` field to Set
96107 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
97108 impl<S: State> sealed::Sealed for SetSubject<S> {}
98109 impl<S: State> State for SetSubject<S> {
110110+ type Issuer = S::Issuer;
99111 type Subject = Set<members::subject>;
100100- type Handle = S::Handle;
101101- type Uri = S::Uri;
102112 type DisplayName = S::DisplayName;
103103- type Issuer = S::Issuer;
113113+ type Uri = S::Uri;
114114+ type Handle = S::Handle;
104115 type CreatedAt = S::CreatedAt;
105116 }
106106- ///State transition - sets the `handle` field to Set
107107- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
108108- impl<S: State> sealed::Sealed for SetHandle<S> {}
109109- impl<S: State> State for SetHandle<S> {
117117+ ///State transition - sets the `display_name` field to Set
118118+ pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
119119+ impl<S: State> sealed::Sealed for SetDisplayName<S> {}
120120+ impl<S: State> State for SetDisplayName<S> {
121121+ type Issuer = S::Issuer;
110122 type Subject = S::Subject;
111111- type Handle = Set<members::handle>;
123123+ type DisplayName = Set<members::display_name>;
112124 type Uri = S::Uri;
113113- type DisplayName = S::DisplayName;
114114- type Issuer = S::Issuer;
125125+ type Handle = S::Handle;
115126 type CreatedAt = S::CreatedAt;
116127 }
117128 ///State transition - sets the `uri` field to Set
118129 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
119130 impl<S: State> sealed::Sealed for SetUri<S> {}
120131 impl<S: State> State for SetUri<S> {
121121- type Subject = S::Subject;
122122- type Handle = S::Handle;
123123- type Uri = Set<members::uri>;
124124- type DisplayName = S::DisplayName;
125132 type Issuer = S::Issuer;
126126- type CreatedAt = S::CreatedAt;
127127- }
128128- ///State transition - sets the `display_name` field to Set
129129- pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
130130- impl<S: State> sealed::Sealed for SetDisplayName<S> {}
131131- impl<S: State> State for SetDisplayName<S> {
132133 type Subject = S::Subject;
134134+ type DisplayName = S::DisplayName;
135135+ type Uri = Set<members::uri>;
133136 type Handle = S::Handle;
134134- type Uri = S::Uri;
135135- type DisplayName = Set<members::display_name>;
136136- type Issuer = S::Issuer;
137137 type CreatedAt = S::CreatedAt;
138138 }
139139- ///State transition - sets the `issuer` field to Set
140140- pub struct SetIssuer<S: State = Empty>(PhantomData<fn() -> S>);
141141- impl<S: State> sealed::Sealed for SetIssuer<S> {}
142142- impl<S: State> State for SetIssuer<S> {
139139+ ///State transition - sets the `handle` field to Set
140140+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
141141+ impl<S: State> sealed::Sealed for SetHandle<S> {}
142142+ impl<S: State> State for SetHandle<S> {
143143+ type Issuer = S::Issuer;
143144 type Subject = S::Subject;
144144- type Handle = S::Handle;
145145+ type DisplayName = S::DisplayName;
145146 type Uri = S::Uri;
146146- type DisplayName = S::DisplayName;
147147- type Issuer = Set<members::issuer>;
147147+ type Handle = Set<members::handle>;
148148 type CreatedAt = S::CreatedAt;
149149 }
150150 ///State transition - sets the `created_at` field to Set
151151 pub struct SetCreatedAt<S: State = Empty>(PhantomData<fn() -> S>);
152152 impl<S: State> sealed::Sealed for SetCreatedAt<S> {}
153153 impl<S: State> State for SetCreatedAt<S> {
154154+ type Issuer = S::Issuer;
154155 type Subject = S::Subject;
155155- type Handle = S::Handle;
156156+ type DisplayName = S::DisplayName;
156157 type Uri = S::Uri;
157157- type DisplayName = S::DisplayName;
158158- type Issuer = S::Issuer;
158158+ type Handle = S::Handle;
159159 type CreatedAt = Set<members::created_at>;
160160 }
161161 /// Marker types for field names
162162 #[allow(non_camel_case_types)]
163163 pub mod members {
164164+ ///Marker type for the `issuer` field
165165+ pub struct issuer(());
164166 ///Marker type for the `subject` field
165167 pub struct subject(());
168168+ ///Marker type for the `display_name` field
169169+ pub struct display_name(());
170170+ ///Marker type for the `uri` field
171171+ pub struct uri(());
166172 ///Marker type for the `handle` field
167173 pub struct handle(());
168168- ///Marker type for the `uri` field
169169- pub struct uri(());
170170- ///Marker type for the `display_name` field
171171- pub struct display_name(());
172172- ///Marker type for the `issuer` field
173173- pub struct issuer(());
174174 ///Marker type for the `created_at` field
175175 pub struct created_at(());
176176 }
···479479impl<'a, S> VerificationViewBuilder<'a, S>
480480where
481481 S: verification_view_state::State,
482482+ S::Issuer: verification_view_state::IsSet,
482483 S::Subject: verification_view_state::IsSet,
483483- S::Handle: verification_view_state::IsSet,
484484- S::Uri: verification_view_state::IsSet,
485484 S::DisplayName: verification_view_state::IsSet,
486486- S::Issuer: verification_view_state::IsSet,
485485+ S::Uri: verification_view_state::IsSet,
486486+ S::Handle: verification_view_state::IsSet,
487487 S::CreatedAt: verification_view_state::IsSet,
488488{
489489 /// Build the final struct
···3636 }
3737 /// State trait tracking which required fields have been set
3838 pub trait State: sealed::Sealed {
3939- type Error;
4039 type Subject;
4040+ type Error;
4141 }
4242 /// Empty state - all required fields are unset
4343 pub struct Empty(());
4444 impl sealed::Sealed for Empty {}
4545 impl State for Empty {
4646- type Error = Unset;
4746 type Subject = Unset;
4848- }
4949- ///State transition - sets the `error` field to Set
5050- pub struct SetError<S: State = Empty>(PhantomData<fn() -> S>);
5151- impl<S: State> sealed::Sealed for SetError<S> {}
5252- impl<S: State> State for SetError<S> {
5353- type Error = Set<members::error>;
5454- type Subject = S::Subject;
4747+ type Error = Unset;
5548 }
5649 ///State transition - sets the `subject` field to Set
5750 pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
5851 impl<S: State> sealed::Sealed for SetSubject<S> {}
5952 impl<S: State> State for SetSubject<S> {
6060- type Error = S::Error;
6153 type Subject = Set<members::subject>;
5454+ type Error = S::Error;
5555+ }
5656+ ///State transition - sets the `error` field to Set
5757+ pub struct SetError<S: State = Empty>(PhantomData<fn() -> S>);
5858+ impl<S: State> sealed::Sealed for SetError<S> {}
5959+ impl<S: State> State for SetError<S> {
6060+ type Subject = S::Subject;
6161+ type Error = Set<members::error>;
6262 }
6363 /// Marker types for field names
6464 #[allow(non_camel_case_types)]
6565 pub mod members {
6666- ///Marker type for the `error` field
6767- pub struct error(());
6866 ///Marker type for the `subject` field
6967 pub struct subject(());
6868+ ///Marker type for the `error` field
6969+ pub struct error(());
7070 }
7171}
7272···139139impl<'a, S> GrantErrorBuilder<'a, S>
140140where
141141 S: grant_error_state::State,
142142- S::Error: grant_error_state::IsSet,
143142 S::Subject: grant_error_state::IsSet,
143143+ S::Error: grant_error_state::IsSet,
144144{
145145 /// Build the final struct
146146 pub fn build(self) -> GrantError<'a> {
···640640 }
641641 /// State trait tracking which required fields have been set
642642 pub trait State: sealed::Sealed {
643643- type Subject;
644644- type DisplayName;
645643 type Handle;
644644+ type DisplayName;
645645+ type Subject;
646646 }
647647 /// Empty state - all required fields are unset
648648 pub struct Empty(());
649649 impl sealed::Sealed for Empty {}
650650 impl State for Empty {
651651+ type Handle = Unset;
652652+ type DisplayName = Unset;
651653 type Subject = Unset;
652652- type DisplayName = Unset;
653653- type Handle = Unset;
654654 }
655655- ///State transition - sets the `subject` field to Set
656656- pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
657657- impl<S: State> sealed::Sealed for SetSubject<S> {}
658658- impl<S: State> State for SetSubject<S> {
659659- type Subject = Set<members::subject>;
655655+ ///State transition - sets the `handle` field to Set
656656+ pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
657657+ impl<S: State> sealed::Sealed for SetHandle<S> {}
658658+ impl<S: State> State for SetHandle<S> {
659659+ type Handle = Set<members::handle>;
660660 type DisplayName = S::DisplayName;
661661- type Handle = S::Handle;
661661+ type Subject = S::Subject;
662662 }
663663 ///State transition - sets the `display_name` field to Set
664664 pub struct SetDisplayName<S: State = Empty>(PhantomData<fn() -> S>);
665665 impl<S: State> sealed::Sealed for SetDisplayName<S> {}
666666 impl<S: State> State for SetDisplayName<S> {
667667- type Subject = S::Subject;
668668- type DisplayName = Set<members::display_name>;
669667 type Handle = S::Handle;
668668+ type DisplayName = Set<members::display_name>;
669669+ type Subject = S::Subject;
670670 }
671671- ///State transition - sets the `handle` field to Set
672672- pub struct SetHandle<S: State = Empty>(PhantomData<fn() -> S>);
673673- impl<S: State> sealed::Sealed for SetHandle<S> {}
674674- impl<S: State> State for SetHandle<S> {
675675- type Subject = S::Subject;
671671+ ///State transition - sets the `subject` field to Set
672672+ pub struct SetSubject<S: State = Empty>(PhantomData<fn() -> S>);
673673+ impl<S: State> sealed::Sealed for SetSubject<S> {}
674674+ impl<S: State> State for SetSubject<S> {
675675+ type Handle = S::Handle;
676676 type DisplayName = S::DisplayName;
677677- type Handle = Set<members::handle>;
677677+ type Subject = Set<members::subject>;
678678 }
679679 /// Marker types for field names
680680 #[allow(non_camel_case_types)]
681681 pub mod members {
682682+ ///Marker type for the `handle` field
683683+ pub struct handle(());
684684+ ///Marker type for the `display_name` field
685685+ pub struct display_name(());
682686 ///Marker type for the `subject` field
683687 pub struct subject(());
684684- ///Marker type for the `display_name` field
685685- pub struct display_name(());
686686- ///Marker type for the `handle` field
687687- pub struct handle(());
688688 }
689689}
690690···797797impl<'a, S> VerificationInputBuilder<'a, S>
798798where
799799 S: verification_input_state::State,
800800- S::Subject: verification_input_state::IsSet,
801801- S::DisplayName: verification_input_state::IsSet,
802800 S::Handle: verification_input_state::IsSet,
801801+ S::DisplayName: verification_input_state::IsSet,
802802+ S::Subject: verification_input_state::IsSet,
803803{
804804 /// Build the final struct
805805 pub fn build(self) -> VerificationInput<'a> {
···236236 }
237237 /// State trait tracking which required fields have been set
238238 pub trait State: sealed::Sealed {
239239- type Error;
240239 type Uri;
240240+ type Error;
241241 }
242242 /// Empty state - all required fields are unset
243243 pub struct Empty(());
244244 impl sealed::Sealed for Empty {}
245245 impl State for Empty {
246246- type Error = Unset;
247246 type Uri = Unset;
248248- }
249249- ///State transition - sets the `error` field to Set
250250- pub struct SetError<S: State = Empty>(PhantomData<fn() -> S>);
251251- impl<S: State> sealed::Sealed for SetError<S> {}
252252- impl<S: State> State for SetError<S> {
253253- type Error = Set<members::error>;
254254- type Uri = S::Uri;
247247+ type Error = Unset;
255248 }
256249 ///State transition - sets the `uri` field to Set
257250 pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
258251 impl<S: State> sealed::Sealed for SetUri<S> {}
259252 impl<S: State> State for SetUri<S> {
260260- type Error = S::Error;
261253 type Uri = Set<members::uri>;
254254+ type Error = S::Error;
255255+ }
256256+ ///State transition - sets the `error` field to Set
257257+ pub struct SetError<S: State = Empty>(PhantomData<fn() -> S>);
258258+ impl<S: State> sealed::Sealed for SetError<S> {}
259259+ impl<S: State> State for SetError<S> {
260260+ type Uri = S::Uri;
261261+ type Error = Set<members::error>;
262262 }
263263 /// Marker types for field names
264264 #[allow(non_camel_case_types)]
265265 pub mod members {
266266- ///Marker type for the `error` field
267267- pub struct error(());
268266 ///Marker type for the `uri` field
269267 pub struct uri(());
268268+ ///Marker type for the `error` field
269269+ pub struct error(());
270270 }
271271}
272272···339339impl<'a, S> RevokeErrorBuilder<'a, S>
340340where
341341 S: revoke_error_state::State,
342342- S::Error: revoke_error_state::IsSet,
343342 S::Uri: revoke_error_state::IsSet,
343343+ S::Error: revoke_error_state::IsSet,
344344{
345345 /// Build the final struct
346346 pub fn build(self) -> RevokeError<'a> {
···11//! AuthorList component for displaying multiple authors with progressive disclosure.
2233-use crate::Route;
33+use crate::components::{AppLink, AppLinkTarget};
44use dioxus::prelude::*;
55use jacquard::IntoStatic;
66use jacquard::types::ident::AtIdentifier;
···210210 let handle_display = info.handle.as_ref();
211211212212 rsx! {
213213- Link {
214214- to: Route::RepositoryIndex {
213213+ AppLink {
214214+ to: AppLinkTarget::Profile {
215215 ident: AtIdentifier::Handle(info.handle.clone())
216216 },
217217- class: "embed-author author-block",
217217+ class: Some("embed-author author-block".to_string()),
218218 if let Some(ref avatar) = info.avatar_url {
219219 img {
220220 class: "embed-avatar",
···241241 .unwrap_or_else(|| info.handle.as_ref());
242242243243 rsx! {
244244- Link {
245245- to: Route::RepositoryIndex {
244244+ AppLink {
245245+ to: AppLinkTarget::Profile {
246246 ident: AtIdentifier::Handle(info.handle.clone())
247247 },
248248- class: "author-inline",
248248+ class: Some("author-inline".to_string()),
249249 "{display}"
250250 }
251251 }
+17-16
crates/weaver-app/src/components/entry.rs
···11#![allow(non_snake_case)]
2233+use crate::components::{AppLink, AppLinkTarget};
34use crate::Route;
45#[cfg(feature = "server")]
56use crate::blobcache::BlobCache;
···305306 author_count: usize,
306307 ident: AtIdentifier<'static>,
307308) -> Element {
308308- use crate::Route;
309309 use crate::auth::AuthState;
310310 use jacquard::from_data;
311311 use weaver_api::sh_weaver::notebook::entry::Entry;
···384384 div { class: "entry-card",
385385 div { class: "entry-card-meta",
386386 div { class: "entry-card-header",
387387- Link {
388388- to: Route::EntryPage {
387387+ AppLink {
388388+ to: AppLinkTarget::Entry {
389389 ident: ident.clone(),
390390 book_title: book_title.clone(),
391391- title: entry_path.clone().into()
391391+ entry_path: entry_path.clone().into(),
392392 },
393393- class: "entry-card-title-link",
393393+ class: Some("entry-card-title-link".to_string()),
394394 h3 { class: "entry-card-title", "{title}" }
395395 }
396396 div { class: "entry-card-date",
···453453 profile_ident: Option<AtIdentifier<'static>>,
454454 #[props(default)] on_pinned_changed: Option<EventHandler<bool>>,
455455) -> Element {
456456- use crate::Route;
457456 use crate::auth::AuthState;
458457459458 let title = entry_view
···517516 div { class: "entry-card feed-entry-card",
518517 // Header: title (and date if no author)
519518 div { class: "entry-card-header",
520520- Link {
521521- to: Route::StandaloneEntry {
519519+ AppLink {
520520+ to: AppLinkTarget::StandaloneEntry {
522521 ident: ident.clone(),
523523- rkey: rkey.clone().into()
522522+ rkey: rkey.clone(),
524523 },
525525- class: "entry-card-title-link",
524524+ class: Some("entry-card-title-link".to_string()),
526525 h3 { class: "entry-card-title", "{title}" }
527526 }
528527 // Date inline with title when no author shown
···588587 #[props(default)] word_count: Option<usize>,
589588 #[props(default)] reading_time_mins: Option<usize>,
590589) -> Element {
591591- let navigator = use_navigator();
590590+ use crate::components::use_app_navigate;
591591+592592+ let navigate = use_app_navigate();
592593593594 let title = entry_view
594595 .title
···603604 let nav_ident = ident.clone();
604605 let on_removed = move |_| {
605606 if let Some(ref title) = nav_book_title {
606606- navigator.push(Route::NotebookIndex {
607607+ navigate(AppLinkTarget::Notebook {
607608 ident: nav_ident.clone(),
608609 book_title: title.clone(),
609610 });
···697698 };
698699699700 rsx! {
700700- Link {
701701- to: Route::EntryPage {
701701+ AppLink {
702702+ to: AppLinkTarget::Entry {
702703 ident: ident.clone(),
703704 book_title: book_title.clone(),
704704- title: entry_path.into()
705705+ entry_path: entry_path.into(),
705706 },
706706- class: "nav-button nav-button-{direction}",
707707+ class: Some(format!("nav-button nav-button-{}", direction)),
707708 if title_first {
708709 span { class: "nav-title", "{entry_title}" }
709710 span { class: "nav-arrow", "{arrow}" }
+21-17
crates/weaver-app/src/components/entry_actions.rs
···11//! Action buttons for entries (edit, delete, remove from notebook, pin/unpin).
2233-use crate::Route;
33+use crate::components::{AppLink, AppLinkTarget, use_app_navigate};
44use crate::auth::AuthState;
55use crate::components::button::{Button, ButtonVariant};
66use crate::components::dialog::{DialogContent, DialogDescription, DialogRoot, DialogTitle};
···5252pub fn EntryActions(props: EntryActionsProps) -> Element {
5353 let auth_state = use_context::<Signal<AuthState>>();
5454 let fetcher = use_context::<Fetcher>();
5555- let navigator = use_navigator();
56555756 let mut show_delete_confirm = use_signal(|| false);
5857 let mut show_remove_confirm = use_signal(|| false);
···9089 None => return rsx! {}, // Can't edit without rkey
9190 };
92919393- // Build edit route based on whether entry is in a notebook
9292+ // Build edit link target based on whether entry is in a notebook
9493 let ident = props.entry_uri.authority().clone();
9595- let edit_route = if props.in_notebook {
9494+ let edit_target = if props.in_notebook {
9695 if let Some(ref notebook) = props.notebook_title {
9797- Route::NotebookEntryEdit {
9898- ident: ident.into_static(),
9696+ AppLinkTarget::EntryEdit {
9797+ ident: ident.clone().into_static(),
9998 book_title: notebook.clone(),
10099 rkey: rkey.clone().into(),
101100 }
102101 } else {
103103- Route::StandaloneEntryEdit {
104104- ident: ident.into_static(),
102102+ AppLinkTarget::StandaloneEntryEdit {
103103+ ident: ident.clone().into_static(),
105104 rkey: rkey.clone().into(),
106105 }
107106 }
108107 } else {
109109- Route::StandaloneEntryEdit {
110110- ident: ident.into_static(),
108108+ AppLinkTarget::StandaloneEntryEdit {
109109+ ident: ident.clone().into_static(),
111110 rkey: rkey.clone().into(),
112111 }
113112 };
114113114114+ // Get navigation function for post-delete redirect
115115+ let navigate = use_app_navigate();
116116+115117 let entry_uri_for_delete = props.entry_uri.clone();
116118 let entry_title = props.entry_title.clone();
117119···119121 let handle_delete = move |_| {
120122 let fetcher = delete_fetcher.clone();
121123 let uri = entry_uri_for_delete.clone();
122122- let navigator = navigator.clone();
124124+ let navigate = navigate.clone();
123125124126 spawn(async move {
125127 use jacquard::prelude::*;
···142144 };
143145144146 let request = DeleteRecord::new()
145145- .repo(AtIdentifier::Did(did))
147147+ .repo(AtIdentifier::Did(did.clone()))
146148 .collection(collection.clone())
147149 .rkey(rkey.clone())
148150 .build();
···150152 match client.send(request).await {
151153 Ok(_) => {
152154 show_delete_confirm.set(false);
153153- // Navigate back to home after delete
154154- navigator.push(Route::Home {});
155155+ // Navigate to profile after delete
156156+ navigate(AppLinkTarget::Profile {
157157+ ident: AtIdentifier::Did(did),
158158+ });
155159 }
156160 Err(e) => {
157161 error.set(Some(format!("Delete failed: {:?}", e)));
···435439436440 div { class: "entry-actions",
437441 // Edit button (always visible for owner)
438438- Link {
439439- to: edit_route,
440440- class: "entry-action-link",
442442+ AppLink {
443443+ to: edit_target,
444444+ class: Some("entry-action-link".to_string()),
441445 Button {
442446 variant: ButtonVariant::Ghost,
443447 "Edit"
+6
crates/weaver-app/src/components/mod.rs
···22//! They can be used to defined common UI elements like buttons, forms, and modals. In this template, we define a Hero
33//! component and an Echo component for fullstack apps to be used in our app.
4455+pub mod app_link;
66+pub use app_link::{
77+ AppLink, AppLinkTarget, use_app_navigate, use_main_navigator_provider,
88+ use_subdomain_navigator_provider,
99+};
1010+511pub mod css;
612pub use css::NotebookCss;
713
···11#![allow(non_snake_case)]
2233-use crate::Route;
33+use crate::components::{AppLink, AppLinkTarget};
44use crate::components::AuthorList;
55use crate::components::button::{Button, ButtonVariant};
66use dioxus::prelude::*;
···9393 if is_owner {
9494 if let Some(ref owner_ident) = ident {
9595 div { class: "notebook-cover-actions",
9696- Link {
9797- to: Route::NewDraft {
9696+ AppLink {
9797+ to: AppLinkTarget::NewDraft {
9898 ident: owner_ident.clone(),
9999 notebook: Some(SmolStr::from(title.as_str()))
100100 },
101101- class: "notebook-cover-action-link",
101101+ class: Some("notebook-cover-action-link".to_string()),
102102 Button {
103103 variant: ButtonVariant::Outline,
104104 "+ Add Entry"
+2-2
crates/weaver-app/src/components/record_editor.rs
···13271327 Ok(response) => {
13281328 if let Ok(output) = response.into_output() {
13291329 tracing::info!("Record created: {}", output.uri);
13301330- let link = format!("{}/record/{}", crate::env::WEAVER_APP_DOMAIN, output.uri);
13301330+ let link = format!("{}/record/{}", crate::env::WEAVER_APP_HOST, output.uri);
13311331 nav.push(link);
13321332 }
13331333 }
···13781378 }
1379137913801380 tracing::info!("Record replaced: {}", create_output.uri);
13811381- let link = format!("{}/record/{}", crate::env::WEAVER_APP_DOMAIN, create_output.uri);
13811381+ let link = format!("{}/record/{}", crate::env::WEAVER_APP_HOST, create_output.uri);
13821382 nav.push(link);
13831383 }
13841384 }
+1-1
crates/weaver-app/src/components/record_view.rs
···398398#[component]
399399pub fn HighlightedUri(uri: AtUri<'static>) -> Element {
400400 let s = uri.as_str();
401401- let link = format!("{}/record/{}", crate::env::WEAVER_APP_DOMAIN, s);
401401+ let link = format!("{}/record/{}", crate::env::WEAVER_APP_HOST, s);
402402403403 if let Some(rest) = s.strip_prefix("at://") {
404404 let parts: Vec<&str> = rest.splitn(3, '/').collect();
+160
crates/weaver-app/src/host_mode.rs
···11+//! Host mode context for subdomain and custom domain routing.
22+33+use crate::env::WEAVER_APP_HOST;
44+use jacquard::smol_str::{SmolStr, format_smolstr};
55+use jacquard::types::string::AtIdentifier;
66+use serde::{Deserialize, Serialize};
77+88+/// Context for subdomain routing - identifies the notebook being served.
99+#[derive(Clone, Debug, PartialEq, Eq, Serialize, Deserialize)]
1010+#[serde(bound(deserialize = ""))]
1111+pub struct SubdomainContext {
1212+ /// DID of the notebook owner.
1313+ #[serde(deserialize_with = "deserialize_static_ident")]
1414+ pub owner: AtIdentifier<'static>,
1515+ /// Notebook path (same as subdomain).
1616+ pub notebook_path: SmolStr,
1717+1818+ /// Notebook title.
1919+ pub notebook_title: SmolStr,
2020+ /// Notebook rkey for direct lookups.
2121+ pub notebook_rkey: SmolStr,
2222+}
2323+2424+fn deserialize_static_ident<'de, D>(deserializer: D) -> Result<AtIdentifier<'static>, D::Error>
2525+where
2626+ D: serde::Deserializer<'de>,
2727+{
2828+ use jacquard::IntoStatic;
2929+ let did: AtIdentifier<'de> = Deserialize::deserialize(deserializer)?;
3030+ Ok(did.into_static())
3131+}
3232+3333+impl SubdomainContext {
3434+ /// Get the owner as an AtIdentifier for route parameters.
3535+ pub fn owner_ident(&self) -> AtIdentifier<'static> {
3636+ self.owner.clone()
3737+ }
3838+}
3939+4040+/// Link mode for generating appropriate URLs based on host context.
4141+///
4242+/// Components use this context to generate links that work on both
4343+/// the main domain and subdomain hosting.
4444+#[derive(Clone, Debug, Default, PartialEq, Eq)]
4545+pub enum LinkMode {
4646+ /// Main domain - full paths with /:ident/:notebook/:entry
4747+ #[default]
4848+ MainDomain,
4949+ /// Subdomain - simplified paths like /:entry
5050+ Subdomain,
5151+}
5252+5353+impl LinkMode {
5454+ /// Check if we're in subdomain mode.
5555+ pub fn is_subdomain(&self) -> bool {
5656+ matches!(self, LinkMode::Subdomain)
5757+ }
5858+5959+ /// Generate link to a notebook entry by title.
6060+ pub fn entry_link(
6161+ &self,
6262+ ident: &AtIdentifier<'_>,
6363+ book_title: &str,
6464+ entry_title: &str,
6565+ ) -> SmolStr {
6666+ match self {
6767+ LinkMode::MainDomain => format_smolstr!("/{}/{}/{}", ident, book_title, entry_title),
6868+ LinkMode::Subdomain => format_smolstr!("/{}", entry_title),
6969+ }
7070+ }
7171+7272+ /// Generate link to a notebook entry by rkey.
7373+ pub fn entry_rkey_link(
7474+ &self,
7575+ ident: &AtIdentifier<'_>,
7676+ book_title: &str,
7777+ rkey: &str,
7878+ ) -> SmolStr {
7979+ match self {
8080+ LinkMode::MainDomain => format_smolstr!("/{}/{}/e/{}", ident, book_title, rkey),
8181+ LinkMode::Subdomain => format_smolstr!("/e/{}", rkey),
8282+ }
8383+ }
8484+8585+ /// Generate link to edit a notebook entry by rkey.
8686+ pub fn entry_edit_link(
8787+ &self,
8888+ ident: &AtIdentifier<'_>,
8989+ book_title: &str,
9090+ rkey: &str,
9191+ ) -> SmolStr {
9292+ match self {
9393+ LinkMode::MainDomain => format_smolstr!("/{}/{}/e/{}/edit", ident, book_title, rkey),
9494+ LinkMode::Subdomain => format_smolstr!("/e/{}/edit", rkey),
9595+ }
9696+ }
9797+9898+ /// Generate link to a notebook index.
9999+ pub fn notebook_link(&self, ident: &AtIdentifier<'_>, book_title: &str) -> SmolStr {
100100+ match self {
101101+ LinkMode::MainDomain => format_smolstr!("/{}/{}", ident, book_title),
102102+ LinkMode::Subdomain => SmolStr::new_static("/"),
103103+ }
104104+ }
105105+106106+ /// Generate link to a profile/repository.
107107+ pub fn profile_link(&self, ident: &AtIdentifier<'_>) -> SmolStr {
108108+ match self {
109109+ LinkMode::MainDomain => format_smolstr!("/{}", ident),
110110+ LinkMode::Subdomain => format_smolstr!("/u/{}", ident),
111111+ }
112112+ }
113113+114114+ /// Generate link to a standalone entry.
115115+ pub fn standalone_entry_link(&self, ident: &AtIdentifier<'_>, rkey: &str) -> SmolStr {
116116+ match self {
117117+ LinkMode::MainDomain => format_smolstr!("/{}/e/{}", ident, rkey),
118118+ // Standalone entries don't exist in subdomain mode - link to main domain
119119+ LinkMode::Subdomain => format_smolstr!("{}/{}/e/{}", WEAVER_APP_HOST, ident, rkey),
120120+ }
121121+ }
122122+123123+ /// Generate link to edit a standalone entry.
124124+ pub fn standalone_entry_edit_link(&self, ident: &AtIdentifier<'_>, rkey: &str) -> SmolStr {
125125+ match self {
126126+ LinkMode::MainDomain => format_smolstr!("/{}/e/{}/edit", ident, rkey),
127127+ // Edit on main domain
128128+ LinkMode::Subdomain => format_smolstr!("{}/{}/e/{}/edit", WEAVER_APP_HOST, ident, rkey),
129129+ }
130130+ }
131131+132132+ /// Generate link to create a new draft.
133133+ pub fn new_draft_link(&self, ident: &AtIdentifier<'_>, notebook: Option<&str>) -> SmolStr {
134134+ match (self, notebook) {
135135+ (LinkMode::MainDomain, Some(nb)) => format_smolstr!("/{}/new?notebook={}", ident, nb),
136136+ (LinkMode::MainDomain, None) => format_smolstr!("/{}/new", ident),
137137+ // Drafts are on main domain
138138+ (LinkMode::Subdomain, Some(nb)) => {
139139+ format_smolstr!("{}/{}/new?notebook={}", WEAVER_APP_HOST, ident, nb)
140140+ }
141141+ (LinkMode::Subdomain, None) => format_smolstr!("{}/{}/new", WEAVER_APP_HOST, ident),
142142+ }
143143+ }
144144+145145+ /// Generate link to drafts list.
146146+ pub fn drafts_link(&self, ident: &AtIdentifier<'_>) -> SmolStr {
147147+ match self {
148148+ LinkMode::MainDomain => format_smolstr!("/{}/drafts", ident),
149149+ LinkMode::Subdomain => format_smolstr!("{}/{}/drafts", WEAVER_APP_HOST, ident),
150150+ }
151151+ }
152152+153153+ /// Generate link to invites page.
154154+ pub fn invites_link(&self, ident: &AtIdentifier<'_>) -> SmolStr {
155155+ match self {
156156+ LinkMode::MainDomain => format_smolstr!("/{}/invites", ident),
157157+ LinkMode::Subdomain => format_smolstr!("{}/{}/invites", WEAVER_APP_HOST, ident),
158158+ }
159159+ }
160160+}
+91
crates/weaver-app/src/lib.rs
···2222pub mod data;
2323pub mod env;
2424pub mod fetch;
2525+pub mod host_mode;
2526#[cfg(feature = "server")]
2627pub mod og;
2728pub mod perf;
2829pub mod record_utils;
2930pub mod service_worker;
3131+3232+pub mod subdomain_app;
3033pub mod views;
31343535+pub use host_mode::{LinkMode, SubdomainContext};
3636+pub use subdomain_app::SubdomainApp;
3737+pub use subdomain_app::SubdomainRoute;
3838+3239use auth::{AuthState, AuthStore};
3340use components::{EntryPage, Repository, RepositoryIndex};
3441use config::{Config, OAuthConfig};
···3946 NotebookIndex, NotebookPage, PcktEntry, PcktEntryBlogNsid, PcktEntryNsid, PrivacyPage,
4047 RecordIndex, RecordPage, StandaloneEntry, StandaloneEntryEdit, StandaloneEntryNsid, TermsPage,
4148 WhiteWindEntry, WhiteWindEntryNsid,
4949+};
5050+5151+use crate::{
5252+ env::WEAVER_APP_DOMAIN,
5353+ subdomain_app::{extract_subdomain, lookup_subdomain_context},
4254};
43554456#[derive(Debug, Clone, Routable, PartialEq)]
···133145 ClientData::new_public(CONFIG.oauth.clone()),
134146 ))
135147 });
148148+149149+ #[cfg(feature = "fullstack-server")]
150150+ let ctx_resource = use_server_future({
151151+ let fetcher = fetcher.clone();
152152+ move || {
153153+ let fetcher = fetcher.clone();
154154+ async move {
155155+ use dioxus::fullstack::FullstackContext;
156156+ use http::header::HOST;
157157+158158+ // Get host header from request
159159+ let Some(ctx) = FullstackContext::current() else {
160160+ tracing::warn!("No FullstackContext available");
161161+ return None;
162162+ };
163163+ let parts = ctx.parts_mut();
164164+165165+ let Some(host_header) = parts.headers.get(HOST) else {
166166+ tracing::warn!("No Host header in request");
167167+ return None;
168168+ };
169169+ let Ok(host) = host_header.to_str() else {
170170+ tracing::warn!("Host header not valid UTF-8");
171171+ return None;
172172+ };
173173+ tracing::info!(host, "Subdomain detection: got host");
174174+175175+ let host_str = host.split(':').next().unwrap_or(host);
176176+ let Some(subdomain) = extract_subdomain(host_str, WEAVER_APP_DOMAIN) else {
177177+ tracing::info!(host_str, domain = WEAVER_APP_DOMAIN, "Not a subdomain request");
178178+ return None;
179179+ };
180180+ tracing::info!(subdomain, "Subdomain detection: extracted subdomain");
181181+182182+ // Look up notebook by global path
183183+ let result = lookup_subdomain_context(&fetcher, &subdomain).await;
184184+ if result.is_none() {
185185+ tracing::warn!(subdomain, "Notebook lookup failed for subdomain");
186186+ }
187187+ result
188188+ }
189189+ }
190190+ })?;
191191+192192+ #[cfg(feature = "fullstack-server")]
193193+ let ctx = match &*ctx_resource.read() {
194194+ Some(ctx) => ctx.clone(),
195195+ None => return rsx! { div { "Loading..." } },
196196+ };
197197+198198+ #[cfg(not(feature = "fullstack-server"))]
199199+ let ctx = None::<SubdomainContext>;
200200+136201 let auth_state = use_signal(|| AuthState::default());
137202 #[allow(unused)]
138203 let auth_state = use_context_provider(|| auth_state);
204204+205205+ // Provide link mode for router-agnostic link generation (subdomain mode)
206206+ let sub = use_context_provider(|| {
207207+ if ctx.is_some() {
208208+ LinkMode::Subdomain
209209+ } else {
210210+ LinkMode::MainDomain
211211+ }
212212+ });
213213+139214 #[cfg(all(target_family = "wasm", target_os = "unknown"))]
140215 let restore_result = {
141216 let fetcher = fetcher.clone();
···152227 use_effect(move || {
153228 let fetcher = fetcher.clone();
154229 spawn(async move {
230230+ use crate::service_worker;
231231+155232 tracing::info!("Registering service worker");
156233 let _ = service_worker::register_service_worker().await;
157234 });
···161238 #[cfg(all(target_family = "wasm", target_os = "unknown"))]
162239 use_context_provider(|| restore_result);
163240241241+ if sub == LinkMode::Subdomain {
242242+ use_context_provider(|| ctx.unwrap());
243243+ rsx! {
244244+ SubdomainApp {}
245245+ }
246246+ } else {
247247+ rsx! {
248248+ MainDomainApp {}
249249+ }
250250+ }
251251+}
252252+253253+#[component]
254254+pub fn MainDomainApp() -> Element {
164255 rsx! {
165256 document::Link { rel: "icon", href: FAVICON }
166257 // Preconnect for external fonts (before loading them)
+81-9
crates/weaver-app/src/main.rs
···11//! Weaver App main binary.
2233use dioxus::prelude::*;
44+55+#[cfg(feature = "server")]
46use std::sync::Arc;
5766-use weaver_app::{App, CONFIG, components, fetch};
88+#[cfg(feature = "server")]
99+use tower::Service;
1010+1111+#[cfg(feature = "server")]
1212+use weaver_app::{App, CONFIG, SubdomainApp, SubdomainContext, fetch};
1313+1414+#[cfg(not(feature = "server"))]
1515+use weaver_app::{App, SubdomainApp};
716817#[cfg(target_arch = "wasm32")]
918use lol_alloc::{FreeListAllocator, LockedAllocator};
···1221#[global_allocator]
1322static ALLOCATOR: LockedAllocator<FreeListAllocator> =
1423 LockedAllocator::new(FreeListAllocator::new());
2424+2525+/// Base domain for subdomain extraction.
2626+#[cfg(feature = "server")]
2727+const BASE_DOMAIN: &str = weaver_app::env::WEAVER_APP_DOMAIN;
2828+2929+/// Reserved subdomains that should not be used for notebooks.
3030+#[cfg(feature = "server")]
3131+const RESERVED_SUBDOMAINS: &[&str] = &[
3232+ "www", "api", "admin", "app", "auth", "cdn", "alpha", "beta", "staging", "index",
3333+];
15341635fn main() {
1736 // Set up better panic messages for wasm
···4968 let reg = Registry::default()
5069 .with(filter)
5170 .with(wasm_layer)
5252- .with(components::editor::LogCaptureLayer);
7171+ .with(weaver_app::components::editor::LogCaptureLayer);
53725473 let _ = set_global_default(reg);
5574 }
···6281 // Run `serve()` on the server only
6382 #[cfg(feature = "server")]
6483 dioxus::serve(|| async move {
6565- use axum::{
6666- extract::{Extension, Request},
6767- middleware,
6868- middleware::Next,
6969- routing::get,
7070- };
8484+ #[cfg(feature = "fullstack-server")]
8585+ use axum::middleware;
8686+ use axum::middleware::Next;
8787+ use axum::{Router, body::Body, extract::Request, response::Response, routing::get};
8888+ use axum_extra::extract::Host;
7189 use jacquard::oauth::{client::OAuthClient, session::ClientData};
7290 use std::convert::Infallible;
7391 use weaver_app::auth::AuthStore;
7492 use weaver_app::blobcache::BlobCache;
75937694 #[cfg(not(feature = "fullstack-server"))]
7777- let router = { axum::Router::new().merge(dioxus::server::router(App)) };
9595+ let router = { Router::new().merge(dioxus::server::router(App)) };
78967997 #[cfg(feature = "fullstack-server")]
8098 let router = {
···107125 #[cfg(not(feature = "server"))]
108126 dioxus::launch(App);
109127}
128128+129129+/// Extract subdomain from host if it matches base domain pattern.
130130+#[cfg(feature = "server")]
131131+fn extract_subdomain<'a>(host: &'a str, base: &str) -> Option<&'a str> {
132132+ let suffix = format!(".{}", base);
133133+ if host.ends_with(&suffix) && host.len() > suffix.len() {
134134+ Some(&host[..host.len() - suffix.len()])
135135+ } else {
136136+ None
137137+ }
138138+}
139139+140140+/// Look up notebook by global path.
141141+///
142142+/// Returns SubdomainContext if a notebook with publishGlobal=true exists for this path.
143143+#[cfg(feature = "server")]
144144+async fn lookup_global_notebook(
145145+ fetcher: &Arc<fetch::Fetcher>,
146146+ path: &str,
147147+) -> Option<SubdomainContext> {
148148+ use jacquard::IntoStatic;
149149+ use jacquard::smol_str::SmolStr;
150150+ use jacquard::smol_str::ToSmolStr;
151151+ use jacquard::types::string::Did;
152152+ use jacquard::xrpc::XrpcClient;
153153+ use weaver_api::sh_weaver::notebook::resolve_global_notebook::ResolveGlobalNotebook;
154154+155155+ let request = ResolveGlobalNotebook::new().path(path).build();
156156+157157+ match fetcher.send(request).await {
158158+ Ok(response) => {
159159+ let output = response.into_output().ok()?;
160160+ let notebook = output.notebook;
161161+162162+ let owner = notebook.uri.authority().clone().into_static();
163163+ let rkey = notebook.uri.rkey()?.0.to_smolstr();
164164+ let notebook_path = notebook
165165+ .path
166166+ .map(|p| SmolStr::new(p.as_ref()))
167167+ .unwrap_or_else(|| SmolStr::new(path));
168168+169169+ Some(SubdomainContext {
170170+ owner,
171171+ notebook_path,
172172+ notebook_rkey: rkey,
173173+ notebook_title: notebook.title.clone().unwrap_or_default().to_smolstr(),
174174+ })
175175+ }
176176+ Err(e) => {
177177+ tracing::debug!(path = path, error = %e, "Global notebook lookup failed");
178178+ None
179179+ }
180180+ }
181181+}
···2222/// routes will be rendered under the outlet inside this component
2323#[component]
2424pub fn Navbar() -> Element {
2525+ // Provide navigator for programmatic navigation in shared components
2626+ crate::components::use_main_navigator_provider();
2727+2528 let route = use_route::<Route>();
2629 tracing::trace!("Route: {:?}", route);
2730
+1-1
crates/weaver-app/src/views/record.rs
···2424 let input_uri = uri_input.read().clone();
2525 if !input_uri.is_empty() {
2626 if let Ok(parsed) = AtUri::new(&input_uri) {
2727- let link = format!("{}/record/{}", crate::env::WEAVER_APP_DOMAIN, parsed);
2727+ let link = format!("{}/record/{}", crate::env::WEAVER_APP_HOST, parsed);
2828 navigator.push(link);
2929 }
3030 }