HenrikBengtsson / R.rsp

:page_facing_up: R package: Dynamic generation of scientific reports
https://henrikbengtsson.github.io/R.rsp/
31 stars 6 forks source link

CLEANUP: language metadata or attribute? #37

Open HenrikBengtsson opened 4 years ago

HenrikBengtsson commented 4 years ago

Right now language appears as both an attribute and a metadata tag. Should probably be one or the other;

$ grep -F '"language"' R/*.R
R/rcode.R:  language <- getAttribute(object, "language", default="R")
R/RspDirective.R:    this <- setAttribute(this, "language", lang)
R/RspDocument.R:        lang <- getAttribute(item, "language")
R/RspDocument.R:      language <- getAttribute(item, "language", default=NA_character_)
R/RspDocument.R:      for (name in c("type", "escape", "language")) {
R/RspDocument.toR.R:    language <- getMetadata(object, "language", default="R")
R/RspString.R:  s <- c(s, sprintf("Language: %s", getAttribute(x, "language", NA)))
R/rstring.R:#  language <- getAttribute(object, "language", default="R")
R/rstring.R:  language <- getMetadata(object, "language", default="R")