Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 0 additions & 30 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ Imports:
dplyr,
DSMolgenisArmadillo,
jsonlite,
methods,
opalr,
purrr,
RcppTOML,
Expand All @@ -55,34 +54,5 @@ Imports:
Depends:
R (>= 4.1.0)
VignetteBuilder: knitr
Collate:
'ArmadilloCredentials-class.R'
'audit.R'
'audit_engine.R'
'dsROCrate-package.R'
'dsROCrate.R'
'print.R'
'report.R'
'safe_data.R'
'safe_output.R'
'safe_people.R'
'safe_project.R'
'safe_setting.R'
'utils-armadillo.R'
'utils-audit.R'
'utils-connection.R'
'utils-cr8tor.R'
'utils-date.R'
'utils-digest.R'
'utils-opal.R'
'utils-rocrate.R'
'utils-rocrateR.R'
'utils-safe_data.R'
'utils-safe_output.R'
'utils-safe_people.R'
'utils-safe_project.R'
'utils-safe_setting.R'
'utils-show.R'
'utils-tibble.R'
URL: https://github.com/FederatedMethods/dsROCrate
BugReports: https://github.com/FederatedMethods/dsROCrate/issues
11 changes: 4 additions & 7 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Generated by roxygen2: do not edit by hand

S3method(audit,armadillo)
S3method(audit,ArmadilloCredentials)
S3method(audit,character)
S3method(audit,cr8tor)
S3method(audit,list)
Expand Down Expand Up @@ -30,9 +30,9 @@ S3method(flatten_safe_setting,default)
S3method(flatten_safe_setting,rocrate)
S3method(init,opal)
S3method(init,rocrate)
S3method(parse_user_profiles,armadillo)
S3method(parse_user_profiles,ArmadilloCredentials)
S3method(print,cr8tor_bundle)
S3method(project_exists,armadillo)
S3method(project_exists,ArmadilloCredentials)
S3method(report,character)
S3method(report,default)
S3method(report,list)
Expand All @@ -49,7 +49,7 @@ S3method(safe_people,character)
S3method(safe_people,default)
S3method(safe_people,opal)
S3method(safe_people,rocrate)
S3method(safe_project,armadillo)
S3method(safe_project,ArmadilloCredentials)
S3method(safe_project,character)
S3method(safe_project,default)
S3method(safe_project,opal)
Expand All @@ -68,8 +68,5 @@ export(safe_output)
export(safe_people)
export(safe_project)
export(safe_setting)
exportMethods(safe_project)
import(methods)
importClassesFrom(DSMolgenisArmadillo,ArmadilloCredentials)
importFrom(rocrateR,get_entity)
importFrom(utils,write.csv)
21 changes: 0 additions & 21 deletions R/ArmadilloCredentials-class.R

This file was deleted.

2 changes: 1 addition & 1 deletion R/audit.R
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ audit <- function(x, ...) {

#' @rdname audit
#' @export
audit.armadillo <- function(x, ..., intent = NULL) {
audit.ArmadilloCredentials <- function(x, ..., intent = NULL) {
stop(
"The audit for Armadillo backend is not currently implemented!",
call. = FALSE
Expand Down
4 changes: 2 additions & 2 deletions R/dsROCrate-package.R
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"_PACKAGE"

## usethis namespace: start
#' @import methods
#' @importClassesFrom DSMolgenisArmadillo ArmadilloCredentials
# @import methods
# @importClassesFrom DSMolgenisArmadillo ArmadilloCredentials
## usethis namespace: end
NULL
53 changes: 21 additions & 32 deletions R/safe_project.R
Original file line number Diff line number Diff line change
Expand Up @@ -251,38 +251,27 @@ safe_project.rocrate <- function(
}

# S4 methods ----
# Bridge method for your S4 class
#' @method safe_project armadillo
#' @method safe_project ArmadilloCredentials
#' @rdname safe_project
#' @export
safe_project.armadillo <- function(x, ...) {
methods::callGeneric(x, ...)
}

#' @aliases safe_project,armadillo-method
#' @export
setMethod(
"safe_project",
signature(x = "armadillo"),
function(
x,
...,
profile = "default",
project = NULL,
rocrate = rocrateR::rocrate_5s(),
asset_id_suffix = "#asset:",
project_id_suffix = "#project:",
path = NULL,
resources = NULL,
tables = NULL,
user = NULL
) {
# check if the given `project` exists
project_exists(x, project = project)
safe_project.ArmadilloCredentials <- function(
x,
...,
profile = "default",
project = NULL,
rocrate = rocrateR::rocrate_5s(),
asset_id_suffix = "#asset:",
project_id_suffix = "#project:",
path = NULL,
resources = NULL,
tables = NULL,
user = NULL
) {
# check if the given `project` exists
project_exists(x, project = project)

# retrieve details associated to `project`
project_details_tbl <- MolgenisArmadillo::armadillo.get_projects_info() |>
purrr::list_c() |>
tibble::as_tibble()
}
)
# retrieve details associated to `project`
project_details_tbl <- MolgenisArmadillo::armadillo.get_projects_info() |>
purrr::list_c() |>
tibble::as_tibble()
}
30 changes: 5 additions & 25 deletions R/utils-connection.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,24 +45,13 @@ parse_user_profiles.opal <- function(x, ..., user) {
}

# S4 methods ----
# Bridge method for your S4 class
#' @method parse_user_profiles armadillo
#' @method parse_user_profiles ArmadilloCredentials
#' @rdname parse_user_profiles
#' @export
parse_user_profiles.armadillo <- function(x, ...) {
methods::callGeneric(x, ...)
parse_user_profiles.ArmadilloCredentials <- function(x, ..., user) {
message("PLACEHOLDER!")
}

#' @aliases parse_user_profiles,armadillo-method
#' @family Armadillo
setMethod(
"parse_user_profiles",
signature(x = "armadillo"),
function(x, ..., user) {
message("PLACEHOLDER!")
}
)

#' Verify if project exists
#'
#' Wrapper for the [opalr::opal.project_exists()] and
Expand Down Expand Up @@ -104,19 +93,11 @@ project_exists.opal <- function(x, ..., project) {
}

# S4 methods ----
# Bridge method for your S4 class
#' @method project_exists armadillo
#' @method project_exists ArmadilloCredentials
#' @rdname project_exists
#' @export
project_exists.armadillo <- function(x, ...) {
methods::callGeneric(x, ...)
}

#' @aliases project_exists,armadillo-method
#' @family Armadillo
setMethod(
"project_exists",
signature(x = "armadillo"),
project_exists.ArmadilloCredentials <-
function(
x,
...,
Expand All @@ -132,4 +113,3 @@ setMethod(
)
}
}
)
21 changes: 0 additions & 21 deletions R/utils-show.R

This file was deleted.

3 changes: 3 additions & 0 deletions R/zzz.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.onLoad <- function(libname, pkgname) {
# methods::setOldClass("ArmadilloCredentials")
}
4 changes: 2 additions & 2 deletions man/audit.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions man/parse_user_profiles.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions man/project_exists.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 14 additions & 2 deletions man/safe_project.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading