pub mod badge;
pub mod branding;
pub mod broadcast;
pub mod chat;
pub mod graph;
pub mod ingest;
pub mod key;
pub mod live;
pub mod livestream;
pub mod metadata;
pub mod moderation;
pub mod multistream;
pub mod playback;
pub mod richtext;
pub mod segment;
pub mod server;
#[jacquard_derive::lexicon]
#[derive(
serde::Serialize,
serde::Deserialize,
Debug,
Clone,
PartialEq,
Eq,
jacquard_derive::IntoStatic
)]
#[serde(rename_all = "camelCase")]
pub struct BlockView<'a> {
#[serde(borrow)]
pub blocker: crate::app_bsky::actor::ProfileViewBasic<'a>,
#[serde(borrow)]
pub cid: jacquard_common::types::string::Cid<'a>,
pub indexed_at: jacquard_common::types::string::Datetime,
#[serde(borrow)]
pub record: crate::app_bsky::graph::block::Block<'a>,
#[serde(borrow)]
pub uri: jacquard_common::types::string::AtUri<'a>,
}
pub mod block_view_state {
pub use crate::builder_types::{Set, Unset, IsSet, IsUnset};
#[allow(unused)]
use ::core::marker::PhantomData;
mod sealed {
pub trait Sealed {}
}
pub trait State: sealed::Sealed {
type Blocker;
type IndexedAt;
type Cid;
type Uri;
type Record;
}
pub struct Empty(());
impl sealed::Sealed for Empty {}
impl State for Empty {
type Blocker = Unset;
type IndexedAt = Unset;
type Cid = Unset;
type Uri = Unset;
type Record = Unset;
}
pub struct SetBlocker<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetBlocker<S> {}
impl<S: State> State for SetBlocker<S> {
type Blocker = Set<members::blocker>;
type IndexedAt = S::IndexedAt;
type Cid = S::Cid;
type Uri = S::Uri;
type Record = S::Record;
}
pub struct SetIndexedAt<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetIndexedAt<S> {}
impl<S: State> State for SetIndexedAt<S> {
type Blocker = S::Blocker;
type IndexedAt = Set<members::indexed_at>;
type Cid = S::Cid;
type Uri = S::Uri;
type Record = S::Record;
}
pub struct SetCid<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetCid<S> {}
impl<S: State> State for SetCid<S> {
type Blocker = S::Blocker;
type IndexedAt = S::IndexedAt;
type Cid = Set<members::cid>;
type Uri = S::Uri;
type Record = S::Record;
}
pub struct SetUri<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetUri<S> {}
impl<S: State> State for SetUri<S> {
type Blocker = S::Blocker;
type IndexedAt = S::IndexedAt;
type Cid = S::Cid;
type Uri = Set<members::uri>;
type Record = S::Record;
}
pub struct SetRecord<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetRecord<S> {}
impl<S: State> State for SetRecord<S> {
type Blocker = S::Blocker;
type IndexedAt = S::IndexedAt;
type Cid = S::Cid;
type Uri = S::Uri;
type Record = Set<members::record>;
}
#[allow(non_camel_case_types)]
pub mod members {
pub struct blocker(());
pub struct indexed_at(());
pub struct cid(());
pub struct uri(());
pub struct record(());
}
}
pub struct BlockViewBuilder<'a, S: block_view_state::State> {
_phantom_state: ::core::marker::PhantomData<fn() -> S>,
__unsafe_private_named: (
::core::option::Option<crate::app_bsky::actor::ProfileViewBasic<'a>>,
::core::option::Option<jacquard_common::types::string::Cid<'a>>,
::core::option::Option<jacquard_common::types::string::Datetime>,
::core::option::Option<crate::app_bsky::graph::block::Block<'a>>,
::core::option::Option<jacquard_common::types::string::AtUri<'a>>,
),
_phantom: ::core::marker::PhantomData<&'a ()>,
}
impl<'a> BlockView<'a> {
pub fn new() -> BlockViewBuilder<'a, block_view_state::Empty> {
BlockViewBuilder::new()
}
}
impl<'a> BlockViewBuilder<'a, block_view_state::Empty> {
pub fn new() -> Self {
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: (None, None, None, None, None),
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::Blocker: block_view_state::IsUnset,
{
pub fn blocker(
mut self,
value: impl Into<crate::app_bsky::actor::ProfileViewBasic<'a>>,
) -> BlockViewBuilder<'a, block_view_state::SetBlocker<S>> {
self.__unsafe_private_named.0 = ::core::option::Option::Some(value.into());
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::Cid: block_view_state::IsUnset,
{
pub fn cid(
mut self,
value: impl Into<jacquard_common::types::string::Cid<'a>>,
) -> BlockViewBuilder<'a, block_view_state::SetCid<S>> {
self.__unsafe_private_named.1 = ::core::option::Option::Some(value.into());
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::IndexedAt: block_view_state::IsUnset,
{
pub fn indexed_at(
mut self,
value: impl Into<jacquard_common::types::string::Datetime>,
) -> BlockViewBuilder<'a, block_view_state::SetIndexedAt<S>> {
self.__unsafe_private_named.2 = ::core::option::Option::Some(value.into());
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::Record: block_view_state::IsUnset,
{
pub fn record(
mut self,
value: impl Into<crate::app_bsky::graph::block::Block<'a>>,
) -> BlockViewBuilder<'a, block_view_state::SetRecord<S>> {
self.__unsafe_private_named.3 = ::core::option::Option::Some(value.into());
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::Uri: block_view_state::IsUnset,
{
pub fn uri(
mut self,
value: impl Into<jacquard_common::types::string::AtUri<'a>>,
) -> BlockViewBuilder<'a, block_view_state::SetUri<S>> {
self.__unsafe_private_named.4 = ::core::option::Option::Some(value.into());
BlockViewBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> BlockViewBuilder<'a, S>
where
S: block_view_state::State,
S::Blocker: block_view_state::IsSet,
S::IndexedAt: block_view_state::IsSet,
S::Cid: block_view_state::IsSet,
S::Uri: block_view_state::IsSet,
S::Record: block_view_state::IsSet,
{
pub fn build(self) -> BlockView<'a> {
BlockView {
blocker: self.__unsafe_private_named.0.unwrap(),
cid: self.__unsafe_private_named.1.unwrap(),
indexed_at: self.__unsafe_private_named.2.unwrap(),
record: self.__unsafe_private_named.3.unwrap(),
uri: self.__unsafe_private_named.4.unwrap(),
extra_data: Default::default(),
}
}
pub fn build_with_data(
self,
extra_data: std::collections::BTreeMap<
jacquard_common::deps::smol_str::SmolStr,
jacquard_common::types::value::Data<'a>,
>,
) -> BlockView<'a> {
BlockView {
blocker: self.__unsafe_private_named.0.unwrap(),
cid: self.__unsafe_private_named.1.unwrap(),
indexed_at: self.__unsafe_private_named.2.unwrap(),
record: self.__unsafe_private_named.3.unwrap(),
uri: self.__unsafe_private_named.4.unwrap(),
extra_data: Some(extra_data),
}
}
}
fn lexicon_doc_place_stream_defs() -> ::jacquard_lexicon::lexicon::LexiconDoc<'static> {
::jacquard_lexicon::lexicon::LexiconDoc {
lexicon: ::jacquard_lexicon::lexicon::Lexicon::Lexicon1,
id: ::jacquard_common::CowStr::new_static("place.stream.defs"),
revision: None,
description: None,
defs: {
let mut map = ::alloc::collections::BTreeMap::new();
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static("blockView"),
::jacquard_lexicon::lexicon::LexUserType::Object(::jacquard_lexicon::lexicon::LexObject {
description: None,
required: Some(
vec![
::jacquard_common::deps::smol_str::SmolStr::new_static("uri"),
::jacquard_common::deps::smol_str::SmolStr::new_static("cid"),
::jacquard_common::deps::smol_str::SmolStr::new_static("blocker"),
::jacquard_common::deps::smol_str::SmolStr::new_static("record"),
::jacquard_common::deps::smol_str::SmolStr::new_static("indexedAt")
],
),
nullable: None,
properties: {
#[allow(unused_mut)]
let mut map = ::alloc::collections::BTreeMap::new();
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"blocker",
),
::jacquard_lexicon::lexicon::LexObjectProperty::Ref(::jacquard_lexicon::lexicon::LexRef {
description: None,
r#ref: ::jacquard_common::CowStr::new_static(
"app.bsky.actor.defs#profileViewBasic",
),
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"cid",
),
::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
description: None,
format: Some(
::jacquard_lexicon::lexicon::LexStringFormat::Cid,
),
default: None,
min_length: None,
max_length: None,
min_graphemes: None,
max_graphemes: None,
r#enum: None,
r#const: None,
known_values: None,
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"indexedAt",
),
::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
description: None,
format: Some(
::jacquard_lexicon::lexicon::LexStringFormat::Datetime,
),
default: None,
min_length: None,
max_length: None,
min_graphemes: None,
max_graphemes: None,
r#enum: None,
r#const: None,
known_values: None,
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"record",
),
::jacquard_lexicon::lexicon::LexObjectProperty::Ref(::jacquard_lexicon::lexicon::LexRef {
description: None,
r#ref: ::jacquard_common::CowStr::new_static(
"app.bsky.graph.block",
),
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"uri",
),
::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
description: None,
format: Some(
::jacquard_lexicon::lexicon::LexStringFormat::AtUri,
),
default: None,
min_length: None,
max_length: None,
min_graphemes: None,
max_graphemes: None,
r#enum: None,
r#const: None,
known_values: None,
}),
);
map
},
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static("rendition"),
::jacquard_lexicon::lexicon::LexUserType::Object(::jacquard_lexicon::lexicon::LexObject {
description: None,
required: Some(
vec![
::jacquard_common::deps::smol_str::SmolStr::new_static("name")
],
),
nullable: None,
properties: {
#[allow(unused_mut)]
let mut map = ::alloc::collections::BTreeMap::new();
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"name",
),
::jacquard_lexicon::lexicon::LexObjectProperty::String(::jacquard_lexicon::lexicon::LexString {
description: None,
format: None,
default: None,
min_length: None,
max_length: None,
min_graphemes: None,
max_graphemes: None,
r#enum: None,
r#const: None,
known_values: None,
}),
);
map
},
}),
);
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static("renditions"),
::jacquard_lexicon::lexicon::LexUserType::Object(::jacquard_lexicon::lexicon::LexObject {
description: None,
required: Some(
vec![
::jacquard_common::deps::smol_str::SmolStr::new_static("renditions")
],
),
nullable: None,
properties: {
#[allow(unused_mut)]
let mut map = ::alloc::collections::BTreeMap::new();
map.insert(
::jacquard_common::deps::smol_str::SmolStr::new_static(
"renditions",
),
::jacquard_lexicon::lexicon::LexObjectProperty::Array(::jacquard_lexicon::lexicon::LexArray {
description: None,
items: ::jacquard_lexicon::lexicon::LexArrayItem::Ref(::jacquard_lexicon::lexicon::LexRef {
description: None,
r#ref: ::jacquard_common::CowStr::new_static("#rendition"),
}),
min_length: None,
max_length: None,
}),
);
map
},
}),
);
map
},
}
}
impl<'a> ::jacquard_lexicon::schema::LexiconSchema for BlockView<'a> {
fn nsid() -> &'static str {
"place.stream.defs"
}
fn def_name() -> &'static str {
"blockView"
}
fn lexicon_doc() -> ::jacquard_lexicon::lexicon::LexiconDoc<'static> {
lexicon_doc_place_stream_defs()
}
fn validate(
&self,
) -> ::core::result::Result<(), ::jacquard_lexicon::validation::ConstraintError> {
Ok(())
}
}
#[jacquard_derive::lexicon]
#[derive(
serde::Serialize,
serde::Deserialize,
Debug,
Clone,
PartialEq,
Eq,
jacquard_derive::IntoStatic,
Default
)]
#[serde(rename_all = "camelCase")]
pub struct Rendition<'a> {
#[serde(borrow)]
pub name: jacquard_common::CowStr<'a>,
}
impl<'a> ::jacquard_lexicon::schema::LexiconSchema for Rendition<'a> {
fn nsid() -> &'static str {
"place.stream.defs"
}
fn def_name() -> &'static str {
"rendition"
}
fn lexicon_doc() -> ::jacquard_lexicon::lexicon::LexiconDoc<'static> {
lexicon_doc_place_stream_defs()
}
fn validate(
&self,
) -> ::core::result::Result<(), ::jacquard_lexicon::validation::ConstraintError> {
Ok(())
}
}
#[jacquard_derive::lexicon]
#[derive(
serde::Serialize,
serde::Deserialize,
Debug,
Clone,
PartialEq,
Eq,
jacquard_derive::IntoStatic
)]
#[serde(rename_all = "camelCase")]
pub struct Renditions<'a> {
#[serde(borrow)]
pub renditions: Vec<crate::place_stream::Rendition<'a>>,
}
pub mod renditions_state {
pub use crate::builder_types::{Set, Unset, IsSet, IsUnset};
#[allow(unused)]
use ::core::marker::PhantomData;
mod sealed {
pub trait Sealed {}
}
pub trait State: sealed::Sealed {
type Renditions;
}
pub struct Empty(());
impl sealed::Sealed for Empty {}
impl State for Empty {
type Renditions = Unset;
}
pub struct SetRenditions<S: State = Empty>(PhantomData<fn() -> S>);
impl<S: State> sealed::Sealed for SetRenditions<S> {}
impl<S: State> State for SetRenditions<S> {
type Renditions = Set<members::renditions>;
}
#[allow(non_camel_case_types)]
pub mod members {
pub struct renditions(());
}
}
pub struct RenditionsBuilder<'a, S: renditions_state::State> {
_phantom_state: ::core::marker::PhantomData<fn() -> S>,
__unsafe_private_named: (
::core::option::Option<Vec<crate::place_stream::Rendition<'a>>>,
),
_phantom: ::core::marker::PhantomData<&'a ()>,
}
impl<'a> Renditions<'a> {
pub fn new() -> RenditionsBuilder<'a, renditions_state::Empty> {
RenditionsBuilder::new()
}
}
impl<'a> RenditionsBuilder<'a, renditions_state::Empty> {
pub fn new() -> Self {
RenditionsBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: (None,),
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> RenditionsBuilder<'a, S>
where
S: renditions_state::State,
S::Renditions: renditions_state::IsUnset,
{
pub fn renditions(
mut self,
value: impl Into<Vec<crate::place_stream::Rendition<'a>>>,
) -> RenditionsBuilder<'a, renditions_state::SetRenditions<S>> {
self.__unsafe_private_named.0 = ::core::option::Option::Some(value.into());
RenditionsBuilder {
_phantom_state: ::core::marker::PhantomData,
__unsafe_private_named: self.__unsafe_private_named,
_phantom: ::core::marker::PhantomData,
}
}
}
impl<'a, S> RenditionsBuilder<'a, S>
where
S: renditions_state::State,
S::Renditions: renditions_state::IsSet,
{
pub fn build(self) -> Renditions<'a> {
Renditions {
renditions: self.__unsafe_private_named.0.unwrap(),
extra_data: Default::default(),
}
}
pub fn build_with_data(
self,
extra_data: std::collections::BTreeMap<
jacquard_common::deps::smol_str::SmolStr,
jacquard_common::types::value::Data<'a>,
>,
) -> Renditions<'a> {
Renditions {
renditions: self.__unsafe_private_named.0.unwrap(),
extra_data: Some(extra_data),
}
}
}
impl<'a> ::jacquard_lexicon::schema::LexiconSchema for Renditions<'a> {
fn nsid() -> &'static str {
"place.stream.defs"
}
fn def_name() -> &'static str {
"renditions"
}
fn lexicon_doc() -> ::jacquard_lexicon::lexicon::LexiconDoc<'static> {
lexicon_doc_place_stream_defs()
}
fn validate(
&self,
) -> ::core::result::Result<(), ::jacquard_lexicon::validation::ConstraintError> {
Ok(())
}
}