File: listObjects.Rd

package info (click to toggle)
r-bioc-alabaster.base 1.6.1%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 1,652 kB
  • sloc: cpp: 11,377; sh: 29; makefile: 2
file content (46 lines) | stat: -rw-r--r-- 1,203 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/listObjects.R
\name{listObjects}
\alias{listObjects}
\alias{listLocalObjects}
\alias{listDirectory}
\title{List objects in a directory}
\usage{
listObjects(dir, include.children = FALSE)
}
\arguments{
\item{dir}{String containing a path to a staging directory.}

\item{include.children}{Logical scalar indicating whether to include child objects.}
}
\value{
\linkS4class{DataFrame} where each row corresponds to an object and contains;
\itemize{
\item \code{path}, the relative path to the object's subdirectory inside \code{dir}.
\item \code{type}, the type of the object
\item \code{child}, whether or not the object is a child of another object.
}

If \code{include.children=FALSE}, metadata is only returned for non-child objects.
}
\description{
List all objects in a directory, along with their types.
}
\examples{
tmp <- tempfile()
dir.create(tmp)

library(S4Vectors)
df <- DataFrame(A=1:10, B=LETTERS[1:10])
saveObject(df, file.path(tmp, "whee"))

ll <- list(A=1, B=LETTERS, C=DataFrame(X=1:5))
saveObject(ll, file.path(tmp, "stuff"))

listObjects(tmp)
listObjects(tmp, include.children=TRUE)

}
\author{
Aaron Lun
}