# Type parameter transformation, StaticArray with blade indexing

**URL:** <https://discourse.julialang.org/t/type-parameter-transformation-staticarray-with-blade-indexing/18371>\
**Category:** General Usage\
**Tags:** question, array, type, parametric-types\
**Created:** [December 6, 2018, 12:24pm UTC](https://discourse.julialang.org/t/type-parameter-transformation-staticarray-with-blade-indexing/18371 "2018-12-06T12:24:41Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![sairus7](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sairus7/32/10816_2.png) [@sairus7](https://discourse.julialang.org/u/sairus7)\
**Post date:** [December 6, 2018, 12:35pm UTC](https://discourse.julialang.org/t/type-parameter-transformation-staticarray-with-blade-indexing/18371/2 "2018-12-06T12:35:54Z")

</div>

See how it is done in [OffsetArrays.jl](https://github.com/JuliaArrays/OffsetArrays.jl/blob/master/src/OffsetArrays.jl)

Also, I have asked similar question for custom array types here:

> [@Recipe for custom array types with metadata bound to it](https://discourse.julialang.org/t/recipe-for-custom-array-types-with-meta-data-bound-to-it/18370):
>
> I want to implement custom array type with some additional fields to store useful metadata information bound to that array. But, similar to [OffsetArrays.jl](https://github.com/JuliaArrays/OffsetArrays.jl), I want to implement it for any AbstractArray subtype (simple array, [AxisArray](https://github.com/JuliaArrays/AxisArrays.jl), [StructArray](https://github.com/piever/StructArrays.jl), [CircularBuffer](https://github.com/JuliaCollections/DataStructures.jl/blob/master/src/circular_buffer.jl), etc.). To do that, I should write something like OffsetArray [source](https://github.com/JuliaArrays/OffsetArrays.jl/blob/master/src/OffsetArrays.jl): mutable struct MyArray{T,N,AA\<:AbstractArray} \<: AbstractArray{T,N} array::AA useful\_data1::Int64 useful\_data2::String # and maybe another useful da…

---

_[View the full topic](https://discourse.julialang.org/t/type-parameter-transformation-staticarray-with-blade-indexing/18371)._
