mirror of
https://github.com/FunkinCrew/Funkin.git
synced 2024-11-30 11:26:53 -05:00
16 lines
360 B
Haxe
16 lines
360 B
Haxe
package funkin.util.tools;
|
|
|
|
/**
|
|
* A static extension which provides utility functions for Maps.
|
|
*
|
|
* For example, add `using MapTools` then call `map.values()`.
|
|
*
|
|
* @see https://haxe.org/manual/lf-static-extension.html
|
|
*/
|
|
class MapTools
|
|
{
|
|
public static function values<K, T>(map:Map<K, T>):Array<T>
|
|
{
|
|
return [for (i in map.iterator()) i];
|
|
}
|
|
}
|