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

« back to all changes in this revision

Viewing changes to include/inchi103/inchi_api.h

  • Committer: Package Import Robot
  • Author(s): Daniel Leidert
  • Date: 2013-05-22 19:08:27 UTC
  • mfrom: (1.1.11) (7.1.9 sid)
  • Revision ID: package-import@ubuntu.com-20130522190827-72q0fnx5y2nm3bc0
Tags: 2.3.2+dfsg-1
* New upstream release.
* debian/control: Dropped DM-Upload-Allowed field.
  (Standards-Version): Bumped to 3.9.4.
* debian/copyright: Massive update.
* debian/upstream: Author name update.
* debian/get-orig-source.sh: Remove the windows-*/ directory too.
* debian/openbabel.install: Removed roundtrip manpage.
* debian/openbabel-gui.install: Fixed manpage name.
* debian/openbabel-gui.links: Removed unused file.
* debian/rules: Enable OpenMP. Disable tests on `nocheck'.
* debian/patches/gaussformat_nosym.patch: Dropped. Applied upstream.
* debian/patches/moldenformat_coordonly.patch: Ditto.
* debian/patches/obspectrophore_man.patch: Ditto.
* debian/patches/fix_ftbfs.patch: Added.
  - Fix several FTBFS issues in upstream build system.
* debian/patches/series: Adjusted.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * International Chemical Identifier (InChI)
3
 
 * Version 1
4
 
 * Software version 1.03
5
 
 * May 9, 2010
6
 
 *
7
 
 * Originally developed at NIST
8
 
 * Modifications and additions by IUPAC and the InChI Trust
9
 
 *
10
 
 * The InChI library and programs are free software developed under the
11
 
 * auspices of the International Union of Pure and Applied Chemistry (IUPAC);
12
 
 * you can redistribute this software and/or modify it under the terms of 
13
 
 * the GNU Lesser General Public License as published by the Free Software 
14
 
 * Foundation:
15
 
 * http://www.opensource.org/licenses/lgpl-2.1.php
16
 
 */
17
 
 
18
 
 
19
 
#ifndef __INHCH_API_H__
20
 
#define __INHCH_API_H__
21
 
 
22
 
 
23
 
 
24
 
 
25
 
/*^^^ Post-1.02b fix - thanks to David Foss */
26
 
#ifndef FIND_RING_SYSTEMS
27
 
#define FIND_RING_SYSTEMS 1
28
 
#endif
29
 
#ifndef FIND_RINS_SYSTEMS_DISTANCES
30
 
#define FIND_RINS_SYSTEMS_DISTANCES 0
31
 
#endif
32
 
 
33
 
 
34
 
/* radical definitions */
35
 
typedef enum tagINCHIRadical {
36
 
   INCHI_RADICAL_NONE    = 0,
37
 
   INCHI_RADICAL_SINGLET = 1,
38
 
   INCHI_RADICAL_DOUBLET = 2,
39
 
   INCHI_RADICAL_TRIPLET = 3
40
 
} inchi_Radical;
41
 
 
42
 
/* bond type definitions */
43
 
typedef enum tagINCHIBondType {
44
 
   INCHI_BOND_TYPE_NONE    =  0,
45
 
   INCHI_BOND_TYPE_SINGLE  =  1,
46
 
   INCHI_BOND_TYPE_DOUBLE  =  2,
47
 
   INCHI_BOND_TYPE_TRIPLE  =  3,
48
 
   INCHI_BOND_TYPE_ALTERN  =  4  /* avoid by all means */
49
 
} inchi_BondType;
50
 
/* 2D stereo definitions */
51
 
typedef enum tagINCHIBondStereo2D {
52
 
   /* stereocenter-related; positive: the sharp end points to this atom  */
53
 
   INCHI_BOND_STEREO_NONE           =  0,
54
 
   INCHI_BOND_STEREO_SINGLE_1UP     =  1,
55
 
   INCHI_BOND_STEREO_SINGLE_1EITHER =  4,
56
 
   INCHI_BOND_STEREO_SINGLE_1DOWN   =  6,
57
 
   /* stereocenter-related; negative: the sharp end points to the opposite atom  */
58
 
   INCHI_BOND_STEREO_SINGLE_2UP     = -1,
59
 
   INCHI_BOND_STEREO_SINGLE_2EITHER = -4,
60
 
   INCHI_BOND_STEREO_SINGLE_2DOWN   = -6,
61
 
   /* stereobond-related */
62
 
   INCHI_BOND_STEREO_DOUBLE_EITHER  =  3 /* unknown stereobond geometry */
63
 
} inchi_BondStereo2D;
64
 
 
65
 
/*************************************************************************
66
 
 * Notes on using INCHI_BOND_STEREO_SINGLE_*  from inchi_BondStereo2D    *
67
 
 *                                                                       *
68
 
 * These stereo markings are used by InChI to characterize a stereogenic *
69
 
 * atom if and only if all neighbors of this atom have same z-coordinate *
70
 
 * as this atom (that is, in case of 2D fragment).                       *
71
 
 * The only exception is INCHI_BOND_STEREO_SINGLE_?EITHER marking which  *
72
 
 * always assigns to the atom an "unknown" parity (u).                   *
73
 
 *                                                                       *
74
 
 * Note the behavior which is default for InChI software v. 1.03/1.02std *
75
 
 * (at -NEWPSOFF option is not supplied) 2D stereo interpretation:       *
76
 
 * only bonds that have sharp end pointing to the stereogenic atom are   *
77
 
 * considered as being out of plane and only sharp ends of               *
78
 
 * INCHI_BOND_STEREO_SINGLE_?EITHER bonds are considered to determine    *
79
 
 * whether the stereochemistry is unknown.                               *
80
 
 *************************************************************************/
81
 
 
82
 
/* sizes definitions */
83
 
#define MAXVAL                   20 /* max number of bonds per atom                 */
84
 
#define ATOM_EL_LEN               6 /* length of ASCIIZ element symbol field        */
85
 
#define NUM_H_ISOTOPES            3 /* number of hydrogen isotopes: protium, D, T   */
86
 
#define ISOTOPIC_SHIFT_FLAG   10000 /* add to isotopic mass if isotopic_mass =      */
87
 
                                    /* (isotopic mass - average atomic mass)        */
88
 
#define ISOTOPIC_SHIFT_MAX      100 /* max abs(isotopic mass - average atomic mass) */
89
 
 
90
 
#ifndef INCHI_US_CHAR_DEF
91
 
typedef signed char   S_CHAR;
92
 
typedef unsigned char U_CHAR;
93
 
#define INCHI_US_CHAR_DEF
94
 
#endif
95
 
 
96
 
#ifndef INCHI_US_SHORT_DEF
97
 
typedef signed short   S_SHORT;
98
 
typedef unsigned short U_SHORT;
99
 
#define INCHI_US_SHORT_DEF
100
 
#endif
101
 
 
102
 
typedef  S_SHORT AT_NUM;            /* atom number; starts from 0 */
103
 
 
104
 
/*************************************************
105
 
 *
106
 
 *
107
 
 *  A T O M S   a n d   C O N N E C T I V I T Y
108
 
 *
109
 
 *
110
 
 *************************************************/
111
 
 
112
 
typedef struct tagInchiAtom {
113
 
    /* atom coordinates */
114
 
    double x;
115
 
    double y;
116
 
    double z;
117
 
    /* connectivity */
118
 
    AT_NUM  neighbor[MAXVAL];     /* adjacency list: ordering numbers of */
119
 
                                  /*            the adjacent atoms, >= 0 */
120
 
    S_CHAR  bond_type[MAXVAL];    /* inchi_BondType */
121
 
    /* 2D stereo */
122
 
    S_CHAR  bond_stereo[MAXVAL];  /* inchi_BondStereo2D; negative if the */
123
 
                                  /* sharp end points to opposite atom */
124
 
    /* other atom properties */
125
 
    char    elname[ATOM_EL_LEN];  /* zero-terminated chemical element name:*/
126
 
                                  /* "H", "Si", etc. */
127
 
    AT_NUM  num_bonds;            /* number of neighbors, bond types and bond*/
128
 
                                  /* stereo in the adjacency list */
129
 
    S_CHAR  num_iso_H[NUM_H_ISOTOPES+1]; /* implicit hydrogen atoms */
130
 
                                  /* [0]: number of implicit non-isotopic H
131
 
                                       (exception: num_iso_H[0]=-1 means INCHI
132
 
                                       adds implicit H automatically),
133
 
                                     [1]: number of implicit isotopic 1H (protium),
134
 
                                     [2]: number of implicit 2H (deuterium),
135
 
                                     [3]: number of implicit 3H (tritium) */
136
 
    AT_NUM  isotopic_mass;        /* 0 => non-isotopic; isotopic mass or  */
137
 
                                  /* ISOTOPIC_SHIFT_FLAG + mass - (average atomic mass) */
138
 
    S_CHAR  radical;              /* inchi_Radical */
139
 
    S_CHAR  charge;               /* positive or negative; 0 => no charge */
140
 
}inchi_Atom;
141
 
 
142
 
/*******************************************************************
143
 
 * Notes: 1. Atom ordering numbers (i, k, and atom[i].neighbor[j] below)
144
 
 *           start from zero; max. ordering number is (num_atoms-1).
145
 
 *        2. inchi_Atom atom[i] is connected to the atom[atom[i].neighbor[j]]
146
 
 *           by a bond that has type atom[i].bond_type[j] and 2D stereo type
147
 
 *           atom[i].bond_stereo[j] (in case of no stereo
148
 
 *           atom[i].bond_stereo[j] = INCHI_BOND_STEREO_NONE)
149
 
 *           Index j is in the range 0 <= j <= (atom[i].num_bonds-1)
150
 
 *        3. Any connection (represented by atom[i].neighbor[j],
151
 
 *           atom[i].bond_type[j], and atom[i].bond_stereo[j])
152
 
 *           should be present in one or both adjacency list:
153
 
 *             if k = atom[i].neighbor[j] then i may or may not be present in
154
 
 *           atom[k].neighbor[] list. For example, the adjacency lists may be
155
 
 *           populated with only such neighbors that atom[i].neighbor[j] < i
156
 
 *           All elements of an adjacency list must be different, that is,
157
 
 *           a bond must be specified in an adjacency list only once.
158
 
 *        4. in Molfiles usually
159
 
 *           (number of implicit H) = Valence - SUM(bond_type[])
160
 
 *        5. Seemingly illogical order of the inchi_Atom members was
161
 
 *           chosen in an attempt to avoid alignment problems when
162
 
 *           accessing inchi_Atom from unrelated to C programming
163
 
 *           languages such as Visual Basic.
164
 
 *******************************************************************/
165
 
 
166
 
/*******************************************************************
167
 
    0D Stereo Parity and Type definitions
168
 
 *******************************************************************
169
 
            Note:
170
 
            =====
171
 
            o Below #A is the ordering number of atom A, starting from 0
172
 
            o See parity values corresponding to 'o', 'e', and 'u' in
173
 
              inchi_StereoParity0D definition below)
174
 
 
175
 
           =============================================
176
 
            stereogenic bond >A=B< or cumulene >A=C=C=B<
177
 
           =============================================
178
 
 
179
 
                                 neighbor[4]  : {#X,#A,#B,#Y} in this order
180
 
     X                           central_atom : NO_ATOM
181
 
      \            X      Y      type         : INCHI_StereoType_DoubleBond
182
 
       A==B         \    /
183
 
           \         A==B
184
 
            Y
185
 
 
186
 
    parity= 'e'    parity= 'o'   unknown parity = 'u'
187
 
 
188
 
    Limitations:
189
 
    ============
190
 
    o Atoms A and B in cumulenes MUST be connected by a chain of double bonds;
191
 
      atoms A and B in a stereogenic 'double bond' may be connected by a double,
192
 
      single, or alternating bond.
193
 
    o One atom may belong to up to 3 stereogenic bonds (i.g. in a fused
194
 
      aromatic structure).
195
 
    o Multiple stereogenic bonds incident to any given atom should
196
 
      either all except possibly one have (possibly different) defined
197
 
      parities ('o' or 'e') or should all have an unknown parity 'u'.
198
 
 
199
 
      Note on parities of alternating stereobonds
200
 
      ===========================================
201
 
                                                     D--E
202
 
      In large rings  (see Fig. 1, all              //   \\
203
 
      atoms are C) all alternating bonds         B--C      F--G
204
 
      are treated as stereogenic.              //              \\
205
 
      To avoid "undefined" bond parities      A                  H
206
 
      for bonds BC, DE, FG, HI, JK, LM, AN     \               /
207
 
      it is recommended to mark them with       N==M       J==I
208
 
      parities.                                     \     /
209
 
                                                      L==K    Fig. 1
210
 
      Such a marking will make
211
 
      the stereochemical layer unambiguous
212
 
      and it will be different from the          B--C      F--G
213
 
      stereochemical layer of the second       //   \\   //    \\
214
 
      structure (Fig. 2).                     A      D--E        H
215
 
                                               \               /
216
 
                                                N==M       J==I
217
 
      By default, double and alternating            \     /
218
 
      bonds in 8-member and greater rings             L==K    Fig. 2
219
 
      are treated by InChI as stereogenic.
220
 
 
221
 
 
222
 
           =============================================
223
 
            tetrahedral atom
224
 
           =============================================
225
 
 
226
 
   4 neighbors
227
 
 
228
 
            X                    neighbor[4] : {#W, #X, #Y, #Z}
229
 
            |                    central_atom: #A
230
 
         W--A--Y                 type        : INCHI_StereoType_Tetrahedral
231
 
            |
232
 
            Z
233
 
   parity: if (X,Y,Z) are clockwize when seen from W then parity is 'e' otherwise 'o'
234
 
   Example (see AXYZW above): if W is above the plane XYZ then parity = 'e'
235
 
 
236
 
   3 neighbors
237
 
 
238
 
              Y          Y       neighbor[4] : {#A, #X, #Y, #Z}
239
 
             /          /        central_atom: #A
240
 
         X--A  (e.g. O=S   )     type        : INCHI_StereoType_Tetrahedral
241
 
             \          \
242
 
              Z          Z
243
 
 
244
 
   parity: if (X,Y,Z) are clockwize when seen from A then parity is 'e',
245
 
                                                          otherwise 'o'
246
 
   unknown parity = 'u'
247
 
   Example (see AXYZ above): if A is above the plane XYZ then parity = 'e'
248
 
   This approach may be used also in case of an implicit H attached to A.
249
 
 
250
 
           =============================================
251
 
            allene
252
 
           =============================================
253
 
 
254
 
       X       Y                 neighbor[4]  : {#X,#A,#B,#Y}
255
 
        \     /                  central_atom : #C
256
 
         A=C=B                   type         : INCHI_StereoType_Allene
257
 
 
258
 
                                      Y      X
259
 
                                      |      |
260
 
     when seen from A along A=C=B:  X-A    Y-A
261
 
 
262
 
                          parity:   'e'    'o'
263
 
 
264
 
   parity: if A, B, Y are clockwise when seen from X then parity is 'e',
265
 
                                                          otherwise 'o'
266
 
   unknown parity = 'u'
267
 
   Example (see XACBY above): if X on the diagram is above the plane ABY
268
 
                                                      then parity is 'o'
269
 
 
270
 
   Limitations
271
 
   ===========
272
 
   o Atoms A and B in allenes MUST be connected by a chain of double bonds;
273
 
 
274
 
   ==============================================
275
 
   Note. Correspondence to CML 0D stereo parities
276
 
   ==============================================
277
 
   a list of 4 atoms corresponds to CML atomRefs4
278
 
 
279
 
   tetrahedral atom
280
 
   ================
281
 
       CML atomParity > 0 <=> INCHI_PARITY_EVEN
282
 
       CML atomParity < 0 <=> INCHI_PARITY_ODD
283
 
 
284
 
                                    | 1   1   1   1  |  where xW is x-coordinate of
285
 
                                    | xW  xX  xY  xZ |  atom W, etc. (xyz is a
286
 
       CML atomParity = determinant | yW  yX  yY  yZ |  'right-handed' Cartesian
287
 
                                    | zW  zX  xY  zZ |  coordinate system)
288
 
 
289
 
   allene (not yet defined in CML)
290
 
   ===============================
291
 
   the parity corresponds to the sign of the following determinant
292
 
   in exactly same way as for tetrahedral atoms:
293
 
 
294
 
       | 1   1   1   1  |  where bonds and neighbor[4] array are
295
 
       | xX  xA  xB  xY |  same as defined above for allenes
296
 
       | yX  yA  yB  yY |  Obviously, the parity is same for
297
 
       | zX  zA  xB  zY |  {#X,#A,#B,#Y} and {#Y,#B,#A,#X}
298
 
                           because of the even number of column permutations.
299
 
 
300
 
   stereogenic double bond and (not yet defined in CML) cumulenes
301
 
   ==============================================================
302
 
       CML 'C' (cis)      <=> INCHI_PARITY_ODD
303
 
       CML 'T' (trans)    <=> INCHI_PARITY_EVEN
304
 
 
305
 
 
306
 
   How InChI uses 0D parities
307
 
   ==========================
308
 
 
309
 
   1. 0D parities are used if all atom coordinates are zeroes.
310
 
 
311
 
   In addition to that:
312
 
 
313
 
   2. 0D parities are used for Stereobonds, Allenes, or Cumulenes if:
314
 
 
315
 
   2a. A bond to the end-atom is shorter than MIN_BOND_LEN=0.000001
316
 
   2b. A ratio of two bond lengths to the end-atom is smaller than MIN_SINE=0.03
317
 
   2c. In case of a linear fragment X-A=B end-atom A is treated as satisfying 2a-b
318
 
 
319
 
       0D parities are used if 2a or 2b or 2c applies to one or both end-atoms.
320
 
 
321
 
   3. 0D parities are used for Tetrahedral Atoms if at least one of 3a-c is true:
322
 
 
323
 
   3a. One of bonds to the central atom is shorter than MIN_BOND_LEN=0.000001
324
 
   3b. A ratio of two bond lengths to the central atom is smaller than MIN_SINE=0.03
325
 
   3c. The four neighbors are almost in one plane or the central atom and
326
 
       its only 3 explicit neighbors are almost in one plane
327
 
 
328
 
   Notes on 0D parities and 'undefined' stereogenic elements
329
 
   =========================================================
330
 
 
331
 
   If 0D parity is to be used according to 1-3 but    CH3     CH3
332
 
   has not been provided then the corresponding         \    /
333
 
   stereogenic element is considered 'undefined'.        C=CH
334
 
                                                        /
335
 
   For example, if in the structure (Fig. 3)           H
336
 
   the explicit H has been moved so that it                Fig. 3
337
 
   has same coordinates as atom >C= (that is,
338
 
   the length of the bond H-C became zero)
339
 
   then the double bond is assigned 'undefined'       CH3      CH3
340
 
   parity which by default is omitted from the          \     /
341
 
   Identifier.                                           CH=CH
342
 
 
343
 
   However, the structure on Fig. 4 will have double        Fig. 4
344
 
   bond parity 'o' and its parity in the Identifier is (-).
345
 
 
346
 
   Notes on 0D parities in structures containing metals
347
 
   ====================================================
348
 
   Since InChI disconnects bonds to metals the 0D parities upon the
349
 
   disconnection may change in several different ways:
350
 
 
351
 
   1) previously non-stereogenic bond may become stereogenic:
352
 
 
353
 
         \     /                            \     /  
354
 
          CH==CH          disconnection      CH==CH  
355
 
           \ /               ======>                 
356
 
            M                                  M     
357
 
 
358
 
     before the disconnection:    after the disconnection:
359
 
     atoms C have valence=5 and   the double bond may become
360
 
     the double bond is not       stereogenic
361
 
     recognized as stereogenic
362
 
 
363
 
   2) previously stereogenic bond may become non-stereogenic:
364
 
 
365
 
       M                           M(+)       
366
 
        \    /                             / 
367
 
         N==C      disconnection    (-)N==C  
368
 
             \        ======>              \ 
369
 
 
370
 
   3) Oddball structures, usually resulting from projecting 3D
371
 
      structures on the plane, may contain fragment like that
372
 
      depicted on Fig. 5:
373
 
 
374
 
              M   A                      M   A   
375
 
              |\ /   B                      /   B 
376
 
              | X   /     disconnection    /   /  
377
 
              |/ \ /         ======>      /   /   
378
 
              C===C                      C===C    
379
 
             Fig. 5
380
 
     (X stands for bond intersection)
381
 
    
382
 
     A-C=C-B parity is              A-C=C-B parity is
383
 
     trans (e)                      cis (o) or undefined
384
 
     because the bond               because C valence = 3,
385
 
     orientation is same            not 4.
386
 
     as on Fig, 6 below:
387
 
 
388
 
          A       M
389
 
           \     /     Removal of M from the structure
390
 
            C===C      on Fig. 5 changes the geometry from trans
391
 
           /     \     to cis. 
392
 
          M'      B    Removal of M and M' from the structure
393
 
          Fig. 6       on Fig. 6 does not change the A-C=C-B
394
 
                       geometry: it is trans.
395
 
 
396
 
   To resolve the problem InChI API accepts the second parity
397
 
   corresponding to the metal-disconnected structure.
398
 
   To store both bond parities use left shift by 3 bits:
399
 
 
400
 
   inchi_Stereo0D::parity = ParityOfConnected | (ParityOfDisconnected<<3)
401
 
 
402
 
   In case when only disconnected structure parity exists set
403
 
   ParityOfConnected = INCHI_PARITY_UNDEFINED.
404
 
   This is the only case when INCHI_PARITY_UNDEFINED parity
405
 
   may be fed to the InChI.
406
 
 
407
 
   In cases when the bond parity in a disconnected structure exists and
408
 
   differs from the parity in the connected structure the atoms A and B
409
 
   should be non-metals.
410
 
 
411
 
****************************************************************************/
412
 
 
413
 
#define NO_ATOM          (-1) /* non-existent (central) atom */
414
 
 
415
 
/* 0D parity types */
416
 
typedef enum tagINCHIStereoType0D {
417
 
   INCHI_StereoType_None        = 0,
418
 
   INCHI_StereoType_DoubleBond  = 1,
419
 
   INCHI_StereoType_Tetrahedral = 2,
420
 
   INCHI_StereoType_Allene      = 3
421
 
} inchi_StereoType0D;
422
 
 
423
 
/* 0D parities */
424
 
typedef enum tagINCHIStereoParity0D {
425
 
   INCHI_PARITY_NONE      = 0,
426
 
   INCHI_PARITY_ODD       = 1,  /* 'o' */
427
 
   INCHI_PARITY_EVEN      = 2,  /* 'e' */
428
 
   INCHI_PARITY_UNKNOWN   = 3,  /* 'u' */ /* (see also readinch.c)
429
 
                                          used in: Extract0DParities, INChITo_Atom  */
430
 
   INCHI_PARITY_UNDEFINED = 4   /* '?' -- should not be used; however, see Note above */
431
 
} inchi_StereoParity0D;
432
 
 
433
 
 
434
 
/*************************************************
435
 
 *
436
 
 *
437
 
 *  0D - S T E R E O  (if no coordinates given)
438
 
 *
439
 
 *
440
 
 *************************************************/
441
 
 
442
 
 
443
 
typedef struct tagINCHIStereo0D {
444
 
    AT_NUM  neighbor[4];    /* 4 atoms always */
445
 
    AT_NUM  central_atom;   /* central tetrahedral atom or a central */
446
 
                            /* atom of allene; otherwise NO_ATOM */
447
 
    S_CHAR  type;           /* inchi_StereoType0D */
448
 
    S_CHAR  parity;         /* inchi_StereoParity0D: may be a combination of two parities: */
449
 
                            /* ParityOfConnected | (ParityOfDisconnected << 3), see Note above */
450
 
}inchi_Stereo0D;
451
 
 
452
 
 
453
 
 
454
 
 
455
 
/*************************************************
456
 
 *
457
 
 *
458
 
 *  I N C h I    D L L     I n p u t
459
 
 *
460
 
 *
461
 
 *************************************************/
462
 
 
463
 
 
464
 
/* Structure -> InChI, GetINCHI() / GetStdINCHI() */
465
 
typedef struct tagINCHI_Input {
466
 
    /* the caller is responsible for the data allocation and deallocation */
467
 
    inchi_Atom     *atom;         /* array of num_atoms elements */
468
 
    inchi_Stereo0D *stereo0D;     /* array of num_stereo0D 0D stereo elements or NULL */
469
 
    char           *szOptions;    /* InChI options: space-delimited; each is preceded by */
470
 
                                  /* '/' or '-' depending on OS and compiler */
471
 
    AT_NUM          num_atoms;    /* number of atoms in the structure < 1024 */
472
 
    AT_NUM          num_stereo0D; /* number of 0D stereo elements */
473
 
}inchi_Input;
474
 
 
475
 
/* InChI -> Structure, GetStructFromINCHI()/GetStructFromStdINCHI() */
476
 
typedef struct tagINCHI_InputINCHI {
477
 
    /* the caller is responsible for the data allocation and deallocation */
478
 
    char *szInChI;     /* InChI ASCIIZ string to be converted to a strucure */
479
 
    char *szOptions;   /* InChI options: space-delimited; each is preceded by */
480
 
                       /* '/' or '-' depending on OS and compiler */
481
 
} inchi_InputINCHI;
482
 
 
483
 
 
484
 
/*************************************************
485
 
 *
486
 
 *
487
 
 *  I N C h I     D L L     O u t p u t
488
 
 *
489
 
 *
490
 
 *************************************************/
491
 
 
492
 
/* Structure -> InChI */
493
 
typedef struct tagINCHI_Output {
494
 
    /* zero-terminated C-strings allocated by GetStdINCHI() */
495
 
    /* to deallocate all of them call FreeStdINCHI() (see below) */
496
 
    char *szInChI;     /* InChI ASCIIZ string */
497
 
    char *szAuxInfo;   /* Aux info ASCIIZ string */
498
 
    char *szMessage;   /* Error/warning ASCIIZ message */
499
 
    char *szLog;       /* log-file ASCIIZ string, contains a human-readable list */
500
 
                       /* of recognized options and possibly an Error/warning message */
501
 
} inchi_Output;
502
 
 
503
 
/* InChI -> Structure */
504
 
typedef struct tagINCHI_OutputStruct {
505
 
    /* 4 pointers are allocated by GetStructFromINCHI()/GetStructFromStdINCHI()     */
506
 
    /* to deallocate all of them call FreeStructFromStdINCHI()/FreeStructFromStdINCHI() */
507
 
    inchi_Atom     *atom;         /* array of num_atoms elements */
508
 
    inchi_Stereo0D *stereo0D;     /* array of num_stereo0D 0D stereo elements or NULL */
509
 
    AT_NUM          num_atoms;    /* number of atoms in the structure < 1024 */
510
 
    AT_NUM          num_stereo0D; /* number of 0D stereo elements */
511
 
    char           *szMessage;    /* Error/warning ASCIIZ message */
512
 
    char           *szLog;        /* log-file ASCIIZ string, contains a human-readable list */
513
 
                                  /* of recognized options and possibly an Error/warning message */
514
 
    unsigned long  WarningFlags[2][2]; /* warnings, see INCHIDIFF in inchicmp.h */
515
 
                                       /* [x][y]: x=0 => Reconnected if present in InChI otherwise Disconnected/Normal
516
 
                                                  x=1 => Disconnected layer if Reconnected layer is present
517
 
                                                  y=1 => Main layer or Mobile-H
518
 
                                                  y=0 => Fixed-H layer
519
 
                                        */
520
 
}inchi_OutputStruct;
521
 
 
522
 
 
523
 
 
524
 
 
525
 
/*************************************************
526
 
 *
527
 
 *
528
 
 *  I N C h I      D L L     I n t e r f a c e
529
 
 *
530
 
 *
531
 
 *************************************************/
532
 
 
533
 
#if (defined( _WIN32 ) && defined( _MSC_VER ) && defined(INCHI_LINK_AS_DLL) )
534
 
    /* Win32 & MS VC ++, compile and link as a DLL */
535
 
    #ifdef _USRDLL
536
 
        /* InChI library dll */
537
 
        #define INCHI_API __declspec(dllexport)
538
 
        #define EXPIMP_TEMPLATE
539
 
        #define INCHI_DECL __stdcall
540
 
     #else
541
 
        /* calling the InChI dll program */
542
 
        #define INCHI_API __declspec(dllimport)
543
 
        #define EXPIMP_TEMPLATE extern
544
 
        #define INCHI_DECL __stdcall
545
 
     #endif
546
 
#else
547
 
    /* create a statically linked InChI library or link to an executable */
548
 
    #define INCHI_API
549
 
    #define EXPIMP_TEMPLATE
550
 
    #define INCHI_DECL
551
 
#endif
552
 
 
553
 
/*^^^ Return codes for 
554
 
        GetINCHI 
555
 
        GetStdINCHI 
556
 
        Get_inchi_Input_FromAuxInfo 
557
 
        Get_std_inchi_Input_FromAuxInfo 
558
 
                GetStructFromINCHI
559
 
                GetStructFromStdINCHI
560
 
*/
561
 
typedef enum tagRetValGetINCHI {
562
 
    inchi_Ret_SKIP    = -2, /* not used in InChI library */
563
 
    inchi_Ret_EOF     = -1, /* no structural data has been provided */
564
 
    inchi_Ret_OKAY    =  0, /* Success; no errors or warnings */
565
 
    inchi_Ret_WARNING =  1, /* Success; warning(s) issued */
566
 
    inchi_Ret_ERROR   =  2, /* Error: no InChI has been created */
567
 
    inchi_Ret_FATAL   =  3, /* Severe error: no InChI has been created (typically, memory allocation failure) */
568
 
    inchi_Ret_UNKNOWN =  4, /* Unknown program error */
569
 
    inchi_Ret_BUSY    =  5  /* Previuos call to InChI has not returned yet */
570
 
 
571
 
} RetValGetINCHI;
572
 
 
573
 
/*^^^ Return codes for CheckINCHI */
574
 
typedef enum tagRetValCheckINCHI 
575
 
{
576
 
    INCHI_VALID_STANDARD     =   0,
577
 
    INCHI_VALID_NON_STANDARD =  -1,    
578
 
    INCHI_INVALID_PREFIX     =   1,
579
 
    INCHI_INVALID_VERSION    =   2,
580
 
    INCHI_INVALID_LAYOUT     =   3,
581
 
    INCHI_FAIL_I2I           =   4
582
 
    
583
 
} RetValCheckINCHI;
584
 
 
585
 
 
586
 
 
587
 
/* to compile all InChI code as a C++ code #define INCHI_ALL_CPP */
588
 
#ifndef INCHI_ALL_CPP
589
 
#ifdef __cplusplus
590
 
extern "C" {
591
 
#endif
592
 
#endif
593
 
 
594
 
 
595
 
/*^^^ InChI PREFIX */
596
 
#define INCHI_STRING_PREFIX "InChI="
597
 
#define LEN_INCHI_STRING_PREFIX 6
598
 
 
599
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
600
 
Format:
601
 
    
602
 
    Standard InChI starts with: InChI=1S/
603
 
    Non-standard one with:      InChI=1/
604
 
    Empty std InChI:            InChI=1S//
605
 
    Empty InChI:                InChI=1//
606
 
                                AuxInfo=1//
607
 
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
608
 
 
609
 
 
610
 
 
611
 
 
612
 
/* EXPORTED FUNCTIONS */
613
 
 
614
 
 
615
 
 
616
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
617
 
GetINCHI / GetStdINCHI
618
 
 
619
 
 
620
 
    inchi_Input is created by the user; strings in inchi_Output are allocated and deallocated by InChI
621
 
    inchi_Output does not need to be initilized out to zeroes; see FreeNCHI()/FreeSTDINCHI() on how to deallocate it
622
 
 
623
 
 
624
 
    Valid options for GetINCHI:
625
 
    (use - instead of / for O.S. other than MS Windows)
626
 
 
627
 
    Structure perception (compatible with stdInChI)                     
628
 
        /NEWPSOFF   /DoNotAddH   /SNon
629
 
    Stereo interpretation (lead to generation of non-standard InChI)
630
 
        /SRel /SRac /SUCF /ChiralFlagON /ChiralFlagOFF
631
 
    InChI creation options (lead to generation of non-standard InChI)
632
 
        /SUU /SLUUD   /FixedH  /RecMet  /KET /15T
633
 
 
634
 
    
635
 
    GetINCHI produces standard InChI if no InChI creation/stereo modification options 
636
 
    are specified. Inveresely, if any of SUU/SLUUD/RecMet/FixedH/Ket/15T/SRel/SRac/SUCF 
637
 
    options are specified, generated InChI will be non-standard one. 
638
 
 
639
 
    
640
 
    GetStdINCHI produces standard InChI only. 
641
 
    The valid structure perception options are:
642
 
        /NEWPSOFF   /DoNotAddH   /SNon
643
 
 
644
 
    
645
 
    Other options are:    
646
 
        /AuxNone    Omit auxiliary information (default: Include)
647
 
        /Wnumber    Set time-out per structure in seconds; W0 means unlimited
648
 
                    In InChI library the default value is unlimited
649
 
        /OutputSDF  Output SDfile instead of InChI
650
 
        /WarnOnEmptyStructure 
651
 
                    Warn and produce empty InChI for empty structure
652
 
        /SaveOpt    Save custom InChI creation options (non-standard InChI)
653
 
 
654
 
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
655
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetINCHI( inchi_Input *inp, inchi_Output *out );
656
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetStdINCHI( inchi_Input *inp, inchi_Output *out );
657
 
 
658
 
 
659
 
 
660
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
661
 
FreeINCHI / FreeStdINCHI
662
 
 
663
 
    should be called to deallocate char* pointers 
664
 
    obtained from each GetINCHI /GetStdINCHI call                         
665
 
 
666
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
667
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL FreeINCHI ( inchi_Output *out );
668
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL FreeStdINCHI ( inchi_Output *out );
669
 
 
670
 
 
671
 
 
672
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
673
 
GetStringLength
674
 
    
675
 
    helper: get string length
676
 
 
677
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
678
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetStringLength( char *p );
679
 
 
680
 
 
681
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
682
 
GetStructFromINCHI / GetStructFromStdINCHI
683
 
 
684
 
    inchi_Inputinchi_InputINCHI is created by the user; pointers in inchi_OutputStruct are allocated and deallocated by InChI 
685
 
    inchi_OutputStruct does not need to be initilized out to zeroes; see FreeStructFromStdINCHI() on how to deallocate it 
686
 
    Option /Inchi2Struct is not needed for GetStructFromINCHI()/GetStructFromStdINCHI()
687
 
 
688
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
689
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetStructFromINCHI( inchi_InputINCHI *inpInChI, inchi_OutputStruct *outStruct );
690
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetStructFromStdINCHI( inchi_InputINCHI *inpInChI, inchi_OutputStruct *outStruct );
691
 
 
692
 
 
693
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
694
 
FreeStructFromINCHI / FreeStructFromStdINCHI
695
 
 
696
 
    should be called to deallocate pointers obtained from each 
697
 
    GetStructFromStdINCHI / GetStructFromINCHI
698
 
 
699
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
700
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL FreeStructFromINCHI( inchi_OutputStruct *out );
701
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL FreeStructFromStdINCHI( inchi_OutputStruct *out );
702
 
 
703
 
 
704
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
705
 
GetINCHIfromINCHI
706
 
 
707
 
    GetINCHIfromINCHI does same as -InChI2InChI option: converts InChI into InChI for validation purposes    
708
 
    It may also be used to filter out specific layers. For instance, /Snon would remove stereochemical layer 
709
 
    Omitting /FixedH and/or /RecMet would remove Fixed-H or Reconnected layers                               
710
 
    To keep all InChI layers use options string "/FixedH /RecMet"; option /InChI2InChI is not needed         
711
 
    inchi_InputINCHI is created by the user; strings in inchi_Output are allocated and deallocated by InChI  
712
 
    inchi_Output does not need to be initilized out to zeroes; see FreeINCHI() on how to deallocate it  
713
 
                                                                                                        
714
 
    Note: there is no explicit tool to conversion from/to standard InChI                                   
715
 
 
716
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
717
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetINCHIfromINCHI( inchi_InputINCHI *inpInChI, inchi_Output *out );
718
 
 
719
 
#ifndef INCHI_ALL_CPP
720
 
#ifdef __cplusplus
721
 
}
722
 
#endif
723
 
#endif
724
 
 
725
 
 
726
 
/*****************************************************************
727
 
 *
728
 
 *
729
 
 *   C o n v e r s i o n:   InChI  AuxInfo string => inchi_Input
730
 
 *
731
 
 *
732
 
 *****************************************************************/
733
 
 
734
 
#ifndef STR_ERR_LEN
735
 
#define STR_ERR_LEN     256
736
 
#endif
737
 
 
738
 
typedef struct tagInchiInpData {
739
 
    inchi_Input *pInp;    /* a pointer to pInp that has all items 0 or NULL */
740
 
    int          bChiral; /* 1 => the structure was marked as chiral, 2=> not chiral, 0=> not marked */
741
 
    char         szErrMsg[STR_ERR_LEN];
742
 
} InchiInpData;
743
 
 
744
 
/* to compile all InChI code as a C++ code #define INCHI_ALL_CPP */
745
 
#ifndef INCHI_ALL_CPP
746
 
#ifdef __cplusplus
747
 
extern "C" {
748
 
#endif
749
 
#endif
750
 
 
751
 
 
752
 
 
753
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
754
 
Get_inchi_Input_FromAuxInfo / Get_std_inchi_Input_FromAuxInfo
755
 
 
756
 
Input:
757
 
    szInchiAuxInfo: contains ASCIIZ string of InChI output for a single
758
 
                   structure or only the AuxInfo line
759
 
    bDoNotAddH:    if 0 then InChI will be allowed to add implicit H
760
 
    bDiffUnkUndfStereo
761
 
                   if not 0, use different labels for unknown and undefined stereo
762
 
    pInchiInp:     should have a valid pointer pInchiInp->pInp to an empty 
763
 
                   (all members = 0) inchi_Input structure 
764
 
 
765
 
Output:
766
 
    pInchiInp:     The following members of pInp may be filled during the call:
767
 
                   atom, num_atoms, stereo0D, num_stereo0D
768
 
    Return value:  see RetValGetINCHI
769
 
 
770
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
771
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL Get_inchi_Input_FromAuxInfo( 
772
 
                                                        char *szInchiAuxInfo, 
773
 
                                                        int bDoNotAddH, 
774
 
                                                        int bDiffUnkUndfStereo,
775
 
                                                        InchiInpData *pInchiInp );
776
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL Get_std_inchi_Input_FromAuxInfo( char *szInchiAuxInfo, 
777
 
                                                        int bDoNotAddH, 
778
 
                                                        InchiInpData *pInchiInp );
779
 
 
780
 
 
781
 
 
782
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
783
 
Free_inchi_Input / Free_std_inchi_Input
784
 
 
785
 
    To deallocate and write zeroes into the changed members of pInchiInp->pInp call
786
 
    Free_std_inchi_Input( inchi_Input *pInp )
787
 
 
788
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
789
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL Free_inchi_Input( inchi_Input *pInp );
790
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL Free_std_inchi_Input( inchi_Input *pInp );
791
 
 
792
 
 
793
 
 
794
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
795
 
CheckINCHI
796
 
 
797
 
Check if the string represents valid InChI/standard InChI.          
798
 
Input:
799
 
    szINCHI     source InChI
800
 
    strict      if 0, just briefly check for proper layout (prefix, version, etc.)
801
 
                The result may not be strict.
802
 
                If not 0, try to perform InChI2InChI conversion and 
803
 
                returns success if a resulting InChI string exactly match source.
804
 
                The result may be 'false alarm' due to imperfectness of conversion.
805
 
Returns:
806
 
    success/errors codes
807
 
 
808
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
809
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL CheckINCHI(const char *szINCHI, const int strict);    
810
 
 
811
 
 
812
 
#ifndef INCHI_ALL_CPP
813
 
#ifdef __cplusplus
814
 
}
815
 
#endif
816
 
#endif
817
 
 
818
 
 
819
 
 
820
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
821
 
    
822
 
                                InChIKey API
823
 
                                
824
 
 
825
 
    InChIKey description
826
 
 
827
 
 
828
 
 
829
 
    The InChIKey is a character signature based on a hash code of the InChI string.        
830
 
    Standard InChIKey is produced out of standard InChI.
831
 
    Non-standard InChIKey is produced out of non-standard InChI.
832
 
           
833
 
                    AAAAAAAAAAAAAA-BBBBBBBBCD-P
834
 
 
835
 
 
836
 
    InChIKey layout is as follows:
837
 
 
838
 
    AAAAAAAAAAAAAA
839
 
        First block (14 letters)
840
 
        Encodes molecular skeleton (connectivity)
841
 
 
842
 
    BBBBBBBB
843
 
        Second block (8 letters)
844
 
        Encodes tautomers, stereochemistry, isotopomers, reconnected layer 
845
 
    C
846
 
        'S' for standard
847
 
        'N' for non-standard
848
 
    D
849
 
        InChI version ('A' for 1)
850
 
    P - (de)protonation flag
851
 
        Protonization encoding:
852
 
        N 0
853
 
        O +1 P +2 Q +3 R +4 S +5 T +6 U +7 V +8 W +9 X +10 Y +11 Z +12
854
 
        M -1 L-2 K -3 J -4 I -5 H -6 G -7 F -8 E -9 D -10 C -11 B -12 
855
 
        A < -12 or > +12
856
 
 
857
 
 
858
 
    All symbols except delimiter (dash, that is, minus) are uppercase English 
859
 
    letters representing a "base 26" encoding.
860
 
    
861
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
862
 
 
863
 
 
864
 
/*^^^ Return codes for key generation procedure */
865
 
#define INCHIKEY_OK 0
866
 
#define INCHIKEY_UNKNOWN_ERROR 1
867
 
#define INCHIKEY_EMPTY_INPUT 2
868
 
#define INCHIKEY_INVALID_INCHI_PREFIX 3
869
 
#define INCHIKEY_NOT_ENOUGH_MEMORY 4
870
 
#define INCHIKEY_INVALID_INCHI 20
871
 
#define INCHIKEY_INVALID_STD_INCHI 21
872
 
 
873
 
 
874
 
/*^^^ Return codes for CheckINCHIKey */
875
 
typedef enum tagRetValGetINCHIKey
876
 
{
877
 
    INCHIKEY_VALID_STANDARD     =   0,
878
 
    INCHIKEY_VALID_NON_STANDARD =  -1,
879
 
    INCHIKEY_INVALID_LENGTH     =   1,
880
 
    INCHIKEY_INVALID_LAYOUT     =   2,
881
 
    INCHIKEY_INVALID_VERSION    =   3
882
 
} RetValCheckINCHIKeyv;
883
 
 
884
 
 
885
 
 
886
 
/* EXPORTED FUNCTIONS */
887
 
 
888
 
 
889
 
 
890
 
/* To compile all InChI code as a C++ code #define INCHI_ALL_CPP */
891
 
 
892
 
#ifndef INCHI_ALL_CPP
893
 
#ifdef __cplusplus
894
 
extern "C" {
895
 
#endif
896
 
#endif
897
 
 
898
 
 
899
 
 
900
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
901
 
GetINCHIKeyFromINCHI
902
 
 
903
 
Calculate InChIKey by InChI string. 
904
 
 
905
 
Input:
906
 
        szINCHISource
907
 
            source InChI string 
908
 
        xtra1
909
 
            =1 calculate hash extension (up to 256 bits; 1st block)
910
 
        xtra2
911
 
            =1 calculate hash extension (up to 256 bits; 2nd block)
912
 
 
913
 
Output:
914
 
        szINCHIKey
915
 
            InChIKey string 
916
 
            The user-supplied buffer szINCHIKey should be at least 28 bytes long.
917
 
        szXtra1
918
 
            hash extension (up to 256 bits; 1st block) string 
919
 
            Caller should allocate space for 64 characters + trailing NULL
920
 
        szXtra2
921
 
            hash extension (up to 256 bits; 2nd block) string 
922
 
            Caller should allocate space for 64 characters + trailing NULL
923
 
 
924
 
Returns:
925
 
        success/errors codes
926
 
 
927
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
928
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetINCHIKeyFromINCHI(const char* szINCHISource, 
929
 
                                                              const int xtra1,
930
 
                                                              const int xtra2,
931
 
                                                              char* szINCHIKey, 
932
 
                                                              char* szXtra1, 
933
 
                                                              char* szXtra2);
934
 
 
935
 
 
936
 
 
937
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
938
 
GetStdINCHIKeyFromStdINCHI
939
 
 
940
 
    "Standard" counterpart
941
 
 
942
 
    For compatibility with v. 1.02std, no extra hash calculation is allowed.
943
 
    To calculate extra hash(es), use GetINCHIKeyFromINCHI with stdInChI as input.
944
 
 
945
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
946
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL GetStdINCHIKeyFromStdINCHI(const char* szINCHISource, 
947
 
                                                                    char* szINCHIKey);
948
 
 
949
 
 
950
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
951
 
CheckINCHIKey
952
 
 
953
 
Check if the string represents valid InChIKey.          
954
 
Input:
955
 
        szINCHIKey
956
 
            source InChIKey string 
957
 
Returns:
958
 
        success/errors codes
959
 
 
960
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
961
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL CheckINCHIKey(const char *szINCHIKey);    
962
 
 
963
 
#ifndef INCHI_ALL_CPP
964
 
#ifdef __cplusplus
965
 
}
966
 
#endif
967
 
#endif
968
 
 
969
 
 
970
 
 
971
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
972
 
    
973
 
                          Modularized InChI generation API
974
 
 
975
 
 
976
 
 
977
 
    Note. Functions with STDINCHIGEN prefix are 
978
 
    retained for compatibility with v. 1.02std
979
 
 
980
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
981
 
 
982
 
 
983
 
 
984
 
 
985
 
/*^^^ Data structures holding intermediate (normalization) results */
986
 
 
987
 
#ifndef MAX_NUM_STEREO_ATOM_NEIGH
988
 
#define MAX_NUM_STEREO_ATOM_NEIGH 4
989
 
#endif
990
 
#ifndef MAX_NUM_STEREO_BONDS
991
 
#define MAX_NUM_STEREO_BONDS      3
992
 
#endif
993
 
#ifndef INCHI_NUM
994
 
#define INCHI_NUM            2    /* = array size; member indexes: */
995
 
#endif
996
 
 
997
 
 
998
 
typedef unsigned short AT_NUMBR;    
999
 
typedef signed short NUM_HS; 
1000
 
typedef unsigned long INCHI_MODES;        
1001
 
 
1002
 
typedef struct tagNormAtom 
1003
 
{
1004
 
    char          elname[ATOM_EL_LEN];      /* chem. element name */
1005
 
    U_CHAR        el_number;                /* number of the element in the Periodic Table */
1006
 
    AT_NUMBR      neighbor[MAXVAL];         /* positions (from 0) of the neighbors in the NORM_ATOM array */
1007
 
    AT_NUMBR      orig_at_number;           /* original atom number, starts from 1 */
1008
 
    AT_NUMBR      orig_compt_at_numb;       /* atom number within a component before terminal H removal */
1009
 
    S_CHAR        bond_stereo[MAXVAL];      /* 1=Up,4=Either,6=Down (this atom is at the pointing wedge)
1010
 
                                               negative => on the opposite side of the wedge; 3=Either double bond  */
1011
 
    U_CHAR        bond_type[MAXVAL];        /* 1=single, 2=double, 3=triple, 4=1/2 (bond order is 1 or 2) */
1012
 
                                            /* 5=1/2/3, 6=1/3, 7=2/3, 8=tautomeric, 9=1/2 non-stereogenic */
1013
 
 
1014
 
    S_CHAR        valence;                  /* number of bonds = number of neighbors not greater than MAXVAL */
1015
 
    S_CHAR        chem_bonds_valence;       /* sum of bond types (1,2,3); type 4 needs special treatment */
1016
 
    S_CHAR        num_H;                    /* number of adjacent implicit hydrogen atoms including D and T    */
1017
 
    S_CHAR        num_iso_H[NUM_H_ISOTOPES];/* number of adjacent implicit 1H(protium), 2H(D), 3H(T) < 16 */
1018
 
    S_CHAR        iso_atw_diff;             /* =0 => natural isotopic abundances  */
1019
 
                                            /* >0 => (isotopic mass) - (rounded average atomic mass) + 1 */
1020
 
                                            /* <0 => (isotopic mass) - (rounded average atomic mass) */
1021
 
    S_CHAR        charge;                   /* charge */
1022
 
    S_CHAR        radical;                  /* RADICAL_SINGLET, RADICAL_DOUBLET, or RADICAL_TRIPLET */
1023
 
    S_CHAR        bAmbiguousStereo;         /* flag of detected stereo ambiguity */
1024
 
    S_CHAR        cFlags;                   /* AT_FLAG_ISO_H_POINT: atom may have exchangeable isotopic H */
1025
 
    AT_NUMBR      at_type;                  /* ATT_NONE, ATT_ACIDIC, etc. See InChI normalization code */
1026
 
    AT_NUMBR      component;                /* number of the structure component > 0 */
1027
 
    AT_NUMBR      endpoint;                 /* id of a tautomeric group */
1028
 
    AT_NUMBR      c_point;                  /* id of a positive charge group */
1029
 
    double        x;                        /* x coordinate */
1030
 
    double        y;                        /* y coordinate */
1031
 
    double        z;                        /* x coordinate */
1032
 
    /*---------  0D parities ----------*/
1033
 
    S_CHAR        bUsed0DParity;            /* bit=1 => stereobond; bit=2 => stereocenter */
1034
 
    /*-----  tetrahedral stereo parity */
1035
 
    S_CHAR        p_parity;                 /* tetrahedral (sp3) cml parity */
1036
 
    AT_NUMBR      p_orig_at_num[MAX_NUM_STEREO_ATOM_NEIGH]; /* orig_at_number of each neighbor > 0; 0=> no neighbor */
1037
 
    /*----- stereo bond (SB) parities */
1038
 
    S_CHAR        sb_ord[MAX_NUM_STEREO_BONDS];  /* neighbor[] index of another end of this SB, starts from 0 */
1039
 
    S_CHAR        sn_ord[MAX_NUM_STEREO_BONDS];  /* neighbor[] index of a bond that is not this SB; starts from 0;
1040
 
                                                  -1 means the neighbor is a removed explicit H */
1041
 
    /* atoms on both ends of a stereobond have same parity => trans/T/E/2, diff. parities => cis/C/Z/1 */
1042
 
    S_CHAR        sb_parity[MAX_NUM_STEREO_BONDS];       /* parities of stereobonds (sp2) incident to this atom */      
1043
 
    AT_NUMBR      sn_orig_at_num[MAX_NUM_STEREO_BONDS];  /* orig_at_number of sn_ord[] neighbor > 0 */
1044
 
 
1045
 
#if( FIND_RING_SYSTEMS == 1 )
1046
 
    S_CHAR  bCutVertex;                    /* is the atom a cut-vertex or not */
1047
 
    AT_NUMBR nRingSystem;                  /* starts from 1; number of a ring system */
1048
 
    AT_NUMBR nNumAtInRingSystem;           /* number of atoms in a ring system to which this at belongs */
1049
 
    AT_NUMBR nBlockSystem;                 /* ambiguous if the atom is a cut-vertex: better apply this to bonds */
1050
 
 
1051
 
#if( FIND_RINS_SYSTEMS_DISTANCES == 1 )
1052
 
    AT_NUMBR nDistanceFromTerminal;        /* not used */
1053
 
#endif
1054
 
 
1055
 
#endif
1056
 
} NORM_ATOM;
1057
 
 
1058
 
 
1059
 
 
1060
 
typedef struct tagNormAtomData
1061
 
{
1062
 
    NORM_ATOM *at;                  /* atom list */
1063
 
    NORM_ATOM *at_fixed_bonds;      /* atom list with added or removed protons only */
1064
 
    int       num_at;               /* number of atoms except removed terminal H */
1065
 
    int       num_removed_H;        /* number of removed H; at[] has (num_at+num_removed_H) elements */
1066
 
    int       num_bonds;
1067
 
    int       num_isotopic;         /* number of isotopic atoms */
1068
 
    int       bExists;              /* for internal use */
1069
 
    int       bDeleted;             /* for internal use */
1070
 
    int       bHasIsotopicLayer;
1071
 
    int       bTautomeric;
1072
 
    int       bTautPreprocessed;    /* for internal use */
1073
 
    int       nNumRemovedProtons;
1074
 
    NUM_HS    nNumRemovedProtonsIsotopic[NUM_H_ISOTOPES]; 
1075
 
                                    /* isotopic composition of removed protons, not included in num_iso_H[] */
1076
 
    NUM_HS    num_iso_H[NUM_H_ISOTOPES]; 
1077
 
                                    /* isotopic H on tautomeric atoms and those 
1078
 
                                       in nIsotopicEndpointAtomNumber */
1079
 
    INCHI_MODES bTautFlags;         /* for internal use */
1080
 
    INCHI_MODES bTautFlagsDone;     /* for internal use */
1081
 
    INCHI_MODES bNormalizationFlags;/* for internal use */
1082
 
} NORM_ATOMS;
1083
 
 
1084
 
 
1085
 
typedef struct tagINCHIGEN_DATA 
1086
 
{
1087
 
    
1088
 
    char          pStrErrStruct[STR_ERR_LEN]; /* intermediate log (warning/error report) */
1089
 
    int           num_components[INCHI_NUM];  /* number of allocated INChI, INChI_Aux data structures */
1090
 
                                              /* index=0 => disconnected, 1 => reconnected structure */
1091
 
    
1092
 
    /*^^^ The results of normalization stage */
1093
 
    /*^^^ for each member of pair disconnected/reconnected structures: */
1094
 
    NORM_ATOMS   *NormAtomsNontaut[INCHI_NUM]; 
1095
 
    NORM_ATOMS   *NormAtomsTaut[INCHI_NUM];
1096
 
 
1097
 
} INCHIGEN_DATA;
1098
 
 
1099
 
 
1100
 
/*^^^ InChI Generator Handle */
1101
 
 
1102
 
typedef void* INCHIGEN_HANDLE;
1103
 
 
1104
 
 
1105
 
 
1106
 
 
1107
 
/* EXPORTED FUNCTIONS */
1108
 
 
1109
 
 
1110
 
 
1111
 
/* to compile all InChI code as a C++ code #define INCHI_ALL_CPP */
1112
 
#ifndef INCHI_ALL_CPP
1113
 
#ifdef __cplusplus
1114
 
extern "C" {
1115
 
#endif
1116
 
#endif
1117
 
 
1118
 
 
1119
 
 
1120
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1121
 
INCHIGEN_Create / STDINCHIGEN_Create
1122
 
 
1123
 
    InChI Generator: create generator
1124
 
    Returns handle of generator object or NULL on failure
1125
 
 
1126
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1127
 
EXPIMP_TEMPLATE INCHI_API 
1128
 
INCHIGEN_HANDLE INCHI_DECL INCHIGEN_Create(void);
1129
 
EXPIMP_TEMPLATE INCHI_API 
1130
 
INCHIGEN_HANDLE INCHI_DECL STDINCHIGEN_Create(void);
1131
 
 
1132
 
 
1133
 
 
1134
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1135
 
INCHIGEN_Setup / STDINCHIGEN_Setup
1136
 
 
1137
 
    InChI Generator: setup
1138
 
 
1139
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1140
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL INCHIGEN_Setup(INCHIGEN_HANDLE HGen, 
1141
 
                                                        INCHIGEN_DATA * pGenData, 
1142
 
                                                        inchi_Input * pInp);
1143
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL STDINCHIGEN_Setup(INCHIGEN_HANDLE HGen, 
1144
 
                                                           INCHIGEN_DATA * pGenData, 
1145
 
                                                           inchi_Input * pInp);
1146
 
 
1147
 
 
1148
 
 
1149
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1150
 
INCHIGEN_DoNormalization / STDINCHIGEN_DoNormalization
1151
 
 
1152
 
    InChI Generator: structure normalization stage
1153
 
 
1154
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1155
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL INCHIGEN_DoNormalization(INCHIGEN_HANDLE HGen, 
1156
 
                                                                     INCHIGEN_DATA * pGenData);
1157
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL STDINCHIGEN_DoNormalization(INCHIGEN_HANDLE HGen, 
1158
 
                                                                     INCHIGEN_DATA * pGenData);
1159
 
 
1160
 
 
1161
 
 
1162
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1163
 
INCHIGEN_DoCanonicalization / STDINCHIGEN_DoCanonicalization
1164
 
 
1165
 
    InChI Generator: structure canonicalization stage
1166
 
 
1167
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1168
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL INCHIGEN_DoCanonicalization
1169
 
                                (INCHIGEN_HANDLE HGen, INCHIGEN_DATA * pGenData);
1170
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL STDINCHIGEN_DoCanonicalization
1171
 
                                (INCHIGEN_HANDLE HGen, INCHIGEN_DATA * pGenData);
1172
 
 
1173
 
 
1174
 
 
1175
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1176
 
INCHIGEN_DoSerialization / STDINCHIGEN_DoSerialization
1177
 
 
1178
 
    InChI Generator: InChI serialization stage
1179
 
 
1180
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1181
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL INCHIGEN_DoSerialization(INCHIGEN_HANDLE HGen, 
1182
 
                                                                  INCHIGEN_DATA * pGenData, 
1183
 
                                                                  inchi_Output * pResults);
1184
 
EXPIMP_TEMPLATE INCHI_API int INCHI_DECL STDINCHIGEN_DoSerialization(INCHIGEN_HANDLE HGen, 
1185
 
                                                                     INCHIGEN_DATA * pGenData, 
1186
 
                                                                     inchi_Output * pResults);
1187
 
 
1188
 
 
1189
 
 
1190
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1191
 
INCHIGEN_DoSerialization / STDINCHIGEN_DoSerialization
1192
 
 
1193
 
    InChI Generator: reset stage (use before get next structure)
1194
 
 
1195
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1196
 
EXPIMP_TEMPLATE INCHI_API 
1197
 
void INCHI_DECL INCHIGEN_Reset(INCHIGEN_HANDLE HGen, 
1198
 
                               INCHIGEN_DATA * pGenData, 
1199
 
                               inchi_Output * pResults);
1200
 
EXPIMP_TEMPLATE INCHI_API 
1201
 
void INCHI_DECL STDINCHIGEN_Reset(INCHIGEN_HANDLE HGen, 
1202
 
                               INCHIGEN_DATA * pGenData, 
1203
 
                               inchi_Output * pResults);
1204
 
 
1205
 
 
1206
 
 
1207
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1208
 
INCHIGEN_DoSerialization / STDINCHIGEN_DoSerialization
1209
 
 
1210
 
    InChI Generator: destroy generator
1211
 
 
1212
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1213
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL INCHIGEN_Destroy(INCHIGEN_HANDLE HGen);
1214
 
EXPIMP_TEMPLATE INCHI_API void INCHI_DECL STDINCHIGEN_Destroy(INCHIGEN_HANDLE HGen);
1215
 
 
1216
 
 
1217
 
 
1218
 
 
1219
 
 
1220
 
#ifndef INCHI_ALL_CPP
1221
 
#ifdef __cplusplus
1222
 
}
1223
 
#endif
1224
 
#endif
1225
 
 
1226
 
 
1227
 
 
1228
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1229
 
 
1230
 
Prototypes for C calling conventions:
1231
 
 
1232
 
    int  GetINCHI( inchi_Input *inp, inchi_Output *out );
1233
 
    int  GetStdINCHI( inchi_Input *inp, inchi_Output *out );
1234
 
    void FreeINCHI( inchi_Output *out );
1235
 
    void FreeStdINCHI( inchi_Output *out );
1236
 
    int  GetStringLength( char *p );
1237
 
    int  Get_inchi_Input_FromAuxInfo
1238
 
     ( char *szInchiAuxInfo, int bDoNotAddH, int bDiffUnkUndfStereo, InchiInpData *pInchiInp );
1239
 
    int  Get_std_inchi_Input_FromAuxInfo
1240
 
     ( char *szInchiAuxInfo, int bDoNotAddH, int bDiffUnkUndfStereo,InchiInpData *pInchiInp );
1241
 
    void Free_inchi_Input( inchi_Input *pInp );
1242
 
    void Free_std_inchi_Input( inchi_Input *pInp );
1243
 
    int GetStructFromINCHI( inchi_InputINCHI *inpInChI, inchi_OutputStruct *outStruct );
1244
 
    int GetStructFromStdINCHI( inchi_InputINCHI *inpInChI, inchi_OutputStruct *outStruct );
1245
 
    void FreeStructFromStdINCHI( inchi_OutputStruct *out );
1246
 
 
1247
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1248
 
 
1249
 
 
1250
 
/*^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1251
 
 
1252
 
Win32 Dumpbin export information
1253
 
 
1254
 
    ordinal hint RVA      name
1255
 
cdecl 
1256
 
          1    0 000B7EAB CheckINCHI
1257
 
          2    1 000B7221 CheckINCHIKey
1258
 
          3    2 000B7C62 FreeINCHI
1259
 
          4    3 000B7B04 FreeStdINCHI
1260
 
          5    4 000B72B7 FreeStructFromINCHI
1261
 
          6    5 000B7BC2 FreeStructFromStdINCHI
1262
 
          7    6 000B7E33 Free_inchi_Input
1263
 
          8    7 000B7C58 Free_std_inchi_Input
1264
 
          9    8 000B727B GetINCHI
1265
 
         10    9 000B75B4 GetINCHIKeyFromINCHI
1266
 
         11    A 000B757D GetINCHIfromINCHI
1267
 
         12    B 000B8211 GetStdINCHI
1268
 
         13    C 000B7F0A GetStdINCHIKeyFromStdINCHI
1269
 
         14    D 000B77CB GetStringLength
1270
 
         15    E 000B7CA3 GetStructFromINCHI
1271
 
         16    F 000B778A GetStructFromStdINCHI
1272
 
         17   10 000B7DAC Get_inchi_Input_FromAuxInfo
1273
 
         18   11 000B7D6B Get_std_inchi_Input_FromAuxInfo
1274
 
         19   12 000B7D6B INCHIGEN_Create
1275
 
         20   13 000B7F2D INCHIGEN_Destroy
1276
 
         21   14 000B7F23 INCHIGEN_DoCanonicalization
1277
 
         22   15 000B7F23 INCHIGEN_DoNormalization
1278
 
         23   16 000B714A INCHIGEN_DoSerialization
1279
 
         24   17 000B7FCD INCHIGEN_Reset
1280
 
         25   18 000B7FCD INCHIGEN_Setup
1281
 
         26   19 000B7EA6 STDINCHIGEN_Create
1282
 
         27   1A 000B7EA6 STDINCHIGEN_Destroy
1283
 
         28   1B 000B711D STDINCHIGEN_DoCanonicalization
1284
 
         29   1C 000B7073 STDINCHIGEN_DoNormalization
1285
 
         30   1D 000B7FC3 STDINCHIGEN_DoSerialization
1286
 
         31   1E 000B7668 STDINCHIGEN_Reset
1287
 
         32   1F 000B7438 STDINCHIGEN_Setup
1288
 
__stdcall or PASCAL
1289
 
         33   20 000B7DFC _CheckINCHI@8
1290
 
         34   21 000B7802 _CheckINCHIKey@4
1291
 
         35   22 000B7F73 _FreeINCHI@4
1292
 
         36   23 000B7F82 _FreeStdINCHI@4
1293
 
         37   24 000B75E1 _FreeStructFromINCHI@4
1294
 
         38   25 000B7B81 _FreeStructFromStdINCHI@4
1295
 
         39   26 000B7B86 _Free_inchi_Input@4
1296
 
         40   27 000B7A96 _Free_std_inchi_Input@4
1297
 
         41   28 000B7B5E _GetINCHI@8
1298
 
         42   29 000B7285 _GetINCHIKeyFromINCHI@24
1299
 
         43   2A 000B758C _GetINCHIfromINCHI@8
1300
 
         44   2B 000B7CDA _GetStdINCHI@8
1301
 
         45   2C 000B7979 _GetStdINCHIKeyFromStdINCHI@8
1302
 
         46   2D 000B7BA4 _GetStringLength@4
1303
 
         47   2E 000B70A5 _GetStructFromINCHI@8
1304
 
         48   2F 000B79B0 _GetStructFromStdINCHI@8
1305
 
         49   30 000B8022 _Get_inchi_Input_FromAuxInfo@16
1306
 
         50   31 000B76E0 _Get_std_inchi_Input_FromAuxInfo@12
1307
 
         51   32 000B7230 _INCHIGEN_Create@0
1308
 
         52   33 000B760E _INCHIGEN_Destroy@4
1309
 
         53   34 000B7087 _INCHIGEN_DoCanonicalization@8
1310
 
         54   35 000B70B4 _INCHIGEN_DoNormalization@8
1311
 
         55   36 000B72D5 _INCHIGEN_DoSerialization@12
1312
 
         56   37 000B7FE1 _INCHIGEN_Reset@12
1313
 
         57   38 000B7163 _INCHIGEN_Setup@12
1314
 
         58   39 000B7159 _STDINCHIGEN_Create@0
1315
 
         59   3A 000B78A7 _STDINCHIGEN_Destroy@4
1316
 
         60   3B 000B72F3 _STDINCHIGEN_DoCanonicalization@8
1317
 
         61   3C 000B737A _STDINCHIGEN_DoNormalization@8
1318
 
         62   3D 000B7B72 _STDINCHIGEN_DoSerialization@12
1319
 
         63   3E 000B7654 _STDINCHIGEN_Reset@12
1320
 
         64   3F 000B75FF _STDINCHIGEN_Setup@12
1321
 
 
1322
 
 
1323
 
    Note. Currently there is no callback function for aborting, progress, etc.
1324
 
 
1325
 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*/
1326
 
 
1327
 
#endif /* __INHCH_API_H__ */