Sha256: ea16ec3ca06f7a920e573cd91af66d35ca8358057b0475c1bbfbe1bf2a19b7a9

Contents?: true

Size: 487 Bytes

Versions: 79

Compression:

Stored size: 487 Bytes

Contents

require_relative 'guaranteed_file'

module Trackler
  class Description
    def self.for(problem:, track: )
      new(GuaranteedFile.for(problem: problem, track: track, filename: 'description.md'))
    end

    def initialize(description_file)
      @file = description_file
      @content = description_file.content
    end
    private_class_method :new

    def to_s
      @content
    end

    def url
      @file.url
    end

    def exists?
      !@content.empty?
    end
  end
end

Version data entries

79 entries across 79 versions & 1 rubygems

Version Path
trackler-2.1.0.24 lib/trackler/description.rb
trackler-2.1.0.23 lib/trackler/description.rb
trackler-2.1.0.22 lib/trackler/description.rb
trackler-2.1.0.21 lib/trackler/description.rb
trackler-2.1.0.20 lib/trackler/description.rb
trackler-2.1.0.19 lib/trackler/description.rb
trackler-2.1.0.18 lib/trackler/description.rb
trackler-2.1.0.17 lib/trackler/description.rb
trackler-2.1.0.16 lib/trackler/description.rb
trackler-2.1.0.15 lib/trackler/description.rb
trackler-2.1.0.14 lib/trackler/description.rb
trackler-2.1.0.13 lib/trackler/description.rb
trackler-2.1.0.12 lib/trackler/description.rb
trackler-2.1.0.11 lib/trackler/description.rb
trackler-2.1.0.10 lib/trackler/description.rb
trackler-2.1.0.9 lib/trackler/description.rb
trackler-2.1.0.8 lib/trackler/description.rb
trackler-2.1.0.7 lib/trackler/description.rb
trackler-2.1.0.6 lib/trackler/description.rb
trackler-2.1.0.5 lib/trackler/description.rb