pub struct BlenderLiveSyncState { /* private fields */ }Expand description
Shared concurrent runtime state backing the Hyperlane euv blender live-sync daemon.
Implementations§
Source§impl BlenderLiveSyncState
Shared state management and SSE fan-out methods for BlenderLiveSyncState.
impl BlenderLiveSyncState
Shared state management and SSE fan-out methods for BlenderLiveSyncState.
Sourcepub fn new(
sse_config: SseConfig,
out_dir: Option<PathBuf>,
max_asset_bytes: usize,
replay_capacity: usize,
) -> Self
pub fn new( sse_config: SseConfig, out_dir: Option<PathBuf>, max_asset_bytes: usize, replay_capacity: usize, ) -> Self
Creates a new concurrent Live-Link state backed by a Hyperlane SseHub.
§Arguments
SseConfig- SSE heartbeat, retry, and replay configuration.Option<PathBuf>- Optional directory mirroring hot-swapped binary assets to disk.usize- Maximum accepted binary asset payload size in bytes.usize- Maximum replay events retained in memory.
§Returns
Self- Initialized Live-Link daemon state.
Sourcepub fn sse_config(&self) -> &SseConfig
pub fn sse_config(&self) -> &SseConfig
Returns the active SSE heartbeat and retry configuration.
§Returns
&SseConfig- Active SSE configuration.
Sourcepub fn max_asset_bytes(&self) -> usize
pub fn max_asset_bytes(&self) -> usize
Returns the maximum permitted binary upload size in bytes.
§Returns
usize- Maximum payload size in bytes.
Sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Sourcepub fn latest_seq(&self) -> u64
pub fn latest_seq(&self) -> u64
Returns the latest monotonic event sequence number emitted so far.
§Returns
u64- Latest sequence number (0before any events).
Sourcepub fn delta_count(&self) -> u64
pub fn delta_count(&self) -> u64
Sourcepub fn asset_count(&self) -> u64
pub fn asset_count(&self) -> u64
Sourcepub fn asset_ids(&self) -> Vec<String>
pub fn asset_ids(&self) -> Vec<String>
Returns sorted asset identifiers currently stored in memory.
§Returns
Vec<String>- Cached asset identifiers.
Sourcepub fn get_asset(&self, asset_id: &str) -> Option<BlenderStoredAsset>
pub fn get_asset(&self, asset_id: &str) -> Option<BlenderStoredAsset>
Sourcepub fn latest_delta(&self) -> Option<BlenderLiveDeltaPayload>
pub fn latest_delta(&self) -> Option<BlenderLiveDeltaPayload>
Returns the most recent JSON delta payload received from Blender, if any.
§Returns
Option<BlenderLiveDeltaPayload>- Latest delta payload.
Sourcepub fn events_after(&self, cursor: u64) -> Vec<BlenderLiveEventRecord>
pub fn events_after(&self, cursor: u64) -> Vec<BlenderLiveEventRecord>
Sourcepub fn record_delta(
&self,
payload: BlenderLiveDeltaPayload,
) -> Result<BlenderLiveEventRecord>
pub fn record_delta( &self, payload: BlenderLiveDeltaPayload, ) -> Result<BlenderLiveEventRecord>
Sourcepub fn record_asset(
&self,
asset_id: &str,
bytes: Vec<u8>,
) -> Result<BlenderLiveAssetNotice>
pub fn record_asset( &self, asset_id: &str, bytes: Vec<u8>, ) -> Result<BlenderLiveAssetNotice>
Sourcepub fn build_report(&self, base_url: &str, once: bool) -> BlenderLiveSyncReport
pub fn build_report(&self, base_url: &str, once: bool) -> BlenderLiveSyncReport
Trait Implementations§
Source§impl Debug for BlenderLiveSyncState
impl Debug for BlenderLiveSyncState
Auto Trait Implementations§
impl !Freeze for BlenderLiveSyncState
impl Forget for BlenderLiveSyncState
impl Move for BlenderLiveSyncState
impl RefUnwindSafe for BlenderLiveSyncStatewhere
Atomic<usize>: RefUnwindSafe,
Atomic<u64>: RefUnwindSafe,
RwLock<HashMap<Arc<str>, Arc<TopicState>, BuildHasherDefault<FxHasher>>>: RefUnwindSafe,
Mutex<HashMap<(Id, u64), Arc<SseHeartbeatWheel>>>: RefUnwindSafe,
Mutex<Vec<BlenderLiveEventRecord>>: RefUnwindSafe,
RwLock<BTreeMap<String, BlenderStoredAsset>>: RefUnwindSafe,
RwLock<Option<BlenderLiveDeltaPayload>>: RefUnwindSafe,
Atomic<bool>: RefUnwindSafe,
impl Send for BlenderLiveSyncState
impl Sync for BlenderLiveSyncState
impl Unpin for BlenderLiveSyncState
impl UnsafeUnpin for BlenderLiveSyncStatewhere
*const ArcInner<SseHubInner> is !null: UnsafeUnpin,
PhantomData<ArcInner<SseHubInner>>: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
Align8<u64>: UnsafeUnpin,
Align4<u32>: UnsafeUnpin,
Align1<u8>: UnsafeUnpin,
PhantomData<BlenderLiveEventRecord>: UnsafeUnpin,
*const LeafNode<String, BlenderStoredAsset> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, BlenderStoredAsset)>>: UnsafeUnpin,
PhantomData<BlenderLiveTransformDelta>: UnsafeUnpin,
PhantomData<BlenderLiveCameraDelta>: UnsafeUnpin,
PhantomData<BlenderLiveLightDelta>: UnsafeUnpin,
PhantomData<BlenderLiveMaterialDelta>: UnsafeUnpin,
PhantomData<BlenderLiveMorphDelta>: UnsafeUnpin,
impl UnwindSafe for BlenderLiveSyncStatewhere
Arc<SseHubInner>: UnwindSafe,
RawVecInner: UnwindSafe,
Align8<u64>: UnwindSafe,
Mutex<Vec<BlenderLiveEventRecord>>: UnwindSafe,
RwLock<BTreeMap<String, BlenderStoredAsset>>: UnwindSafe,
RwLock<Option<BlenderLiveDeltaPayload>>: UnwindSafe,
Align1<u8>: UnwindSafe,
Blanket Implementations§
impl<T> AnySend for T
impl<T> AnySendSync for T
impl<T> AnySync for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more