Class: Rxrb::Rx::Type

Inherits:
Object
  • Object
show all
Defined in:
lib/rxrb/rx/type.rb

Direct Known Subclasses

Core

Defined Under Namespace

Modules: NoParams Classes: Core

Instance Method Summary collapse

Constructor Details

#initialize(param, _rx) ⇒ Type

Returns a new instance of Type.



4
5
6
# File 'lib/rxrb/rx/type.rb', line 4

def initialize(param, _rx)
  assert_valid_params(param)
end

Instance Method Details

#assert_valid_params(param) ⇒ Object



12
13
14
15
16
17
18
# File 'lib/rxrb/rx/type.rb', line 12

def assert_valid_params(param)
  param.each_key do |k|
    unless allowed_param?(k)
      raise Rx::Exception, "unknown parameter #{k} for #{uri}"
    end
  end
end

#uriObject



8
9
10
# File 'lib/rxrb/rx/type.rb', line 8

def uri
  self.class.uri
end