package: Installed or available packages

Description Usage Arguments Value Examples

Description

Retrieves the packages installed or available for this version of SyncroSim.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
package(ssimObject = NULL, installed = TRUE, listTemplates = NULL)

## S4 method for signature 'character'
package(ssimObject = NULL, installed = TRUE, listTemplates = NULL)

## S4 method for signature 'missingOrNULL'
package(ssimObject = NULL, installed = TRUE, listTemplates = NULL)

## S4 method for signature 'Session'
package(ssimObject = NULL, installed = TRUE, listTemplates = NULL)

## S4 method for signature 'SsimLibrary'
package(ssimObject)

Arguments

ssimObject

Session or SsimLibrary object. If NULL (default), session() will be used

installed

logical or character. TRUE (default) to list installed packages, FALSE to list available packages, and "BASE" to list installed base packages

listTemplates

character. Name of a SyncroSim package. If not NULL (default), then lists all templates available for that package. The package must be installed in the current Session. Ignored if ssimObject is a SsimLibrary object

Value

Returns a data.frame of packages installed or templates available for a specified package.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Set the file path and name of the new SsimLibrary
myLibraryName <- file.path(tempdir(),"testlib")

# Set the SyncroSim Session and SsimLibrary
mySession <- session()
myLibrary <- ssimLibrary(name = myLibraryName, session = mySession)

# List all installed packages
package(mySession)

# List all the installed base packages
package(installed = "BASE")

# List all available packages on the server (including currently installed)
package(installed = FALSE)
 
# Check the package you're SsimLibrary is currently using
package(myLibrary)

# Check the templates available for an installed package
addPackage("helloworldSpatial")
package(listTemplates = "helloworldSpatial")

rsyncrosim documentation built on Oct. 28, 2021, 1:07 a.m.