@datagrok-libraries/chem-meta
Advanced tools
Comparing version 1.2.4 to 1.2.5
# chem-meta changelog | ||
## 1.2.4 (2024-03-29) | ||
## 1.2.5 (2024-04-17) | ||
Port molfile-related constants to chem-meta | ||
## 1.2.4 (2024-04-15) | ||
### Features | ||
@@ -6,0 +10,0 @@ |
@@ -7,3 +7,3 @@ { | ||
"friendlyName": "Datagrok chem-meta library", | ||
"version": "1.2.4", | ||
"version": "1.2.5", | ||
"description": "RDKit JS API, utils for molfiles parsing", | ||
@@ -10,0 +10,0 @@ "dependencies": { |
@@ -0,4 +1,3 @@ | ||
import { R_GROUP_ELEMENT_SYMBOL, V2K_CONST } from '../formats/molfile-const'; | ||
import { MolfileHandlerBase } from './molfile-handler-base'; | ||
import { V2K_CONST } from '../formats/molfile-v2k-const'; | ||
import { R_GROUP_ELEMENT_SYMBOL } from '../formats/const'; | ||
export class MolfileV2KHandler extends MolfileHandlerBase { | ||
@@ -63,3 +62,3 @@ constructor(molfile) { | ||
static isValidMolfile(molfile) { | ||
return (molfile.indexOf(V2K_CONST.HEADER) !== -1 && | ||
return (molfile.indexOf(V2K_CONST.TYPE) !== -1 && | ||
molfile.indexOf(V2K_CONST.END) !== -1); | ||
@@ -107,2 +106,2 @@ } | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibW9sZmlsZS12MmstaGFuZGxlci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIm1vbGZpbGUtdjJrLWhhbmRsZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQ0EsT0FBTyxFQUFDLGtCQUFrQixFQUFDLE1BQU0sd0JBQXdCLENBQUM7QUFDMUQsT0FBTyxFQUFDLFNBQVMsRUFBQyxNQUFNLDhCQUE4QixDQUFDO0FBQ3ZELE9BQU8sRUFBQyxzQkFBc0IsRUFBQyxNQUFNLGtCQUFrQixDQUFDO0FBRXhELE1BQU0sT0FBTyxpQkFBa0I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KyspXG4gICAgICBpZHggPSB0aGlzLmdldE5leHRMaW5lSWR4KGlkeCk7XG4gICAgcmV0dXJuIGlkeDtcbiAgfVxuXG4gIHByb3RlY3RlZCBwYXJzZUF0b21BbmRCb25kQ291bnRzKCk6IEF0b21BbmRCb25kQ291bnRzIHtcbiAgICBsZXQgYmVnaW4gPSB0aGlzLmdldENvdW50c0xpbmVJZHgoKTtcbiAgICBsZXQgZW5kID0gYmVnaW4gKyBWMktfQ09OU1QuTlVNX09GX0NPVU5UU19ESUdJVFM7XG4gICAgY29uc3QgYXRvbUNvdW50ID0gcGFyc2VJbnQodGhpcy5maWxlQ29udGVudC5zdWJzdHJpbmcoYmVnaW4sIGVuZCkpO1xuICAgIGJlZ2luID0gZW5kO1xuICAgIGVuZCArPSBWMktfQ09OU1QuTlVNX09GX0NPVU5UU19ESUdJVFM7XG4gICAgY29uc3QgYm9uZENvdW50ID0gcGFyc2VJbnQodGhpcy5maWxlQ29udGVudC5zdWJzdHJpbmcoYmVnaW4sIGVuZCkpO1xuICAgIHJldHVybiB7YXRvbUNvdW50OiBhdG9tQ291bnQsIGJvbmRDb3VudDogYm9uZENvdW50fTtcbiAgfTtcbn1cbiJdfQ== |
@@ -63,3 +63,3 @@ import { MolfileHandlerBase } from './molfile-handler-base'; | ||
static isValidMolfile(molfile) { | ||
return (molfile.indexOf("V3000" /* V3K_CONST.HEADER */) !== -1 && | ||
return (molfile.indexOf("V3000" /* V3K_CONST.TYPE */) !== -1 && | ||
molfile.indexOf("M END" /* V3K_CONST.END */) !== -1); | ||
@@ -79,2 +79,2 @@ } | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibW9sZmlsZS12M2staGFuZGxlci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIm1vbGZpbGUtdjNrLWhhbmRsZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQ0EsT0FBTyxFQUFDLGtCQU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hpcy5maWxlQ29udGVudC5zdWJzdHJpbmcoYmVnaW4sIGVuZCkpO1xuXG4gICAgcmV0dXJuIHthdG9tQ291bnQ6IG51bU9mQXRvbXMsIGJvbmRDb3VudDogbnVtT2ZCb25kc307XG4gIH1cbn1cbiJdfQ== |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
900
112510
37