{"id":14067896,"url":"https://github.com/HenrikBengtsson/RNativeAPI","last_synced_at":"2025-07-30T02:32:09.067Z","repository":{"id":146695754,"uuid":"155436537","full_name":"HenrikBengtsson/RNativeAPI","owner":"HenrikBengtsson","description":"R package: RNativeAPI - Documentation and Examples of the R Native API (Proof of Concept)","archived":false,"fork":false,"pushed_at":"2023-03-27T19:09:27.000Z","size":417,"stargazers_count":14,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-08-13T07:13:58.452Z","etag":null,"topics":["api","c","documentation","examples","help","native","package","r"],"latest_commit_sha":null,"homepage":"https://henrikbengtsson.github.io/RNativeAPI/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/HenrikBengtsson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-10-30T18:29:13.000Z","updated_at":"2024-07-03T18:54:55.000Z","dependencies_parsed_at":"2024-02-19T19:16:16.667Z","dependency_job_id":"dfe5b3c8-0b9d-41ff-a51a-c7ca5ea3295c","html_url":"https://github.com/HenrikBengtsson/RNativeAPI","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HenrikBengtsson%2FRNativeAPI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HenrikBengtsson%2FRNativeAPI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HenrikBengtsson%2FRNativeAPI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HenrikBengtsson%2FRNativeAPI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HenrikBengtsson","download_url":"https://codeload.github.com/HenrikBengtsson/RNativeAPI/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228075641,"owners_count":17865508,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","c","documentation","examples","help","native","package","r"],"created_at":"2024-08-13T07:05:50.032Z","updated_at":"2024-12-04T08:31:19.215Z","avatar_url":"https://github.com/HenrikBengtsson.png","language":"R","funding_links":[],"categories":["R"],"sub_categories":[],"readme":"# R package: RNativeAPI - Documentation and Examples of the R Native API\n\nA proof-of-concept package documenting the R Native API via the built-in R help system.  The help pages are written in Roxygen2 that are compiled to Rd format and then rendered by R as regular help pages.\n\n_Disclaimer: This is just a proof of concept; I'm not claiming this is the best approach._\n\n\n## Examples\n\n\n### Help pages\n\n#### HTML version\n\n\u003cimg src=\"man/figures/getAttrib.png\" alt=\"Screenshot of help(getAttrib)\" style=\"border: 1px solid black; box-shadow: 10px 10px 5px grey; margin: 4ex;\"\u003e\n\n\n#### Text version\n\n```r\n\u003e options(help_type = \"text\")\n\u003e ?RNativeAPI::getAttrib\n\ngetAttrib              package:RNativeAPI              R Documentation\n\nGets and Sets an Attribute of an R Object\n\nDescription:\n\n     Gets and Sets an Attribute of an R Object\n\nUsage:\n\n     getAttrib(vec, name)\n     \n     setAttrib(vec, name, val)\n     \nArguments:\n\n     vec: (SEXP) An R object.\n\n    name: (SEXP) A character of length one.\n\n     val: (SEXP) An R object.\n\nValue:\n\n     getAttrib() returns (SEXP) the value of attribute ‘name’.\n\n     setAttrib() returns (SEXP) a copy of R object ‘vec’ with attribute ‘name’ set.\n\nC API:\n\n     SEXP getAttrib(SEXP vec, SEXP name)\n     SEXP setAttrib(SEXP vec, SEXP name, SEXP val)\n\nR API:\n\n     value \u003c- attr(vec, name)\n     attr(vec, name) \u003c- val\n\nSource:\n\n     Declaration: src/include/Rinternals.h\n\n     Implementation: src/main/attrib.c\n```\n\n\n## Displaying functions\n\n```r\n\u003e RNativeAPI::getAttrib\nfunction (vec, name) \n{\n    vec = SEXP\n    name = SEXP\n    return(SEXP)\n}\n\u003cbytecode: 0x561c1cd594c0\u003e\n\u003cenvironment: namespace:RNativeAPI\u003e\n```\n\n_Comment:_ By a customized class and `print()` method, the above can probably be presented much nice.  With some efforts, it could even display the actual source code (there are already R packages providing functionalities for this).\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FHenrikBengtsson%2FRNativeAPI","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FHenrikBengtsson%2FRNativeAPI","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FHenrikBengtsson%2FRNativeAPI/lists"}