Files-class {sevenbridges} | R Documentation |
Class Files
FilesList(...)
... |
one or more |
Files
(with "s
") class is usally returned by the API call
which returns Files. A group of Files
is defined as FilesList
.
Users do not usually need to construct Files
or FilesList
manually, they are generated from a API call most of the time.
Files object
id
character used as file id
name
string used as file name
size
file size
project
project id if any, when returned by a API call, it usually return the project id and stored with the object.
created_on
date created on
modified_on
date modified on
storage
list as storage type
origin
list as origin
tags
list as tags
metadata
a list for metadata associated with the file
url
file download url
add_tag(x, ...)
add new tags while keeping old tags
copy_to(project = NULL, name = NULL)
copy a file to a project (id) with new name
download(destfile, ..., method = "curl")
see 'help(download.file)' for more options
meta()
get metadata from a file
setMeta(..., overwrite = FALSE)
set metadata with provided list, when overwrite is set to TRUE, it overwrites the metadata
set_meta(..., overwrite = FALSE)
set metadata with provided list, when overwrite is set to TRUE, it overwrites the metadata
set_tag(x = NULL, overwrite = TRUE, ...)
set a tag for a file, your tag need to be a list or vector
tag()
get tag from a file
update(name = NULL, metadata = NULL, tags = NULL)
This call updates the name, the full set metadata, and tags for a specified file.
In sevenbridges package version <= 1.5.4, the Files
class
inherits from the File
class defined in CWL. To avoid confusion,
in the current implementation, they are defined separately and not
coupled anymore.
Files(id = "test_id", name = "test.bam")