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

namespace cAudio {

using System;
using System.Runtime.InteropServices;

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

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

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

  ~ILogger() {
    Dispose();
  }

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

  public virtual void logCritical(string sender, string msg) {
    cAudioCSharpWrapperPINVOKE.ILogger_logCritical(swigCPtr, sender, msg);
  }

  public virtual void logError(string sender, string msg) {
    cAudioCSharpWrapperPINVOKE.ILogger_logError(swigCPtr, sender, msg);
  }

  public virtual void logWarning(string sender, string msg) {
    cAudioCSharpWrapperPINVOKE.ILogger_logWarning(swigCPtr, sender, msg);
  }

  public virtual void logInfo(string sender, string msg) {
    cAudioCSharpWrapperPINVOKE.ILogger_logInfo(swigCPtr, sender, msg);
  }

  public virtual void logDebug(string sender, string msg) {
    cAudioCSharpWrapperPINVOKE.ILogger_logDebug(swigCPtr, sender, msg);
  }

  public virtual LogLevel getLogLevel() {
    LogLevel ret = (LogLevel)cAudioCSharpWrapperPINVOKE.ILogger_getLogLevel(swigCPtr);
    return ret;
  }

  public virtual void setLogLevel(LogLevel logLevel) {
    cAudioCSharpWrapperPINVOKE.ILogger_setLogLevel(swigCPtr, (int)logLevel);
  }

  public virtual bool registerLogReceiver(ILogReceiver receiver, string name) {
    bool ret = cAudioCSharpWrapperPINVOKE.ILogger_registerLogReceiver(swigCPtr, ILogReceiver.getCPtr(receiver), name);
    return ret;
  }

  public virtual void unRegisterLogReceiver(string name) {
    cAudioCSharpWrapperPINVOKE.ILogger_unRegisterLogReceiver(swigCPtr, name);
  }

  public virtual bool isLogReceiverRegistered(string name) {
    bool ret = cAudioCSharpWrapperPINVOKE.ILogger_isLogReceiverRegistered(swigCPtr, name);
    return ret;
  }

  public virtual ILogReceiver getLogReceiver(string name) {
    IntPtr cPtr = cAudioCSharpWrapperPINVOKE.ILogger_getLogReceiver(swigCPtr, name);
    ILogReceiver ret = (cPtr == IntPtr.Zero) ? null : new ILogReceiver(cPtr, false);
    return ret;
  }

}

}
