public override int OnRegistrationEvent(RegistrationEvent e) { short code = e.getCode(); tsip_register_event_type_t type = e.getType(); String text; RegistrationSession session = e.getSession(); switch (type) { case tsip_register_event_type_t.tsip_i_register: case tsip_register_event_type_t.tsip_ao_register: case tsip_register_event_type_t.tsip_i_unregister: case tsip_register_event_type_t.tsip_ao_unregister: break; } text = String.Format("OnRegistrationChanged() ==> {0}:{1}", code, e.getPhrase()); if (this.form.InvokeRequired) { this.form.Invoke(this.form.mydel, new object[] { text }); } return(0); }
public override int OnRegistrationEvent(RegistrationEvent e) { short code = e.getCode(); tsip_register_event_type_t type = e.getType(); RegistrationSession session = e.getSession(); SipMessage message = e.getSipMessage(); if (message != null) { Console.WriteLine("call-id={0}", message.getSipHeaderValue("call-id")); //byte[] bytes = message.getContent(); } switch (type) { case tsip_register_event_type_t.tsip_ao_register: case tsip_register_event_type_t.tsip_ao_unregister: break; } Console.WriteLine("OnRegistrationChanged() ==> {0}:{1}", code, e.getPhrase()); return(0); }
public override int OnRegistrationEvent(RegistrationEvent e) { short code = e.getCode(); tsip_register_event_type_t type = e.getType(); String text; RegistrationSession session = e.getSession(); switch (type) { case tsip_register_event_type_t.tsip_i_register: case tsip_register_event_type_t.tsip_ao_register: case tsip_register_event_type_t.tsip_i_unregister: case tsip_register_event_type_t.tsip_ao_unregister: break; } text = String.Format("OnRegistrationChanged() ==> {0}:{1}", code, e.getPhrase()); if (this.form.InvokeRequired) { this.form.Invoke(this.form.mydel, new object[] { text }); } return 0; }