Class PredictionUtils
java.lang.Object
eu.qualimaster.easy.extension.internal.PredictionUtils
Some utility methods for algorithm predictions.
- Author:
- Holger Eichelberger
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static <K,V> Map <K, V> toMappedMap(net.ssehub.easy.instantiation.core.model.vilTypes.Map<K, V> map) Translates a VIL map to a Java map.(package private) static <K,KV, V> net.ssehub.easy.instantiation.core.model.vilTypes.Map <K, net.ssehub.easy.instantiation.core.model.vilTypes.Map<KV, V>> Translates the Java result instance to a VIL result instance.
-
Constructor Details
-
PredictionUtils
public PredictionUtils()
-
-
Method Details
-
toMappedMap
Translates a VIL map to a Java map.- Type Parameters:
K- the key typeV- the value type- Parameters:
map- the map to be translated (may be null)- Returns:
- the translated map (may be null if
mapis null)
-
transferMap
static <K,KV, net.ssehub.easy.instantiation.core.model.vilTypes.Map<K,V> net.ssehub.easy.instantiation.core.model.vilTypes.Map<KV, transferMapV>> (Map<K, Map<KV, V>> res, Class<K> classK, Class<KV> classKV, Class<V> classV) Translates the Java result instance to a VIL result instance.- Type Parameters:
K- the main access keyKV- the secondary access key to the internal map/valuesV- the value type- Parameters:
res- the Java result instanceclassK- the actual class ofKclassKV- the actual class ofKVclassV- the actual class ofV- Returns:
- the corresponding VIL result instance, always a result even if empty
-