/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version 1.3.35
 *
 * Do not make changes to this file unless you know what you are doing--modify
 * the SWIG interface file instead.
 * ----------------------------------------------------------------------------- */

namespace FreeSWITCH.Native {

using System;
using System.Runtime.InteropServices;

public class switch_caller_application : IDisposable {
  private HandleRef swigCPtr;
  protected bool swigCMemOwn;

  internal switch_caller_application(IntPtr cPtr, bool cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = new HandleRef(this, cPtr);
  }

  internal static HandleRef getCPtr(switch_caller_application obj) {
    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
  }

  ~switch_caller_application() {
    Dispose();
  }

  public virtual void Dispose() {
    lock(this) {
      if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
        swigCMemOwn = false;
        freeswitchPINVOKE.delete_switch_caller_application(swigCPtr);
      }
      swigCPtr = new HandleRef(null, IntPtr.Zero);
      GC.SuppressFinalize(this);
    }
  }

  public string application_name {
    set {
      freeswitchPINVOKE.switch_caller_application_application_name_set(swigCPtr, value);
    } 
    get {
      string ret = freeswitchPINVOKE.switch_caller_application_application_name_get(swigCPtr);
      return ret;
    } 
  }

  public string application_data {
    set {
      freeswitchPINVOKE.switch_caller_application_application_data_set(swigCPtr, value);
    } 
    get {
      string ret = freeswitchPINVOKE.switch_caller_application_application_data_get(swigCPtr);
      return ret;
    } 
  }

  public SWIGTYPE_p_f_p_switch_core_session_p_q_const__char__void application_function {
    set {
      freeswitchPINVOKE.switch_caller_application_application_function_set(swigCPtr, SWIGTYPE_p_f_p_switch_core_session_p_q_const__char__void.getCPtr(value));
    } 
    get {
      IntPtr cPtr = freeswitchPINVOKE.switch_caller_application_application_function_get(swigCPtr);
      SWIGTYPE_p_f_p_switch_core_session_p_q_const__char__void ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_f_p_switch_core_session_p_q_const__char__void(cPtr, false);
      return ret;
    } 
  }

  public switch_caller_application next {
    set {
      freeswitchPINVOKE.switch_caller_application_next_set(swigCPtr, switch_caller_application.getCPtr(value));
    } 
    get {
      IntPtr cPtr = freeswitchPINVOKE.switch_caller_application_next_get(swigCPtr);
      switch_caller_application ret = (cPtr == IntPtr.Zero) ? null : new switch_caller_application(cPtr, false);
      return ret;
    } 
  }

  public switch_caller_application() : this(freeswitchPINVOKE.new_switch_caller_application(), true) {
  }

}

}
