Sha256: 86ab8bf9162df887bc369e4d6debf5945e2c00de3b0f10e0a5abb882113b3c69

Contents?: true

Size: 1.97 KB

Versions: 1

Compression:

Stored size: 1.97 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 (ProDOSFile)</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/ProDOSFile.rb, line 10</span>
        <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">filename</span>,<span class="ruby-identifier">contents</span>,<span class="ruby-identifier">file_type</span>,<span class="ruby-identifier">aux_type</span>)
                <span class="ruby-identifier">raise</span> <span class="ruby-node">&quot;filename too long - #{filename}&quot;</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">filename</span>.<span class="ruby-identifier">length</span><span class="ruby-operator">&lt;=</span><span class="ruby-value">15</span>
                <span class="ruby-ivar">@filename</span>=<span class="ruby-identifier">filename</span>
                <span class="ruby-ivar">@contents</span>=<span class="ruby-identifier">contents</span>
                <span class="ruby-ivar">@file_type</span>=<span class="ruby-constant">PRODOS_FILE_TYPES</span>[<span class="ruby-identifier">file_type</span>]
                <span class="ruby-ivar">@file_type</span>=<span class="ruby-identifier">sprintf</span>(<span class="ruby-value str">'$%02X'</span>,<span class="ruby-identifier">file_type</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@file_type</span>.<span class="ruby-identifier">nil?</span>
                <span class="ruby-ivar">@aux_type</span>=<span class="ruby-identifier">aux_type</span>
        <span class="ruby-keyword kw">end</span></pre>
</body>
</html>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
dsktool-0.4.1 doc/classes/ProDOSFile.src/M000121.html