Module: GBDev::Utils::PrivateMethods

Included in:
PDF::Book, PDF::Page
Defined in:
lib/pdf_filler/util_methods.rb

Instance Method Summary collapse

Instance Method Details

#build_random_file_nameObject

:nodoc:



12
13
14
# File 'lib/pdf_filler/util_methods.rb', line 12

def build_random_file_name # :nodoc:
  build_random_string << '.pdf'
end

#build_random_stringObject

:nodoc:



7
8
9
10
# File 'lib/pdf_filler/util_methods.rb', line 7

def build_random_string # :nodoc:
  letters_array = [('a'..'z'),('A'..'Z')].collect{|i| i.to_a}.flatten
  (1..10).collect{ letters_array[ rand(letters_array.length) ] }.join 
end