From b5d23150591cd29accf3ec818389e30d5812d7ef Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Thu, 13 Aug 2009 11:12:40 +0200 Subject: description added, rdoc removed --- rdoc/classes/OpenTox/Compound.html | 247 ------------------------------------- 1 file changed, 247 deletions(-) delete mode 100644 rdoc/classes/OpenTox/Compound.html (limited to 'rdoc/classes/OpenTox/Compound.html') diff --git a/rdoc/classes/OpenTox/Compound.html b/rdoc/classes/OpenTox/Compound.html deleted file mode 100644 index c892d0e..0000000 --- a/rdoc/classes/OpenTox/Compound.html +++ /dev/null @@ -1,247 +0,0 @@ - - - - - - Class: OpenTox::Compound - - - - - - - - - - -
- - - - - - - - - - - - - - -
ClassOpenTox::Compound
In: - - lib/opentox-ruby-api-wrapper.rb - -
-
Parent: - - OpenTox - -
-
- - -
- - - -
- - - -
- -
-

Methods

- -
- match   - match?   - new   - smiles   -
-
- -
- - - - -
- - - - - - - - - -
-

Public Class methods

- -
- - - - -
-

-Initialize with :uri => uri, :smiles => smiles or :name => name -(name can be also an InChI/InChiKey, CAS number, etc) -

-

[Source]

-
-
-# File lib/opentox-ruby-api-wrapper.rb, line 18
-                def initialize(params)
-                        if params[:uri]
-                                @uri = params[:uri].to_s
-                        elsif params[:smiles]
-                                @uri = RestClient.post ENV['OPENTOX_COMPOUNDS'] ,:smiles => uri_escape(params[:smiles])
-                        elsif params[:name]
-                                @uri = RestClient.post ENV['OPENTOX_COMPOUNDS'] ,:name => uri_escape(params[:name])
-                        end
-                end
-
-
-
-
- -

Public Instance methods

- -
- - - - -
-

-Match an array of smarts features, returns matching features -

-

[Source]

-
-
-# File lib/opentox-ruby-api-wrapper.rb, line 43
-                def match(smarts_features)
-                        smarts_features.collect{ |smarts| smarts if self.match?(smarts.name) }.compact
-                end
-
-
-
-
- -
- - - - -
-

-Matchs a smarts string -

-

[Source]

-
-
-# File lib/opentox-ruby-api-wrapper.rb, line 34
-                def match?(smarts)
-                        if RestClient.get(@uri + '/match/' + uri_escape(smarts)) == 'true'
-                                true
-                        else
-                                false
-                        end
-                end
-
-
-
-
- -
- - - - -
-

-Get the (canonical) smiles -

-

[Source]

-
-
-# File lib/opentox-ruby-api-wrapper.rb, line 29
-                def smiles
-                        RestClient.get @uri
-                end
-
-
-
-
- - -
- - -
- - -
-

[Validate]

-
- - - \ No newline at end of file -- cgit v1.2.3