pub struct ClaudeToChatStream { /* private fields */ }Implementations§
Source§impl ClaudeToChatStream
impl ClaudeToChatStream
pub fn new( context: ClaudeToChatContext, flow: IdentityFlow, limits: StreamLimits, ) -> Result<Self, TransformError>
pub fn new_with_policy( context: ClaudeToChatContext, flow: IdentityFlow, limits: StreamLimits, policy: TargetIdPolicy, ) -> Result<Self, TransformError>
pub fn identities(&self) -> &IdentityFlow
pub fn push( &mut self, event: StreamEvent, ) -> Result<Converted<Vec<ChatCompletionChunk>>, TransformError>
pub fn finish(self) -> Result<StreamEnd<ChatCompletionChunk>, TransformError>
Trait Implementations§
Source§impl FanoutBridge for ClaudeToChatStream
impl FanoutBridge for ClaudeToChatStream
fn reserve( &mut self, role: IdentityRole, ids: &BTreeSet<String>, ) -> Result<(), TransformError>
Source§impl StreamBridge for ClaudeToChatStream
impl StreamBridge for ClaudeToChatStream
type NativeEvent = StreamEvent
type ClientEvent = ChatCompletionChunk
type NativeRequest = GenerateContentRequestBody
type ClientRequest = GenerateContentRequestBody
fn identities(&self) -> &IdentityFlow
fn push( &mut self, event: Self::NativeEvent, ) -> Result<Converted<Vec<Self::ClientEvent>>, TransformError>
fn finish(self) -> Result<BridgeEnd<Self::ClientEvent>, TransformError>
fn push_done(&mut self) -> Result<(), TransformError>
Auto Trait Implementations§
impl Freeze for ClaudeToChatStream
impl RefUnwindSafe for ClaudeToChatStream
impl Send for ClaudeToChatStream
impl Sync for ClaudeToChatStream
impl Unpin for ClaudeToChatStream
impl UnsafeUnpin for ClaudeToChatStream
impl UnwindSafe for ClaudeToChatStream
Blanket Implementations§
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