Class MPModelRequest

  • All Implemented Interfaces:
    MPModelRequestOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, java.io.Serializable

    public final class MPModelRequest
    extends com.google.protobuf.GeneratedMessageV3
    implements MPModelRequestOrBuilder
     Next id: 18.
     
    Protobuf type operations_research.MPModelRequest
    See Also:
    Serialized Form
    • Field Detail

      • SOLVER_TYPE_FIELD_NUMBER

        public static final int SOLVER_TYPE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • SOLVER_TIME_LIMIT_SECONDS_FIELD_NUMBER

        public static final int SOLVER_TIME_LIMIT_SECONDS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ENABLE_INTERNAL_SOLVER_OUTPUT_FIELD_NUMBER

        public static final int ENABLE_INTERNAL_SOLVER_OUTPUT_FIELD_NUMBER
        See Also:
        Constant Field Values
      • SOLVER_SPECIFIC_PARAMETERS_FIELD_NUMBER

        public static final int SOLVER_SPECIFIC_PARAMETERS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • IGNORE_SOLVER_SPECIFIC_PARAMETERS_FAILURE_FIELD_NUMBER

        public static final int IGNORE_SOLVER_SPECIFIC_PARAMETERS_FAILURE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • MODEL_DELTA_FIELD_NUMBER

        public static final int MODEL_DELTA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • POPULATE_ADDITIONAL_SOLUTIONS_UP_TO_FIELD_NUMBER

        public static final int POPULATE_ADDITIONAL_SOLUTIONS_UP_TO_FIELD_NUMBER
        See Also:
        Constant Field Values
      • PARSER

        @Deprecated
        public static final com.google.protobuf.Parser<MPModelRequest> PARSER
        Deprecated.
    • Method Detail

      • newInstance

        protected java.lang.Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • hasModel

        public boolean hasModel()
         The model to be optimized by the server.
         
        optional .operations_research.MPModelProto model = 1;
        Specified by:
        hasModel in interface MPModelRequestOrBuilder
        Returns:
        Whether the model field is set.
      • getModel

        public MPModelProto getModel()
         The model to be optimized by the server.
         
        optional .operations_research.MPModelProto model = 1;
        Specified by:
        getModel in interface MPModelRequestOrBuilder
        Returns:
        The model.
      • hasSolverType

        public boolean hasSolverType()
        optional .operations_research.MPModelRequest.SolverType solver_type = 2 [default = GLOP_LINEAR_PROGRAMMING];
        Specified by:
        hasSolverType in interface MPModelRequestOrBuilder
        Returns:
        Whether the solverType field is set.
      • hasSolverTimeLimitSeconds

        public boolean hasSolverTimeLimitSeconds()
         Maximum time to be spent by the solver to solve 'model'. If the server is
         busy and the RPC's deadline_left is less than this, it will immediately
         give up and return an error, without even trying to solve.
        
         The client can use this to have a guarantee on how much time the
         solver will spend on the problem (unless it finds and proves
         an optimal solution more quickly).
        
         If not specified, the time limit on the solver is the RPC's deadline_left.
         
        optional double solver_time_limit_seconds = 3;
        Specified by:
        hasSolverTimeLimitSeconds in interface MPModelRequestOrBuilder
        Returns:
        Whether the solverTimeLimitSeconds field is set.
      • getSolverTimeLimitSeconds

        public double getSolverTimeLimitSeconds()
         Maximum time to be spent by the solver to solve 'model'. If the server is
         busy and the RPC's deadline_left is less than this, it will immediately
         give up and return an error, without even trying to solve.
        
         The client can use this to have a guarantee on how much time the
         solver will spend on the problem (unless it finds and proves
         an optimal solution more quickly).
        
         If not specified, the time limit on the solver is the RPC's deadline_left.
         
        optional double solver_time_limit_seconds = 3;
        Specified by:
        getSolverTimeLimitSeconds in interface MPModelRequestOrBuilder
        Returns:
        The solverTimeLimitSeconds.
      • hasEnableInternalSolverOutput

        public boolean hasEnableInternalSolverOutput()
         If this is set, then EnableOutput() will be set on the internal MPSolver
         that solves the model.
         WARNING: if you set this on a request to prod servers, it will be rejected
         and yield the RPC Application Error code MPSOLVER_SOLVER_TYPE_UNAVAILABLE.
         
        optional bool enable_internal_solver_output = 4 [default = false];
        Specified by:
        hasEnableInternalSolverOutput in interface MPModelRequestOrBuilder
        Returns:
        Whether the enableInternalSolverOutput field is set.
      • getEnableInternalSolverOutput

        public boolean getEnableInternalSolverOutput()
         If this is set, then EnableOutput() will be set on the internal MPSolver
         that solves the model.
         WARNING: if you set this on a request to prod servers, it will be rejected
         and yield the RPC Application Error code MPSOLVER_SOLVER_TYPE_UNAVAILABLE.
         
        optional bool enable_internal_solver_output = 4 [default = false];
        Specified by:
        getEnableInternalSolverOutput in interface MPModelRequestOrBuilder
        Returns:
        The enableInternalSolverOutput.
      • hasSolverSpecificParameters

        public boolean hasSolverSpecificParameters()
         Advanced usage. Solver-specific parameters in the solver's own format,
         different for each solver. For example, if you use SCIP and you want to
         stop the solve earlier than the time limit if it reached a solution that is
         at most 1% away from the optimal, you can set this to "limits/gap=0.01".
        
         Note however that there is no "security" mechanism in place so it is up to
         the client to make sure that the given options don't make the solve
         non thread safe or use up too much memory for instance.
        
         If the option format is not understood by the solver, the request will be
         rejected and yield an RPC Application error with code
         MPSOLVER_MODEL_INVALID_SOLVER_PARAMETERS, unless you have set
         ignore_solver_specific_parameters_failure=true (in which case they are
         simply ignored).
         
        optional string solver_specific_parameters = 5;
        Specified by:
        hasSolverSpecificParameters in interface MPModelRequestOrBuilder
        Returns:
        Whether the solverSpecificParameters field is set.
      • getSolverSpecificParameters

        public java.lang.String getSolverSpecificParameters()
         Advanced usage. Solver-specific parameters in the solver's own format,
         different for each solver. For example, if you use SCIP and you want to
         stop the solve earlier than the time limit if it reached a solution that is
         at most 1% away from the optimal, you can set this to "limits/gap=0.01".
        
         Note however that there is no "security" mechanism in place so it is up to
         the client to make sure that the given options don't make the solve
         non thread safe or use up too much memory for instance.
        
         If the option format is not understood by the solver, the request will be
         rejected and yield an RPC Application error with code
         MPSOLVER_MODEL_INVALID_SOLVER_PARAMETERS, unless you have set
         ignore_solver_specific_parameters_failure=true (in which case they are
         simply ignored).
         
        optional string solver_specific_parameters = 5;
        Specified by:
        getSolverSpecificParameters in interface MPModelRequestOrBuilder
        Returns:
        The solverSpecificParameters.
      • getSolverSpecificParametersBytes

        public com.google.protobuf.ByteString getSolverSpecificParametersBytes()
         Advanced usage. Solver-specific parameters in the solver's own format,
         different for each solver. For example, if you use SCIP and you want to
         stop the solve earlier than the time limit if it reached a solution that is
         at most 1% away from the optimal, you can set this to "limits/gap=0.01".
        
         Note however that there is no "security" mechanism in place so it is up to
         the client to make sure that the given options don't make the solve
         non thread safe or use up too much memory for instance.
        
         If the option format is not understood by the solver, the request will be
         rejected and yield an RPC Application error with code
         MPSOLVER_MODEL_INVALID_SOLVER_PARAMETERS, unless you have set
         ignore_solver_specific_parameters_failure=true (in which case they are
         simply ignored).
         
        optional string solver_specific_parameters = 5;
        Specified by:
        getSolverSpecificParametersBytes in interface MPModelRequestOrBuilder
        Returns:
        The bytes for solverSpecificParameters.
      • hasIgnoreSolverSpecificParametersFailure

        public boolean hasIgnoreSolverSpecificParametersFailure()
        optional bool ignore_solver_specific_parameters_failure = 9 [default = false];
        Specified by:
        hasIgnoreSolverSpecificParametersFailure in interface MPModelRequestOrBuilder
        Returns:
        Whether the ignoreSolverSpecificParametersFailure field is set.
      • getIgnoreSolverSpecificParametersFailure

        public boolean getIgnoreSolverSpecificParametersFailure()
        optional bool ignore_solver_specific_parameters_failure = 9 [default = false];
        Specified by:
        getIgnoreSolverSpecificParametersFailure in interface MPModelRequestOrBuilder
        Returns:
        The ignoreSolverSpecificParametersFailure.
      • hasModelDelta

        public boolean hasModelDelta()
         Advanced usage: model "delta". If used, "model" must be unset. See the
         definition of MPModelDeltaProto.
         
        optional .operations_research.MPModelDeltaProto model_delta = 8;
        Specified by:
        hasModelDelta in interface MPModelRequestOrBuilder
        Returns:
        Whether the modelDelta field is set.
      • getModelDelta

        public MPModelDeltaProto getModelDelta()
         Advanced usage: model "delta". If used, "model" must be unset. See the
         definition of MPModelDeltaProto.
         
        optional .operations_research.MPModelDeltaProto model_delta = 8;
        Specified by:
        getModelDelta in interface MPModelRequestOrBuilder
        Returns:
        The modelDelta.
      • hasPopulateAdditionalSolutionsUpTo

        public boolean hasPopulateAdditionalSolutionsUpTo()
         Controls the recovery of additional solutions, if any, saved by the
         underlying solver back in the MPSolutionResponse.additional_solutions.
         The repeated field will be length
            min(populate_addition_solutions_up_to,
                #additional_solutions_available_in_underlying_solver)
         These additional solutions may have a worse objective than the main
         solution returned in the response.
         
        optional int32 populate_additional_solutions_up_to = 11 [default = 0];
        Specified by:
        hasPopulateAdditionalSolutionsUpTo in interface MPModelRequestOrBuilder
        Returns:
        Whether the populateAdditionalSolutionsUpTo field is set.
      • getPopulateAdditionalSolutionsUpTo

        public int getPopulateAdditionalSolutionsUpTo()
         Controls the recovery of additional solutions, if any, saved by the
         underlying solver back in the MPSolutionResponse.additional_solutions.
         The repeated field will be length
            min(populate_addition_solutions_up_to,
                #additional_solutions_available_in_underlying_solver)
         These additional solutions may have a worse objective than the main
         solution returned in the response.
         
        optional int32 populate_additional_solutions_up_to = 11 [default = 0];
        Specified by:
        getPopulateAdditionalSolutionsUpTo in interface MPModelRequestOrBuilder
        Returns:
        The populateAdditionalSolutionsUpTo.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws java.io.IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        java.io.IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(java.lang.Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static MPModelRequest parseFrom​(java.nio.ByteBuffer data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(java.nio.ByteBuffer data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(com.google.protobuf.ByteString data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(com.google.protobuf.ByteString data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(byte[] data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(byte[] data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static MPModelRequest parseFrom​(java.io.InputStream input)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static MPModelRequest parseFrom​(java.io.InputStream input,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static MPModelRequest parseDelimitedFrom​(java.io.InputStream input)
                                                 throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static MPModelRequest parseDelimitedFrom​(java.io.InputStream input,
                                                        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                 throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static MPModelRequest parseFrom​(com.google.protobuf.CodedInputStream input)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static MPModelRequest parseFrom​(com.google.protobuf.CodedInputStream input,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • newBuilderForType

        public MPModelRequest.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public MPModelRequest.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected MPModelRequest.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static MPModelRequest getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<MPModelRequest> parser()
      • getParserForType

        public com.google.protobuf.Parser<MPModelRequest> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public MPModelRequest getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder