Extends File class and add new method
class MyFile < File def MyFile.ftype(*args) return "The type is #{super}." end end File.ftype("/bin") # => "directory" puts MyFile.ftype("/bin") # => "The type is directory."