Modified some accessors to use a template type instead of an std::size_t for the index.