library(jsonlite)
library(yaml)
f1 <- File()
f2 <- File(path = "./out.bam", checksum = "test",
size = 3L, secondaryFile = FileList(File(path = "./out.bai")))
fl <- FileList(f1, f2)
asList(fl)
writeLines(asYAML(fl))
asJSON(fl)
f1
f2
fl
Run the code above in your browser using DataLab