diff --git a/.Rbuildignore b/.Rbuildignore index c28732f826..78a1de5ef1 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -50,3 +50,6 @@ ^\.aviator/config\.yml$ ^src/vendor/cigraph/CITATION\.cff$ ^R/revdep\.R$ +^man/dot-extract_constructor_and_modifiers\.Rd$ +^man/dot-apply_modifiers\.Rd$ +^man/handle_vertex_type_arg\.Rd$ diff --git a/DESCRIPTION b/DESCRIPTION index 9ab79592b6..36562a9672 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -63,7 +63,7 @@ LinkingTo: cpp11 (>= 0.5.0) VignetteBuilder: knitr -Config/Needs/build: roxygen2, devtools, irlba, pkgconfig, igraph/igraph.r2cdocs +Config/Needs/build: roxygen2, devtools, irlba, pkgconfig, igraph/igraph.r2cdocs, maelle/devtag@keywords-internal Config/Needs/coverage: covr Config/Needs/website: readr Config/testthat/edition: 3 @@ -71,7 +71,6 @@ Config/testthat/parallel: true Config/testthat/start-first: vs-es, scan, vs-operators, weakref, watts.strogatz.game Encoding: UTF-8 -Roxygen: list(markdown = TRUE, roclets = c("collate", "rd", "namespace", - "igraph.r2cdocs::cdocs_roclet"), packages = "igraph.r2cdocs") +Roxygen: list(markdown = TRUE, roclets = c("collate", "rd", "namespace", "igraph.r2cdocs::cdocs_roclet", "devtag::dev_roclet"), packages = "igraph.r2cdocs") RoxygenNote: 7.3.2 SystemRequirements: libxml2 (optional), glpk (>= 4.57, optional) diff --git a/R/make.R b/R/make.R index b2e1a7ee7d..541b0c93c0 100644 --- a/R/make.R +++ b/R/make.R @@ -664,11 +664,10 @@ graph.atlas <- function(n) { # nocov start #' @param .variant Constructor variant; must be one of \sQuote{make}, #' \sQuote{graph} or \sQuote{sample}. Used in cases when the same constructor #' specification has deterministic and random variants. -#' @family constructor modifiers #' @return A named list with three items: \sQuote{cons} for the constructor #' function, \sQuote{mods} for the modifiers and \sQuote{args} for the #' remaining, unparsed arguments. -#' @noRd +#' @dev .extract_constructor_and_modifiers <- function(..., .operation, .variant) { args <- list(...) cidx <- vapply(args, inherits, TRUE, what = "igraph_constructor_spec") @@ -715,9 +714,8 @@ graph.atlas <- function(n) { # nocov start #' #' @param graph The graph to apply the modifiers to #' @param mods The modifiers to apply -#' @family constructor modifiers #' @return The modified graph -#' @noRd +#' @dev .apply_modifiers <- function(graph, mods) { for (m in mods) { if (m$id == "without_attr") { diff --git a/R/other.R b/R/other.R index 896305245e..50ef202c03 100644 --- a/R/other.R +++ b/R/other.R @@ -154,7 +154,7 @@ sample_seq <- function(low, high, length) { #' @return A logical vector representing the resolved vertex type for each #' vertex in the graph #' @author Tamas Nepusz \email{ntamas@@gmail.com} -#' @keywords internal +#' @dev #' handle_vertex_type_arg <- function(types, graph, required = T) { if (is.null(types) && "type" %in% vertex_attr_names(graph)) { diff --git a/man/dot-apply_modifiers.Rd b/man/dot-apply_modifiers.Rd new file mode 100644 index 0000000000..0aa08bbb27 --- /dev/null +++ b/man/dot-apply_modifiers.Rd @@ -0,0 +1,21 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/make.R +\name{.apply_modifiers} +\alias{.apply_modifiers} +\title{Applies a set of constructor modifiers to an already constructed graph.} +\usage{ +.apply_modifiers(graph, mods) +} +\arguments{ +\item{graph}{The graph to apply the modifiers to} + +\item{mods}{The modifiers to apply} +} +\value{ +The modified graph +} +\description{ +This is a helper function for the common parts of \code{make_()} and +\code{sample_()}. +} +\keyword{internal} diff --git a/man/dot-extract_constructor_and_modifiers.Rd b/man/dot-extract_constructor_and_modifiers.Rd new file mode 100644 index 0000000000..ab9dcc29f4 --- /dev/null +++ b/man/dot-extract_constructor_and_modifiers.Rd @@ -0,0 +1,29 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/make.R +\name{.extract_constructor_and_modifiers} +\alias{.extract_constructor_and_modifiers} +\title{Takes an argument list and extracts the constructor specification and +constructor modifiers from it.} +\usage{ +.extract_constructor_and_modifiers(..., .operation, .variant) +} +\arguments{ +\item{...}{Parameters to extract from} + +\item{.operation}{Human-readable description of the operation that this +helper is a part of} + +\item{.variant}{Constructor variant; must be one of \sQuote{make}, +\sQuote{graph} or \sQuote{sample}. Used in cases when the same constructor +specification has deterministic and random variants.} +} +\value{ +A named list with three items: \sQuote{cons} for the constructor +function, \sQuote{mods} for the modifiers and \sQuote{args} for the +remaining, unparsed arguments. +} +\description{ +This is a helper function for the common parts of \code{make_()} and +\code{sample_()}. +} +\keyword{internal}