cheminee 0.1.19 → 0.1.22
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +9 -9
- data/README.md +6 -5
- data/cheminee.gemspec +1 -1
- data/docs/DefaultApi.md +74 -1
- data/docs/QuerySearchHit.md +1 -1
- data/docs/StructureSearchHit.md +1 -1
- data/lib/cheminee/api/default_api.rb +87 -10
- data/lib/cheminee/api_client.rb +3 -3
- data/lib/cheminee/api_error.rb +1 -1
- data/lib/cheminee/configuration.rb +11 -1
- data/lib/cheminee/models/bulk_request.rb +1 -1
- data/lib/cheminee/models/bulk_request_doc.rb +1 -1
- data/lib/cheminee/models/converted_smiles.rb +1 -1
- data/lib/cheminee/models/create_index_error.rb +1 -1
- data/lib/cheminee/models/get_indexes_response_error.rb +1 -1
- data/lib/cheminee/models/index_meta.rb +1 -1
- data/lib/cheminee/models/index_schema.rb +1 -1
- data/lib/cheminee/models/list_index_response_err.rb +1 -1
- data/lib/cheminee/models/mol_block.rb +1 -1
- data/lib/cheminee/models/post_index_bulk_response_error.rb +1 -1
- data/lib/cheminee/models/post_index_bulk_response_ok.rb +1 -1
- data/lib/cheminee/models/post_index_bulk_response_ok_status.rb +1 -1
- data/lib/cheminee/models/query_response_error.rb +1 -1
- data/lib/cheminee/models/query_search_hit.rb +7 -3
- data/lib/cheminee/models/schema.rb +1 -1
- data/lib/cheminee/models/smiles.rb +1 -1
- data/lib/cheminee/models/standardized_smiles.rb +1 -1
- data/lib/cheminee/models/structure_response_error.rb +1 -1
- data/lib/cheminee/models/structure_search_hit.rb +7 -3
- data/lib/cheminee/version.rb +2 -2
- data/lib/cheminee.rb +1 -1
- data/pkg/cheminee-0.1.22.gem +0 -0
- data/spec/spec_helper.rb +1 -1
- metadata +17 -17
- data/pkg/cheminee-0.1.19.gem +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fd0fd97ae51080c209966e664af3d010b5039209f090bb675ed8c8fabb9b54cd
|
4
|
+
data.tar.gz: 0b64fcebc54a5a300b823e15c5a5675579ba82f413d45f45829878ca8d86f61d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2d19c6eb9230b6636e5744bddc2bc070687fa9f6d6cadf5434770b8ba7d9ebda7c364353c58bc6a378077b09679bc7db0935f0b1650e7e64ea72ec592139bfc2
|
7
|
+
data.tar.gz: 6b4108795132e7b21cd6f9e4bd2f46933cb7fc6935043b2c0f95b9b24ee7a0f0673266e341804160789dc3d154b86c7cace186bb6b4ac8bf6f6e7f6cefb09e87
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
cheminee (0.1.
|
4
|
+
cheminee (0.1.22)
|
5
5
|
typhoeus (~> 1.0, >= 1.0.1)
|
6
6
|
|
7
7
|
GEM
|
@@ -13,11 +13,11 @@ GEM
|
|
13
13
|
diff-lcs (1.5.1)
|
14
14
|
ethon (0.16.0)
|
15
15
|
ffi (>= 1.15.0)
|
16
|
-
ffi (1.
|
16
|
+
ffi (1.17.0-x86_64-linux-gnu)
|
17
17
|
jaro_winkler (1.5.6)
|
18
|
-
method_source (1.
|
19
|
-
parallel (1.
|
20
|
-
parser (3.3.0
|
18
|
+
method_source (1.1.0)
|
19
|
+
parallel (1.25.1)
|
20
|
+
parser (3.3.4.0)
|
21
21
|
ast (~> 2.4.1)
|
22
22
|
racc
|
23
23
|
pry (0.14.2)
|
@@ -28,7 +28,7 @@ GEM
|
|
28
28
|
pry (>= 0.13, < 0.15)
|
29
29
|
psych (5.1.2)
|
30
30
|
stringio
|
31
|
-
racc (1.
|
31
|
+
racc (1.8.0)
|
32
32
|
rainbow (3.1.1)
|
33
33
|
rake (13.0.6)
|
34
34
|
rspec (3.13.0)
|
@@ -37,10 +37,10 @@ GEM
|
|
37
37
|
rspec-mocks (~> 3.13.0)
|
38
38
|
rspec-core (3.13.0)
|
39
39
|
rspec-support (~> 3.13.0)
|
40
|
-
rspec-expectations (3.13.
|
40
|
+
rspec-expectations (3.13.1)
|
41
41
|
diff-lcs (>= 1.2.0, < 2.0)
|
42
42
|
rspec-support (~> 3.13.0)
|
43
|
-
rspec-mocks (3.13.
|
43
|
+
rspec-mocks (3.13.1)
|
44
44
|
diff-lcs (>= 1.2.0, < 2.0)
|
45
45
|
rspec-support (~> 3.13.0)
|
46
46
|
rspec-support (3.13.1)
|
@@ -53,7 +53,7 @@ GEM
|
|
53
53
|
ruby-progressbar (~> 1.7)
|
54
54
|
unicode-display_width (>= 1.4.0, < 1.6)
|
55
55
|
ruby-progressbar (1.13.0)
|
56
|
-
stringio (3.1.
|
56
|
+
stringio (3.1.1)
|
57
57
|
typhoeus (1.4.1)
|
58
58
|
ethon (>= 0.9.0)
|
59
59
|
unicode-display_width (1.5.0)
|
data/README.md
CHANGED
@@ -7,8 +7,8 @@ Cheminée: The Chemical Structure Search Engine
|
|
7
7
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
8
8
|
|
9
9
|
- API version: 1.0
|
10
|
-
- Package version: 0.1.
|
11
|
-
- Generator version: 7.
|
10
|
+
- Package version: 0.1.22
|
11
|
+
- Generator version: 7.8.0-SNAPSHOT
|
12
12
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
13
13
|
For more information, please visit [https://github.com/rdkit-rs/cheminee](https://github.com/rdkit-rs/cheminee)
|
14
14
|
|
@@ -25,16 +25,16 @@ gem build cheminee.gemspec
|
|
25
25
|
Then either install the gem locally:
|
26
26
|
|
27
27
|
```shell
|
28
|
-
gem install ./cheminee-0.1.
|
28
|
+
gem install ./cheminee-0.1.22.gem
|
29
29
|
```
|
30
30
|
|
31
|
-
(for development, run `gem install --dev ./cheminee-0.1.
|
31
|
+
(for development, run `gem install --dev ./cheminee-0.1.22.gem` to install the development dependencies)
|
32
32
|
|
33
33
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
34
34
|
|
35
35
|
Finally add this to the Gemfile:
|
36
36
|
|
37
|
-
gem 'cheminee', '~> 0.1.
|
37
|
+
gem 'cheminee', '~> 0.1.22'
|
38
38
|
|
39
39
|
### Install from Git
|
40
40
|
|
@@ -84,6 +84,7 @@ Class | Method | HTTP request | Description
|
|
84
84
|
*Cheminee::DefaultApi* | [**v1_indexes_index_get**](docs/DefaultApi.md#v1_indexes_index_get) | **GET** /v1/indexes/{index} | Get extended information about an index
|
85
85
|
*Cheminee::DefaultApi* | [**v1_indexes_index_post**](docs/DefaultApi.md#v1_indexes_index_post) | **POST** /v1/indexes/{index} | Create an index
|
86
86
|
*Cheminee::DefaultApi* | [**v1_indexes_index_search_basic_get**](docs/DefaultApi.md#v1_indexes_index_search_basic_get) | **GET** /v1/indexes/{index}/search/basic | Perform basic query search against index
|
87
|
+
*Cheminee::DefaultApi* | [**v1_indexes_index_search_identity_get**](docs/DefaultApi.md#v1_indexes_index_search_identity_get) | **GET** /v1/indexes/{index}/search/identity | Perform identity search (i.e. exact match) against index
|
87
88
|
*Cheminee::DefaultApi* | [**v1_indexes_index_search_substructure_get**](docs/DefaultApi.md#v1_indexes_index_search_substructure_get) | **GET** /v1/indexes/{index}/search/substructure | Perform substructure search against index
|
88
89
|
*Cheminee::DefaultApi* | [**v1_schemas_get**](docs/DefaultApi.md#v1_schemas_get) | **GET** /v1/schemas | List schemas available for creating indexes
|
89
90
|
*Cheminee::DefaultApi* | [**v1_standardize_post**](docs/DefaultApi.md#v1_standardize_post) | **POST** /v1/standardize | Pass a list of SMILES through fragment_parent, uncharger, and canonicalization routines
|
data/cheminee.gemspec
CHANGED
data/docs/DefaultApi.md
CHANGED
@@ -10,6 +10,7 @@ All URIs are relative to *http://localhost:4001/api*
|
|
10
10
|
| [**v1_indexes_index_get**](DefaultApi.md#v1_indexes_index_get) | **GET** /v1/indexes/{index} | Get extended information about an index |
|
11
11
|
| [**v1_indexes_index_post**](DefaultApi.md#v1_indexes_index_post) | **POST** /v1/indexes/{index} | Create an index |
|
12
12
|
| [**v1_indexes_index_search_basic_get**](DefaultApi.md#v1_indexes_index_search_basic_get) | **GET** /v1/indexes/{index}/search/basic | Perform basic query search against index |
|
13
|
+
| [**v1_indexes_index_search_identity_get**](DefaultApi.md#v1_indexes_index_search_identity_get) | **GET** /v1/indexes/{index}/search/identity | Perform identity search (i.e. exact match) against index |
|
13
14
|
| [**v1_indexes_index_search_substructure_get**](DefaultApi.md#v1_indexes_index_search_substructure_get) | **GET** /v1/indexes/{index}/search/substructure | Perform substructure search against index |
|
14
15
|
| [**v1_schemas_get**](DefaultApi.md#v1_schemas_get) | **GET** /v1/schemas | List schemas available for creating indexes |
|
15
16
|
| [**v1_standardize_post**](DefaultApi.md#v1_standardize_post) | **POST** /v1/standardize | Pass a list of SMILES through fragment_parent, uncharger, and canonicalization routines |
|
@@ -400,6 +401,76 @@ No authorization required
|
|
400
401
|
- **Accept**: application/json; charset=utf-8
|
401
402
|
|
402
403
|
|
404
|
+
## v1_indexes_index_search_identity_get
|
405
|
+
|
406
|
+
> <Array<StructureSearchHit>> v1_indexes_index_search_identity_get(index, smiles, opts)
|
407
|
+
|
408
|
+
Perform identity search (i.e. exact match) against index
|
409
|
+
|
410
|
+
### Examples
|
411
|
+
|
412
|
+
```ruby
|
413
|
+
require 'time'
|
414
|
+
require 'cheminee'
|
415
|
+
|
416
|
+
api_instance = Cheminee::DefaultApi.new
|
417
|
+
index = 'index_example' # String |
|
418
|
+
smiles = 'smiles_example' # String |
|
419
|
+
opts = {
|
420
|
+
extra_query: 'extra_query_example', # String |
|
421
|
+
use_scaffolds: 'use_scaffolds_example' # String |
|
422
|
+
}
|
423
|
+
|
424
|
+
begin
|
425
|
+
# Perform identity search (i.e. exact match) against index
|
426
|
+
result = api_instance.v1_indexes_index_search_identity_get(index, smiles, opts)
|
427
|
+
p result
|
428
|
+
rescue Cheminee::ApiError => e
|
429
|
+
puts "Error when calling DefaultApi->v1_indexes_index_search_identity_get: #{e}"
|
430
|
+
end
|
431
|
+
```
|
432
|
+
|
433
|
+
#### Using the v1_indexes_index_search_identity_get_with_http_info variant
|
434
|
+
|
435
|
+
This returns an Array which contains the response data, status code and headers.
|
436
|
+
|
437
|
+
> <Array(<Array<StructureSearchHit>>, Integer, Hash)> v1_indexes_index_search_identity_get_with_http_info(index, smiles, opts)
|
438
|
+
|
439
|
+
```ruby
|
440
|
+
begin
|
441
|
+
# Perform identity search (i.e. exact match) against index
|
442
|
+
data, status_code, headers = api_instance.v1_indexes_index_search_identity_get_with_http_info(index, smiles, opts)
|
443
|
+
p status_code # => 2xx
|
444
|
+
p headers # => { ... }
|
445
|
+
p data # => <Array<StructureSearchHit>>
|
446
|
+
rescue Cheminee::ApiError => e
|
447
|
+
puts "Error when calling DefaultApi->v1_indexes_index_search_identity_get_with_http_info: #{e}"
|
448
|
+
end
|
449
|
+
```
|
450
|
+
|
451
|
+
### Parameters
|
452
|
+
|
453
|
+
| Name | Type | Description | Notes |
|
454
|
+
| ---- | ---- | ----------- | ----- |
|
455
|
+
| **index** | **String** | | |
|
456
|
+
| **smiles** | **String** | | |
|
457
|
+
| **extra_query** | **String** | | [optional] |
|
458
|
+
| **use_scaffolds** | **String** | | [optional] |
|
459
|
+
|
460
|
+
### Return type
|
461
|
+
|
462
|
+
[**Array<StructureSearchHit>**](StructureSearchHit.md)
|
463
|
+
|
464
|
+
### Authorization
|
465
|
+
|
466
|
+
No authorization required
|
467
|
+
|
468
|
+
### HTTP request headers
|
469
|
+
|
470
|
+
- **Content-Type**: Not defined
|
471
|
+
- **Accept**: application/json; charset=utf-8
|
472
|
+
|
473
|
+
|
403
474
|
## v1_indexes_index_search_substructure_get
|
404
475
|
|
405
476
|
> <Array<StructureSearchHit>> v1_indexes_index_search_substructure_get(index, smiles, opts)
|
@@ -418,7 +489,8 @@ smiles = 'smiles_example' # String |
|
|
418
489
|
opts = {
|
419
490
|
result_limit: 56, # Integer |
|
420
491
|
tautomer_limit: 56, # Integer |
|
421
|
-
extra_query: 'extra_query_example' # String |
|
492
|
+
extra_query: 'extra_query_example', # String |
|
493
|
+
use_scaffolds: 'use_scaffolds_example' # String |
|
422
494
|
}
|
423
495
|
|
424
496
|
begin
|
@@ -457,6 +529,7 @@ end
|
|
457
529
|
| **result_limit** | **Integer** | | [optional] |
|
458
530
|
| **tautomer_limit** | **Integer** | | [optional] |
|
459
531
|
| **extra_query** | **String** | | [optional] |
|
532
|
+
| **use_scaffolds** | **String** | | [optional] |
|
460
533
|
|
461
534
|
### Return type
|
462
535
|
|
data/docs/QuerySearchHit.md
CHANGED
data/docs/StructureSearchHit.md
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.8.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -56,7 +56,7 @@ module Cheminee
|
|
56
56
|
# header parameters
|
57
57
|
header_params = opts[:header_params] || {}
|
58
58
|
# HTTP header 'Accept' (if needed)
|
59
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
59
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
60
60
|
# HTTP header 'Content-Type'
|
61
61
|
content_type = @api_client.select_header_content_type(['application/json; charset=utf-8'])
|
62
62
|
if !content_type.nil?
|
@@ -116,7 +116,7 @@ module Cheminee
|
|
116
116
|
# header parameters
|
117
117
|
header_params = opts[:header_params] || {}
|
118
118
|
# HTTP header 'Accept' (if needed)
|
119
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
119
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
120
120
|
|
121
121
|
# form parameters
|
122
122
|
form_params = opts[:form_params] || {}
|
@@ -183,7 +183,7 @@ module Cheminee
|
|
183
183
|
# header parameters
|
184
184
|
header_params = opts[:header_params] || {}
|
185
185
|
# HTTP header 'Accept' (if needed)
|
186
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
186
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
187
187
|
# HTTP header 'Content-Type'
|
188
188
|
content_type = @api_client.select_header_content_type(['application/json; charset=utf-8'])
|
189
189
|
if !content_type.nil?
|
@@ -249,7 +249,7 @@ module Cheminee
|
|
249
249
|
# header parameters
|
250
250
|
header_params = opts[:header_params] || {}
|
251
251
|
# HTTP header 'Accept' (if needed)
|
252
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
252
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
253
253
|
|
254
254
|
# form parameters
|
255
255
|
form_params = opts[:form_params] || {}
|
@@ -320,7 +320,7 @@ module Cheminee
|
|
320
320
|
# header parameters
|
321
321
|
header_params = opts[:header_params] || {}
|
322
322
|
# HTTP header 'Accept' (if needed)
|
323
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
323
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
324
324
|
|
325
325
|
# form parameters
|
326
326
|
form_params = opts[:form_params] || {}
|
@@ -391,7 +391,7 @@ module Cheminee
|
|
391
391
|
# header parameters
|
392
392
|
header_params = opts[:header_params] || {}
|
393
393
|
# HTTP header 'Accept' (if needed)
|
394
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
394
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
395
395
|
|
396
396
|
# form parameters
|
397
397
|
form_params = opts[:form_params] || {}
|
@@ -422,6 +422,80 @@ module Cheminee
|
|
422
422
|
return data, status_code, headers
|
423
423
|
end
|
424
424
|
|
425
|
+
# Perform identity search (i.e. exact match) against index
|
426
|
+
# @param index [String]
|
427
|
+
# @param smiles [String]
|
428
|
+
# @param [Hash] opts the optional parameters
|
429
|
+
# @option opts [String] :extra_query
|
430
|
+
# @option opts [String] :use_scaffolds
|
431
|
+
# @return [Array<StructureSearchHit>]
|
432
|
+
def v1_indexes_index_search_identity_get(index, smiles, opts = {})
|
433
|
+
data, _status_code, _headers = v1_indexes_index_search_identity_get_with_http_info(index, smiles, opts)
|
434
|
+
data
|
435
|
+
end
|
436
|
+
|
437
|
+
# Perform identity search (i.e. exact match) against index
|
438
|
+
# @param index [String]
|
439
|
+
# @param smiles [String]
|
440
|
+
# @param [Hash] opts the optional parameters
|
441
|
+
# @option opts [String] :extra_query
|
442
|
+
# @option opts [String] :use_scaffolds
|
443
|
+
# @return [Array<(Array<StructureSearchHit>, Integer, Hash)>] Array<StructureSearchHit> data, response status code and response headers
|
444
|
+
def v1_indexes_index_search_identity_get_with_http_info(index, smiles, opts = {})
|
445
|
+
if @api_client.config.debugging
|
446
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.v1_indexes_index_search_identity_get ...'
|
447
|
+
end
|
448
|
+
# verify the required parameter 'index' is set
|
449
|
+
if @api_client.config.client_side_validation && index.nil?
|
450
|
+
fail ArgumentError, "Missing the required parameter 'index' when calling DefaultApi.v1_indexes_index_search_identity_get"
|
451
|
+
end
|
452
|
+
# verify the required parameter 'smiles' is set
|
453
|
+
if @api_client.config.client_side_validation && smiles.nil?
|
454
|
+
fail ArgumentError, "Missing the required parameter 'smiles' when calling DefaultApi.v1_indexes_index_search_identity_get"
|
455
|
+
end
|
456
|
+
# resource path
|
457
|
+
local_var_path = '/v1/indexes/{index}/search/identity'.sub('{' + 'index' + '}', CGI.escape(index.to_s))
|
458
|
+
|
459
|
+
# query parameters
|
460
|
+
query_params = opts[:query_params] || {}
|
461
|
+
query_params[:'smiles'] = smiles
|
462
|
+
query_params[:'extra_query'] = opts[:'extra_query'] if !opts[:'extra_query'].nil?
|
463
|
+
query_params[:'use_scaffolds'] = opts[:'use_scaffolds'] if !opts[:'use_scaffolds'].nil?
|
464
|
+
|
465
|
+
# header parameters
|
466
|
+
header_params = opts[:header_params] || {}
|
467
|
+
# HTTP header 'Accept' (if needed)
|
468
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
469
|
+
|
470
|
+
# form parameters
|
471
|
+
form_params = opts[:form_params] || {}
|
472
|
+
|
473
|
+
# http body (model)
|
474
|
+
post_body = opts[:debug_body]
|
475
|
+
|
476
|
+
# return_type
|
477
|
+
return_type = opts[:debug_return_type] || 'Array<StructureSearchHit>'
|
478
|
+
|
479
|
+
# auth_names
|
480
|
+
auth_names = opts[:debug_auth_names] || []
|
481
|
+
|
482
|
+
new_options = opts.merge(
|
483
|
+
:operation => :"DefaultApi.v1_indexes_index_search_identity_get",
|
484
|
+
:header_params => header_params,
|
485
|
+
:query_params => query_params,
|
486
|
+
:form_params => form_params,
|
487
|
+
:body => post_body,
|
488
|
+
:auth_names => auth_names,
|
489
|
+
:return_type => return_type
|
490
|
+
)
|
491
|
+
|
492
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
493
|
+
if @api_client.config.debugging
|
494
|
+
@api_client.config.logger.debug "API called: DefaultApi#v1_indexes_index_search_identity_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
495
|
+
end
|
496
|
+
return data, status_code, headers
|
497
|
+
end
|
498
|
+
|
425
499
|
# Perform substructure search against index
|
426
500
|
# @param index [String]
|
427
501
|
# @param smiles [String]
|
@@ -429,6 +503,7 @@ module Cheminee
|
|
429
503
|
# @option opts [Integer] :result_limit
|
430
504
|
# @option opts [Integer] :tautomer_limit
|
431
505
|
# @option opts [String] :extra_query
|
506
|
+
# @option opts [String] :use_scaffolds
|
432
507
|
# @return [Array<StructureSearchHit>]
|
433
508
|
def v1_indexes_index_search_substructure_get(index, smiles, opts = {})
|
434
509
|
data, _status_code, _headers = v1_indexes_index_search_substructure_get_with_http_info(index, smiles, opts)
|
@@ -442,6 +517,7 @@ module Cheminee
|
|
442
517
|
# @option opts [Integer] :result_limit
|
443
518
|
# @option opts [Integer] :tautomer_limit
|
444
519
|
# @option opts [String] :extra_query
|
520
|
+
# @option opts [String] :use_scaffolds
|
445
521
|
# @return [Array<(Array<StructureSearchHit>, Integer, Hash)>] Array<StructureSearchHit> data, response status code and response headers
|
446
522
|
def v1_indexes_index_search_substructure_get_with_http_info(index, smiles, opts = {})
|
447
523
|
if @api_client.config.debugging
|
@@ -464,11 +540,12 @@ module Cheminee
|
|
464
540
|
query_params[:'result_limit'] = opts[:'result_limit'] if !opts[:'result_limit'].nil?
|
465
541
|
query_params[:'tautomer_limit'] = opts[:'tautomer_limit'] if !opts[:'tautomer_limit'].nil?
|
466
542
|
query_params[:'extra_query'] = opts[:'extra_query'] if !opts[:'extra_query'].nil?
|
543
|
+
query_params[:'use_scaffolds'] = opts[:'use_scaffolds'] if !opts[:'use_scaffolds'].nil?
|
467
544
|
|
468
545
|
# header parameters
|
469
546
|
header_params = opts[:header_params] || {}
|
470
547
|
# HTTP header 'Accept' (if needed)
|
471
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
548
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
472
549
|
|
473
550
|
# form parameters
|
474
551
|
form_params = opts[:form_params] || {}
|
@@ -523,7 +600,7 @@ module Cheminee
|
|
523
600
|
# header parameters
|
524
601
|
header_params = opts[:header_params] || {}
|
525
602
|
# HTTP header 'Accept' (if needed)
|
526
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
603
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
527
604
|
|
528
605
|
# form parameters
|
529
606
|
form_params = opts[:form_params] || {}
|
@@ -587,7 +664,7 @@ module Cheminee
|
|
587
664
|
# header parameters
|
588
665
|
header_params = opts[:header_params] || {}
|
589
666
|
# HTTP header 'Accept' (if needed)
|
590
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8'])
|
667
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json; charset=utf-8']) unless header_params['Accept']
|
591
668
|
# HTTP header 'Content-Type'
|
592
669
|
content_type = @api_client.select_header_content_type(['application/json; charset=utf-8'])
|
593
670
|
if !content_type.nil?
|
data/lib/cheminee/api_client.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.8.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -211,7 +211,7 @@ module Cheminee
|
|
211
211
|
# @param [String] mime MIME
|
212
212
|
# @return [Boolean] True if the MIME is application/json
|
213
213
|
def json_mime?(mime)
|
214
|
-
(mime == '*/*') || !(mime =~
|
214
|
+
(mime == '*/*') || !(mime =~ /^Application\/.*json(?!p)(;.*)?/i).nil?
|
215
215
|
end
|
216
216
|
|
217
217
|
# Deserialize the response to the given return type.
|
@@ -290,7 +290,7 @@ module Cheminee
|
|
290
290
|
# @param [String] filename the filename to be sanitized
|
291
291
|
# @return [String] the sanitized filename
|
292
292
|
def sanitize_filename(filename)
|
293
|
-
filename.
|
293
|
+
filename.split(/[\/\\]/).last
|
294
294
|
end
|
295
295
|
|
296
296
|
def build_request_url(path, opts = {})
|
data/lib/cheminee/api_error.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.8.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -79,6 +79,14 @@ module Cheminee
|
|
79
79
|
# @return [true, false]
|
80
80
|
attr_accessor :debugging
|
81
81
|
|
82
|
+
# Set this to ignore operation servers for the API client. This is useful when you need to
|
83
|
+
# send requests to a different server than the one specified in the OpenAPI document.
|
84
|
+
# Will default to the base url defined in the spec but can be overridden by setting
|
85
|
+
# `scheme`, `host`, `base_path` directly.
|
86
|
+
# Default to false.
|
87
|
+
# @return [true, false]
|
88
|
+
attr_accessor :ignore_operation_servers
|
89
|
+
|
82
90
|
# Defines the logger used for debugging.
|
83
91
|
# Default to `Rails.logger` (when in Rails) or logging to STDOUT.
|
84
92
|
#
|
@@ -166,6 +174,7 @@ module Cheminee
|
|
166
174
|
@timeout = 0
|
167
175
|
@params_encoding = nil
|
168
176
|
@debugging = false
|
177
|
+
@ignore_operation_servers = false
|
169
178
|
@inject_format = false
|
170
179
|
@force_ending_format = false
|
171
180
|
@logger = defined?(Rails) ? Rails.logger : Logger.new(STDOUT)
|
@@ -200,6 +209,7 @@ module Cheminee
|
|
200
209
|
|
201
210
|
# Returns base URL for specified operation based on server settings
|
202
211
|
def base_url(operation = nil)
|
212
|
+
return "#{scheme}://#{[host, base_path].join('/').gsub(/\/+/, '/')}".sub(/\/+\z/, '') if ignore_operation_servers
|
203
213
|
if operation_server_settings.key?(operation) then
|
204
214
|
index = server_operation_index.fetch(operation, server_index)
|
205
215
|
server_url(index.nil? ? 0 : index, server_operation_variables.fetch(operation, server_variables), operation_server_settings[operation])
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.8.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -38,7 +38,7 @@ module Cheminee
|
|
38
38
|
# Attribute type mapping.
|
39
39
|
def self.openapi_types
|
40
40
|
{
|
41
|
-
:'extra_data' => :'
|
41
|
+
:'extra_data' => :'String',
|
42
42
|
:'smiles' => :'String',
|
43
43
|
:'query' => :'String'
|
44
44
|
}
|
@@ -47,7 +47,6 @@ module Cheminee
|
|
47
47
|
# List of attributes with nullable: true
|
48
48
|
def self.openapi_nullable
|
49
49
|
Set.new([
|
50
|
-
:'extra_data',
|
51
50
|
])
|
52
51
|
end
|
53
52
|
|
@@ -90,6 +89,10 @@ module Cheminee
|
|
90
89
|
def list_invalid_properties
|
91
90
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
92
91
|
invalid_properties = Array.new
|
92
|
+
if @extra_data.nil?
|
93
|
+
invalid_properties.push('invalid value for "extra_data", extra_data cannot be nil.')
|
94
|
+
end
|
95
|
+
|
93
96
|
if @smiles.nil?
|
94
97
|
invalid_properties.push('invalid value for "smiles", smiles cannot be nil.')
|
95
98
|
end
|
@@ -105,6 +108,7 @@ module Cheminee
|
|
105
108
|
# @return true if the model is valid
|
106
109
|
def valid?
|
107
110
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
111
|
+
return false if @extra_data.nil?
|
108
112
|
return false if @smiles.nil?
|
109
113
|
return false if @query.nil?
|
110
114
|
true
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.
|
9
|
+
Generator version: 7.8.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -44,7 +44,7 @@ module Cheminee
|
|
44
44
|
# Attribute type mapping.
|
45
45
|
def self.openapi_types
|
46
46
|
{
|
47
|
-
:'extra_data' => :'
|
47
|
+
:'extra_data' => :'String',
|
48
48
|
:'smiles' => :'String',
|
49
49
|
:'score' => :'Float',
|
50
50
|
:'query' => :'String',
|
@@ -55,7 +55,6 @@ module Cheminee
|
|
55
55
|
# List of attributes with nullable: true
|
56
56
|
def self.openapi_nullable
|
57
57
|
Set.new([
|
58
|
-
:'extra_data',
|
59
58
|
])
|
60
59
|
end
|
61
60
|
|
@@ -110,6 +109,10 @@ module Cheminee
|
|
110
109
|
def list_invalid_properties
|
111
110
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
112
111
|
invalid_properties = Array.new
|
112
|
+
if @extra_data.nil?
|
113
|
+
invalid_properties.push('invalid value for "extra_data", extra_data cannot be nil.')
|
114
|
+
end
|
115
|
+
|
113
116
|
if @smiles.nil?
|
114
117
|
invalid_properties.push('invalid value for "smiles", smiles cannot be nil.')
|
115
118
|
end
|
@@ -133,6 +136,7 @@ module Cheminee
|
|
133
136
|
# @return true if the model is valid
|
134
137
|
def valid?
|
135
138
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
139
|
+
return false if @extra_data.nil?
|
136
140
|
return false if @smiles.nil?
|
137
141
|
return false if @score.nil?
|
138
142
|
return false if @query.nil?
|
data/lib/cheminee/version.rb
CHANGED
data/lib/cheminee.rb
CHANGED
Binary file
|
data/spec/spec_helper.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cheminee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.22
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Xavier Lange
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-07-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -116,7 +116,7 @@ files:
|
|
116
116
|
- lib/cheminee/version.rb
|
117
117
|
- openapi-generator-config.json
|
118
118
|
- openapi.json
|
119
|
-
- pkg/cheminee-0.1.
|
119
|
+
- pkg/cheminee-0.1.22.gem
|
120
120
|
- spec/api/default_api_spec.rb
|
121
121
|
- spec/api_client_spec.rb
|
122
122
|
- spec/configuration_spec.rb
|
@@ -170,26 +170,26 @@ test_files:
|
|
170
170
|
- spec/api/default_api_spec.rb
|
171
171
|
- spec/api_client_spec.rb
|
172
172
|
- spec/configuration_spec.rb
|
173
|
+
- spec/models/bulk_request_spec.rb
|
174
|
+
- spec/models/query_search_hit_spec.rb
|
175
|
+
- spec/models/index_schema_spec.rb
|
176
|
+
- spec/models/index_meta_spec.rb
|
177
|
+
- spec/models/post_index_bulk_response_ok_status_spec.rb
|
178
|
+
- spec/models/get_indexes_response_error_spec.rb
|
173
179
|
- spec/models/post_index_bulk_response_ok_spec.rb
|
180
|
+
- spec/models/query_response_error_spec.rb
|
174
181
|
- spec/models/post_index_bulk_response_error_spec.rb
|
182
|
+
- spec/models/smiles_spec.rb
|
175
183
|
- spec/models/standardized_smile_spec.rb
|
176
|
-
- spec/models/
|
177
|
-
- spec/models/structure_response_error_spec.rb
|
184
|
+
- spec/models/bulk_request_doc_spec.rb
|
178
185
|
- spec/models/converted_smiles_spec.rb
|
179
|
-
- spec/models/
|
180
|
-
- spec/models/
|
181
|
-
- spec/models/
|
182
|
-
- spec/models/
|
183
|
-
- spec/models/query_response_error_spec.rb
|
186
|
+
- spec/models/standardized_smiles_spec.rb
|
187
|
+
- spec/models/schema_spec.rb
|
188
|
+
- spec/models/smile_spec.rb
|
189
|
+
- spec/models/create_index_error_spec.rb
|
184
190
|
- spec/models/substructure_search_hit_spec.rb
|
185
191
|
- spec/models/mol_block_spec.rb
|
186
|
-
- spec/models/bulk_request_doc_spec.rb
|
187
|
-
- spec/models/post_index_bulk_response_ok_status_spec.rb
|
188
|
-
- spec/models/smiles_spec.rb
|
189
|
-
- spec/models/schema_spec.rb
|
190
192
|
- spec/models/structure_search_hit_spec.rb
|
191
|
-
- spec/models/
|
193
|
+
- spec/models/structure_response_error_spec.rb
|
192
194
|
- spec/models/list_index_response_err_spec.rb
|
193
|
-
- spec/models/index_meta_spec.rb
|
194
|
-
- spec/models/create_index_error_spec.rb
|
195
195
|
- spec/spec_helper.rb
|
data/pkg/cheminee-0.1.19.gem
DELETED
Binary file
|