module VV::FileMethods

Public Class Methods

check_file_methods() click to toggle source
# File lib/vv/file_methods.rb, line 4
def self.check_file_methods
  ClassMethods.public_instance_methods.each do |method|
    next if method.to_s.starts_with? "vv_"

    message = \
    "File defines method already, cowardly exiting."
    fail message if File.respond_to? method
  end
end
included(base) click to toggle source
# File lib/vv/file_methods.rb, line 14
def self.included(base)
  self.check_file_methods if base == File

  base.extend(ClassMethods)
end

Public Instance Methods

vv_readlines() click to toggle source
# File lib/vv/file_methods.rb, line 247
def vv_readlines
  self.class.vv_readlines self
end