Package hydra.lib.maps
Class FromList
java.lang.Object
hydra.tools.PrimitiveFunction
hydra.lib.maps.FromList
Creates a map from a list of pairs.
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class hydra.tools.PrimitiveFunction
term, toNative
-
Constructor Details
-
FromList
public FromList()
-
-
Method Details
-
name
Get the name of this primitive function.- Specified by:
namein classPrimitiveFunction- Returns:
- the name
-
type
Get the type scheme of this primitive function.- Specified by:
typein classPrimitiveFunction- Returns:
- the type scheme
-
implementation
Get the implementation of this primitive function.- Specified by:
implementationin classPrimitiveFunction- Returns:
- the implementation function
-
apply
Apply the function to its single argument.- Type Parameters:
K- the key typeV- the value type- Parameters:
pairs- the list of key-value pairs- Returns:
- a map constructed from the pairs
-