| PolyhedraDatabase | R Documentation |
Scrapes all polyhedra in data folder to save a representation which
is accessible by the final users upon call to getPolyhedron().
versionversion of database file
polyhedra.rds.filepath of rds database file
sources.configSources configuration for scraping different sources
ledgerrr ledger of scraping process
loggerclass logger
new()Create a new PolyhedraDatabase object.
PolyhedraDatabase$new()
A new 'PolyhedraDatabase' object.
getVersion()get the version of the current object.
PolyhedraDatabase$getVersion()
Database version
configPolyhedraRDSPath()sets the path of the RDS object
PolyhedraDatabase$configPolyhedraRDSPath()
Database version
existsSource()Determines if the source exists on the database
PolyhedraDatabase$existsSource(source)
sourcesource description
boolean value
addSourceConfig()add source.config to the database
PolyhedraDatabase$addSourceConfig(source.config)
source.configSourceConfig object able to scrape source polyhedra definitions
PolyhedraDatabase object
existsPolyhedron()Determines if the database includes a polyhedron which name matches the parameter value
PolyhedraDatabase$existsPolyhedron(source = "netlib", polyhedron.name)
sourcesource description
polyhedron.namepolyhedron description
boolean value
getPolyhedraSourceDir()gets polyhedra sources folder
PolyhedraDatabase$getPolyhedraSourceDir(source, create.dir = TRUE)
sourcesource description
create.dirif dir does not exists, create it
string with polyhedra sources path
getPolyhedronFilename()gets the filename of the polyhedron matching parameter.
PolyhedraDatabase$getPolyhedronFilename(source, polyhedron.name, extension)
sourcesource description
polyhedron.namepolyhedron description
extensionextension of the polyhedron filename
string with polyhedron filename
getPolyhedron()gets polyhedron object which name matches the parameter value
PolyhedraDatabase$getPolyhedron( source = "netlib", polyhedron.name, strict = FALSE )
sourcesource description
polyhedron.namepolyhedron description
stricthalts execution if polyhedron not found
Polyhedron object
addPolyhedron()add polyhedron object to the database
PolyhedraDatabase$addPolyhedron( source = "netlib", source.filename, polyhedron, overwrite = FALSE, save.on.change = FALSE )
sourcesource description
source.filenamefilename of the polyhedron source definition
polyhedronpolyhedron object
overwriteoverwrite exiting definition
save.on.changesaves Database state after operation
Polyhedron object
configPolyhedraSource()Process parameter filenames using source.config parameter
PolyhedraDatabase$configPolyhedraSource( source.config, source.filenames = NULL, max.quant = 0, save.on.change = FALSE )
source.configsource configuration for scraping files
source.filenamesfilenames of the polyhedron source definition
max.quantmaximum filenames to process
save.on.changesaves Database state after operation
Modified 'PolyhedraDatabase' object.
saveRDS()saveRDS
PolyhedraDatabase$saveRDS(save.on.change = TRUE)
save.on.changesaves Database state after operation
saveRDS return status
cover()Cover objects and applies covering.code parameter
PolyhedraDatabase$cover( mode, sources = names(self$sources.config), covering.code, polyhedra.names = NULL, max.quant = 0, save.on.change = FALSE, seed = NULL )
modecovering mode. Available values are "scrape.queued", "scrape.retry","skipped", "test"
sourcessources names
covering.codecode for applying in covering
polyhedra.namespolyhedra names to cover (optional)
max.quantmaximum numbers of polyhedra to cover
save.on.changesaves Database state after operation
seedseed for deterministic random generator
A list with resulting objects covered
scrape()Scrape polyhedra queued sources
PolyhedraDatabase$scrape( mode = "scrape.queued", sources = names(self$sources.config), max.quant = 0, time2scrape.source = 30, save.on.change = FALSE, skip.still.queued = FALSE )
modecovering mode. Available values are "scrape.queued", "scrape.retry","skipped", "test"
sourcessources names
max.quantmaximum numbers of polyhedra to cover
time2scrape.sourcemaximum time to spend scraping each source
save.on.changesaves Database state after operation
skip.still.queuedFlag unscraped files with status 'skipped“
covering.codecode for applying in covering
polyhedra.namespolyhedra names to cover (optional)
A list with resulting objects covered
testRR()testRR
PolyhedraDatabase$testRR(sources = names(self$sources.config), max.quant = 0)
sourcessources names
max.quantmaximum numbers of polyhedra to cover
A list with resulting objects tested
generateTestTasks()generate Test tasks for selected polyhedra
PolyhedraDatabase$generateTestTasks( sources = names(self$sources.config), polyhedra.names = NULL, TestTaskClass, max.quant = 0 )
sourcessources names
polyhedra.namespolyhedra names to cover (optional)
TestTaskClassan R6 TestTaskClass class
max.quantmaximum numbers of polyhedra to cover
A list with resulting TestTasks generated
schedulePolyhedraSources()Schedules polyhedra sources for scraping
PolyhedraDatabase$schedulePolyhedraSources(
sources.config = getPackageEnvir(".available.sources"),
source.filenames = NULL,
max.quant = 0,
save.on.change = FALSE
)sources.configsources configurations for scraping files
source.filenamesfilenames of the polyhedron source definition
max.quantmaximum filenames to process
save.on.changesaves Database state after operation
Modified 'PolyhedraDatabase' object.
getAvailableSources()Returns available sources in current database
PolyhedraDatabase$getAvailableSources()
A vector with names of available sources
getAvailablePolyhedra()Retrieves all polyhedron within the source those names match with search.string
PolyhedraDatabase$getAvailablePolyhedra( sources = self$getAvailableSources(), search.string = NULL, ignore.case = TRUE )
sourcessources names
search.stringstring for matching polyhedron names
ignore.caseignore case in search string
A list with resulting objects covered
clone()The objects of this class are cloneable with this method.
PolyhedraDatabase$clone(deep = FALSE)
deepWhether to make a deep clone.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.