Mercurial > repos > public > sbplib_julia
comparison src/Grids/grid.jl @ 1507:de7b76b61ecd feature/grids/componentview
Clearify docs of `component_type`
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Mon, 19 Feb 2024 15:56:03 +0100 |
parents | 06dec7b68f82 |
children | 6309ca375dcd |
comparison
equal
deleted
inserted
replaced
1500:0d630d4e1d21 | 1507:de7b76b61ecd |
---|---|
33 coordinate_size(g::Grid) = coordinate_size(typeof(g)) # TBD: Name of this function?! | 33 coordinate_size(g::Grid) = coordinate_size(typeof(g)) # TBD: Name of this function?! |
34 | 34 |
35 """ | 35 """ |
36 component_type(gf) | 36 component_type(gf) |
37 | 37 |
38 The type of the components of `gf`. | 38 The type of the components of the elements of `gf`. |
39 """ | 39 """ |
40 component_type(T::Type) = eltype(eltype(T)) | 40 component_type(T::Type) = eltype(eltype(T)) |
41 component_type(t) = component_type(typeof(t)) | 41 component_type(t) = component_type(typeof(t)) |
42 | 42 |
43 componentview(gf, component_index...) = ArrayComponentView(gf, component_index) | 43 componentview(gf, component_index...) = ArrayComponentView(gf, component_index) |