/// <summary> /// Add a StreamHost /// </summary> /// <param name="jid"></param> /// <param name="host"></param> /// <param name="port"></param> /// <param name="zeroconf"></param> /// <returns></returns> public StreamHost AddStreamHost(Jid jid, string host, int port, string zeroconf) { StreamHost sh = new StreamHost(jid, host, port, zeroconf); AddChild(sh); return(sh); }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="jid"></param> /// <param name="host"></param> /// <param name="port"></param> /// <returns></returns> public StreamHost AddStreamHost(Jid jid, string host, int port) { var sh = new StreamHost(jid, host, port); AddChild(sh); return(sh); }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="jid"></param> /// <param name="host"></param> /// <returns></returns> public StreamHost AddStreamHost(Jid jid, string host) { StreamHost sh = new StreamHost(jid, host); AddChild(sh); return(sh); }
/// <summary> /// Add a StreamHost /// </summary> /// <returns></returns> public StreamHost AddStreamHost() { StreamHost sh = new StreamHost(); AddChild(sh); return(sh); }
/// <summary> /// Get the list of streamhosts /// </summary> /// <returns></returns> public StreamHost[] GetStreamHosts() { var nl = SelectElements(typeof(StreamHost)); var hosts = new StreamHost[nl.Count]; var i = 0; foreach (Element e in nl) { hosts[i] = (StreamHost)e; i++; } return(hosts); }
/// <summary> /// Get the list of streamhosts /// </summary> /// <returns></returns> public StreamHost[] GetStreamHosts() { ElementList nl = SelectElements(typeof(StreamHost)); StreamHost[] hosts = new StreamHost[nl.Count]; int i = 0; foreach (Element e in nl) { hosts[i] = (StreamHost)e; i++; } return(hosts); }
private void SendStreamHostUsedResponse(StreamHost sh, IQ iq) { ByteStreamIq bsIQ = new ByteStreamIq(IqType.result, Contact.FullJid); bsIQ.Id = iq.Id; bsIQ.Query.StreamHostUsed = new StreamHostUsed(sh.Jid); _xmppConnection.Send(bsIQ); }
private void OnProxyDiscoResult(object sender, IQ iq, object data) { _streamHostProxy = null; if (iq.Error == null && iq.Type == IqType.result) { ByteStream byteStream = iq.Query as ByteStream; if (byteStream != null && byteStream.GetStreamHosts().Length > 0) { _streamHostProxy = byteStream.GetStreamHosts()[0]; } } SendStreamHosts(); }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="sh"></param> /// <returns></returns> public StreamHost AddStreamHost(StreamHost sh) { AddChild(sh); return(sh); }
private void SendStreamHostUsedResponse(StreamHost sh, IQ iq) { ByteStreamIq bsIQ = new ByteStreamIq(IqType.result, m_From); bsIQ.Id = iq.Id; bsIQ.Query.StreamHostUsed = new StreamHostUsed(sh.Jid); m_XmppCon.Send(bsIQ); }
/// <summary> /// Add a StreamHost /// </summary> /// <returns></returns> public StreamHost AddStreamHost() { StreamHost sh = new StreamHost(); AddChild(sh); return sh; }
/// <summary> /// Get the list of streamhosts /// </summary> /// <returns></returns> public StreamHost[] GetStreamHosts() { ElementList nl = SelectElements(typeof(StreamHost)); StreamHost[] hosts = new StreamHost[nl.Count]; int i = 0; foreach (Element e in nl) { hosts[i] = (StreamHost) e; i++; } return hosts; }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="jid"></param> /// <param name="host"></param> /// <param name="port"></param> /// <param name="zeroconf"></param> /// <returns></returns> public StreamHost AddStreamHost(Jid jid, string host, int port, string zeroconf) { StreamHost sh = new StreamHost(jid, host, port, zeroconf); AddChild(sh); return sh; }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="jid"></param> /// <param name="host"></param> /// <returns></returns> public StreamHost AddStreamHost(Jid jid, string host) { StreamHost sh = new StreamHost(jid, host); AddChild(sh); return sh; }
/// <summary> /// Add a StreamHost /// </summary> /// <param name="sh"></param> /// <returns></returns> public StreamHost AddStreamHost(StreamHost sh) { AddChild(sh); return sh; }