nimble (version 0.7.0)

nfMethod: access (call) a member function of a nimbleFunction

Description

Internal function for accessing a member function (method) of a nimbleFunction. Normally a user will write nf$method(x) instead of nfMethod(nf, method)(x).

Usage

nfMethod(nf, methodName)

Arguments

nf

a specialized nimbleFunction, i.e. one that has already had setup parameters processed

methodName

a character string giving the name of the member function to call

Value

a function that can be called.

Details

nimbleFunctions have a default member function called run, and may have other member functions provided via the methods argument to nimbleFunction. As an internal step, the NIMBLE compiler turns nf$method(x) into nfMethod(nf, method)(x), but a NIMBLE user or programmer would not normally need to use nfMethod directly.