Sha256: c0d3e3e62420811dcd3363f89578733fbd238033ad32d64e602398ce0b3321db

Contents?: true

Size: 1.96 KB

Versions: 2

Compression:

Stored size: 1.96 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>show_file (bin/dskserver.rb)</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 bin/dskserver.rb, line 125</span>
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">show_file</span>(<span class="ruby-identifier">relative_path</span>,<span class="ruby-identifier">filename</span>)
        <span class="ruby-identifier">absolute_path</span>=<span class="ruby-ivar">@@root_directory</span><span class="ruby-operator">+</span><span class="ruby-identifier">relative_path</span>
        <span class="ruby-identifier">dsk</span>=<span class="ruby-constant">DSK</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">absolute_path</span>)
        <span class="ruby-identifier">file</span>=<span class="ruby-identifier">dsk</span>.<span class="ruby-identifier">files</span>[<span class="ruby-identifier">filename</span>]
        <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">file</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-keyword kw">then</span>
                <span class="ruby-identifier">s</span>=<span class="ruby-node">&quot;&lt;i&gt;#{filename} not found&lt;/i&gt;&quot;</span>
        <span class="ruby-keyword kw">else</span> 
                <span class="ruby-identifier">s</span>=<span class="ruby-node">&quot;&lt;hl&gt;&lt;pre&gt;#{file.file_type=='B'?file.disassembly : file.to_s}\n&lt;/pre&gt;&lt;hl&gt;&quot;</span>
        <span class="ruby-keyword kw">end</span>
        <span class="ruby-identifier">s</span>
<span class="ruby-keyword kw">end</span></pre>
</body>
</html>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
dsktool-0.1.5 doc/files/bin/dskserver_rb.src/M000005.html
dsktool-0.2.1 doc/files/bin/dskserver_rb.src/M000005.html