class Gecode::Set::Cardinality::CardinalityConstraint

Describes a cardinality constraint specifically for ranges. This is just a special case which is used instead of the more general composite constraint when the target cardinality is a range.

Public Instance Methods

post() click to toggle source
# File doc/tmp/rdoc_dev/gecoder/interface/constraints/set/cardinality.rb, line 21
def post
  var, range = @params.values_at(:lhs, :range)
  Gecode::Raw::cardinality(@model.active_space, var.to_set_var.bind, 
    range.first, range.last)