Class: Pathname

Inherits:
Object
  • Object
show all
Defined in:
lib/torquebox/vfs/ext/pathname.rb

Instance Method Summary collapse

Instance Method Details

#realpathObject



25
26
27
# File 'lib/torquebox/vfs/ext/pathname.rb', line 25

def realpath
  vfs_path? ? expand_path : realpath_without_vfs
end

#realpath_without_vfsObject



22
# File 'lib/torquebox/vfs/ext/pathname.rb', line 22

alias_method :realpath_without_vfs, :realpath

#relative?Boolean

Returns:

  • (Boolean)


33
34
35
# File 'lib/torquebox/vfs/ext/pathname.rb', line 33

def relative?
  vfs_path? ? false : relative_without_vfs
end

#relative_without_vfsObject



23
# File 'lib/torquebox/vfs/ext/pathname.rb', line 23

alias_method :relative_without_vfs, :relative?

#vfs_path?Boolean

Returns:

  • (Boolean)


29
30
31
# File 'lib/torquebox/vfs/ext/pathname.rb', line 29

def vfs_path?
  @path.to_s =~ /^vfs:/
end