struct ORTools::Sat::CpModelProto

Included Modules

Defined in:

ortools-sat/connector/cp_model.pb.cr

Constant Summary

FIELDS = {1 => {name: :name, pb_type: :string, crystal_type: String, cast_type: String?, native: true, optional: true, repeated: false, default: nil, packed: false}, 2 => {name: :variables, pb_type: IntegerVariableProto, crystal_type: IntegerVariableProto, cast_type: Array(IntegerVariableProto)?, native: false, optional: true, repeated: true, default: nil, packed: false}, 3 => {name: :constraints, pb_type: ConstraintProto, crystal_type: ConstraintProto, cast_type: Array(ConstraintProto)?, native: false, optional: true, repeated: true, default: nil, packed: false}, 4 => {name: :objective, pb_type: CpObjectiveProto, crystal_type: CpObjectiveProto, cast_type: CpObjectiveProto?, native: false, optional: true, repeated: false, default: nil, packed: false}, 9 => {name: :floating_point_objective, pb_type: FloatObjectiveProto, crystal_type: FloatObjectiveProto, cast_type: FloatObjectiveProto?, native: false, optional: true, repeated: false, default: nil, packed: false}, 5 => {name: :search_strategy, pb_type: DecisionStrategyProto, crystal_type: DecisionStrategyProto, cast_type: Array(DecisionStrategyProto)?, native: false, optional: true, repeated: true, default: nil, packed: false}, 6 => {name: :solution_hint, pb_type: PartialVariableAssignment, crystal_type: PartialVariableAssignment, cast_type: PartialVariableAssignment?, native: false, optional: true, repeated: false, default: nil, packed: false}, 7 => {name: :assumptions, pb_type: :int32, crystal_type: Int32, cast_type: Array(Int32)?, native: true, optional: true, repeated: true, default: nil, packed: false}, 8 => {name: :symmetry, pb_type: SymmetryProto, crystal_type: SymmetryProto, cast_type: SymmetryProto?, native: false, optional: true, repeated: false, default: nil, packed: false}} of Int32 => HashLiteral(Symbol, ASTNode)

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(buf : Protobuf::Buffer) #

def self.new(name : String | Nil = nil, variables : Array(IntegerVariableProto) | Nil = nil, constraints : Array(ConstraintProto) | Nil = nil, objective : CpObjectiveProto | Nil = nil, floating_point_objective : FloatObjectiveProto | Nil = nil, search_strategy : Array(DecisionStrategyProto) | Nil = nil, solution_hint : PartialVariableAssignment | Nil = nil, assumptions : Array(Int32) | Nil = nil, symmetry : SymmetryProto | Nil = nil) #

Class Method Detail

def self.from_protobuf(io) #

Instance Method Detail

def [](key : String) #

def assumptions : Array(Int32) | Nil #

def assumptions=(assumptions : Array(Int32) | Nil) #

def constraints : Array(ConstraintProto) | Nil #

def constraints=(constraints : Array(ConstraintProto) | Nil) #

def floating_point_objective : FloatObjectiveProto | Nil #

def floating_point_objective=(floating_point_objective : FloatObjectiveProto | Nil) #

def name : String | Nil #

def name=(name : String | Nil) #

def objective : CpObjectiveProto | Nil #

def objective=(objective : CpObjectiveProto | Nil) #

def search_strategy : Array(DecisionStrategyProto) | Nil #

def search_strategy=(search_strategy : Array(DecisionStrategyProto) | Nil) #

def solution_hint : PartialVariableAssignment | Nil #

def solution_hint=(solution_hint : PartialVariableAssignment | Nil) #

def symmetry : SymmetryProto | Nil #

def symmetry=(symmetry : SymmetryProto | Nil) #

def to_protobuf(io : IO, embedded = false) #

def to_protobuf #

def variables : Array(IntegerVariableProto) | Nil #

def variables=(variables : Array(IntegerVariableProto) | Nil) #