Mercurial > repos > public > sbplib_julia
comparison src/Grids/equidistant_grid.jl @ 1421:69c9e6eae686
Merge bugfix/grids/complete_interface_impl
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Fri, 25 Aug 2023 08:49:07 +0200 |
parents | adbdbf1c3480 |
children | e3a80ef08d09 |
comparison
equal
deleted
inserted
replaced
1409:cb5f30cd0e68 | 1421:69c9e6eae686 |
---|---|
17 # Indexing interface | 17 # Indexing interface |
18 Base.getindex(g::EquidistantGrid, i) = g.points[i] | 18 Base.getindex(g::EquidistantGrid, i) = g.points[i] |
19 Base.eachindex(g::EquidistantGrid) = eachindex(g.points) | 19 Base.eachindex(g::EquidistantGrid) = eachindex(g.points) |
20 Base.firstindex(g::EquidistantGrid) = firstindex(g.points) | 20 Base.firstindex(g::EquidistantGrid) = firstindex(g.points) |
21 Base.lastindex(g::EquidistantGrid) = lastindex(g.points) | 21 Base.lastindex(g::EquidistantGrid) = lastindex(g.points) |
22 | |
23 Base.axes(g::EquidistantGrid, d) = axes(g.points, d) | |
22 | 24 |
23 # Iteration interface | 25 # Iteration interface |
24 Base.iterate(g::EquidistantGrid) = iterate(g.points) | 26 Base.iterate(g::EquidistantGrid) = iterate(g.points) |
25 Base.iterate(g::EquidistantGrid, state) = iterate(g.points, state) | 27 Base.iterate(g::EquidistantGrid, state) = iterate(g.points, state) |
26 | 28 |