in Education by
By default Spring framework creates all the beans as singletons. Isn't this contradicting with basic Object Oriented Programing concept of creating multiple object instances based on a template (class). JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
Well, if you really think about it, spring does make some practices of OOP really hard/impossible, say: return new Cached(new ImageLoader("cat.png")).load(); or return new Parrarel(new ImageLoader("cat.png"), new ImageLoader("dog.png")).load(); It's really hard (don't know if even possible) in spring (and most DI frameworks in general).

Related questions

0 votes
    How to get the object of DAO in spring framework? A. Using Spring Dependency injection B. Using new keyword...
asked Nov 8, 2022 in Education by JackTerrance
0 votes
    Functional programming language cannot be an object oriented language too 1. True 2. False...
asked Mar 7, 2023 in Technology by JackTerrance
0 votes
    What is Object-Oriented Programming?...
asked Feb 8, 2023 in Technology by JackTerrance
0 votes
    What is structure analysis briefly explain how the inheritance feature of object oriented programming helps in code reuse? Select the correct answer from above options...
asked Dec 21, 2021 in Education by JackTerrance
0 votes
    Is Swift an object-oriented programming language?...
asked Nov 30, 2020 in Technology by JackTerrance
0 votes
    What is the difference between an object-oriented programming language and object-based programming language?...
asked Nov 17, 2020 in Education by Editorial Staff
+1 vote
    What is default scope of bean in Spring framework? A - singleton B - prototype C - request D - session...
asked Oct 14, 2020 in Technology by JackTerrance
0 votes
    I've been using some basic AOP style solutions for cross-cutting concerns like security, logging, validation ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 29, 2022 in Education by JackTerrance
0 votes
    Python is a Procedure Oriented Programming Language true or false Select the correct answer from above options...
asked Dec 6, 2021 in Education by JackTerrance
0 votes
    Python is a Procedure Oriented Programming Language true or false Select the correct answer from above options...
asked Dec 5, 2021 in Education by JackTerrance
0 votes
    in procedure oriented programming,the global data is loosely attached to the __ Select the correct answer from above options...
asked Nov 26, 2021 in Education by JackTerrance
0 votes
    Python is a Procedure Oriented Programming Language true or false Select the correct answer from above options...
asked Nov 26, 2021 in Education by JackTerrance
0 votes
    What is Aspect oriented programming(AOP)?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    I'm just curious if any project exists that attempts to group all (or most) of PHP's built-in ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 27, 2022 in Education by JackTerrance
0 votes
    What is the potential abuse of object oriented design araises? Select the correct answer from above options...
asked Dec 21, 2021 in Education by JackTerrance
...