fakefs/classes/FakeFS/File/Stat.html

210 lines
7.9 KiB
HTML
Raw Normal View History

2009-10-07 04:44:05 +00:00
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>FakeFS::File::Stat</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" href="../../../css/reset.css" type="text/css" media="screen" />
<link rel="stylesheet" href="../../../css/main.css" type="text/css" media="screen" />
<script src="../../../js/jquery-1.3.2.min.js" type="text/javascript" charset="utf-8"></script>
<script src="../../../js/jquery-effect.js" type="text/javascript" charset="utf-8"></script>
<script src="../../../js/main.js" type="text/javascript" charset="utf-8"></script>
</head>
<body>
<div class="banner">
<h1>
<span class="type">Class</span>
FakeFS::File::Stat
<span class="parent">&lt;
<a href="../../Object.html">Object</a>
</span>
</h1>
<ul class="files">
<li><a href="../../../files/lib/fakefs/file_rb.html">lib/fakefs/file.rb</a></li>
</ul>
</div>
<div id="bodyContent">
<div id="content">
<div class="sectiontitle">Methods</div>
<dl class="methods">
<dt>D</dt>
<dd>
<ul>
2009-10-30 17:03:19 +00:00
<li><a href="#M000086">directory?</a></li>
2009-10-07 04:44:05 +00:00
</ul>
</dd>
<dt>N</dt>
<dd>
<ul>
2009-10-30 17:03:19 +00:00
<li><a href="#M000083">new</a>,</li>
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
<li><a href="#M000087">nlink</a></li>
2009-10-07 04:44:05 +00:00
</ul>
</dd>
<dt>S</dt>
<dd>
<ul>
2009-10-30 17:03:19 +00:00
<li><a href="#M000085">symlink?</a></li>
2009-10-07 04:44:05 +00:00
</ul>
</dd>
</dl>
<div class="sectiontitle">Class Public methods</div>
<div class="method">
2009-10-30 17:03:19 +00:00
<div class="title" id="M000083">
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
<a name="M000083"></a><b>new</b>(file)
2009-10-07 04:44:05 +00:00
</div>
<div class="sourcecode">
<p class="source-link">
2009-10-30 17:03:19 +00:00
Source: <a href="javascript:toggleSource('M000083_source')" id="l_M000083_source">show</a>
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
| <a href="http://github.com/defunkt/fakefs/blob/bfffa910e9a8d5caf1628d7707ef19b7c4e5e1f0/lib/fakefs/file.rb#L184" target="_blank" class="github_url">on GitHub</a>
2009-10-07 04:44:05 +00:00
</p>
2009-10-30 17:03:19 +00:00
<div id="M000083_source" class="dyn-source">
<pre><span class="ruby-comment cmt"># File lib/fakefs/file.rb, line 184</span>
2009-10-07 04:44:05 +00:00
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">file</span>)
<span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-constant">File</span>.<span class="ruby-identifier">exists?</span>(<span class="ruby-identifier">file</span>)
<span class="ruby-identifier">raise</span>(<span class="ruby-constant">Errno</span><span class="ruby-operator">::</span><span class="ruby-constant">ENOENT</span>, <span class="ruby-node">&quot;No such file or directory - #{file}&quot;</span>)
<span class="ruby-keyword kw">end</span>
<span class="ruby-ivar">@file</span> = <span class="ruby-identifier">file</span>
<span class="ruby-keyword kw">end</span></pre>
</div>
</div>
</div>
<div class="sectiontitle">Instance Public methods</div>
<div class="method">
2009-10-30 17:03:19 +00:00
<div class="title" id="M000086">
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
<a name="M000086"></a><b>directory?</b>()
2009-10-07 04:44:05 +00:00
</div>
<div class="sourcecode">
<p class="source-link">
2009-10-30 17:03:19 +00:00
Source: <a href="javascript:toggleSource('M000086_source')" id="l_M000086_source">show</a>
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
| <a href="http://github.com/defunkt/fakefs/blob/bfffa910e9a8d5caf1628d7707ef19b7c4e5e1f0/lib/fakefs/file.rb#L196" target="_blank" class="github_url">on GitHub</a>
2009-10-07 04:44:05 +00:00
</p>
2009-10-30 17:03:19 +00:00
<div id="M000086_source" class="dyn-source">
<pre><span class="ruby-comment cmt"># File lib/fakefs/file.rb, line 196</span>
2009-10-07 04:44:05 +00:00
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">directory?</span>
<span class="ruby-constant">File</span>.<span class="ruby-identifier">directory?</span>(<span class="ruby-ivar">@file</span>)
<span class="ruby-keyword kw">end</span></pre>
</div>
</div>
</div>
<div class="method">
2009-10-30 17:03:19 +00:00
<div class="title" id="M000087">
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
<a name="M000087"></a><b>nlink</b>()
2009-10-07 04:44:05 +00:00
</div>
<div class="sourcecode">
<p class="source-link">
2009-10-30 17:03:19 +00:00
Source: <a href="javascript:toggleSource('M000087_source')" id="l_M000087_source">show</a>
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
| <a href="http://github.com/defunkt/fakefs/blob/bfffa910e9a8d5caf1628d7707ef19b7c4e5e1f0/lib/fakefs/file.rb#L200" target="_blank" class="github_url">on GitHub</a>
2009-10-07 04:44:05 +00:00
</p>
2009-10-30 17:03:19 +00:00
<div id="M000087_source" class="dyn-source">
<pre><span class="ruby-comment cmt"># File lib/fakefs/file.rb, line 200</span>
2009-10-07 04:44:05 +00:00
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">nlink</span>
<span class="ruby-constant">FileSystem</span>.<span class="ruby-identifier">find</span>(<span class="ruby-ivar">@file</span>).<span class="ruby-identifier">links</span>.<span class="ruby-identifier">size</span>
<span class="ruby-keyword kw">end</span></pre>
</div>
</div>
</div>
<div class="method">
2009-10-30 17:03:19 +00:00
<div class="title" id="M000085">
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
<a name="M000085"></a><b>symlink?</b>()
2009-10-07 04:44:05 +00:00
</div>
<div class="sourcecode">
<p class="source-link">
2009-10-30 17:03:19 +00:00
Source: <a href="javascript:toggleSource('M000085_source')" id="l_M000085_source">show</a>
2009-10-07 04:44:05 +00:00
2009-10-30 17:03:19 +00:00
| <a href="http://github.com/defunkt/fakefs/blob/bfffa910e9a8d5caf1628d7707ef19b7c4e5e1f0/lib/fakefs/file.rb#L192" target="_blank" class="github_url">on GitHub</a>
2009-10-07 04:44:05 +00:00
</p>
2009-10-30 17:03:19 +00:00
<div id="M000085_source" class="dyn-source">
<pre><span class="ruby-comment cmt"># File lib/fakefs/file.rb, line 192</span>
2009-10-07 04:44:05 +00:00
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">symlink?</span>
<span class="ruby-constant">File</span>.<span class="ruby-identifier">symlink?</span>(<span class="ruby-ivar">@file</span>)
<span class="ruby-keyword kw">end</span></pre>
</div>
</div>
</div>
</div>
</div>
</body>
</html>