## Open virtual device to demonstrate methods
my_device <- demo_adf(write_protected = FALSE)
device_type(my_device)
device_capacity(my_device) # in bytes
volume_capacity(my_device) # in bytes
n_volumes(my_device) # number of volumes available on device
volume_name(my_device) # name of the volume
volume_name(my_device) <- "new_name" # rename the volume
bytes_free(my_device) # bytes available for writing
is_bootable(my_device) # tests if device is potentially bootable
is_fast_file_system(my_device) # tests if volume uses FFS
is_international(my_device) # tests if file system uses intl mode
is_dircache(my_device) # tests if file system uses dir caching
is_write_protected(my_device) # tests if device is protected against writing
close(my_device)
Run the code above in your browser using DataLab