| fdp-class {rDataPipeline} | R Documentation |
fdp-class
Description
fdp-class
fdp-class
Details
Container for class fdp
Public fields
yamla
listcontaining the contents of the working config.yamlfdp_config_dira
stringspecifying the directory passed fromfair runmodel_configa
stringspecifying the URL of an entry in theobjecttable associated with thestorage_locationof the working config.yamlsubmission_scripta
stringspecifying the URL of an entry in theobjecttable associated with thestorage_locationof the submission scriptcode_repoa
stringspecifying the URL of an entry in theobjecttable associated with the GitHub repositorycode_runa
stringspecifying the URL of an entry in thecode_runtableinputsa
data.framecontaining metadata associated withcode_runinputsoutputsa
data.framecontaining metadata associated withcode_runoutputsissuesa
data.framecontaining metadata associated withcode_runissues
Methods
Public methods
Method new()
Create a new fdp object
Usage
fdp$new( yaml, fdp_config_dir, model_config, submission_script, code_repo, code_run )
Arguments
yamla
listcontaining the contents of the working config.yamlfdp_config_dira
stringspecifying the directory passed fromfair runmodel_configa
stringspecifying the URL of an entry in theobjecttable associated with thestorage_locationof the working config.yamlsubmission_scripta
stringspecifying the URL of an entry in theobjecttable associated with thestorage_locationof the submission scriptcode_repoa
stringspecifying the URL of an entry in theobjecttable associated with the GitHub repositorycode_runa
stringspecifying the URL of an entry in thecode_runtable
Returns
Returns a new fdp object
Method print()
Print method
Usage
fdp$print(...)
Method input()
Record code_run inputs in fdp object
Usage
fdp$input( data_product, use_data_product, use_component, use_version, use_namespace, path, component_url )
Arguments
data_producta
stringspecifying the name of the data product, used as a referenceuse_data_producta
stringspecifying the name of the data product, used as input in thecode_runuse_componenta
stringspecifying the name of the data product component, used as input in thecode_runuse_versiona
stringspecifying the data product version, used as input in thecode_runuse_namespacea
stringspecifying the namespace in which the data product resides, used as input in thecode_runpatha
stringspecifying the location of the data product in the local data storecomponent_urla
stringspecifying the URL of an entry in theobject_componenttable
Returns
Returns an updated fdp object
Method output()
Record code_run outputs in fdp object
Usage
fdp$output( data_product, use_data_product, use_component, use_version, use_namespace, path, data_product_description, component_description, public )
Arguments
data_producta
stringspecifying the name of the data product, used as a referenceuse_data_producta
stringspecifying the name of the data product, used as output in thecode_runuse_componenta
stringspecifying the name of the data product component, used as output in thecode_runuse_versiona
stringspecifying the version of the data product, used as output in thecode_runuse_namespacea
stringspecifying the namespace in which the data product resides, used as output in thecode_runpatha
stringspecifying the location of the data product in the local data storedata_product_descriptiona
stringcontaining a description of the data productcomponent_descriptiona
stringcontaining a description of the data product componentpublic
Returns
Returns an updated fdp object
Method output_index()
Return index of data product recorded in fdp object
so that an issue may be attached
Usage
fdp$output_index(data_product, component, version, namespace)
Arguments
data_producta
stringspecifying the name of the data product, used as output in thecode_runcomponenta
stringspecifying the name of the data product component, used as output in thecode_runversiona
stringspecifying the name of the data product version, used as output in thecode_runnamespacea
stringspecifying the namespace in which the data product resides, used as input in thecode_run
Returns
Returns an index used to identify the data product
Method raise_issue()
Record issue in fdp object
Usage
fdp$raise_issue( index, type, use_data_product, use_component, use_version, use_namespace, issue, severity )
Arguments
indexa
numericindex, used to identify each input and output in thefdpobjecttypea
stringspecifying the type of issue (one of "data", "config", "script", "repo")use_data_producta
stringspecifying the name of the data product, used as output in thecode_runuse_componenta
stringspecifying the name of the data product component, used as output in thecode_runuse_versiona
stringspecifying the name of the data product version, used as output in thecode_runuse_namespacea
stringspecifying the namespace in which the data product resides, used as input in thecode_runissuea
stringcontaining a free text description of theissueseverityan
integerspecifying the severity of theissue
Returns
Returns an updated fdp object
Method finalise_output_hash()
Record file hash and update path name in fdp object
Usage
fdp$finalise_output_hash( use_data_product, use_data_product_runid, use_version, use_namespace, hash, new_path, data_product_url, delete_if_duplicate = FALSE )
Arguments
use_data_producta
stringspecifying the name of the data product, used as output in thecode_runuse_data_product_runida
stringspecifying the name of the data product, the same asuse_data_productexcluding the RUN_ID variableuse_versiona
stringspecifying the name of the data product version, used as output in thecode_runuse_namespacea
stringspecifying the namespace in which the data product resides, used as input in thecode_runhasha
stringspecifying the hash of the filenew_patha
stringspecifying the updated location (filename is now the hash of the file) of the data product in the local data storedata_product_urla
stringspecifying the URL of anobjectassociated with thedata_productdelete_if_duplicate(optional) default is
FALSE
Returns
Returns an updated fdp object
Method finalise_output_url()
Record data_product and component URLs in fdp
object
Usage
fdp$finalise_output_url( use_data_product, use_component, use_version, use_namespace, component_url )
Arguments
use_data_producta
stringspecifying the name of the data product, used as output in thecode_runuse_componenta
stringspecifying the name of the data product component, used as output in thecode_runuse_versiona
stringspecifying the name of the data product version, used as output in thecode_runuse_namespacea
stringspecifying the namespace in which the data product resides, used as input in thecode_runcomponent_urla
stringspecifying the URL of an entry in theobject_componenttable
Returns
Returns an updated fdp object
Method clone()
The objects of this class are cloneable with this method.
Usage
fdp$clone(deep = FALSE)
Arguments
deepWhether to make a deep clone.