@@ -3,6 +3,8 @@ export AbstractSolver, solve!
3
3
" Abstract type from which JSO solvers derive."
4
4
abstract type AbstractSolver end
5
5
6
+ abstract type AbstractOptimizationSolver <: AbstractSolver end
7
+
6
8
"""
7
9
solve!(solver, model; kwargs...)
8
10
solve!(solver, model, stats; kwargs...)
@@ -11,7 +13,7 @@ Apply `solver` to `model`.
11
13
12
14
# Arguments
13
15
14
- - `solver::AbstractSolver `: solver structure to hold all storage necessary for a solve
16
+ - `solver::AbstractOptimizationSolver `: solver structure to hold all storage necessary for a solve
15
17
- `model::AbstractNLPModel`: the model solved, see `NLPModels.jl`
16
18
- `stats::GenericExecutionStats`: stats structure to hold solution information.
17
19
@@ -20,9 +22,14 @@ The second one fills out a preallocated stats structure and allows for efficient
20
22
21
23
The `kwargs` are passed to the solver.
22
24
"""
23
- function solve! (solver:: AbstractSolver , model:: AbstractNLPModel ; kwargs... )
25
+ function solve! (solver:: AbstractOptimizationSolver , model:: AbstractNLPModel ; kwargs... )
24
26
stats = GenericExecutionStats (:unknown , model)
25
27
solve! (solver, model, stats; kwargs... )
26
28
end
27
29
28
- function solve! (:: AbstractSolver , :: AbstractNLPModel , :: GenericExecutionStats ; kwargs... ) end
30
+ function solve! (
31
+ :: AbstractOptimizationSolver ,
32
+ :: AbstractNLPModel ,
33
+ :: GenericExecutionStats ;
34
+ kwargs... ,
35
+ ) end
0 commit comments