20660: Add devtools::check to run_test.R
[arvados.git] / sdk / R / man / ArvadosFile.Rd
index f48a71f515c6cf9ee01c4d1805b39ce78bf757b7..81c25af5f14323f880e4f9235dbde984e5d7ac0e 100644 (file)
-% Generated by roxygen2: do not edit by hand
-% Please edit documentation in R/ArvadosFile.R
-\docType{data}
-\name{ArvadosFile}
-\alias{ArvadosFile}
-\title{ArvadosFile Object}
-\format{An object of class \code{R6ClassGenerator} of length 24.}
-\usage{
-ArvadosFile
-}
-\description{
-Update description
-}
-\keyword{datasets}
+% Generated by roxygen2: do not edit by hand\r
+% Please edit documentation in R/ArvadosFile.R\r
+\name{ArvadosFile}\r
+\alias{ArvadosFile}\r
+\title{R6 Class Representing a ArvadosFile}\r
+\description{\r
+ArvadosFile class represents a file inside Arvados collection.\r
+}\r
+\examples{\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$new`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+myFile   <- ArvadosFile$new("myFile")\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$getName`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+arvadosFile$getName()\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$getFileListing`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+arvadosFile$getFileListing()\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$getSizeInBytes`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+arvadosFile$getSizeInBytes()\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$read`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+fileContent <- arvadosFile$read("text")\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$connection`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+arvConnection <- arvadosFile$connection("w")\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$flush`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+myFile$write("This is new file content")\r
+arvadosFile$flush()\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$write`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+myFile$write("This is new file content")\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$move`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+arvadosFile$move(newPath)\r
+}\r
+\r
+## ------------------------------------------------\r
+## Method `ArvadosFile$copy`\r
+## ------------------------------------------------\r
+\r
+\dontrun{\r
+arvadosFile$copy("NewName.format")\r
+}\r
+}\r
+\section{Methods}{\r
+\subsection{Public methods}{\r
+\itemize{\r
+\item \href{#method-ArvadosFile-new}{\code{ArvadosFile$new()}}\r
+\item \href{#method-ArvadosFile-getName}{\code{ArvadosFile$getName()}}\r
+\item \href{#method-ArvadosFile-getFileListing}{\code{ArvadosFile$getFileListing()}}\r
+\item \href{#method-ArvadosFile-getSizeInBytes}{\code{ArvadosFile$getSizeInBytes()}}\r
+\item \href{#method-ArvadosFile-get}{\code{ArvadosFile$get()}}\r
+\item \href{#method-ArvadosFile-getFirst}{\code{ArvadosFile$getFirst()}}\r
+\item \href{#method-ArvadosFile-getCollection}{\code{ArvadosFile$getCollection()}}\r
+\item \href{#method-ArvadosFile-setCollection}{\code{ArvadosFile$setCollection()}}\r
+\item \href{#method-ArvadosFile-getRelativePath}{\code{ArvadosFile$getRelativePath()}}\r
+\item \href{#method-ArvadosFile-getParent}{\code{ArvadosFile$getParent()}}\r
+\item \href{#method-ArvadosFile-setParent}{\code{ArvadosFile$setParent()}}\r
+\item \href{#method-ArvadosFile-read}{\code{ArvadosFile$read()}}\r
+\item \href{#method-ArvadosFile-connection}{\code{ArvadosFile$connection()}}\r
+\item \href{#method-ArvadosFile-flush}{\code{ArvadosFile$flush()}}\r
+\item \href{#method-ArvadosFile-write}{\code{ArvadosFile$write()}}\r
+\item \href{#method-ArvadosFile-move}{\code{ArvadosFile$move()}}\r
+\item \href{#method-ArvadosFile-copy}{\code{ArvadosFile$copy()}}\r
+\item \href{#method-ArvadosFile-duplicate}{\code{ArvadosFile$duplicate()}}\r
+}\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-new"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-new}{}}}\r
+\subsection{Method \code{new()}}{\r
+Initialize new enviroment.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$new(name)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{name}}{Name of the new enviroment.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Returns}{\r
+A new `ArvadosFile` object.\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+myFile   <- ArvadosFile$new("myFile")\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getName"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getName}{}}}\r
+\subsection{Method \code{getName()}}{\r
+Returns name of the file.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getName()}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+arvadosFile$getName()\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getFileListing"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getFileListing}{}}}\r
+\subsection{Method \code{getFileListing()}}{\r
+Returns collections file content as character vector.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getFileListing(fullpath = TRUE)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{fullPath}}{Checking if TRUE.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+arvadosFile$getFileListing()\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getSizeInBytes"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getSizeInBytes}{}}}\r
+\subsection{Method \code{getSizeInBytes()}}{\r
+Returns collections content size in bytes.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getSizeInBytes()}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+arvadosFile$getSizeInBytes()\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-get"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-get}{}}}\r
+\subsection{Method \code{get()}}{\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$get(fileLikeObjectName)}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getFirst"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getFirst}{}}}\r
+\subsection{Method \code{getFirst()}}{\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getFirst()}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getCollection"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getCollection}{}}}\r
+\subsection{Method \code{getCollection()}}{\r
+Returns collection UUID.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getCollection()}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-setCollection"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-setCollection}{}}}\r
+\subsection{Method \code{setCollection()}}{\r
+Sets new collection.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$setCollection(collection, setRecursively = TRUE)}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getRelativePath"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getRelativePath}{}}}\r
+\subsection{Method \code{getRelativePath()}}{\r
+Returns file path relative to the root.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getRelativePath()}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-getParent"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-getParent}{}}}\r
+\subsection{Method \code{getParent()}}{\r
+Returns project UUID.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$getParent()}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-setParent"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-setParent}{}}}\r
+\subsection{Method \code{setParent()}}{\r
+Sets project collection.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$setParent(newParent)}\if{html}{\out{</div>}}\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-read"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-read}{}}}\r
+\subsection{Method \code{read()}}{\r
+Read file content.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$read(contentType = "raw", offset = 0, length = 0)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{contentType}}{Type of content. Possible is "text", "raw".}\r
+\r
+\item{\code{offset}}{Describes the location of a piece of data compared to another location}\r
+\r
+\item{\code{length}}{Length of content}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+fileContent <- arvadosFile$read("text")\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-connection"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-connection}{}}}\r
+\subsection{Method \code{connection()}}{\r
+Get connection opened in "read" or "write" mode.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$connection(rw)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{rw}}{Type of connection.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+arvConnection <- arvadosFile$connection("w")\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-flush"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-flush}{}}}\r
+\subsection{Method \code{flush()}}{\r
+Write connections content to a file or override current content of the file.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$flush()}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+myFile$write("This is new file content")\r
+arvadosFile$flush()\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-write"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-write}{}}}\r
+\subsection{Method \code{write()}}{\r
+Write to file or override current content of the file.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$write(content, contentType = "text/html")}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{content}}{File to write.}\r
+\r
+\item{\code{contentType}}{Type of content. Possible is "text", "raw".}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+collection <- Collection$new(arv, collectionUUID)\r
+arvadosFile <- collection$get(fileName)\r
+myFile$write("This is new file content")\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-move"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-move}{}}}\r
+\subsection{Method \code{move()}}{\r
+Moves file to a new location inside collection.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$move(destination)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{destination}}{Path to new folder.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+arvadosFile$move(newPath)\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-copy"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-copy}{}}}\r
+\subsection{Method \code{copy()}}{\r
+Copies file to a new location inside collection.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$copy(destination)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{destination}}{Path to new folder.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+\subsection{Examples}{\r
+\if{html}{\out{<div class="r example copy">}}\r
+\preformatted{\dontrun{\r
+arvadosFile$copy("NewName.format")\r
+}\r
+}\r
+\if{html}{\out{</div>}}\r
+\r
+}\r
+\r
+}\r
+\if{html}{\out{<hr>}}\r
+\if{html}{\out{<a id="method-ArvadosFile-duplicate"></a>}}\r
+\if{latex}{\out{\hypertarget{method-ArvadosFile-duplicate}{}}}\r
+\subsection{Method \code{duplicate()}}{\r
+Duplicate file and gives it a new name.\r
+\subsection{Usage}{\r
+\if{html}{\out{<div class="r">}}\preformatted{ArvadosFile$duplicate(newName = NULL)}\if{html}{\out{</div>}}\r
+}\r
+\r
+\subsection{Arguments}{\r
+\if{html}{\out{<div class="arguments">}}\r
+\describe{\r
+\item{\code{newName}}{New name for duplicated file.}\r
+}\r
+\if{html}{\out{</div>}}\r
+}\r
+}\r
+}\r