~ubuntu-branches/debian/stretch/openbabel/stretch

« back to all changes in this revision

Viewing changes to scripts/csharp/OBSqrtTbl.cs

  • Committer: Bazaar Package Importer
  • Author(s): Michael Banck
  • Date: 2008-07-22 23:54:58 UTC
  • mfrom: (3.1.10 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080722235458-3o606czluviz4akx
Tags: 2.2.0-2
* Upload to unstable.
* debian/control: Updated descriptions.
* debian/patches/gauss_cube_format.patch: New patch, makes the 
  gaussian cube format available again.
* debian/rules (DEB_DH_MAKESHLIBS_ARGS_libopenbabel3): Removed.
* debian/rules (DEB_CONFIGURE_EXTRA_FLAGS): Likewise.
* debian/libopenbabel3.install: Adjust formats directory to single 
  version hierarchy.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* ----------------------------------------------------------------------------
 
2
 * This file was automatically generated by SWIG (http://www.swig.org).
 
3
 * Version 1.3.36
 
4
 *
 
5
 * Do not make changes to this file unless you know what you are doing--modify
 
6
 * the SWIG interface file instead.
 
7
 * ----------------------------------------------------------------------------- */
 
8
 
 
9
 
 
10
using System;
 
11
using System.Runtime.InteropServices;
 
12
 
 
13
public class OBSqrtTbl : IDisposable {
 
14
  private HandleRef swigCPtr;
 
15
  protected bool swigCMemOwn;
 
16
 
 
17
  internal OBSqrtTbl(IntPtr cPtr, bool cMemoryOwn) {
 
18
    swigCMemOwn = cMemoryOwn;
 
19
    swigCPtr = new HandleRef(this, cPtr);
 
20
  }
 
21
 
 
22
  internal static HandleRef getCPtr(OBSqrtTbl obj) {
 
23
    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
 
24
  }
 
25
 
 
26
  ~OBSqrtTbl() {
 
27
    Dispose();
 
28
  }
 
29
 
 
30
  public virtual void Dispose() {
 
31
    lock(this) {
 
32
      if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
 
33
        swigCMemOwn = false;
 
34
        openbabelPINVOKE.delete_OBSqrtTbl(swigCPtr);
 
35
      }
 
36
      swigCPtr = new HandleRef(null, IntPtr.Zero);
 
37
      GC.SuppressFinalize(this);
 
38
    }
 
39
  }
 
40
 
 
41
  public OBSqrtTbl() : this(openbabelPINVOKE.new_OBSqrtTbl__SWIG_0(), true) {
 
42
  }
 
43
 
 
44
  public OBSqrtTbl(double max, double incr) : this(openbabelPINVOKE.new_OBSqrtTbl__SWIG_1(max, incr), true) {
 
45
  }
 
46
 
 
47
  public double Sqrt(double d2) {
 
48
    double ret = openbabelPINVOKE.OBSqrtTbl_Sqrt(swigCPtr, d2);
 
49
    return ret;
 
50
  }
 
51
 
 
52
  public void Init(double max, double incr) {
 
53
    openbabelPINVOKE.OBSqrtTbl_Init(swigCPtr, max, incr);
 
54
  }
 
55
 
 
56
}