-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added source file for native registration
- Loading branch information
1 parent
7ddb243
commit be4a3e9
Showing
1 changed file
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#include <R.h> | ||
#include <Rinternals.h> | ||
#include <stdlib.h> // for NULL | ||
#include <R_ext/Rdynload.h> | ||
|
||
/* FIXME: | ||
Check these declarations against the C/Fortran source code. | ||
*/ | ||
|
||
/* .Call calls */ | ||
extern SEXP R_all_int(SEXP); | ||
extern SEXP R_amatch(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP); | ||
extern SEXP R_get_qgrams(SEXP, SEXP); | ||
extern SEXP R_lengths(SEXP); | ||
extern SEXP R_lower_tri(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP); | ||
extern SEXP R_soundex(SEXP, SEXP); | ||
extern SEXP R_stringdist(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP); | ||
|
||
static const R_CallMethodDef CallEntries[] = { | ||
{"R_all_int", (DL_FUNC) &R_all_int, 1}, | ||
{"R_amatch", (DL_FUNC) &R_amatch, 11}, | ||
{"R_get_qgrams", (DL_FUNC) &R_get_qgrams, 2}, | ||
{"R_lengths", (DL_FUNC) &R_lengths, 1}, | ||
{"R_lower_tri", (DL_FUNC) &R_lower_tri, 7}, | ||
{"R_soundex", (DL_FUNC) &R_soundex, 2}, | ||
{"R_stringdist", (DL_FUNC) &R_stringdist, 8}, | ||
{NULL, NULL, 0} | ||
}; | ||
|
||
void R_init_stringdist(DllInfo *dll) | ||
{ | ||
R_registerRoutines(dll, NULL, CallEntries, NULL, NULL); | ||
R_useDynamicSymbols(dll, FALSE); | ||
} |