Movatterモバイル変換


[0]ホーム

URL:


rdrr.io

getDLLRegisteredRoutines: Reflectance Information for C/Fortran routines in a DLL

getDLLRegisteredRoutinesR Documentation

Reflectance Information for C/Fortran routines in a DLL

Description

This function allows us to query the set of routinesin a DLL that are registered with R to enhancedynamic lookup, error handling when calling native routines,and potentially security in the future.This function provides a description of each of theregistered routines in the DLL for the different interfaces,i.e..C,.Call,.Fortranand.External.

Usage

getDLLRegisteredRoutines(dll, addNames = TRUE)

Arguments

dll

a character string orDLLInfo object.The character string specifies the file name of the DLLof interest, and is given without the file name extension (e.g., the‘.dll’ or ‘.so’) and with no directory/path information.So a file ‘MyPackage/libs/MyPackage.so’ would be specified asMyPackage.

TheDLLInfo objects can be obtained directlyin calls todyn.load andlibrary.dynam,or can be found after the DLL has been loaded usinggetLoadedDLLs, which returns a list ofDLLInfo objects (index-able by DLL file name).

TheDLLInfo approach avoids any ambiguities related to twoDLLs having the same name but corresponding to files in differentdirectories.

addNames

a logical value. If this isTRUE, the elementsof the returned lists are named using the names of the routines (asseen by R via registration or raw name). IfFALSE,these names are not computed and assigned to the lists. As aresult, the call should be quicker. The name information is alsoavailable in theNativeSymbolInfo objects in the lists.

Details

This takes the registration information after it has been registeredand processed by the R internals. In other words, it uses the extendedinformation.

There isprint methods for the class, which prints only thetypes which have registered routines.

Value

A list of class"DLLRegisteredRoutines" with four elementscorresponding to the routines registered for the.C,.Call,.Fortran and.External interfaces. Each isa list (of class"NativeRoutineList") with as many elements asthere were routines registered for that interface.

Each element identifies a routine and is an objectof class"NativeSymbolInfo".An object of this class has the following fields:

name

the registered name of the routine (not necessarily thename in the C code).

address

the memory address of the routine as resolved in theloaded DLL. This may beNULL if the symbol has not yet beenresolved.

dll

an object of classDLLInfo describing the DLL.This is same for all elements returned.

numParameters

the number of arguments the native routine is tobe called with.

Author(s)

Duncan Temple Langduncan@wald.ucdavis.edu

References

‘Writing R Extensions’ manual for symbol registration.

Duncan Temple Lang (2001).“In Search of C/C++ & FORTRAN Routines”.R News,1(3), 20–23.https://www.r-project.org/doc/Rnews/Rnews_2001-3.pdf.

See Also

getLoadedDLLs,getNativeSymbolInfo for information on the entry points listed.

Examples

dlls <- getLoadedDLLs()getDLLRegisteredRoutines(dlls[["base"]])getDLLRegisteredRoutines("stats")

What can we improve?

R Package Documentation

Browse R Packages

We want your feedback!

Note that we can't provide technical support on individual packages. You should contact the package authors for that.

 
Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, readEmbedding Snippets.

Close

[8]ページ先頭

©2009-2026 Movatter.jp