Sha256: 93530fc5bbae9d63c43b73f541ec54e414f8cdf6eae8402b1d2687c137a5271f

Contents?: true

Size: 1.39 KB

Versions: 4

Compression:

Stored size: 1.39 KB

Contents

module Inch
  module Language
    module Ruby
      module Evaluation
        module Role
          # Roles assigned to constants
          module Constant
            class WithDoc < Object::WithDoc
              applicable_if :has_doc?
            end
            class WithoutDoc < Object::WithoutDoc
              applicable_unless :has_doc?
            end

            class TaggedAsNodoc < Object::TaggedAsNodoc
              applicable_if :nodoc?
            end
            class InRoot < Object::InRoot
              applicable_if :in_root?
            end

            class Public < Object::Public
              applicable_if :public?
              priority(-1)
            end
            class Private < Object::Private
              applicable_if :private?
              priority(-3)
            end

            class WithCodeExample < Object::WithCodeExample
              applicable_if do |o|
                o.has_code_example? && !o.has_multiple_code_examples?
              end
            end

            class WithMultipleCodeExamples < Object::WithMultipleCodeExamples
              applicable_if :has_multiple_code_examples?
            end

            class WithoutCodeExample < Object::WithoutCodeExample
              applicable_unless :has_code_example?

              def suggestion
                nil
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
inch-0.9.0.rc1 lib/inch/language/ruby/roles/constant.rb
inch-0.8.0 lib/inch/language/ruby/roles/constant.rb
inch-0.8.0.rc2 lib/inch/language/ruby/roles/constant.rb
inch-0.8.0.rc1 lib/inch/language/ruby/roles/constant.rb