<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>mux.comsys on StompyMUX Documentation</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/</link><description>Recent content in mux.comsys on StompyMUX Documentation</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://stompymux.com/docs/scripting/packages/mux/comsys/index.xml" rel="self" type="application/rss+xml"/><item><title>mux.comsys.flags</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/flags/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://stompymux.com/docs/scripting/packages/mux/comsys/flags/</guid><description>&lt;p&gt;&lt;code&gt;mux.comsys.flags&lt;/code&gt; contains immutable typed constants accepted by
&lt;a href="type-channel-flags/"&gt;&lt;code&gt;ChannelFlags&lt;/code&gt;&lt;/a&gt;:&lt;/p&gt;
&lt;table&gt;
	&lt;thead&gt;
			&lt;tr&gt;
					&lt;th&gt;Constant&lt;/th&gt;
					&lt;th&gt;Native behavior&lt;/th&gt;
			&lt;/tr&gt;
	&lt;/thead&gt;
	&lt;tbody&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;PUBLIC&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Makes the channel visible without a successful join lock.&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;LOUD&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Announces applicable connection and presence changes.&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;TRANSPARENT&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Relaxes hidden-member filtering in native channel displays.&lt;/td&gt;
			&lt;/tr&gt;
	&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;Constants compare by identity within the current Lua runtime and render as
