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" > <
< 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 >
2010-12-18 19:28:01 +00:00
< li > < a href = "#M000086" > directory?< / a > < / li >
2009-10-07 04:44:05 +00:00
< / ul >
< / dd >
< dt > N< / dt >
< dd >
< ul >
2010-12-18 19:28:01 +00:00
< li > < a href = "#M000084" > new< / a > ,< / li >
2009-10-07 04:44:05 +00:00
2010-12-18 19:28:01 +00:00
< li > < a href = "#M000087" > nlink< / a > < / li >
2009-10-07 04:44:05 +00:00
< / ul >
< / dd >
< dt > S< / dt >
< dd >
< ul >
2010-12-18 19:22:02 +00:00
< li > < a href = "#M000089" > size< / a > ,< / li >
2010-12-18 19:14:00 +00:00
2010-12-18 19:28:01 +00:00
< li > < a href = "#M000085" > symlink?< / a > < / li >
2009-10-07 04:44:05 +00:00
< / ul >
< / dd >
< / dl >
2010-12-18 19:14:00 +00:00
< div class = "sectiontitle" > Attributes< / div >
< table border = '0' cellpadding = '5' >
< tr valign = 'top' >
< td class = 'attr-rw' >
[R]
< / td >
< td class = 'attr-name' > ctime< / td >
< td class = 'attr-desc' > < / td >
< / tr >
< tr valign = 'top' >
< td class = 'attr-rw' >
[R]
< / td >
< td class = 'attr-name' > mtime< / td >
< td class = 'attr-desc' > < / td >
< / tr >
< / table >
2009-10-07 04:44:05 +00:00
< div class = "sectiontitle" > Class Public methods< / div >
< div class = "method" >
2010-12-18 19:28:01 +00:00
< div class = "title" id = "M000084" >
2009-10-07 04:44:05 +00:00
2010-12-18 19:28:01 +00:00
< a name = "M000084" > < / a > < b > new< / b > (file, __lstat = false)
2009-10-07 04:44:05 +00:00
< / div >
< div class = "sourcecode" >
< p class = "source-link" >
2010-12-18 19:28:01 +00:00
Source: < a href = "javascript:toggleSource('M000084_source')" id = "l_M000084_source" > show< / a >
2010-12-18 19:14:23 +00:00
| < a href = "http://github.com/defunkt/fakefs/blob/82db05e85d1a486fbdb671af4b1d93085e515c82/lib/fakefs/file.rb#L192" target = "_blank" class = "github_url" > on GitHub< / a >
2009-10-07 04:44:05 +00:00
< / p >
2010-12-18 19:28:01 +00:00
< div id = "M000084_source" class = "dyn-source" >
2010-12-18 19:14:00 +00:00
< pre > < span class = "ruby-comment cmt" > # File lib/fakefs/file.rb, line 192< / span >
< span class = "ruby-keyword kw" > def< / span > < span class = "ruby-identifier" > initialize< / span > (< span class = "ruby-identifier" > file< / span > , < span class = "ruby-identifier" > __lstat< / span > = < span class = "ruby-keyword kw" > false< / span > )
2009-10-07 04:44:05 +00:00
< 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" > " No such file or directory - #{file}" < / span > )
< span class = "ruby-keyword kw" > end< / span >
2010-12-18 19:14:00 +00:00
< span class = "ruby-ivar" > @file< / span > = < span class = "ruby-identifier" > file< / span >
< span class = "ruby-ivar" > @fake_file< / span > = < span class = "ruby-constant" > FileSystem< / span > .< span class = "ruby-identifier" > find< / span > (< span class = "ruby-ivar" > @file< / span > )
< span class = "ruby-ivar" > @__lstat< / span > = < span class = "ruby-identifier" > __lstat< / span >
< span class = "ruby-ivar" > @ctime< / span > = < span class = "ruby-ivar" > @fake_file< / span > .< span class = "ruby-identifier" > ctime< / span >
< span class = "ruby-ivar" > @mtime< / span > = < span class = "ruby-ivar" > @fake_file< / span > .< span class = "ruby-identifier" > mtime< / span >
2009-10-07 04:44:05 +00:00
< span class = "ruby-keyword kw" > end< / span > < / pre >
< / div >
< / div >
< / div >
< div class = "sectiontitle" > Instance Public methods< / div >
< div class = "method" >
2010-12-18 19:28:01 +00:00
< div class = "title" id = "M000086" >
2009-10-07 04:44:05 +00:00
2010-12-18 19:28:01 +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" >
2010-12-18 19:28:01 +00:00
Source: < a href = "javascript:toggleSource('M000086_source')" id = "l_M000086_source" > show< / a >
2010-12-18 19:14:23 +00:00
| < a href = "http://github.com/defunkt/fakefs/blob/82db05e85d1a486fbdb671af4b1d93085e515c82/lib/fakefs/file.rb#L208" target = "_blank" class = "github_url" > on GitHub< / a >
2009-10-07 04:44:05 +00:00
< / p >
2010-12-18 19:28:01 +00:00
< div id = "M000086_source" class = "dyn-source" >
2010-12-18 19:14:00 +00:00
< pre > < span class = "ruby-comment cmt" > # File lib/fakefs/file.rb, line 208< / 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" >
2010-12-18 19:28:01 +00:00
< div class = "title" id = "M000087" >
2009-10-07 04:44:05 +00:00
2010-12-18 19:28:01 +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" >
2010-12-18 19:28:01 +00:00
Source: < a href = "javascript:toggleSource('M000087_source')" id = "l_M000087_source" > show< / a >
2010-12-18 19:14:23 +00:00
| < a href = "http://github.com/defunkt/fakefs/blob/82db05e85d1a486fbdb671af4b1d93085e515c82/lib/fakefs/file.rb#L212" target = "_blank" class = "github_url" > on GitHub< / a >
2009-10-07 04:44:05 +00:00
< / p >
2010-12-18 19:28:01 +00:00
< div id = "M000087_source" class = "dyn-source" >
2010-12-18 19:14:00 +00:00
< pre > < span class = "ruby-comment cmt" > # File lib/fakefs/file.rb, line 212< / span >
2009-10-07 04:44:05 +00:00
< span class = "ruby-keyword kw" > def< / span > < span class = "ruby-identifier" > nlink< / span >
2010-12-18 19:14:00 +00:00
< span class = "ruby-ivar" > @fake_file< / span > .< span class = "ruby-identifier" > links< / span > .< span class = "ruby-identifier" > size< / span >
2009-10-07 04:44:05 +00:00
< span class = "ruby-keyword kw" > end< / span > < / pre >
< / div >
< / div >
< / div >
< div class = "method" >
2010-12-18 19:22:02 +00:00
< div class = "title" id = "M000089" >
2009-10-07 04:44:05 +00:00
2010-12-18 19:22:02 +00:00
< a name = "M000089" > < / a > < b > size< / b > ()
2009-10-07 04:44:05 +00:00
< / div >
< div class = "sourcecode" >
< p class = "source-link" >
2010-12-18 19:22:02 +00:00
Source: < a href = "javascript:toggleSource('M000089_source')" id = "l_M000089_source" > show< / a >
2010-12-18 19:14:23 +00:00
| < a href = "http://github.com/defunkt/fakefs/blob/82db05e85d1a486fbdb671af4b1d93085e515c82/lib/fakefs/file.rb#L216" target = "_blank" class = "github_url" > on GitHub< / a >
2009-10-07 04:44:05 +00:00
2010-12-18 19:14:00 +00:00
< / p >
2010-12-18 19:22:02 +00:00
< div id = "M000089_source" class = "dyn-source" >
2010-12-18 19:14:00 +00:00
< pre > < span class = "ruby-comment cmt" > # File lib/fakefs/file.rb, line 216< / span >
< span class = "ruby-keyword kw" > def< / span > < span class = "ruby-identifier" > size< / span >
< span class = "ruby-keyword kw" > if< / span > < span class = "ruby-ivar" > @__lstat< / span > < span class = "ruby-operator" > & & < / span > < span class = "ruby-identifier" > symlink?< / span >
< span class = "ruby-ivar" > @fake_file< / span > .< span class = "ruby-identifier" > target< / span > .< span class = "ruby-identifier" > size< / span >
< span class = "ruby-keyword kw" > else< / span >
< span class = "ruby-constant" > File< / span > .< span class = "ruby-identifier" > size< / span > (< span class = "ruby-ivar" > @file< / span > )
< span class = "ruby-keyword kw" > end< / span >
< span class = "ruby-keyword kw" > end< / span > < / pre >
< / div >
< / div >
< / div >
< div class = "method" >
2010-12-18 19:28:01 +00:00
< div class = "title" id = "M000085" >
2010-12-18 19:14:00 +00:00
2010-12-18 19:28:01 +00:00
< a name = "M000085" > < / a > < b > symlink?< / b > ()
2010-12-18 19:14:00 +00:00
< / div >
< div class = "sourcecode" >
< p class = "source-link" >
2010-12-18 19:28:01 +00:00
Source: < a href = "javascript:toggleSource('M000085_source')" id = "l_M000085_source" > show< / a >
2010-12-18 19:14:23 +00:00
| < a href = "http://github.com/defunkt/fakefs/blob/82db05e85d1a486fbdb671af4b1d93085e515c82/lib/fakefs/file.rb#L204" target = "_blank" class = "github_url" > on GitHub< / a >
2009-10-07 04:44:05 +00:00
< / p >
2010-12-18 19:28:01 +00:00
< div id = "M000085_source" class = "dyn-source" >
2010-12-18 19:14:00 +00:00
< pre > < span class = "ruby-comment cmt" > # File lib/fakefs/file.rb, line 204< / 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 >