stat.nlink â fixnum Instance Public methods Returns the number of hard links to stat. File.stat("testfile").nlink #=> 1 File.link("testfile", "testfile.bak") #=> 0 File.stat("testfile").nlink #=> 2
stat.owned? â true or false Instance Public methods Returns true if the effective user id of the process is the same as the owner of stat. File.stat("testfile").owned? #=> true File.stat("/etc/passwd").owned? #=> false
stat.pipe? â true or false Instance Public methods Returns true if the operating system supports pipes and stat is a pipe; false otherwise.
pretty_print(q) Instance Public methods
stat.rdev â fixnum or nil Instance Public methods Returns an integer representing the device type on which stat resides. Returns nil if the operating system doesn't support this feature. File.stat("/dev/fd1").rdev #=> 513 File.stat("/dev/tty").rdev #=> 1280
stat.rdev_major â fixnum Instance Public methods Returns the major part of File_Stat#rdev or nil. File.stat("/dev/fd1").rdev_major #=> 2 File.stat("/dev/tty").rdev_major #=> 5
stat.rdev_minor â fixnum Instance Public methods Returns the minor part of File_Stat#rdev or nil. File.stat("/dev/fd1").rdev_minor #=> 1 File.stat("/dev/tty").rdev_minor #=> 0
stat.readable? â true or false Instance Public methods Returns true if stat is readable by the effective user id of this process. File.stat("testfile").readable? #=> true
stat.readable_real? â true or false Instance Public methods Returns true if stat is readable by the real user id of this process. File.stat("testfile").readable_real? #=> true
stat.setgid? â true or false Instance Public methods Returns true if stat has the set-group-id permission bit set, false if it doesn't or if the operating system doesn't support this feature. File.stat("/usr/sbin/lpc").setgid? #=> true
Page 237 of 11844