Sha256: 942c53578300e589eb02dff7455d183fb652bbc0a0b0dfe9c686bd20efee6182

Contents?: true

Size: 247 Bytes

Versions: 9

Compression:

Stored size: 247 Bytes

Contents

require 'facets/functor'

class String

  # Use fluent notation for making file directives.
  #
  #    '~/trans/Desktop/notes.txt'.file.mtime
  #  
  def file
    f = self
    Functor.new do |op, *a|
      File.send(op, f, *a)
    end
  end

end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
facets-2.8.4 lib/core/facets/string/file.rb
facets-2.8.3 lib/core/facets/string/file.rb
facets-2.8.2 lib/core/facets/string/file.rb
facets-2.8.1 lib/core/facets/string/file.rb
facets-2.8.0 lib/core/facets/string/file.rb
facets-2.7.0 lib/core/facets/string/file.rb
facets-2.6.0 lib/core/facets/string/file.rb
facets-2.5.1 lib/core/facets/string/file.rb
facets-2.5.2 lib/core/facets/string/file.rb