Send feedback
Stay organized with collections
Save and categorize content based on your preferences.
C++ Reference: class SatHelper
This documentation is automatically generated.
Method
ModelStats
Return type: static std::string
Arguments:
const operations_research::sat::CpModelProto& model_proto
Returns a string with some statistics on the given CpModelProto.
Solve
Return type: static operations_research::sat::CpSolverResponse
Arguments:
const operations_research::sat::CpModelProto& model_proto
The arguments of the functions defined below must follow these rules
to be wrapped by swig correctly:
1) Their types must include the full operations_research::sat::
namespace.
2) Their names must correspond to the ones declared in the .i
file (see the python/ and java/ subdirectories).
3) String variations of the parameters have been added for C# as
C# protobufs do not support proto2.
SolverResponseStats
Return type: static std::string
Arguments:
const operations_research::sat::CpSolverResponse& response
Returns a string with some statistics on the solver response.
SolveWithParameters
Return type: static operations_research::sat::CpSolverResponse
Arguments:
const operations_research::sat::CpModelProto& model_proto,
const operations_research::sat::SatParameters& parameters
SolveWithParametersAndSolutionCallback
Arguments:
const operations_research::sat::CpModelProto& model_proto,
const operations_research::sat::SatParameters& parameters,
const SolutionCallback& callback
SolveWithStringParameters
Return type: static operations_research::sat::CpSolverResponse
Arguments:
const operations_research::sat::CpModelProto& model_proto,
const std::string& parameters
SolveWithStringParametersAndSolutionCallback
Arguments:
const operations_research::sat::CpModelProto& model_proto,
const std::string& parameters, const SolutionCallback& callback
ValidateModel
Return type: static std::string
Arguments:
const operations_research::sat::CpModelProto& model_proto
Returns a non empty string explaining the issue if the model is not valid.
VariableDomain
Return type: static operations_research::Domain
Arguments:
const operations_research::sat::IntegerVariableProto& variable_proto
Rebuilds a domain from an integer variable proto.
WriteModelToFile
Return type: static bool
Arguments:
const operations_research::sat::CpModelProto& model_proto,
const std::string& filename
Write the model proto to file.
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2021-01-05 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples / code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Need to tell us more?