Package jnr.ffi.mapper
Interface FunctionMapper
- All Known Implementing Classes:
CompositeFunctionMapper,IdentityFunctionMapper
public interface FunctionMapper
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classstatic interface -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final FunctionMapperAn implementation ofFunctionMapperthat maps 1:1 between java symbols and native functions -
Method Summary
Modifier and TypeMethodDescriptionmapFunctionName(String functionName, FunctionMapper.Context context) Translate the (Java) function name into its (native) equivalent.
-
Field Details
-
IDENTITY
An implementation ofFunctionMapperthat maps 1:1 between java symbols and native functions
-
-
Method Details
-
mapFunctionName
Translate the (Java) function name into its (native) equivalent. If the name is not present in the map, it is to return the supplied name (same object exactly).- Parameters:
functionName- to translatecontext- for translation- Returns:
- native equivalent or
functionNameif not in map
-