their uppercase names. Unknown constants, raw strings, and constants from
another runtime raise &lt;code&gt;mux.channel_flag.invalid&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id="see-also"&gt;See Also&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="../"&gt;&lt;code&gt;mux.comsys&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel-flags/"&gt;&lt;code&gt;ChannelFlags&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description></item><item><title>channel</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/channel/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://stompymux.com/docs/scripting/packages/mux/comsys/channel/</guid><description>&lt;p&gt;Retrieves an existing communication channel by name.&lt;/p&gt;
&lt;h2 id="function"&gt;Function&lt;/h2&gt;
&lt;h3 id="synopsis"&gt;Synopsis&lt;/h3&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mux.comsys.channel( name )
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="arguments"&gt;Arguments&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;string name&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;An existing channel name without embedded NUL bytes. Lookup is
case-insensitive.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="returns"&gt;Returns&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;Channel channel&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;A live handle for the channel. &lt;code&gt;Channel:name()&lt;/code&gt; returns its canonical
spelling.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="raises"&gt;Raises&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;mux.unavailable.checking&lt;/code&gt; during &lt;code&gt;@lua/check&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.arg.invalid&lt;/code&gt; when the name contains an embedded NUL byte.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.channel.invalid&lt;/code&gt; when the channel does not exist.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="example"&gt;Example&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;local&lt;/span&gt; public &lt;span style="color:#f92672"&gt;=&lt;/span&gt; mux.comsys.channel(&lt;span style="color:#e6db74"&gt;&amp;#34;Public&amp;#34;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id="see-also"&gt;See Also&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="../../"&gt;&lt;code&gt;mux&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel/"&gt;&lt;code&gt;Channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../create-channel/"&gt;&lt;code&gt;mux.comsys.create_channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description></item><item><title>create_channel</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/create-channel/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://stompymux.com/docs/scripting/packages/mux/comsys/create-channel/</guid><description>&lt;p&gt;Creates a private communication channel using the native channel-name rules.&lt;/p&gt;
&lt;h2 id="function"&gt;Function&lt;/h2&gt;
&lt;h3 id="synopsis"&gt;Synopsis&lt;/h3&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mux.comsys.create_channel( name )
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="arguments"&gt;Arguments&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;string name&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;A non-empty printable ASCII name without spaces, shorter than 50 bytes.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="returns"&gt;Returns&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;Channel channel&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;A handle for the newly created channel.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="raises"&gt;Raises&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;mux.unavailable.checking&lt;/code&gt; during &lt;code&gt;@lua/check&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.arg.invalid&lt;/code&gt; for an invalid name, including an embedded NUL byte.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.channel.invalid&lt;/code&gt; when a channel with the same name already exists.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="example"&gt;Example&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;local&lt;/span&gt; staff &lt;span style="color:#f92672"&gt;=&lt;/span&gt; mux.comsys.create_channel(&lt;span style="color:#e6db74"&gt;&amp;#34;Staff&amp;#34;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;staff:flags():add(mux.comsys.flags.PUBLIC)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id="see-also"&gt;See Also&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="../../"&gt;&lt;code&gt;mux&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel/"&gt;&lt;code&gt;Channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../channel/"&gt;&lt;code&gt;mux.comsys.channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description></item><item><title>destroy_channel</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/destroy-channel/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://stompymux.com/docs/scripting/packages/mux/comsys/destroy-channel/</guid><description>&lt;p&gt;Permanently removes a live communication channel and its membership storage.&lt;/p&gt;
&lt;h2 id="function"&gt;Function&lt;/h2&gt;
&lt;h3 id="synopsis"&gt;Synopsis&lt;/h3&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mux.comsys.destroy_channel( channel )
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="arguments"&gt;Arguments&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;Channel channel&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;A live channel handle.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="returns"&gt;Returns&lt;/h3&gt;
&lt;p&gt;Nothing.&lt;/p&gt;
&lt;h3 id="raises"&gt;Raises&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;mux.unavailable.checking&lt;/code&gt; during &lt;code&gt;@lua/check&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.channel.invalid&lt;/code&gt; when the channel handle is stale.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="notes"&gt;Notes&lt;/h2&gt;
&lt;p&gt;The supplied handle and every &lt;code&gt;ChannelFlags&lt;/code&gt; handle derived from it become
stale. A later channel created with the same name does not revive them.&lt;/p&gt;
&lt;h2 id="example"&gt;Example&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;local&lt;/span&gt; staff &lt;span style="color:#f92672"&gt;=&lt;/span&gt; mux.comsys.create_channel(&lt;span style="color:#e6db74"&gt;&amp;#34;Staff&amp;#34;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mux.comsys.destroy_channel(staff)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id="see-also"&gt;See Also&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="../../"&gt;&lt;code&gt;mux&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel/"&gt;&lt;code&gt;Channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel-flags/"&gt;&lt;code&gt;ChannelFlags&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description></item><item><title>list_channels</title><link>https://stompymux.com/docs/scripting/packages/mux/comsys/list-channels/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://stompymux.com/docs/scripting/packages/mux/comsys/list-channels/</guid><description>&lt;p&gt;Lists every live communication channel in deterministic name order.&lt;/p&gt;
&lt;h2 id="function"&gt;Function&lt;/h2&gt;
&lt;h3 id="synopsis"&gt;Synopsis&lt;/h3&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mux.comsys.list_channels( )
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="arguments"&gt;Arguments&lt;/h3&gt;
&lt;p&gt;None.&lt;/p&gt;
&lt;h3 id="returns"&gt;Returns&lt;/h3&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;code&gt;Channel[] channels&lt;/code&gt;&lt;/dt&gt;
&lt;dd&gt;A dense array of channel handles sorted case-insensitively by name, with the
original spelling as the tie-breaker.&lt;/dd&gt;
&lt;/dl&gt;
&lt;h3 id="raises"&gt;Raises&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;mux.unavailable.checking&lt;/code&gt; during &lt;code&gt;@lua/check&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mux.internal&lt;/code&gt; if the native registry count changes while the channel list is
copied.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="example"&gt;Example&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lua" data-lang="lua"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;for&lt;/span&gt; _, channel &lt;span style="color:#66d9ef"&gt;in&lt;/span&gt; ipairs(mux.comsys.list_channels()) &lt;span style="color:#66d9ef"&gt;do&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; mux.log(&lt;span style="color:#e6db74"&gt;&amp;#34;channels.log&amp;#34;&lt;/span&gt;, channel:name())
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id="see-also"&gt;See Also&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="../../"&gt;&lt;code&gt;mux&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../type-channel/"&gt;&lt;code&gt;Channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../channel/"&gt;&lt;code&gt;mux.comsys.channel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description></item></channel></rss>