Sha256: d6e9ad08b87e5800b153c01b0164d1c1f8fa468d655d5d827c169c60ed64b326

Contents?: true

Size: 1.04 KB

Versions: 8

Compression:

Stored size: 1.04 KB

Contents

# frozen_string_literal: true

module ConvenientService
  module Service
    module Plugins
      module CanHaveSteps
        module Entities
          class Step
            module Plugins
              module CanBeCompleted
                module Concern
                  include Support::Concern

                  instance_methods do
                    ##
                    # @return [Bool]
                    #
                    def completed?
                      Utils.to_bool(internals.cache[:completed])
                    end

                    ##
                    # @return [Bool]
                    #
                    def not_completed?
                      !completed?
                    end

                    ##
                    # @return [void]
                    #
                    def mark_as_completed!
                      internals.cache[:completed] = true
                    end
                  end
                end
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
convenient_service-0.19.1 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.19.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.18.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.17.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.16.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.15.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.14.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb
convenient_service-0.13.0 lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/can_be_completed/concern.rb