Class: Rtlog::MonthEntry

Inherits:
Entry
  • Object
show all
Defined in:
lib/rtlog/archives.rb

Instance Attribute Summary

Attributes inherited from Entry

#config, #logger, #path

Instance Method Summary collapse

Methods inherited from Entry

#==, #date, #initialize

Methods included from DirUtils

#entries

Constructor Details

This class inherits a constructor from Rtlog::Entry

Instance Method Details

#day_entriesObject



169
170
171
172
173
174
175
176
177
# File 'lib/rtlog/archives.rb', line 169

def day_entries
  unless defined?(@day_entries) && @day_entries
    @day_entries = []
    entries(@path).each do |path|
      @day_entries << DayEntry.new(config, path)
    end
  end
  @day_entries
end

#sizeObject



179
180
181
182
183
184
185
186
187
# File 'lib/rtlog/archives.rb', line 179

def size
  unless defined?(@size) && @size
    @size = 0
    day_entries.each do |d|
      @size += d.size
    end
  end
  @size
end