Skip to content

Commit 996102f

Browse files
committed
Added domains
1 parent 700a8b1 commit 996102f

File tree

4 files changed

+41
-2
lines changed

4 files changed

+41
-2
lines changed

Project.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ uuid = "6c38235a-427b-4736-80fa-cf75909744ec"
33
authors = ["Eduardo M. G. Vila <72969764+e-duar-do@users.noreply.github.com> and contributors"]
44
version = "0.0.0"
55

6+
[deps]
7+
MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"
8+
69
[compat]
710
julia = "1.6"
811

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# 🦖DynOptInterface
2+
3+
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://JuDO-dev.github.io/DynOptInterface.jl/stable/)
4+
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://JuDO-dev.github.io/DynOptInterface.jl/dev/)
5+
[![Build Status](https://github.com/JuDO-dev/DynOptInterface.jl/actions/workflows/CI.yml/badge.svg?branch=dev)](https://github.com/JuDO-dev/DynOptInterface.jl/actions/workflows/CI.yml?query=branch%3Adev)
6+
[![Coverage](https://codecov.io/gh/JuDO-dev/DynOptInterface.jl/branch/dev/graph/badge.svg)](https://codecov.io/gh/JuDO-dev/DynOptInterface.jl)

src/DynOptInterface.jl

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
module DynOptInterface
22

3-
# Write your package code here.
3+
import MathOptInterface as MOI
44

5-
end
5+
abstract type AbstractDomain end
6+
7+
include("domains.jl")
8+
9+
end

src/domains.jl

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
"""
2+
supports_domain(
3+
model::MOI.ModelLike,
4+
::Type{<:AbstractDomain},
5+
)::Bool
6+
7+
Returns true if a domain type is supported and false ortherwise.
8+
"""
9+
function supports_domain(
10+
::MOI.ModelLike,
11+
::Type{<:AbstractDomain})
12+
return false
13+
end
14+
15+
"""
16+
FixedDomain{T} <: AbstractDomain
17+
initial::T
18+
final::T
19+
end
20+
21+
A domain type with fixed initial and final limits.
22+
"""
23+
struct FixedDomain{T} <: AbstractDomain
24+
initial::T
25+
final::T
26+
end

0 commit comments

Comments
 (0)