Class: CSP::Algorithms::Filtering::NoFilter

Inherits:
Object
  • Object
show all
Defined in:
lib/csp/algorithms/filtering/no_filter.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(problem) ⇒ NoFilter

Returns a new instance of NoFilter.



13
14
15
# File 'lib/csp/algorithms/filtering/no_filter.rb', line 13

def initialize(problem)
  @problem = problem
end

Instance Attribute Details

#problemObject (readonly)

Returns the value of attribute problem.



7
8
9
# File 'lib/csp/algorithms/filtering/no_filter.rb', line 7

def problem
  @problem
end

Class Method Details

.for(problem:, dependency: nil) ⇒ Object

rubocop:disable Lint/UnusedMethodArgument



9
10
11
# File 'lib/csp/algorithms/filtering/no_filter.rb', line 9

def self.for(problem:, dependency: nil) # rubocop:disable Lint/UnusedMethodArgument
  new(problem)
end

Instance Method Details

#call(values:, assignment_values: []) ⇒ Object

rubocop:disable Lint/UnusedMethodArgument



17
18
19
# File 'lib/csp/algorithms/filtering/no_filter.rb', line 17

def call(values:, assignment_values: []) # rubocop:disable Lint/UnusedMethodArgument
  values
end