Faster implementation

I tried your package on a large dataset and it took over a minute. I re-implemented it and got the time down to half a second.

``` {.r}
txt <- readLines("http://data.ssb.no/api/v0/dataset/85436.json?lang=en", warn = F)
devtools::install_github("ajschumacher/rjstat", quiet = T)
```

    ## Installing github repo rjstat/master from ajschumacher
    ## Downloading master.zip from https://github.com/ajschumacher/rjstat/archive/master.zip
    ## arguments 'minimized' and 'invisible' are for Windows only

``` {.r}
library("rjstat")
system.time(fromJSONstat(txt))
```

    ##    user  system elapsed 
    ##  72.529   0.731  73.336

``` {.r}
detach("package:rjstat", unload = T)
devtools::install_github("hmalmedal/rjstat", quiet = T)
```

    ## Installing github repo rjstat/master from hmalmedal
    ## Downloading master.zip from https://github.com/hmalmedal/rjstat/archive/master.zip
    ## arguments 'minimized' and 'invisible' are for Windows only

``` {.r}
library("rjstat")
system.time(fromJSONstat(txt))
```

    ##    user  system elapsed 
    ##   0.441   0.006   0.447