APIdock / Ruby
/
Browse About
method

path

v2_1_10 - Show latest stable - Class: File
path(p1)
public

Returns the string representation of the path

File.path("/dev/null")          #=> "/dev/null"
File.path(Pathname.new("/tmp")) #=> "/tmp"
static VALUE
rb_file_s_path(VALUE klass, VALUE fname)
{
    return rb_get_path(fname);
}

Related methods

  • Instance methods
  • atime
  • chmod
  • chown
  • ctime
  • flock
  • lstat
  • mtime
  • path
  • size
  • to_path
  • truncate
  • Class methods
  • absolute_path
  • atime
  • basename
  • blockdev?
  • chardev?
  • chmod
  • chown
  • ctime
  • delete
  • directory?
  • dirname
  • executable?
  • executable_real?
  • exist?
  • exists?
  • expand_path
  • extname
  • file?
  • fnmatch
  • fnmatch?
  • ftype
  • grpowned?
  • identical?
  • join
  • lchmod
  • lchown
  • link
  • lstat
  • mtime
  • new
  • open
  • owned?
  • path
  • pipe?
  • readable?
  • readable_real?
  • readlink
  • realdirpath
  • realpath
  • rename
  • setgid?
  • setuid?
  • size
  • size?
  • socket?
  • split
  • stat
  • sticky?
  • symlink
  • symlink?
  • truncate
  • umask
  • unlink
  • utime
  • world_readable?
  • world_writable?
  • writable?
  • writable_real?
  • zero?
APIdock API Documentation Browser

© 2026 APIdock