Sha256: d34cab9575525dcf61ef297e42a21f2f8780c396ab95d9c156062e13bfbc6387

Contents?: true

Size: 1.92 KB

Versions: 6

Compression:

Stored size: 1.92 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>generate_html_result (WebT2App)</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 pkg/t2-web-0.0.5/bin/t2_webapp.rb, line 137</span>
    <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generate_html_result</span>(<span class="ruby-identifier">data</span>)
      <span class="ruby-identifier">html</span> = <span class="ruby-value str">&quot;&quot;</span>
      <span class="ruby-comment cmt">#p data</span>
      <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">data</span>.<span class="ruby-identifier">instance_of?</span> <span class="ruby-constant">Array</span>
        <span class="ruby-identifier">html</span> = <span class="ruby-identifier">data</span>.<span class="ruby-identifier">flatten</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">'&lt;br&gt;'</span>)
      <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">data</span>.<span class="ruby-identifier">instance_of?</span> <span class="ruby-constant">String</span>
        <span class="ruby-identifier">html</span> = <span class="ruby-identifier">data</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-regexp re">/[\n]/</span>, <span class="ruby-value str">'&lt;br&gt;'</span>)
      <span class="ruby-keyword kw">else</span>
        <span class="ruby-identifier">html</span> = <span class="ruby-identifier">data</span>
      <span class="ruby-keyword kw">end</span>
      <span class="ruby-identifier">html</span>
    <span class="ruby-keyword kw">end</span></pre>
</body>
</html>

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
t2-web-0.1.1 doc/classes/WebT2App.src/M000050.html
t2-web-0.1.0 doc/classes/WebT2App.src/M000050.html
t2-web-0.0.9 doc/classes/WebT2App.src/M000050.html
t2-web-0.0.8 doc/classes/WebT2App.src/M000050.html
t2-web-0.0.7 doc/classes/WebT2App.src/M000050.html
t2-web-0.0.6 doc/classes/WebT2App.src/M000050.html