Class: ROM::CommandProxy Private

Inherits:
Object
  • Object
show all
Defined in:
lib/rom/command_proxy.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

TODO: look into making command graphs work without the root key in the input so that we can get rid of this wrapper

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(command, root) ⇒ CommandProxy

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of CommandProxy.



16
17
18
19
# File 'lib/rom/command_proxy.rb', line 16

def initialize(command, root)
  @command = command
  @root = root
end

Instance Attribute Details

#commandObject (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



11
12
13
# File 'lib/rom/command_proxy.rb', line 11

def command
  @command
end

#rootObject (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



13
14
15
# File 'lib/rom/command_proxy.rb', line 13

def root
  @root
end

Instance Method Details

#>>(other) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



27
28
29
# File 'lib/rom/command_proxy.rb', line 27

def >>(other)
  self.class.new(command >> other, root)
end

#call(input) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



22
23
24
# File 'lib/rom/command_proxy.rb', line 22

def call(input)
  command.call(root => input)
end

#restrictible?Boolean

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (Boolean)


32
33
34
# File 'lib/rom/command_proxy.rb', line 32

def restrictible?
  command.restrictible?
end