// ListR lists the objects and directories of the Fs starting
// from dir recursively into out.
//
// dir should be "" to start from the root, and should not
// have trailing slashes.
//
// This should return ErrDirNotFound if the directory isn't
// found.
//
// It should call callback for each tranche of entries read.
// These need not be returned in any particular order.  If
// callback returns an error then the listing will stop
// immediately.
//
// Don't implement this unless you have a more efficient way
// of listing recursively that doing a directory traversal.
ListR lists the objects and directories of the Fs starting
from dir recursively into out.

dir should be "" to start from the root, and should not
have trailing slashes.

This should return ErrDirNotFound if the directory isn't
found.

It should call callback for each tranche of entries read.
These need not be returned in any particular order.  If
callback returns an error then the listing will stop
immediately.

Don't implement this unless you have a more efficient way
of listing recursively that doing a directory traversal.
// ListR lists the objects and directories of the Fs starting // from dir recursively into out . // // dir should be " " to start from the root and should not // have trailing slashes . // // This should return ErrDirNotFound if the directory isn ' t // found . // // It should call callback for each tranche of entries read . // These need not be returned in any particular order . If // callback returns an error then the listing will stop // immediately . // // Don ' t implement this unless you have a more efficient way // of listing recursively that doing a directory traversal .
func (f *Fs) ListR(dir string, callback fs.ListRCallback) (err error) {
	if f.bucket == "" {
		return fs.ErrorListBucketRequired
	}
	list := walk.NewListRHelper(callback)
	err = f.list(dir, true, func(remote string, object *s3.Object, isDirectory bool) error {
		entry, err := f.itemToDirEntry(remote, object, isDirectory)
		if err != nil {
			return err
		}
		return list.Add(entry)
	})
	if err != nil {
		return err
	}
	f.markBucketOK()
	return list.Flush()
}
func ( f * Fs ) ListR ( dir string , callback fs . ListRCallback ) ( err error ) { if f . bucket == " " { return fs . ErrorListBucketRequired } list := walk . NewListRHelper ( callback ) err = f . list ( dir , true , func ( remote string , object * s3 . Object , isDirectory bool ) error { entry , err := f . itemToDirEntry ( remote , object , isDirectory ) if err != nil { return err } return list . Add ( entry ) } ) if err != nil { return err } f . markBucketOK ( ) return list . Flush ( ) }
ListR lists the objects and directories of the Fs starting
from dir recursively into out.
ListR lists the objects and directories of the Fs starting from dir recursively into out .
// bucket must be present if listing succeeded