Haxe Code Cookbook

type params

Overview of Haxe code snippets, examples and tutorials tagged with type params.

  • Jan 23, 2018 Abstract types /

     abstract-type type-params extern

    A common pattern, often found in (but not only in) dynamic languages, is to denote the type of some object with a string, for example:‥

  • Jan 23, 2018 Abstract types /

     abstract-type type-params iterator

    Iterators are a helpful Haxe structure. Any structure that implements the next and hasNext functions with the appropriate signature will allow you build a for loop. Arrays have an iterator() function that returns exactly this, and you don't need to call it, the for language construction does it for you.‥