Defining a Singleton Object Type in Interface Style
Defining a singleton object type is a special case of defining an object type. The difference is that a singleton object type does not require a provider. Alternatively, we might say that its unique instance is its own provider.
Because a singleton is its own provider, the SingletonTeaObject interface subsumes the other provider methods (namely, getTypeName, getTypeDescription and getConcept).
Because it is a singleton, it needs no getInstance method.
Procedure
Copyright © Cloud Software Group, Inc. All Rights Reserved.