basig file read implementation