Class: Vpim::Repo::Directory

Inherits:
Vpim::Repo show all
Defined in:
lib/vpim/repo.rb

Defined Under Namespace

Classes: Calendar

Instance Method Summary collapse

Constructor Details

#initialize(where = ".") ⇒ Directory

Returns a new instance of Directory.



173
174
175
# File 'lib/vpim/repo.rb', line 173

def initialize(where = ".")
  @where = where.to_str
end

Instance Method Details

#eachObject

:nodoc:



177
178
179
180
181
182
# File 'lib/vpim/repo.rb', line 177

def each #:nodoc:
  Dir[ File.expand_path(@where + "/**/*.ics") ].each do |file|
    yield Calendar.new(file)
  end
  self
end