singleton

Generate a @property function which creates/returns a thread-local singleton of a class with the given arguments.

  1. T singleton [@property getter]
    @property
    T
    singleton
    (
    T
    args...
    )
    ()
    if (
    is(typeof(new T(args)))
    )
  2. singleton [@property getter]

Meta