Sha256: 399efecf1f726aa6b7e01d4778699b2fd6f0b7476dc47cb7f071502523d8fcca
Contents?: true
Size: 1.98 KB
Versions: 1
Compression:
Stored size: 1.98 KB
Contents
<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title>new (OdbcConnectionWrapper)</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" /> </head> <body class="standalone-code"> <pre><span class="ruby-comment cmt"># File lib/marjoree/odbc_connection_wrapper.rb, line 15</span> <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span> <span class="ruby-identifier">yaml</span> = <span class="ruby-constant">IO</span>.<span class="ruby-identifier">read</span>(<span class="ruby-node">"#{OdbcConnectionWrapper.odbc_config_path}"</span>) <span class="ruby-ivar">@odbc_config</span> = <span class="ruby-constant">YAML</span>.<span class="ruby-identifier">load</span>(<span class="ruby-constant">ERB</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">yaml</span>).<span class="ruby-identifier">result</span>(<span class="ruby-identifier">binding</span>)) <span class="ruby-ivar">@odbc_connections</span> = {} <span class="ruby-ivar">@default_odbc_name</span> = <span class="ruby-ivar">@odbc_config</span>.<span class="ruby-identifier">size</span> <span class="ruby-operator">==</span> <span class="ruby-value">1</span> <span class="ruby-operator">?</span> <span class="ruby-ivar">@odbc_config</span>.<span class="ruby-identifier">keys</span>.<span class="ruby-identifier">first</span> <span class="ruby-operator">:</span> <span class="ruby-ivar">@odbc_config</span>[<span class="ruby-value str">'default'</span>][<span class="ruby-value str">'odbc_connection'</span>] <span class="ruby-identifier">connect_me_to</span>( <span class="ruby-value str">'default'</span> ) <span class="ruby-keyword kw">end</span></pre> </body> </html>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
marjoree-0.0.9 | ./html/classes/OdbcConnectionWrapper.src/M000025.html |