GPhoto2::Camera::Filesystem
Instance methods
/(path) : CameraFolder
Returns CameraFolder instance of the given path.
# Get a list of filenames in a path.
folder = camera/"store_00010001/DCIM/100D5100"
folder.files.map(&.name) # => ["DSC_0001.JPG", "DSC_0002.JPG", ...]
blob(path : Path | String) : CameraFile
Returns CameraFile instance of the given path.
file = camera.blob("/store_00010001/DCIM/100D5100/DSC_0001.JPG")
file.name # => "DSC_0001.JPG"
filesystem(path : Path | String = "/") : CameraFolder
Returns CameraFolder instance of the given path.
# Get a list of filenames in a path.
folder = camera/"store_00010001/DCIM/100D5100"
folder.files.map(&.name) # => ["DSC_0001.JPG", "DSC_0002.JPG", ...]
filesystem_reset
Clear the filesystem.
Resets the filesystem. All cached information including the folder tree will get lost and will be queried again on demand.