|Description: programming languages Online Quiz - 184|
|Number of Questions: 20|
|Created by: Aliensbrain Bot|
|Tags: programming languages|
When would you use the Visitor pattern?
You are a Computer Science lecturer at a top University. You are giving a presentation of a new piece of software you have written. Basically you have written the next generation spell checker, the reason yours is so good is that it can learn the common typing mistakes of an individual user. You have already sold licenses to many major software vendors and plan to retire in the Sun. However before you go they all require slight changes in the logic to suit their individual needs. What design pattern will help you slightly change the logic in a class to be used in many applications?
You are designing an application to be used to edit photographs. The aim of the application is to provide effects such as converting a color picture to black and white, enlarging certain areas of the print, creating a watercolor effect etc. At the moment the application is structured so that the photographic image is represented by one object, other objects represent each effect and a control object is used to co-ordinate with these objects. When the user selects the color to black and white effect it changes the state of the Color object to Black and White. This then needs to co-ordinate with the control object and apply the effect. Basically as the state of the effects objects changes it need to co-ordinate with the photographic image object.Which design pattern do you use?
You are creating a web application for an online product ordering system. You will be using data from several different databases and to reduce the load on the databases you have decided to use connection pooling. You have a ConnectionPool class and you want one pool for each database however you will have to connect to a variable number of databases. What pattern should you use?
As part of your new application you need to create a custom class loader so that you can implement with custom security. So you need to create objects without knowing the class of the objects or how to create them. What pattern should you use for this?
Which of the following are true about the Bridge and Adapter patterns?
Compact Computers is a small computer assembly company. Their online application allows customers to pick and choose accessories to build their own PCs. The accessories are: i. Processor - 800Mhz, 1Ghz, 1.2Ghz ii. HDD - 40 GB, 60 GB, 80 GB iii. Memory - 128 MB, 256 MB, 512 MB If a computer can have exactly 1 processor, 1 HDD and 1 memory stick, what pattern would be best used here?
Which of the following is a key concept of SOA?
A service provider is also known as the “service registry”
A service provider creates and publishes Web services, together with their interface and access description
A service provider is responsible for the business aspects of the published web service, such as pricing
Which of the following is a feature of the “Web service”, as the building block of SOA?
Which of the following is considered to be guiding principles of SOA?
What is Service-oriented Architecture (SOA)?
MVC is a software approach that separates application logic from presentation
Hibernate is the best solutions for data centric applications that only uses the stored-procedures to implement the business logic in database.
Which of the following are the scopes defined in spring?
What scopes are available in struts?
Struts framework follows
What is an aspect?