Abstract interface to implement random-access instances.
This module forms a shared interface for reading and writing bytes to different backends. By having a shared interface, it means implementations can easily be swapped, depending on the environment.
```rust extern crate randomaccessstorage;
use randomaccessstorage::{RandomAccessMethods, RandomAccess};
struct S; impl RandomAccessMethods for S { type Error = std::io::Error;
fn open(&mut self) -> Result<(), Self::Error> { unimplemented!(); }
fn write(&mut self, offset: u64, data: &[u8]) -> Result<(), Self::Error> { unimplemented!(); }
fn read(&mut self, offset: u64, length: u64) -> Result
fn readtowriter( &mut self, offset: u64, length: u64, writer: &mut impl std::io::Writer ) -> Result<(), Self::Error> { unimplemented!(); }
fn del(&mut self, offset: u64, length: u64) -> Result<(), Self::Error> { unimplemented!(); }
fn truncate(&mut self, length: u64) -> Result<(), Self::Error> { unimplemented!(); } }
let _file = RandomAccess::new(S); ```
sh
$ cargo add random-access-storage
MIT OR Apache-2.0