O'Reilly logo

HoloLens Beginner’s Guide by Jason Odom

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

There can be only one

The primary point of the singleton pattern is to instantiate a single object of a specific class. The instanced object will check whether it would create a conflict when another exists and destroy itself if it does. It is notable that many of the classes that we are working with from the HoloToolkit are singletons. The input manager and the Spatial Mapping Manager are perfect examples of singletons that are active in our project right this moment.

The reason for its popularity and criticism comes down to how simple it is to understand and get working with. This simplicity means that many people use it and often in places where another pattern would work better. Often, games use a singleton pattern by creating a single ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required