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

package com.chilkatsoft;

public class CkAi {
  private transient long swigCPtr;
  protected transient boolean swigCMemOwn;

  protected CkAi(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  protected static long getCPtr(CkAi obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  protected static long swigRelease(CkAi obj) {
    long ptr = 0;
    if (obj != null) {
      if (!obj.swigCMemOwn)
        throw new RuntimeException("Cannot release ownership as memory is not owned");
      ptr = obj.swigCPtr;
      obj.swigCMemOwn = false;
      obj.delete();
    }
    return ptr;
  }

  @SuppressWarnings({"deprecation", "removal"})
  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if (swigCPtr != 0) {
      if (swigCMemOwn) {
        swigCMemOwn = false;
        chilkatJNI.delete_CkAi(swigCPtr);
      }
      swigCPtr = 0;
    }
  }

  public CkAi() {
    this(chilkatJNI.new_CkAi(), true);
  }

  public void LastErrorXml(CkString str) {
    chilkatJNI.CkAi_LastErrorXml(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public void LastErrorHtml(CkString str) {
    chilkatJNI.CkAi_LastErrorHtml(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public void LastErrorText(CkString str) {
    chilkatJNI.CkAi_LastErrorText(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public void put_EventCallbackObject(CkBaseProgress progress) {
    chilkatJNI.CkAi_put_EventCallbackObject(swigCPtr, this, CkBaseProgress.getCPtr(progress), progress);
  }

  public void get_ApiKey(CkString str) {
    chilkatJNI.CkAi_get_ApiKey(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String apiKey() {
    return chilkatJNI.CkAi_apiKey(swigCPtr, this);
  }

  public void put_ApiKey(String newVal) {
    chilkatJNI.CkAi_put_ApiKey(swigCPtr, this, newVal);
  }

  public void get_DebugLogFilePath(CkString str) {
    chilkatJNI.CkAi_get_DebugLogFilePath(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String debugLogFilePath() {
    return chilkatJNI.CkAi_debugLogFilePath(swigCPtr, this);
  }

  public void put_DebugLogFilePath(String newVal) {
    chilkatJNI.CkAi_put_DebugLogFilePath(swigCPtr, this, newVal);
  }

  public boolean get_FullTranscript() {
    return chilkatJNI.CkAi_get_FullTranscript(swigCPtr, this);
  }

  public void put_FullTranscript(boolean newVal) {
    chilkatJNI.CkAi_put_FullTranscript(swigCPtr, this, newVal);
  }

  public int get_HeartbeatMs() {
    return chilkatJNI.CkAi_get_HeartbeatMs(swigCPtr, this);
  }

  public void put_HeartbeatMs(int newVal) {
    chilkatJNI.CkAi_put_HeartbeatMs(swigCPtr, this, newVal);
  }

  public boolean get_HostedConvo() {
    return chilkatJNI.CkAi_get_HostedConvo(swigCPtr, this);
  }

  public void put_HostedConvo(boolean newVal) {
    chilkatJNI.CkAi_put_HostedConvo(swigCPtr, this, newVal);
  }

  public int get_IdleTimeoutMs() {
    return chilkatJNI.CkAi_get_IdleTimeoutMs(swigCPtr, this);
  }

  public void put_IdleTimeoutMs(int newVal) {
    chilkatJNI.CkAi_put_IdleTimeoutMs(swigCPtr, this, newVal);
  }

  public void get_LastErrorHtml(CkString str) {
    chilkatJNI.CkAi_get_LastErrorHtml(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String lastErrorHtml() {
    return chilkatJNI.CkAi_lastErrorHtml(swigCPtr, this);
  }

  public void get_LastErrorText(CkString str) {
    chilkatJNI.CkAi_get_LastErrorText(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String lastErrorText() {
    return chilkatJNI.CkAi_lastErrorText(swigCPtr, this);
  }

  public void get_LastErrorXml(CkString str) {
    chilkatJNI.CkAi_get_LastErrorXml(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String lastErrorXml() {
    return chilkatJNI.CkAi_lastErrorXml(swigCPtr, this);
  }

  public boolean get_LastMethodSuccess() {
    return chilkatJNI.CkAi_get_LastMethodSuccess(swigCPtr, this);
  }

  public void put_LastMethodSuccess(boolean newVal) {
    chilkatJNI.CkAi_put_LastMethodSuccess(swigCPtr, this, newVal);
  }

  public void get_Model(CkString str) {
    chilkatJNI.CkAi_get_Model(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String model() {
    return chilkatJNI.CkAi_model(swigCPtr, this);
  }

  public void put_Model(String newVal) {
    chilkatJNI.CkAi_put_Model(swigCPtr, this, newVal);
  }

  public void get_Provider(CkString str) {
    chilkatJNI.CkAi_get_Provider(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String provider() {
    return chilkatJNI.CkAi_provider(swigCPtr, this);
  }

  public void put_Provider(String newVal) {
    chilkatJNI.CkAi_put_Provider(swigCPtr, this, newVal);
  }

  public int get_ResponseStatusCode() {
    return chilkatJNI.CkAi_get_ResponseStatusCode(swigCPtr, this);
  }

  public void get_SelectedConvo(CkString str) {
    chilkatJNI.CkAi_get_SelectedConvo(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String selectedConvo() {
    return chilkatJNI.CkAi_selectedConvo(swigCPtr, this);
  }

  public void put_SelectedConvo(String newVal) {
    chilkatJNI.CkAi_put_SelectedConvo(swigCPtr, this, newVal);
  }

  public boolean get_Streaming() {
    return chilkatJNI.CkAi_get_Streaming(swigCPtr, this);
  }

  public void put_Streaming(boolean newVal) {
    chilkatJNI.CkAi_put_Streaming(swigCPtr, this, newVal);
  }

  public void get_UncommonOptions(CkString str) {
    chilkatJNI.CkAi_get_UncommonOptions(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String uncommonOptions() {
    return chilkatJNI.CkAi_uncommonOptions(swigCPtr, this);
  }

  public void put_UncommonOptions(String newVal) {
    chilkatJNI.CkAi_put_UncommonOptions(swigCPtr, this, newVal);
  }

  public boolean get_VerboseLogging() {
    return chilkatJNI.CkAi_get_VerboseLogging(swigCPtr, this);
  }

  public void put_VerboseLogging(boolean newVal) {
    chilkatJNI.CkAi_put_VerboseLogging(swigCPtr, this, newVal);
  }

  public void get_Version(CkString str) {
    chilkatJNI.CkAi_get_Version(swigCPtr, this, CkString.getCPtr(str), str);
  }

  public String version() {
    return chilkatJNI.CkAi_version(swigCPtr, this);
  }

  public boolean Ask(String outputType) {
    return chilkatJNI.CkAi_Ask(swigCPtr, this, outputType);
  }

  public CkTask AskAsync(String outputType) {
    long cPtr = chilkatJNI.CkAi_AskAsync(swigCPtr, this, outputType);
    return (cPtr == 0) ? null : new CkTask(cPtr, true);
  }

  public boolean DeleteConvo(String name) {
    return chilkatJNI.CkAi_DeleteConvo(swigCPtr, this, name);
  }

  public boolean ExportConvo(String name, CkJsonObject json) {
    return chilkatJNI.CkAi_ExportConvo(swigCPtr, this, name, CkJsonObject.getCPtr(json), json);
  }

  public void GetLastJsonData(CkJsonObject json) {
    chilkatJNI.CkAi_GetLastJsonData(swigCPtr, this, CkJsonObject.getCPtr(json), json);
  }

  public boolean GetModels(CkStringTable st) {
    return chilkatJNI.CkAi_GetModels(swigCPtr, this, CkStringTable.getCPtr(st), st);
  }

  public CkTask GetModelsAsync(CkStringTable st) {
    long cPtr = chilkatJNI.CkAi_GetModelsAsync(swigCPtr, this, CkStringTable.getCPtr(st), st);
    return (cPtr == 0) ? null : new CkTask(cPtr, true);
  }

  public boolean GetOutputText(CkString outStr) {
    return chilkatJNI.CkAi_GetOutputText(swigCPtr, this, CkString.getCPtr(outStr), outStr);
  }

  public String getOutputText() {
    return chilkatJNI.CkAi_getOutputText(swigCPtr, this);
  }

  public String outputText() {
    return chilkatJNI.CkAi_outputText(swigCPtr, this);
  }

  public boolean GetOutputTextSb(CkStringBuilder sb) {
    return chilkatJNI.CkAi_GetOutputTextSb(swigCPtr, this, CkStringBuilder.getCPtr(sb), sb);
  }

  public boolean ImportConvo(String name, CkJsonObject json) {
    return chilkatJNI.CkAi_ImportConvo(swigCPtr, this, name, CkJsonObject.getCPtr(json), json);
  }

  public boolean InputAddFileData(String filename, CkBinData bd, String summary) {
    return chilkatJNI.CkAi_InputAddFileData(swigCPtr, this, filename, CkBinData.getCPtr(bd), bd, summary);
  }

  public boolean InputAddFileUrl(String url, String summary) {
    return chilkatJNI.CkAi_InputAddFileUrl(swigCPtr, this, url, summary);
  }

  public boolean InputAddImageData(CkBinData bd, String summary) {
    return chilkatJNI.CkAi_InputAddImageData(swigCPtr, this, CkBinData.getCPtr(bd), bd, summary);
  }

  public boolean InputAddImageUrl(String url, String summary) {
    return chilkatJNI.CkAi_InputAddImageUrl(swigCPtr, this, url, summary);
  }

  public boolean InputAddText(String text) {
    return chilkatJNI.CkAi_InputAddText(swigCPtr, this, text);
  }

  public boolean InputAddTextSb(CkStringBuilder sb) {
    return chilkatJNI.CkAi_InputAddTextSb(swigCPtr, this, CkStringBuilder.getCPtr(sb), sb);
  }

  public void InputClear() {
    chilkatJNI.CkAi_InputClear(swigCPtr, this);
  }

  public boolean ListConvos(CkStringTable st) {
    return chilkatJNI.CkAi_ListConvos(swigCPtr, this, CkStringTable.getCPtr(st), st);
  }

  public boolean NewConvo(String name, String sysMsg, String devMsg) {
    return chilkatJNI.CkAi_NewConvo(swigCPtr, this, name, sysMsg, devMsg);
  }

  public boolean NextAiEvent(int maxWaitMs, CkStringBuilder sbName, CkStringBuilder sbDelta) {
    return chilkatJNI.CkAi_NextAiEvent(swigCPtr, this, maxWaitMs, CkStringBuilder.getCPtr(sbName), sbName, CkStringBuilder.getCPtr(sbDelta), sbDelta);
  }

  public int PollAi(boolean abort) {
    return chilkatJNI.CkAi_PollAi(swigCPtr, this, abort);
  }

  public boolean SetConnectionSettings(CkSocket sock) {
    return chilkatJNI.CkAi_SetConnectionSettings(swigCPtr, this, CkSocket.getCPtr(sock), sock);
  }

  public void SleepMs(int millisec) {
    chilkatJNI.CkAi_SleepMs(swigCPtr, this, millisec);
  }

}
