Read data from files using a Fortran format specification.
Fortran is great, isn't it? But do you have lots of data sitting in Fortran-formatted files that you would like to access using Swift for your own nefarious purposes? Yes, I thought so. All of the boilerplate you need is here.
let format = try FortranFile.format(string: "1x,4i1,i5,12i3,f15.11,2f18.11,f14.11,f20.11")
let result = try FortranFile.read(input: input, using: format)
The result is an array of any FortranValue
corresponding to the values read from the input.
Dw.d
Ew.d
Fw.d
Gw.d
Iw
Lw
Aw
nX
B
BN
BZ
nP