Skip to content

Commit c790e57

Browse files
committed
fixed attributes, added tests
1 parent a269639 commit c790e57

23 files changed

+329
-440
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "DynOptInterface"
22
uuid = "6c38235a-427b-4736-80fa-cf75909744ec"
33
authors = ["Eduardo M. G. Vila <72969764+e-duar-do@users.noreply.github.com> and contributors"]
4-
version = "0.0.0"
4+
version = "0.1.0"
55

66
[deps]
77
MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"

docs/make.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ using DocumenterMermaid
66
DocMeta.setdocmeta!(DynOptInterface, :DocTestSetup, :(import DynOptInterface as DOI); recursive=true)
77

88
const _PAGES = [
9-
#"Home" => "index.md",
9+
"Home" => "index.md",
1010
"API Reference" => [
1111
"Dynamic Functions" => [
1212
"reference/dynamic_functions/abstraction.md",
@@ -17,9 +17,9 @@ const _PAGES = [
1717
],
1818
"reference/boundary_functions.md",
1919
"reference/nonlinear_support.md",
20-
"reference/attributes.md",
2120
"reference/solutions.md",
2221
],
22+
"Changelog" => "changelog.md",
2323
]
2424

2525
links = InterLinks(

docs/src/changelog.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
```@meta
2+
CurrentModule = DynOptInterface
3+
```
4+
5+
# Changelog
6+
7+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
8+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
9+
10+
## v0.1.0 (July 26, 2024)
11+
12+
- Initial release

docs/src/reference/attributes.md

Lines changed: 0 additions & 22 deletions
This file was deleted.

docs/src/reference/dynamic_functions/dynamic_variables.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,21 @@ CurrentModule = DynOptInterface
88
DynamicVariableIndex
99
supports_dynamic_variable
1010
UnsupportedDynamicVariable
11-
add_dynamic_variable
1211
AddDynamicVariableNotAllowed
12+
add_dynamic_variable
1313
MOI.is_valid(::MOI.ModelLike, ::DynamicVariableIndex)
1414
InvalidDynamicVariableIndex
15+
```
16+
17+
# Attributes
18+
19+
The [`DynamicVariableIndex`](@ref) object is compatible with the following attributes:
20+
* [`MOI.VariableName`](@extref MathOptInterface.VariableName) with value types `String`
21+
* [`MOI.VariablePrimal`](@extref MathOptInterface.VariablePrimal) with value types [`AbstractDynamicSolution`](@ref)
22+
* [`MOI.VariablePrimalStart`](@extref MathOptInterface.VariablePrimalStart) with value types [`AbstractDynamicSolution`](@ref)
23+
24+
```@docs
25+
MOI.supports(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::Type{DynamicVariableIndex})
26+
MOI.set(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::DynamicVariableIndex, ::Any)
27+
MOI.get(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::DynamicVariableIndex)
1528
```

docs/src/reference/dynamic_functions/expressions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ LinearDynamicTerm
1111
LinearDynamicFunction
1212
```
1313

14-
## Squared
14+
## Pure Quadratic
1515
```@docs
16-
SquaredDynamicTerm
17-
SquaredDynamicFunction
16+
PureQuadraticDynamicTerm
17+
PureQuadraticDynamicFunction
1818
```
1919

2020
## Nonlinear

docs/src/reference/dynamic_functions/phases.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,17 @@ AddPhaseNotAllowed
1212
add_phase
1313
MOI.is_valid(::MOI.ModelLike, ::PhaseIndex)
1414
InvalidPhaseIndex
15+
```
16+
17+
# Attributes
18+
19+
The [`PhaseIndex`](@ref) object is compatible with the following attributes:
20+
* [`MOI.VariableName`](@extref MathOptInterface.VariableName) with value types `String`
21+
* [`MOI.VariablePrimal`](@extref MathOptInterface.VariablePrimal) with value types `Tuple{<:Real,<:Real}`
22+
* [`MOI.VariablePrimalStart`](@extref MathOptInterface.VariablePrimalStart) with value types `Tuple{<:Real,<:Real}`
23+
24+
```@docs
25+
MOI.supports(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::Type{PhaseIndex})
26+
MOI.set(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::PhaseIndex, ::Any)
27+
MOI.get(::MOI.ModelLike, ::MOI.AbstractVariableAttribute, ::PhaseIndex)
1528
```

src/DynOptInterface.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ include("boundary_functions.jl")
1212

1313
include("nonlinear_support.jl")
1414

15-
include("attributes.jl")
16-
1715
include("solutions.jl")
1816

1917
end

src/attributes.jl

Lines changed: 0 additions & 257 deletions
This file was deleted.

0 commit comments

Comments
 (0)