class Loader

@note This class loads file with text to analyze @return [Hash] of all text

Public Class Methods

call(path) click to toggle source

@note This method is loading text, next is removing special characters,

next is splitting it to Array.
# File lib/artemo/loader.rb, line 8
def self.call(path)
  begin
    File.read(File.expand_path(path)).gsub!(/[^a-zA-Z ]/, '').downcase!.split(' ')
  rescue
    nil
  end
end