doubango/branches/2.0/doubango/bindings/csharp/PublicationSession.cs

69 lines
2.0 KiB
C#
Raw Normal View History

2011-03-25 09:38:07 +00:00
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
2014-11-06 05:15:14 +00:00
* Version 1.3.40
2011-03-25 09:38:07 +00:00
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
namespace org.doubango.tinyWRAP {
using System;
using System.Runtime.InteropServices;
public class PublicationSession : SipSession {
private HandleRef swigCPtr;
2014-11-06 05:15:14 +00:00
internal PublicationSession(IntPtr cPtr, bool cMemoryOwn) : base(tinyWRAPPINVOKE.PublicationSessionUpcast(cPtr), cMemoryOwn) {
2011-03-25 09:38:07 +00:00
swigCPtr = new HandleRef(this, cPtr);
}
internal static HandleRef getCPtr(PublicationSession obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
~PublicationSession() {
Dispose();
}
public override void Dispose() {
lock(this) {
if (swigCPtr.Handle != IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
tinyWRAPPINVOKE.delete_PublicationSession(swigCPtr);
}
swigCPtr = new HandleRef(null, IntPtr.Zero);
2011-03-25 09:38:07 +00:00
}
GC.SuppressFinalize(this);
base.Dispose();
}
}
2011-04-24 02:14:39 +00:00
public PublicationSession(SipStack pStack) : this(tinyWRAPPINVOKE.new_PublicationSession(SipStack.getCPtr(pStack)), true) {
2011-03-25 09:38:07 +00:00
}
public bool publish(IntPtr payload, uint len, ActionConfig config) {
2011-03-31 15:07:01 +00:00
bool ret = tinyWRAPPINVOKE.PublicationSession_publish__SWIG_0(swigCPtr, payload, len, ActionConfig.getCPtr(config));
return ret;
}
public bool publish(IntPtr payload, uint len) {
2011-03-31 15:07:01 +00:00
bool ret = tinyWRAPPINVOKE.PublicationSession_publish__SWIG_1(swigCPtr, payload, len);
return ret;
}
public bool unPublish(ActionConfig config) {
bool ret = tinyWRAPPINVOKE.PublicationSession_unPublish__SWIG_0(swigCPtr, ActionConfig.getCPtr(config));
2011-03-25 09:38:07 +00:00
return ret;
}
public bool unPublish() {
2011-03-31 15:07:01 +00:00
bool ret = tinyWRAPPINVOKE.PublicationSession_unPublish__SWIG_1(swigCPtr);
2011-03-25 09:38:07 +00:00
return ret;
}
}
}