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


using System;
using System.Runtime.InteropServices;

public class OBTypeTable : OBGlobalDataBase {
  private HandleRef swigCPtr;

  internal OBTypeTable(IntPtr cPtr, bool cMemoryOwn) : base(openbabelPINVOKE.OBTypeTableUpcast(cPtr), cMemoryOwn) {
    swigCPtr = new HandleRef(this, cPtr);
  }

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

  ~OBTypeTable() {
    Dispose();
  }

  public override void Dispose() {
    lock(this) {
      if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
        swigCMemOwn = false;
        openbabelPINVOKE.delete_OBTypeTable(swigCPtr);
      }
      swigCPtr = new HandleRef(null, IntPtr.Zero);
      GC.SuppressFinalize(this);
      base.Dispose();
    }
  }

  public OBTypeTable() : this(openbabelPINVOKE.new_OBTypeTable(), true) {
  }

  public bool SetFromType(string arg0) {
    bool ret = openbabelPINVOKE.OBTypeTable_SetFromType(swigCPtr, arg0);
    return ret;
  }

  public bool SetToType(string arg0) {
    bool ret = openbabelPINVOKE.OBTypeTable_SetToType(swigCPtr, arg0);
    return ret;
  }

  public bool Translate(string to, string from) {
    bool ret = openbabelPINVOKE.OBTypeTable_Translate__SWIG_0(swigCPtr, to, from);
    return ret;
  }

  public bool Translate(SWIGTYPE_p_std__string to, string from) {
    bool ret = openbabelPINVOKE.OBTypeTable_Translate__SWIG_1(swigCPtr, SWIGTYPE_p_std__string.getCPtr(to), from);
    if (openbabelPINVOKE.SWIGPendingException.Pending) throw openbabelPINVOKE.SWIGPendingException.Retrieve();
    return ret;
  }

  public string Translate(string from) {
    string ret = openbabelPINVOKE.OBTypeTable_Translate__SWIG_2(swigCPtr, from);
    if (openbabelPINVOKE.SWIGPendingException.Pending) throw openbabelPINVOKE.SWIGPendingException.Retrieve();
    return ret;
  }

  public string GetFromType() {
    string ret = openbabelPINVOKE.OBTypeTable_GetFromType(swigCPtr);
    return ret;
  }

  public string GetToType() {
    string ret = openbabelPINVOKE.OBTypeTable_GetToType(swigCPtr);
    return ret;
  }

}
