Mountain/Environment/OutputProvider/
mod.rs1use CommonLibrary::Output::OutputChannelManager::OutputChannelManager;
26use async_trait::async_trait;
27
28mod ChannelLifecycle;
30mod ChannelContent;
31mod ChannelVisibility;
32
33#[async_trait]
34impl OutputChannelManager for crate::Environment::MountainEnvironment::MountainEnvironment {
35 async fn RegisterChannel(
36 &self,
37 name:String,
38 language_identifier:Option<String>,
39 ) -> Result<String, CommonLibrary::Error::CommonError::CommonError> {
40 ChannelLifecycle::register_channel(self, name, language_identifier).await
41 }
42
43 async fn Append(
44 &self,
45 channel_identifier:String,
46 value:String,
47 ) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
48 ChannelContent::append_to_channel(self, channel_identifier, value).await
49 }
50
51 async fn Replace(
52 &self,
53 channel_identifier:String,
54 value:String,
55 ) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
56 ChannelContent::replace_channel_content(self, channel_identifier, value).await
57 }
58
59 async fn Clear(&self, channel_identifier:String) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
60 ChannelContent::clear_channel(self, channel_identifier).await
61 }
62
63 async fn Reveal(
64 &self,
65 channel_identifier:String,
66 preserve_focus:bool,
67 ) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
68 ChannelVisibility::reveal_channel(self, channel_identifier, preserve_focus).await
69 }
70
71 async fn Close(&self, channel_identifier:String) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
72 ChannelVisibility::close_channel(self, channel_identifier).await
73 }
74
75 async fn Dispose(&self, channel_identifier:String) -> Result<(), CommonLibrary::Error::CommonError::CommonError> {
76 ChannelLifecycle::dispose_channel(self, channel_identifier).await
77 }
78}