An array which contents can be loaded only when needed
Install via composer
composer require harp-orm/lazy-array
$arr = new LazyArray($loader);
// This is where the loader->load() method gets executed
echo $arr[2];
Copyright (c) 2015, Clippings Ltd. Developed by Ivan Kerin
Under BSD-3-Clause license, read LICENSE file.