util.weaksingleton - ICE 0.1 API documentation

ICE 0.1 API documentation

# util.weaksingleton

Singleton with no global access.

template WeakSingleton()

  Singleton template mixin with support for polymorphism, without global access.

  Note:
  Any non-abstract weak singleton class must call singletonCtor() in its ctor and singletonDtor in its dtor or die() method.

  typeof(this) _instance_;

    Singleton object itself.

  void singletonCtor();

    Enforce only single instance at any given time.

  void singletonDtor();

    Enforce only single instance at any given time.

Copyright © Ferdinand Majerech 2011. | Page generated by AutoDDoc and Ddoc.