Object-oriented Programming (OOP) / Event-Driven Programming (EDP) versus Procedural Programming (PP)

Object-orientedProgramming (OOP) / Event-Driven Programming (EDP) versus ProceduralProgramming (PP)

Object-orientedProgramming (OOP) / Event-Driven Programming (EDP) versus ProceduralProgramming (PP)

  1. Identify at least two (2) advantages to using OOP as compared to using only PP.

Object-orientedProgramming (OOP) is a programming language which develops models byusing intellection (in the form of classes and objects) based on thereal world environment. An application that is object-oriented usesan assortment of objects to pass, receive, and request massages andprocess data into information. The main objective of object-orientedprogramming is to maximize not only programs’ reusability butmaintainability of programs as well. On other hand, event drivenprogramming is a very efficient and easier method of permittingprograms to counter to numerous events or inputs. It is worth notingthat, unlike the previous old programming methods, where the controlflow is under the program structure, when comes to event drivenprogramming (EDP), the control flow is mainly determined by externalevents. In general, as noted by Eliason (2013), events loops arepre-programmed in order to incessantly search for information toprocess. When comes to event driven programming handling features,they are in diverse languages, such as visual basic for applicationand visual basic as well as other systems. Whenit comes to ProceduralProgramming (PP), it programming paradigm is normally based upon thenotion of the ‘procedure call’. This means that, it rotatesaround, thereby upholding code as concise as possible. In addition,it focuses on a given task in order to complete a mission. It isworth noting that, a given programming steps have to be adhered inorder to obtain the desired result. At this juncture, the code can besaid to have been written as per the procedural programming (Eliason,2013).

Programmingbased on Object-oriented module has quite a number of advantages overother types of programming [ CITATION Ken13 l 1033 ].This programming language is easy to maintain as well as adapt thecurrent code as new objects are created receiving physiognomies fromexisting objects [ CITATION Ken13 l 1033 ].This reduces the time used for development in a considerable way andmakes adjustment of the program much easier. On the other hand,procedural programming takes on applications by tackling problemsfrom the top of the code to its bottom (Top Down Design). Thisapplication has been at times referred to as inline programming. Theone advantage of using object-Oriented Programming is that it usesclasses and objects whereas Procedural Programming takes a program inform of a problem to break it up into sub-procedures. Thesesub-procedures are continually broken down through functionaldecomposition. The application does so until the problem is simpleenough to be solved. This takes too much time and adjustment ofprograms is not easy [ CITATION Ken13 l 1033 ].Thesecond advantage of using OOP as compared to using only PP is thatObject-Oriented Programming (OOP) offers a clear structure forsoftware components which makes it good for central abstract datatypes where application details are concealed, and the unit has aclearly defined interface that can be used for developing GUI(Graphical User Interfaces) [ CITATION Jem00 l 1033 ].Inobject oriented programming, the core components in a program areclasses, and not procedures. The object-oriented approach lets youcreate classes and objects that model real world objects.

  1. Create one (1) original example of a class with at least one (1) attribute and one (1) method. Identify what the class in question represents, the attributes the class stores, and the purpose of the related method. Next, examine the relationship between the class, attributes, and methods that you have identified.

Aclass can be defined as an assortment of objects that have mutual orcommon procedures, properties as well as activities or behaviors. Itis made up of data and methods. Objects are formed or created fromclasses’ models (Eliason, 2013). For instance, I may design a classwild animal, which is a collection of all wild animals in the world.Animals have state, such as color, height as well as weight. They aswell have behavior, such as squatting, crawling, walking, flying andeating. All of the state and behavior of a wild animal isencapsulated within the class wild animals. This class wild animalhas a string behavior to represent the wild animal’s mode ofmovement. The operations associated with a class, together with theattributes of a class are encapsulated within the class. Theseoperations are referred to as the methods of a class.

  1. Describe at least one (1) feature of object-oriented programming that Visual Logic lacks.

Itis worth noting that, Object-oriented programming (OOP) has quite anumber of features that other applications lack. The most importantfeature of Object-oriented programming (OOP) is that it is proceduralas well as objects oriented nature [ CITATION Ken13 l 1033 ].Visual logic does not have this feature thus making Object-orientedprogramming (OOP) different from VisualLogic.

  1. Identify at least one (1) advantage to using event-driven programming, as compared to using purely procedural programming.

Itis worth noting that, one of the primary advantages of event-drivenprogramming, compared to using purely procedural programming isflexibility. Since the flow of the application is observed byoccurrences rather than procedural program, it is not a must for userto be conventional to the programmer’s understanding of the waytasks ought to be undertaken (Simon,1999).

References

Eliason, K. (2013, August 1). neon brand. Retrieved from neon brand web site: https://neonbrand.com/website-design/procedural-programming-vs-object-oriented-programming-a-review/

Jemmy, W. E. (2000, May 5). Bilkent Education. Retrieved from Bilkent Education web site: http://www.ctp.bilkent.edu.tr/~russell/java/LectureNotes/1_OOConcepts.htm

Simon,TH. (1999). TheCraft of Functional Programming.Second Edition, Addison Wesley Longman Limited.