Sha256: 33e388028a787d8fb24bafd41022fc7899bd0b467a1958370753004b9990427a

Contents?: true

Size: 574 Bytes

Versions: 9

Compression:

Stored size: 574 Bytes

Contents

module Papercall
  # Superclass for fetchers. A fetcher fetches submissions of different
  # categories and stores them in instance variables.
  class Fetcher
    attr_reader :submitted, :accepted, :rejected, :waitlist, :declined

    def all
      {
        submitted: @submitted,
        accepted: @accepted,
        rejected: @rejected,
        waitlist: @waitlist,
        declined: @declined
      }
    end

    def analysis
      all = @submitted
      all += @accepted
      all += @rejected
      all += @waitlist
      all += @declined
      all
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
papercall-1.0.0 lib/papercall/fetcher.rb
papercall-0.15.2 lib/papercall/fetcher.rb
papercall-0.15.1 lib/papercall/fetcher.rb
papercall-0.15.0 lib/papercall/fetcher.rb
papercall-0.14.0 lib/papercall/fetcher.rb
papercall-0.13.0 lib/papercall/fetcher.rb
papercall-0.12.0 lib/papercall/fetcher.rb
papercall-0.11.0 lib/papercall/fetcher.rb
papercall-0.10.0 lib/papercall/fetcher.rb