Sha256: 96bdb457ffad0edb5f37a365e3812df4383ff87d0220a2c13c6b365647e841a9
Contents?: true
Size: 416 Bytes
Versions: 44
Compression:
Stored size: 416 Bytes
Contents
# Aruba module Aruba # Platforms module Platforms # Determine size of a file # # @param [String] path # The path to file # # @return [Integer] # Returns size if exists. Returns -1 if path does not exist class DetermineFileSize def call(path) return -1 unless File.file? path FileSize.new( File.size(path) ) end end end end
Version data entries
44 entries across 44 versions & 4 rubygems