Sha256: 1d4a9a3d2a31a91eda23d1f4c1023405e03e9bc70ce16d9fd6184eac8655da9a

Contents?: true

Size: 437 Bytes

Versions: 12

Compression:

Stored size: 437 Bytes

Contents

module Conveyor
  class Status
    attr_reader :success
    attr_accessor :errors
    attr_reader :path
    
    def initialize(path = nil)
      reset!(path)
    end
    
    def reset!(path = nil)
      @path = path
      @success = true
      @errors = []
    end
    
    def fail!(v = false)
      @success &= v
    end
    
    def success!(v=true)
      @success &= v
    end
    
    def success?
      @success
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
gina-conveyor-1.0.1 lib/conveyor/status.rb
gina-conveyor-1.0.0 lib/conveyor/status.rb
gina-conveyor-0.2.4 lib/conveyor/status.rb
gina-conveyor-0.2.3 lib/conveyor/status.rb
gina-conveyor-0.2.2 lib/conveyor/status.rb
gina-conveyor-0.2.1 lib/conveyor/status.rb
gina-conveyor-0.2.0 lib/conveyor/status.rb
gina-conveyor-0.1.3 lib/conveyor/status.rb
gina-conveyor-0.1.2 lib/conveyor/status.rb
gina-conveyor-0.1.1 lib/conveyor/status.rb
gina-conveyor-0.1.0 lib/conveyor/status.rb
gina-conveyor-0.0.2 lib/conveyor/status.rb