ESLconnection.2017.cs 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. //------------------------------------------------------------------------------
  2. // <auto-generated />
  3. //
  4. // This file was automatically generated by SWIG (http://www.swig.org).
  5. // Version 3.0.12
  6. //
  7. // Do not make changes to this file unless you know what you are doing--modify
  8. // the SWIG interface file instead.
  9. //------------------------------------------------------------------------------
  10. public class ESLconnection : global::System.IDisposable {
  11. private global::System.Runtime.InteropServices.HandleRef swigCPtr;
  12. protected bool swigCMemOwn;
  13. internal ESLconnection(global::System.IntPtr cPtr, bool cMemoryOwn) {
  14. swigCMemOwn = cMemoryOwn;
  15. swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
  16. }
  17. internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ESLconnection obj) {
  18. return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
  19. }
  20. ~ESLconnection() {
  21. Dispose();
  22. }
  23. public virtual void Dispose() {
  24. lock(this) {
  25. if (swigCPtr.Handle != global::System.IntPtr.Zero) {
  26. if (swigCMemOwn) {
  27. swigCMemOwn = false;
  28. ESLPINVOKE.delete_ESLconnection(swigCPtr);
  29. }
  30. swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
  31. }
  32. global::System.GC.SuppressFinalize(this);
  33. }
  34. }
  35. public ESLconnection(string host, int port, string user, string password) : this(ESLPINVOKE.new_ESLconnection__SWIG_0(host, port, user, password), true) {
  36. }
  37. public ESLconnection(string host, int port, string password) : this(ESLPINVOKE.new_ESLconnection__SWIG_1(host, port, password), true) {
  38. }
  39. public ESLconnection(string host, string port, string user, string password) : this(ESLPINVOKE.new_ESLconnection__SWIG_2(host, port, user, password), true) {
  40. }
  41. public ESLconnection(string host, string port, string password) : this(ESLPINVOKE.new_ESLconnection__SWIG_3(host, port, password), true) {
  42. }
  43. public ESLconnection(int socket) : this(ESLPINVOKE.new_ESLconnection__SWIG_4(socket), true) {
  44. }
  45. public int SocketDescriptor() {
  46. int ret = ESLPINVOKE.ESLconnection_SocketDescriptor(swigCPtr);
  47. return ret;
  48. }
  49. public int Connected() {
  50. int ret = ESLPINVOKE.ESLconnection_Connected(swigCPtr);
  51. return ret;
  52. }
  53. public ESLevent GetInfo() {
  54. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_GetInfo(swigCPtr);
  55. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  56. return ret;
  57. }
  58. public int Send(string cmd) {
  59. int ret = ESLPINVOKE.ESLconnection_Send(swigCPtr, cmd);
  60. return ret;
  61. }
  62. public ESLevent SendRecv(string cmd) {
  63. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_SendRecv(swigCPtr, cmd);
  64. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  65. return ret;
  66. }
  67. public ESLevent Api(string cmd, string arg) {
  68. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Api(swigCPtr, cmd, arg);
  69. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  70. return ret;
  71. }
  72. public ESLevent Bgapi(string cmd, string arg, string job_uuid) {
  73. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Bgapi(swigCPtr, cmd, arg, job_uuid);
  74. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  75. return ret;
  76. }
  77. public ESLevent SendEvent(ESLevent send_me) {
  78. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_SendEvent(swigCPtr, ESLevent.getCPtr(send_me));
  79. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  80. return ret;
  81. }
  82. public int sendMSG(ESLevent send_me, string uuid) {
  83. int ret = ESLPINVOKE.ESLconnection_sendMSG(swigCPtr, ESLevent.getCPtr(send_me), uuid);
  84. return ret;
  85. }
  86. public ESLevent RecvEvent() {
  87. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEvent(swigCPtr);
  88. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  89. return ret;
  90. }
  91. public ESLevent RecvEventTimed(int ms) {
  92. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEventTimed(swigCPtr, ms);
  93. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  94. return ret;
  95. }
  96. public ESLevent Filter(string header, string value) {
  97. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Filter(swigCPtr, header, value);
  98. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  99. return ret;
  100. }
  101. public int Events(string etype, string value) {
  102. int ret = ESLPINVOKE.ESLconnection_Events(swigCPtr, etype, value);
  103. return ret;
  104. }
  105. public ESLevent Execute(string app, string arg, string uuid) {
  106. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Execute(swigCPtr, app, arg, uuid);
  107. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  108. return ret;
  109. }
  110. public ESLevent ExecuteAsync(string app, string arg, string uuid) {
  111. global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_ExecuteAsync(swigCPtr, app, arg, uuid);
  112. ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
  113. return ret;
  114. }
  115. public int SetAsyncExecute(string val) {
  116. int ret = ESLPINVOKE.ESLconnection_SetAsyncExecute(swigCPtr, val);
  117. return ret;
  118. }
  119. public int SetEventLock(string val) {
  120. int ret = ESLPINVOKE.ESLconnection_SetEventLock(swigCPtr, val);
  121. return ret;
  122. }
  123. public int Disconnect() {
  124. int ret = ESLPINVOKE.ESLconnection_Disconnect(swigCPtr);
  125. return ret;
  126. }
  127. }