Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

QUESTION 5 (18 marks) (a) Consider the development of a robot system with a framework for adding executable modules for specialized tasks. A third-party developer

image text in transcribed
QUESTION 5 (18 marks) (a) Consider the development of a robot system with a framework for adding executable modules for specialized tasks. A third-party developer has created modules we would like to integrate into our system and use, but these were developed for a different module framework. Modules in our framework are managed using OurModuleManager: class OurModuleManager void addModule (Our Module module) () void initAllModules() (-) void process FrameAllModules() () 1 All modules in our module framework must inherit from the following class: class Our Module OurModule(); // constructor does almost nothing void init(); // most initialitation happens here void processFrame(): execute one tick worth of work The third-party modules are developed to a different interface and cannot be changed. An example of one of these is the LowlevelVisionProvider: class LowLavel Vision Provider LowLevelVisionProvider() inste everything void update (HLinePoints. hor LinePointsOut) () void update (VLinePoints* vertLine Points out) 1 (1) Briefly explain how design patterns improve the quality of software. (11) Use the Adapter design pattern to write an adapter class to adapt LowlevelVisionProvider to a form acceptable to Our ModuleManager (Note: The work done by the update functions corresponds to the work normally done in processFrame.) Write the code to add the adapted LowLevelVision Provider to our ModuleManager (which is an instance of OurModuleManager), initialize all the modules, and process one frame for all modules

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Strategic Database Technology Management For The Year 2000

Authors: Alan Simon

1st Edition

155860264X, 978-1558602649

More Books

Students also viewed these Databases questions

Question

How can a firm obtain a unique market position?

Answered: 1 week ago

Question

=+ Are unions company-wide, regional, or national?

Answered: 1 week ago

Question

=+j Explain the litigation risks in international labor relations.

Answered: 1 week ago

Question

=+j What rules will apply to the process of negotiations?

Answered: 1 week ago