[Laszlo-user] rtmpconnection - how to disconnect ?

Pierre Augier pierre.augier at inrialpes.fr
Thu Jul 19 05:40:55 PDT 2007


I all !!

Do you know if it's possible actually to disconnect a rtmpconnection and 
how ?

There is no "disconnect" method in the official doc, and also in the 
rtmpconnection.lzx ... is this a lack ? If you think that this is 
usefull i would post a new issue on JIRA.

I need this function, but NetConnection doesn't provide a disconnect 
function, so i've tried to do it:

<!--- disconnect to the rtmp server. -->
        <method name="disconnect"><![CDATA[

            if (this.stage == 0) {
                return; // already disconnected
            }

            Debug.write("disconnect");


            this.setAttribute("status", "disconnected");
            this.setAttribute("stage", 0);

        this._nc = null;
            var t = this;
            this._nc.onStatus = null;
        this._nc = null;
           
          ]]>
        </method>
   

==> this is not working, setting the _nc to null doesn't close the 
netstreams objects. So maybe someone have the solution ?

regards,

Pierre



More information about the Laszlo-user mailing list