Describe a pattern that is not the factory pattern? How is it used and when?



Describe a pattern that is not the factory pattern? How is it used and when?..

Answer / Shailendra Kumar Dwivedi

One example of a design pattern different from the Factory Pattern is the Singleton Pattern. This pattern ensures that a class has only one instance, providing a global point of access to it. It is typically used when exactly one object is needed to coordinate actions across the system or when expensive object creation must be minimized.nnFor example, consider a logging utility in an embedded system. A singleton can ensure that only a single logging instance exists, directing all log messages to a central location for efficient processing and analysis.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Embedded Systems AllOther Interview Questions

What do you mean by interrupt latency?

1 Answers  


Explain some of the commonly found errors in embedded systems?

1 Answers  


Do you know what is priority inheritance?

1 Answers  


What are the different types of buses used by the embedded systems?

1 Answers  


Tell me what are buses used for communication in embedded system?

1 Answers  


Have you developed software testing procedures for new systems and performed qa, quality assurance, or audits?

1 Answers  


Name three primary attributes of object-oriented design. Describe what they mean and why they're important.

1 Answers  


Explain me what is the difference between microprocessor and microcontroller?

1 Answers  


Can structures be passed to the functions by value?

1 Answers  


Tell me what is the difference between hardware design and software design?

1 Answers  


What type of scheduling is there in rtos?

1 Answers  


What is return type of isr?

1 Answers  


Categories