Sha256: 81e022f111be55b74b55bca2c18be5c6a8d53ee83604f28beb91771475e10a54

Contents?: true

Size: 595 Bytes

Versions: 47

Compression:

Stored size: 595 Bytes

Contents

module Doorkeeper
  module Rails
    class Routes
      class Mapper
        def initialize(mapping = Mapping.new)
          @mapping = mapping
        end

        def map(&block)
          self.instance_eval(&block) if block
          @mapping
        end

        def controllers(controller_names = {})
          @mapping.controllers.merge!(controller_names)
        end

        def skip_controllers(*controller_names)
          @mapping.skips = controller_names
        end

        def as(alias_names = {})
          @mapping.as.merge!(alias_names)
        end
      end
    end
  end
end

Version data entries

47 entries across 47 versions & 1 rubygems

Version Path
doorkeeper-4.0.0.rc3 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-4.0.0.rc2 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-4.0.0.rc1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-3.1.0 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-3.0.1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.2.2 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-3.0.0 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-3.0.0.rc2 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-3.0.0.rc1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.2.1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.2.0 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.1.4 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-1.4.2 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.1.3 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.1.2 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.1.1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.1.0 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.0.1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-1.4.1 lib/doorkeeper/rails/routes/mapper.rb
doorkeeper-2.0.0 lib/doorkeeper/rails/routes/mapper.rb